diff --git a/packages/google-cloud-datacatalog/README.md b/packages/google-cloud-datacatalog/README.md index 549713e137f..4028e746e59 100644 --- a/packages/google-cloud-datacatalog/README.md +++ b/packages/google-cloud-datacatalog/README.md @@ -231,12 +231,14 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/ | Data_catalog.get_entry_group | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_entry_group.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_entry_group.js,samples/README.md) | | Data_catalog.get_iam_policy | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_iam_policy.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_iam_policy.js,samples/README.md) | | Data_catalog.get_tag_template | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_tag_template.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.get_tag_template.js,samples/README.md) | +| Data_catalog.import_entries | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js,samples/README.md) | | Data_catalog.list_entries | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_entries.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_entries.js,samples/README.md) | | Data_catalog.list_entry_groups | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_entry_groups.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_entry_groups.js,samples/README.md) | | Data_catalog.list_tags | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_tags.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_tags.js,samples/README.md) | | Data_catalog.lookup_entry | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.lookup_entry.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.lookup_entry.js,samples/README.md) | | Data_catalog.modify_entry_contacts | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.modify_entry_contacts.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.modify_entry_contacts.js,samples/README.md) | | Data_catalog.modify_entry_overview | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.modify_entry_overview.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.modify_entry_overview.js,samples/README.md) | +| Data_catalog.reconcile_tags | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js,samples/README.md) | | Data_catalog.rename_tag_template_field | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js,samples/README.md) | | Data_catalog.rename_tag_template_field_enum_value | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js,samples/README.md) | | Data_catalog.search_catalog | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js,samples/README.md) | diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/common.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/common.proto index 11483e32f3d..9b7c1fd6ab9 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/common.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/common.proto @@ -51,4 +51,23 @@ enum IntegratedSystem { // Dataplex. DATAPLEX = 4; + + // Cloud Sql + CLOUD_SQL = 8; + + // Looker + LOOKER = 9; +} + +// This enum describes all the systems that manage +// Taxonomy and PolicyTag resources in DataCatalog. +enum ManagingSystem { + // Default value + MANAGING_SYSTEM_UNSPECIFIED = 0; + + // Dataplex. + MANAGING_SYSTEM_DATAPLEX = 1; + + // Other + MANAGING_SYSTEM_OTHER = 2; } diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/datacatalog.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/datacatalog.proto index 7c03a04d81c..e91da18d21b 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/datacatalog.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/datacatalog.proto @@ -33,8 +33,10 @@ import "google/cloud/datacatalog/v1/timestamps.proto"; import "google/cloud/datacatalog/v1/usage.proto"; import "google/iam/v1/iam_policy.proto"; import "google/iam/v1/policy.proto"; +import "google/longrunning/operations.proto"; import "google/protobuf/empty.proto"; import "google/protobuf/field_mask.proto"; +import "google/rpc/status.proto"; option cc_enable_arenas = true; option csharp_namespace = "Google.Cloud.DataCatalog.V1"; @@ -52,7 +54,8 @@ option (google.api.resource_definition) = { // your data. service DataCatalog { option (google.api.default_host) = "datacatalog.googleapis.com"; - option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; // Searches Data Catalog for multiple resources like entries and tags that // match a query. @@ -142,7 +145,8 @@ service DataCatalog { // identified by the `name` parameter. For more information, see [Data Catalog // resource // project](https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc DeleteEntryGroup(DeleteEntryGroupRequest) returns (google.protobuf.Empty) { + rpc DeleteEntryGroup(DeleteEntryGroupRequest) + returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1/{name=projects/*/locations/*/entryGroups/*}" }; @@ -150,7 +154,8 @@ service DataCatalog { } // Lists entry groups. - rpc ListEntryGroups(ListEntryGroupsRequest) returns (ListEntryGroupsResponse) { + rpc ListEntryGroups(ListEntryGroupsRequest) + returns (ListEntryGroupsResponse) { option (google.api.http) = { get: "/v1/{parent=projects/*/locations/*}/entryGroups" }; @@ -272,7 +277,8 @@ service DataCatalog { post: "/v1/{parent=projects/*/locations/*}/tagTemplates" body: "tag_template" }; - option (google.api.method_signature) = "parent,tag_template_id,tag_template"; + option (google.api.method_signature) = + "parent,tag_template_id,tag_template"; } // Gets a tag template. @@ -306,7 +312,8 @@ service DataCatalog { // You must enable the Data Catalog API in the project identified by // the `name` parameter. For more information, see [Data Catalog resource // project](https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc DeleteTagTemplate(DeleteTagTemplateRequest) returns (google.protobuf.Empty) { + rpc DeleteTagTemplate(DeleteTagTemplateRequest) + returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1/{name=projects/*/locations/*/tagTemplates/*}" }; @@ -318,12 +325,14 @@ service DataCatalog { // You must enable the Data Catalog API in the project identified by // the `parent` parameter. For more information, see [Data Catalog resource // project](https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc CreateTagTemplateField(CreateTagTemplateFieldRequest) returns (TagTemplateField) { + rpc CreateTagTemplateField(CreateTagTemplateFieldRequest) + returns (TagTemplateField) { option (google.api.http) = { post: "/v1/{parent=projects/*/locations/*/tagTemplates/*}/fields" body: "tag_template_field" }; - option (google.api.method_signature) = "parent,tag_template_field_id,tag_template_field"; + option (google.api.method_signature) = + "parent,tag_template_field_id,tag_template_field"; } // Updates a field in a tag template. @@ -334,13 +343,15 @@ service DataCatalog { // identified by the `name` parameter. For more information, see [Data Catalog // resource // project](https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc UpdateTagTemplateField(UpdateTagTemplateFieldRequest) returns (TagTemplateField) { + rpc UpdateTagTemplateField(UpdateTagTemplateFieldRequest) + returns (TagTemplateField) { option (google.api.http) = { patch: "/v1/{name=projects/*/locations/*/tagTemplates/*/fields/*}" body: "tag_template_field" }; option (google.api.method_signature) = "name,tag_template_field"; - option (google.api.method_signature) = "name,tag_template_field,update_mask"; + option (google.api.method_signature) = + "name,tag_template_field,update_mask"; } // Renames a field in a tag template. @@ -348,7 +359,8 @@ service DataCatalog { // You must enable the Data Catalog API in the project identified by the // `name` parameter. For more information, see [Data Catalog resource project] // (https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc RenameTagTemplateField(RenameTagTemplateFieldRequest) returns (TagTemplateField) { + rpc RenameTagTemplateField(RenameTagTemplateFieldRequest) + returns (TagTemplateField) { option (google.api.http) = { post: "/v1/{name=projects/*/locations/*/tagTemplates/*/fields/*}:rename" body: "*" @@ -359,7 +371,8 @@ service DataCatalog { // Renames an enum value in a tag template. // // Within a single enum field, enum values must be unique. - rpc RenameTagTemplateFieldEnumValue(RenameTagTemplateFieldEnumValueRequest) returns (TagTemplateField) { + rpc RenameTagTemplateFieldEnumValue(RenameTagTemplateFieldEnumValueRequest) + returns (TagTemplateField) { option (google.api.http) = { post: "/v1/{name=projects/*/locations/*/tagTemplates/*/fields/*/enumValues/*}:rename" body: "*" @@ -373,7 +386,8 @@ service DataCatalog { // You must enable the Data Catalog API in the project identified by // the `name` parameter. For more information, see [Data Catalog resource // project](https://cloud.google.com/data-catalog/docs/concepts/resource-project). - rpc DeleteTagTemplateField(DeleteTagTemplateFieldRequest) returns (google.protobuf.Empty) { + rpc DeleteTagTemplateField(DeleteTagTemplateFieldRequest) + returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1/{name=projects/*/locations/*/tagTemplates/*/fields/*}" }; @@ -442,6 +456,31 @@ service DataCatalog { option (google.api.method_signature) = "parent"; } + // `ReconcileTags` creates or updates a list of tags on the entry. + // If the + // [ReconcileTagsRequest.force_delete_missing][google.cloud.datacatalog.v1.ReconcileTagsRequest.force_delete_missing] + // parameter is set, the operation deletes tags not included in the input tag + // list. + // + // `ReconcileTags` returns a [long-running operation] + // [google.longrunning.Operation] resource that can be queried with + // [Operations.GetOperation][google.longrunning.Operations.GetOperation] + // to return [ReconcileTagsMetadata] + // [google.cloud.datacatalog.v1.ReconcileTagsMetadata] and + // a [ReconcileTagsResponse] + // [google.cloud.datacatalog.v1.ReconcileTagsResponse] message. + rpc ReconcileTags(ReconcileTagsRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/entryGroups/*/entries/*}/tags:reconcile" + body: "*" + }; + option (google.longrunning.operation_info) = { + response_type: "ReconcileTagsResponse" + metadata_type: "ReconcileTagsMetadata" + }; + } + // Marks an [Entry][google.cloud.datacatalog.v1.Entry] as starred by // the current user. Starring information is private to each user. rpc StarEntry(StarEntryRequest) returns (StarEntryResponse) { @@ -479,7 +518,8 @@ service DataCatalog { // - `datacatalog.tagTemplates.setIamPolicy` to set policies on tag // templates. // - `datacatalog.entryGroups.setIamPolicy` to set policies on entry groups. - rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) returns (google.iam.v1.Policy) { + rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) + returns (google.iam.v1.Policy) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/tagTemplates/*}:setIamPolicy" body: "*" @@ -512,7 +552,8 @@ service DataCatalog { // - `datacatalog.tagTemplates.getIamPolicy` to get policies on tag // templates. // - `datacatalog.entryGroups.getIamPolicy` to get policies on entry groups. - rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) returns (google.iam.v1.Policy) { + rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) + returns (google.iam.v1.Policy) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/tagTemplates/*}:getIamPolicy" body: "*" @@ -542,7 +583,8 @@ service DataCatalog { // external Google Cloud Platform resources ingested into Data Catalog. // // No Google IAM permissions are required to call this method. - rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) returns (google.iam.v1.TestIamPermissionsResponse) { + rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) + returns (google.iam.v1.TestIamPermissionsResponse) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/tagTemplates/*}:testIamPermissions" body: "*" @@ -556,6 +598,36 @@ service DataCatalog { } }; } + + // Imports entries from a source, such as data previously dumped into a + // Cloud Storage bucket, into Data Catalog. Import of entries + // is a sync operation that reconciles the state of the third-party system + // with the Data Catalog. + // + // `ImportEntries` accepts source data snapshots of a third-party system. + // Snapshot should be delivered as a .wire or base65-encoded .txt file + // containing a sequence of Protocol Buffer messages of + // [DumpItem][google.cloud.datacatalog.v1.DumpItem] type. + // + // `ImportEntries` returns a [long-running operation] + // [google.longrunning.Operation] resource that can be queried with + // [Operations.GetOperation][google.longrunning.Operations.GetOperation] + // to return + // [ImportEntriesMetadata][google.cloud.datacatalog.v1.ImportEntriesMetadata] + // and an + // [ImportEntriesResponse][google.cloud.datacatalog.v1.ImportEntriesResponse] + // message. + rpc ImportEntries(ImportEntriesRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/entryGroups/*}/entries:import" + body: "*" + }; + option (google.longrunning.operation_info) = { + response_type: "ImportEntriesResponse" + metadata_type: "ImportEntriesMetadata" + }; + } } // Request message for @@ -576,15 +648,15 @@ message SearchCatalogRequest { // numbers, see [Projects](/docs/overview/#projects). repeated string include_project_ids = 3; - // If `true`, include Google Cloud Platform (GCP) public datasets in + // If `true`, include Google Cloud public datasets in // search results. By default, they are excluded. // // See [Google Cloud Public Datasets](/public-datasets) for more // information. bool include_gcp_public_datasets = 7; - // Optional. The list of locations to search within. If empty, all locations are - // searched. + // Optional. The list of locations to search within. If empty, all locations + // are searched. // // Returns an error if any location in the list isn't one of the [Supported // regions](https://cloud.google.com/data-catalog/docs/concepts/regions#supported_regions). @@ -593,19 +665,18 @@ message SearchCatalogRequest { // `SearchCatalogResponse.unreachable` field. To get additional information // on the error, repeat the search request and set the location name as the // value of this parameter. - repeated string restricted_locations = 16 [(google.api.field_behavior) = OPTIONAL]; + repeated string restricted_locations = 16 + [(google.api.field_behavior) = OPTIONAL]; // Optional. If `true`, search only among starred entries. // // By default, all results are returned, starred or not. bool starred_only = 18 [(google.api.field_behavior) = OPTIONAL]; - // Optional. This field is deprecated. The search mechanism for public and private tag - // templates is the same. - bool include_public_tag_templates = 19 [ - deprecated = true, - (google.api.field_behavior) = OPTIONAL - ]; + // Optional. This field is deprecated. The search mechanism for public and + // private tag templates is the same. + bool include_public_tag_templates = 19 + [deprecated = true, (google.api.field_behavior) = OPTIONAL]; } // Required. The scope of this search request. @@ -615,9 +686,8 @@ message SearchCatalogRequest { // the request returns an error. Scope scope = 6 [(google.api.field_behavior) = REQUIRED]; - // Optional. The query string with a minimum of 3 characters and specific syntax. - // For more information, see - // [Data Catalog search + // Optional. The query string with a minimum of 3 characters and specific + // syntax. For more information, see [Data Catalog search // syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference). // // An empty query string returns all data assets (in the specified scope) @@ -637,10 +707,11 @@ message SearchCatalogRequest { // exception. int32 page_size = 2; - // Optional. Pagination token that, if specified, returns the next page of search - // results. If empty, returns the first page. + // Optional. Pagination token that, if specified, returns the next page of + // search results. If empty, returns the first page. // - // This token is returned in the [SearchCatalogResponse.next_page_token][google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token] + // This token is returned in the + // [SearchCatalogResponse.next_page_token][google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token] // field of the response to a previous // [SearchCatalogRequest][google.cloud.datacatalog.v1.DataCatalog.SearchCatalog] // call. @@ -680,7 +751,8 @@ message SearchCatalogResponse { // Request message for // [CreateEntryGroup][google.cloud.datacatalog.v1.DataCatalog.CreateEntryGroup]. message CreateEntryGroupRequest { - // Required. The names of the project and location that the new entry group belongs to. + // Required. The names of the project and location that the new entry group + // belongs to. // // Note: The entry group itself and its child resources might not be // stored in the location specified in its name. @@ -1015,7 +1087,8 @@ message Entry { oneof system { // Output only. Indicates the entry's source system that Data Catalog // integrates with, such as BigQuery, Pub/Sub, or Dataproc Metastore. - IntegratedSystem integrated_system = 17 [(google.api.field_behavior) = OUTPUT_ONLY]; + IntegratedSystem integrated_system = 17 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Indicates the entry's source system that Data Catalog doesn't // automatically integrate with. @@ -1029,6 +1102,19 @@ message Entry { string user_specified_system = 18; } + // System specification. + // Can be used as a complement for `spec`, when some metadata is relevant for + // all entries existing within given system + oneof system_spec { + // Specification that applies to a relational database system. Only settable + // when `user_specified_system` is equal to `SQL_DATABASE` + SqlDatabaseSystemSpec sql_database_system_spec = 39; + + // Specification that applies to Looker sysstem. Only settable when + // `user_specified_system` is equal to `LOOKER` + LookerSystemSpec looker_system_spec = 40; + } + // Type specification. oneof type_spec { // Specification that applies to a Cloud Storage fileset. Valid only @@ -1037,14 +1123,16 @@ message Entry { // Output only. Specification that applies to a BigQuery table. Valid only // for entries with the `TABLE` type. - BigQueryTableSpec bigquery_table_spec = 12 [(google.api.field_behavior) = OUTPUT_ONLY]; + BigQueryTableSpec bigquery_table_spec = 12 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. Specification for a group of BigQuery tables with // the `[prefix]YYYYMMDD` name pattern. // // For more information, see [Introduction to partitioned tables] // (https://cloud.google.com/bigquery/docs/partitioned-tables#partitioning_versus_sharding). - BigQueryDateShardedSpec bigquery_date_sharded_spec = 15 [(google.api.field_behavior) = OUTPUT_ONLY]; + BigQueryDateShardedSpec bigquery_date_sharded_spec = 15 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Type- and system-specific information. Specifications for types contain @@ -1055,7 +1143,7 @@ message Entry { // of the legacy `type_spec`. oneof spec { // Specification that applies to a table resource. Valid only - // for entries with the `TABLE` type. + // for entries with the `TABLE` or `EXPLORE` type. DatabaseTableSpec database_table_spec = 24; // Specification that applies to a data source connection. Valid only @@ -1073,9 +1161,7 @@ message Entry { // Display name of an entry. // - // The name must contain only Unicode letters, numbers (0-9), underscores (_), - // dashes (-), spaces ( ), and can't start or end with spaces. - // The maximum size is 200 bytes when encoded in UTF-8. + // The maximum size is 500 bytes when encoded in UTF-8. // Default value is an empty string. string display_name = 3; @@ -1116,8 +1202,10 @@ message Entry { // Output only. Physical location of the entry. DataSource data_source = 20 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Output only. Additional information related to the entry. Private to the current user. - PersonalDetails personal_details = 26 [(google.api.field_behavior) = OUTPUT_ONLY]; + // Output only. Additional information related to the entry. Private to the + // current user. + PersonalDetails personal_details = 26 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Specification that applies to a table resource. Valid only @@ -1135,12 +1223,44 @@ message DatabaseTableSpec { EXTERNAL = 2; } + // Specification that applies to database view. + message DatabaseViewSpec { + // Concrete type of the view. + enum ViewType { + // Default unknown view type. + VIEW_TYPE_UNSPECIFIED = 0; + + // Standard view. + STANDARD_VIEW = 1; + + // Materialized view. + MATERIALIZED_VIEW = 2; + } + + // Type of this view. + ViewType view_type = 1; + + // Definition of the view. + oneof source_definition { + // Name of a singular table this view reflects one to one. + string base_table = 2; + + // SQL query used to generate this view. + string sql_query = 3; + } + } + // Type of this table. TableType type = 1; // Output only. Fields specific to a Dataplex table and present only in the // Dataplex table entries. - DataplexTableSpec dataplex_table = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + DataplexTableSpec dataplex_table = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Spec what aplies to tables that are actually views. + // Not set for "real" tables. + DatabaseViewSpec database_view_spec = 3; } // Specification that applies to a fileset. Valid only for entries with the @@ -1231,6 +1351,59 @@ message RoutineSpec { } } +// Specification that applies to +// entries that are part `SQL_DATABASE` system +// (user_specified_type) +message SqlDatabaseSystemSpec { + // SQL Database Engine. + // enum SqlEngine { + // UNDEFINED = 0; + // MY_SQL = 1; + // POSTGRE_SQL = 2; + // SQL_SERVER = 3; + // } + // Engine of the enclosing database instance. + string sql_engine = 1; + + // Version of the database engine. + string database_version = 2; + + // Host of the SQL database + // enum InstanceHost { + // UNDEFINED = 0; + // SELF_HOSTED = 1; + // CLOUD_SQL = 2; + // AMAZON_RDS = 3; + // AZURE_SQL = 4; + // } + // Host of the enclousing database instance. + string instance_host = 3; +} + +// Specification that applies to +// entries that are part `LOOKER` system +// (user_specified_type) +message LookerSystemSpec { + // ID of the parent Looker Instance. Empty if it does not exist. + // Example value: `someinstance.looker.com` + string parent_instance_id = 1; + + // Name of the parent Looker Instance. Empty if it does not exist. + string parent_instance_display_name = 2; + + // ID of the parent Model. Empty if it does not exist. + string parent_model_id = 3; + + // Name of the parent Model. Empty if it does not exist. + string parent_model_display_name = 4; + + // ID of the parent View. Empty if it does not exist. + string parent_view_id = 5; + + // Name of the parent View. Empty if it does not exist. + string parent_view_display_name = 6; +} + // Business Context of the entry. message BusinessContext { // Entry overview fields for rich text descriptions of entries. @@ -1294,7 +1467,8 @@ message EntryGroup { string description = 3; // Output only. Timestamps of the entry group. Default value is empty. - SystemTimestamps data_catalog_timestamps = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + SystemTimestamps data_catalog_timestamps = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Request message for @@ -1438,7 +1612,8 @@ message CreateTagTemplateFieldRequest { string tag_template_field_id = 2 [(google.api.field_behavior) = REQUIRED]; // Required. The tag template field to create. - TagTemplateField tag_template_field = 3 [(google.api.field_behavior) = REQUIRED]; + TagTemplateField tag_template_field = 3 + [(google.api.field_behavior) = REQUIRED]; } // Request message for @@ -1453,10 +1628,11 @@ message UpdateTagTemplateFieldRequest { ]; // Required. The template to update. - TagTemplateField tag_template_field = 2 [(google.api.field_behavior) = REQUIRED]; + TagTemplateField tag_template_field = 2 + [(google.api.field_behavior) = REQUIRED]; - // Optional. Names of fields whose values to overwrite on an individual field of a tag - // template. The following fields are modifiable: + // Optional. Names of fields whose values to overwrite on an individual field + // of a tag template. The following fields are modifiable: // // * `display_name` // * `type.enum_type` @@ -1471,7 +1647,8 @@ message UpdateTagTemplateFieldRequest { // // Additionally, updating a template field from optional to required is // *not* allowed. - google.protobuf.FieldMask update_mask = 3 [(google.api.field_behavior) = OPTIONAL]; + google.protobuf.FieldMask update_mask = 3 + [(google.api.field_behavior) = OPTIONAL]; } // Request message for @@ -1485,7 +1662,8 @@ message RenameTagTemplateFieldRequest { } ]; - // Required. The new ID of this tag template field. For example, `my_new_field`. + // Required. The new ID of this tag template field. For example, + // `my_new_field`. string new_tag_template_field_id = 2 [(google.api.field_behavior) = REQUIRED]; } @@ -1500,8 +1678,10 @@ message RenameTagTemplateFieldEnumValueRequest { } ]; - // Required. The new display name of the enum value. For example, `my_new_enum_value`. - string new_enum_value_display_name = 2 [(google.api.field_behavior) = REQUIRED]; + // Required. The new display name of the enum value. For example, + // `my_new_enum_value`. + string new_enum_value_display_name = 2 + [(google.api.field_behavior) = REQUIRED]; } // Request message for @@ -1555,6 +1735,78 @@ message ListTagsResponse { string next_page_token = 2; } +// Request message for +// [ReconcileTags][google.cloud.datacatalog.v1.DataCatalog.ReconcileTags]. +message ReconcileTagsRequest { + // Required. Name of [Entry][google.cloud.datacatalog.v1.Entry] to be tagged. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "datacatalog.googleapis.com/Entry" + } + ]; + + // Required. The name of the tag template, which is used for reconciliation. + string tag_template = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "datacatalog.googleapis.com/TagTemplate" + } + ]; + + // If set to `true`, deletes entry tags related to a tag template + // not listed in the tags source from an entry. If set to `false`, + // unlisted tags are retained. + bool force_delete_missing = 3; + + // A list of tags to apply to an entry. A tag can specify a + // tag template, which must be the template specified in the + // `ReconcileTagsRequest`. + // The sole entry and each of its columns must be mentioned at most once. + repeated Tag tags = 4; +} + +// [Long-running operation][google.longrunning.Operation] +// response message returned by +// [ReconcileTags][google.cloud.datacatalog.v1.DataCatalog.ReconcileTags]. +message ReconcileTagsResponse { + // Number of tags created in the request. + int64 created_tags_count = 1; + + // Number of tags updated in the request. + int64 updated_tags_count = 2; + + // Number of tags deleted in the request. + int64 deleted_tags_count = 3; +} + +// [Long-running operation][google.longrunning.Operation] +// metadata message returned by the +// [ReconcileTags][google.cloud.datacatalog.v1.DataCatalog.ReconcileTags]. +message ReconcileTagsMetadata { + // Enum holding possible states of the reconciliation operation. + enum ReconciliationState { + // Default value. This value is unused. + RECONCILIATION_STATE_UNSPECIFIED = 0; + + // The reconciliation has been queued and awaits for execution. + RECONCILIATION_QUEUED = 1; + + // The reconciliation is in progress. + RECONCILIATION_IN_PROGRESS = 2; + + // The reconciliation has been finished. + RECONCILIATION_DONE = 3; + } + + // State of the reconciliation operation. + ReconciliationState state = 1; + + // Maps the name of each tagged column (or empty string for a + // sole entry) to tagging operation [status][google.rpc.Status]. + map errors = 2; +} + // Request message for // [ListEntries][google.cloud.datacatalog.v1.DataCatalog.ListEntries]. message ListEntriesRequest { @@ -1610,9 +1862,7 @@ message StarEntryRequest { // Response message for // [StarEntry][google.cloud.datacatalog.v1.DataCatalog.StarEntry]. // Empty for now -message StarEntryResponse { - -} +message StarEntryResponse {} // Request message for // [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. @@ -1629,8 +1879,69 @@ message UnstarEntryRequest { // Response message for // [UnstarEntry][google.cloud.datacatalog.v1.DataCatalog.UnstarEntry]. // Empty for now -message UnstarEntryResponse { +message UnstarEntryResponse {} +// Request message for +// [ImportEntries][google.cloud.datacatalog.v1.DataCatalog.ImportEntries] +// method. +message ImportEntriesRequest { + // Required. Target entry group for ingested entries. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "datacatalog.googleapis.com/Entry" + } + ]; + + // Source of imported entries, e.g. dump stored in a Cloud Storage + oneof source { + // Path to a Cloud Storage bucket that contains a dump ready for ingestion. + string gcs_bucket_path = 2; + } +} + +// Response message for [long-running operation][google.longrunning.Operation] +// returned by the +// [ImportEntries][google.cloud.datacatalog.v1.DataCatalog.ImportEntries]. +message ImportEntriesResponse { + // Cumulative number of entries created and entries updated as a result of + // import operation. + optional int64 upserted_entries_count = 5; + + // Number of entries deleted as a result of import operation. + optional int64 deleted_entries_count = 6; +} + +// Metadata message for [long-running operation][google.longrunning.Operation] +// returned by the +// [ImportEntries][google.cloud.datacatalog.v1.DataCatalog.ImportEntries]. +message ImportEntriesMetadata { + // Enum holding possible states of the import operation. + enum ImportState { + // Default value. This value is unused. + IMPORT_STATE_UNSPECIFIED = 0; + + // The dump with entries has been queued for import. + IMPORT_QUEUED = 1; + + // The import of entries is in progress. + IMPORT_IN_PROGRESS = 2; + + // The import of entries has been finished. + IMPORT_DONE = 3; + + // The import of entries has been abandoned in favor of a newer request. + IMPORT_OBSOLETE = 4; + } + + // State of the import operation. + ImportState state = 1; + + // Partial errors that are encountered during the ImportEntries operation. + // There is no guarantee that all the encountered errors are reported. + // However, if no errors are reported, it means that no errors were + // encountered. + repeated google.rpc.Status errors = 2; } // Request message for @@ -1707,4 +2018,22 @@ enum EntryType { // A service, for example, a Dataproc Metastore service. SERVICE = 14; + + // Schema within a relational database. + DATABASE_SCHEMA = 15; + + // A Dashboard, for example from Looker. + DASHBOARD = 16; + + // A Looker Explore. + // + // For more information, see [Looker Explore API] + // (https://developers.looker.com/api/explorer/4.0/methods/LookmlModel/lookml_model_explore). + EXPLORE = 17; + + // A Looker Look. + // + // For more information, see [Looker Look API] + // (https://developers.looker.com/api/explorer/4.0/methods/Look). + LOOK = 18; } diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/dump_content.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/dump_content.proto new file mode 100644 index 00000000000..846877c5ca7 --- /dev/null +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/dump_content.proto @@ -0,0 +1,54 @@ +// Copyright 2022 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. + +syntax = "proto3"; + +package google.cloud.datacatalog.v1; + +import "google/cloud/datacatalog/v1/datacatalog.proto"; +import "google/cloud/datacatalog/v1/tags.proto"; + +option cc_enable_arenas = true; +option csharp_namespace = "Google.Cloud.DataCatalog.V1"; +option go_package = "cloud.google.com/go/datacatalog/apiv1/datacatalogpb;datacatalogpb"; +option java_multiple_files = true; +option java_outer_classname = "DumpContentProto"; +option java_package = "com.google.cloud.datacatalog.v1"; +option php_namespace = "Google\\Cloud\\DataCatalog\\V1"; +option ruby_package = "Google::Cloud::DataCatalog::V1"; + +// Wrapper containing Entry and information about Tags +// that should and should not be attached to it. +message TaggedEntry { + oneof entry { + // Non-encrypted Data Catalog v1 Entry. + Entry v1_entry = 1; + } + + // Tags that should be ingested into the Data Catalog. + // Caller should populate template name, column and fields. + repeated Tag present_tags = 2; + + // Tags that should be deleted from the Data Catalog. + // Caller should populate template name and column only. + repeated Tag absent_tags = 3; +} + +// Wrapper for any item that can be contained in the dump. +message DumpItem { + oneof item { + // Entry and its tags. + TaggedEntry tagged_entry = 1; + } +} diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto index 56d9f4d6ed0..5f6d8f62dea 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto @@ -62,7 +62,8 @@ message GcsFilesetSpec { // Output only. Sample files contained in this fileset, not all files // contained in this fileset are represented here. - repeated GcsFileSpec sample_gcs_file_specs = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + repeated GcsFileSpec sample_gcs_file_specs = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Specification of a single file in Cloud Storage. @@ -70,8 +71,10 @@ message GcsFileSpec { // Required. Full file path. Example: `gs://bucket_name/a/b.txt`. string file_path = 1 [(google.api.field_behavior) = REQUIRED]; - // Output only. Creation, modification, and expiration timestamps of a Cloud Storage file. - SystemTimestamps gcs_timestamps = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + // Output only. Creation, modification, and expiration timestamps of a Cloud + // Storage file. + SystemTimestamps gcs_timestamps = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. File size in bytes. int64 size_bytes = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/physical_schema.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/physical_schema.proto index 693cd60711f..162d7158680 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/physical_schema.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/physical_schema.proto @@ -47,19 +47,13 @@ message PhysicalSchema { } // Marks a Parquet-encoded data source. - message ParquetSchema { - - } + message ParquetSchema {} // Marks an ORC-encoded data source. - message OrcSchema { - - } + message OrcSchema {} // Marks a CSV-encoded data source. - message CsvSchema { - - } + message CsvSchema {} oneof schema { // Schema in Avro JSON format. diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanager.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanager.proto index 45a8489e5f3..3c13a62885f 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanager.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanager.proto @@ -20,6 +20,7 @@ import "google/api/annotations.proto"; import "google/api/client.proto"; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/cloud/datacatalog/v1/common.proto"; import "google/cloud/datacatalog/v1/timestamps.proto"; import "google/iam/v1/iam_policy.proto"; import "google/iam/v1/policy.proto"; @@ -43,7 +44,8 @@ option ruby_package = "Google::Cloud::DataCatalog::V1"; // classify data along a common axis. service PolicyTagManager { option (google.api.default_host) = "datacatalog.googleapis.com"; - option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; // Creates a taxonomy in a specified project. // @@ -142,7 +144,8 @@ service PolicyTagManager { } // Gets the IAM policy for a policy tag or a taxonomy. - rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) returns (google.iam.v1.Policy) { + rpc GetIamPolicy(google.iam.v1.GetIamPolicyRequest) + returns (google.iam.v1.Policy) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/taxonomies/*}:getIamPolicy" body: "*" @@ -154,7 +157,8 @@ service PolicyTagManager { } // Sets the IAM policy for a policy tag or a taxonomy. - rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) returns (google.iam.v1.Policy) { + rpc SetIamPolicy(google.iam.v1.SetIamPolicyRequest) + returns (google.iam.v1.Policy) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/taxonomies/*}:setIamPolicy" body: "*" @@ -167,7 +171,8 @@ service PolicyTagManager { // Returns your permissions on a specified policy tag or // taxonomy. - rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) returns (google.iam.v1.TestIamPermissionsResponse) { + rpc TestIamPermissions(google.iam.v1.TestIamPermissionsRequest) + returns (google.iam.v1.TestIamPermissionsResponse) { option (google.api.http) = { post: "/v1/{resource=projects/*/locations/*/taxonomies/*}:testIamPermissions" body: "*" @@ -219,6 +224,15 @@ message Taxonomy { FINE_GRAINED_ACCESS_CONTROL = 1; } + // The source system of the Taxonomy. + message Service { + // The Google Cloud service name. + ManagingSystem name = 1; + + // P4SA Identity of the service. + string identity = 2; + } + // Output only. Resource name of this taxonomy in URL format. // // Note: Policy tag manager generates unique taxonomy IDs. @@ -244,11 +258,18 @@ message Taxonomy { int32 policy_tag_count = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. Creation and modification timestamps of this taxonomy. - SystemTimestamps taxonomy_timestamps = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Optional. A list of policy types that are activated for this taxonomy. If not set, - // defaults to an empty list. - repeated PolicyType activated_policy_types = 6 [(google.api.field_behavior) = OPTIONAL]; + SystemTimestamps taxonomy_timestamps = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. A list of policy types that are activated for this taxonomy. If + // not set, defaults to an empty list. + repeated PolicyType activated_policy_types = 6 + [(google.api.field_behavior) = OPTIONAL]; + + // Output only. Identity of the service which owns the Taxonomy. This field is + // only populated when the taxonomy is created by a Google Cloud service. + // Currently only 'DATAPLEX' is supported. + Service service = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; } // Denotes one policy tag in a taxonomy, for example, SSN. @@ -297,7 +318,8 @@ message PolicyTag { string parent_policy_tag = 4; // Output only. Resource names of child policy tags of this policy tag. - repeated string child_policy_tags = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + repeated string child_policy_tags = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // Request message for @@ -364,6 +386,10 @@ message ListTaxonomiesRequest { // // The token is returned in the response to a previous list request. string page_token = 3; + + // Supported field for filter is 'service' and value is 'dataplex'. + // Eg: service=dataplex. + string filter = 4; } // Response message for diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanagerserialization.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanagerserialization.proto index 9d320b21f03..a0da69380c7 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanagerserialization.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/policytagmanagerserialization.proto @@ -37,7 +37,8 @@ option ruby_package = "Google::Cloud::DataCatalog::V1"; // Taxonomy is a hierarchical group of policy tags. service PolicyTagManagerSerialization { option (google.api.default_host) = "datacatalog.googleapis.com"; - option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; // Replaces (updates) a taxonomy and all its policy tags. // @@ -67,7 +68,8 @@ service PolicyTagManagerSerialization { // // For an inlined source, taxonomies and policy tags are created in bulk using // nested protocol buffer structures. - rpc ImportTaxonomies(ImportTaxonomiesRequest) returns (ImportTaxonomiesResponse) { + rpc ImportTaxonomies(ImportTaxonomiesRequest) + returns (ImportTaxonomiesResponse) { option (google.api.http) = { post: "/v1/{parent=projects/*/locations/*}/taxonomies:import" body: "*" @@ -80,7 +82,8 @@ service PolicyTagManagerSerialization { // // This method generates `SerializedTaxonomy` protocol buffers with nested // policy tags that can be used as input for `ImportTaxonomies` calls. - rpc ExportTaxonomies(ExportTaxonomiesRequest) returns (ExportTaxonomiesResponse) { + rpc ExportTaxonomies(ExportTaxonomiesRequest) + returns (ExportTaxonomiesResponse) { option (google.api.http) = { get: "/v1/{parent=projects/*/locations/*}/taxonomies:export" }; @@ -91,7 +94,8 @@ service PolicyTagManagerSerialization { // policy tags. Used for taxonomy replacement, import, and // export. message SerializedTaxonomy { - // Required. Display name of the taxonomy. At most 200 bytes when encoded in UTF-8. + // Required. Display name of the taxonomy. At most 200 bytes when encoded in + // UTF-8. string display_name = 1 [(google.api.field_behavior) = REQUIRED]; // Description of the serialized taxonomy. At most 2000 bytes when @@ -138,13 +142,15 @@ message ReplaceTaxonomyRequest { ]; // Required. Taxonomy to update along with its child policy tags. - SerializedTaxonomy serialized_taxonomy = 2 [(google.api.field_behavior) = REQUIRED]; + SerializedTaxonomy serialized_taxonomy = 2 + [(google.api.field_behavior) = REQUIRED]; } // Request message for // [ImportTaxonomies][google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ImportTaxonomies]. message ImportTaxonomiesRequest { - // Required. Resource name of project that the imported taxonomies will belong to. + // Required. Resource name of project that the imported taxonomies will belong + // to. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -165,7 +171,8 @@ message ImportTaxonomiesRequest { // Inline source containing taxonomies to import. message InlineSource { // Required. Taxonomies to import. - repeated SerializedTaxonomy taxonomies = 1 [(google.api.field_behavior) = REQUIRED]; + repeated SerializedTaxonomy taxonomies = 1 + [(google.api.field_behavior) = REQUIRED]; } // Cross-regional source used to import an existing taxonomy into a different @@ -190,7 +197,8 @@ message ImportTaxonomiesResponse { // Request message for // [ExportTaxonomies][google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ExportTaxonomies]. message ExportTaxonomiesRequest { - // Required. Resource name of the project that the exported taxonomies belong to. + // Required. Resource name of the project that the exported taxonomies belong + // to. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/schema.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/schema.proto index f5a1f81eb43..9d799d052fa 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/schema.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/schema.proto @@ -38,6 +38,51 @@ message Schema { // A column within a schema. Columns can be nested inside // other columns. message ColumnSchema { + // Specifies inclusion of the column in an index + enum IndexingType { + // Unspecified. + INDEXING_TYPE_UNSPECIFIED = 0; + + // Column not a part of an index. + INDEXING_TYPE_NONE = 1; + + // Column Part of non unique index. + INDEXING_TYPE_NON_UNIQUE = 2; + + // Column part of unique index. + INDEXING_TYPE_UNIQUE = 3; + + // Column part of the primary key. + INDEXING_TYPE_PRIMARY_KEY = 4; + } + + // Column info specific to Looker System. + message LookerColumnSpec { + // Column type in Looker. + enum LookerColumnType { + // Unspecified. + LOOKER_COLUMN_TYPE_UNSPECIFIED = 0; + + // Dimension. + DIMENSION = 1; + + // Dimension group - parent for Dimension. + DIMENSION_GROUP = 2; + + // Filter. + FILTER = 3; + + // Measure. + MEASURE = 4; + + // Parameter. + PARAMETER = 5; + } + + // Looker specific column type of this column. + LookerColumnType type = 1; + } + // Required. Name of the column. // // Must be a UTF-8 string without dots (.). @@ -55,13 +100,34 @@ message ColumnSchema { // bytes. string description = 2 [(google.api.field_behavior) = OPTIONAL]; - // Optional. A column's mode indicates whether values in this column are required, - // nullable, or repeated. + // Optional. A column's mode indicates whether values in this column are + // required, nullable, or repeated. // // Only `NULLABLE`, `REQUIRED`, and `REPEATED` values are supported. // Default mode is `NULLABLE`. string mode = 3 [(google.api.field_behavior) = OPTIONAL]; - // Optional. Schema of sub-columns. A column can have zero or more sub-columns. + // Optional. Default value for the column. + string default_value = 8 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Ordinal position + int32 ordinal_position = 9 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Most important inclusion of this column. + IndexingType highest_indexing_type = 10 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Schema of sub-columns. A column can have zero or more + // sub-columns. repeated ColumnSchema subcolumns = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Information only applying for columns in Entries from a specific system. + oneof system_spec { + // Looker specific column info of this column. + LookerColumnSpec looker_column_spec = 18; + } + + // Optional. Garbage collection policy for the column or column family. + // Applies to systems like Cloud Bigtable. + string gc_rule = 11 [(google.api.field_behavior) = OPTIONAL]; } diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/search.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/search.proto index 72dbe9f3fcd..4cf3bf82684 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/search.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/search.proto @@ -70,9 +70,10 @@ message SearchCatalogResult { // The source system of the entry. Applicable only when the // `search_result_type` is `ENTRY`. oneof system { - // Output only. The source system that Data Catalog automatically integrates with, such - // as BigQuery, Cloud Pub/Sub, or Dataproc Metastore. - IntegratedSystem integrated_system = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + // Output only. The source system that Data Catalog automatically integrates + // with, such as BigQuery, Cloud Pub/Sub, or Dataproc Metastore. + IntegratedSystem integrated_system = 8 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Custom source system that you can manually integrate Data Catalog with. string user_specified_system = 9; diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/table_spec.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/table_spec.proto index a92e5990efd..a09579bfb8b 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/table_spec.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/table_spec.proto @@ -30,7 +30,8 @@ option ruby_package = "Google::Cloud::DataCatalog::V1"; // Describes a BigQuery table. message BigQueryTableSpec { // Output only. The table source type. - TableSourceType table_source_type = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + TableSourceType table_source_type = 1 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. oneof type_spec { @@ -67,9 +68,9 @@ message ViewSpec { // Normal BigQuery table specification. message TableSpec { - // Output only. If the table is date-sharded, that is, it matches the `[prefix]YYYYMMDD` - // name pattern, this field is the Data Catalog resource name of the - // date-sharded grouped entry. For example: + // Output only. If the table is date-sharded, that is, it matches the + // `[prefix]YYYYMMDD` name pattern, this field is the Data Catalog resource + // name of the date-sharded grouped entry. For example: // // `projects/{PROJECT_ID}/locations/{LOCATION}/entrygroups/{ENTRY_GROUP_ID}/entries/{ENTRY_ID}`. // @@ -88,8 +89,8 @@ message TableSpec { // For more information, see [Introduction to partitioned tables] // (https://cloud.google.com/bigquery/docs/partitioned-tables#partitioning_versus_sharding). message BigQueryDateShardedSpec { - // Output only. The Data Catalog resource name of the dataset entry the current table - // belongs to. For example: + // Output only. The Data Catalog resource name of the dataset entry the + // current table belongs to. For example: // // `projects/{PROJECT_ID}/locations/{LOCATION}/entrygroups/{ENTRY_GROUP_ID}/entries/{ENTRY_ID}`. string dataset = 1 [ diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/tags.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/tags.proto index c5835af1211..8716c5c262a 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/tags.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/tags.proto @@ -73,8 +73,8 @@ message Tag { string column = 4; } - // Required. Maps the ID of a tag field to its value and additional information - // about that field. + // Required. Maps the ID of a tag field to its value and additional + // information about that field. // // Tag template defines valid field IDs. A tag // must have at least 1 field and at most 500 fields. @@ -122,8 +122,9 @@ message TagField { string richtext_value = 8; } - // Output only. The order of this field with respect to other fields in this tag. Can be - // set by [Tag][google.cloud.datacatalog.v1.TagTemplateField.order]. + // Output only. The order of this field with respect to other fields in this + // tag. Can be set by + // [Tag][google.cloud.datacatalog.v1.TagTemplateField.order]. // // For example, a higher value can indicate a more important field. // The value can be negative. Multiple fields can have the same order, and @@ -133,8 +134,8 @@ message TagField { // A tag template defines a tag that can have one or more typed fields. // -// The template is used to create tags that are attached to GCP resources. -// [Tag template roles] +// The template is used to create tags that are attached to Google Cloud +// resources. [Tag template roles] // (https://cloud.google.com/iam/docs/understanding-roles#data-catalog-roles) // provide permissions to create, edit, and use the template. For example, // see the [TagTemplate User] @@ -178,7 +179,8 @@ message TagTemplate { // underscores (_). // * Must be at least 1 character and at most 64 characters long. // * Must start with a letter or underscore. - map fields = 3 [(google.api.field_behavior) = REQUIRED]; + map fields = 3 + [(google.api.field_behavior) = REQUIRED]; } // The template for an individual field within a tag template. @@ -188,7 +190,8 @@ message TagTemplateField { pattern: "projects/{project}/locations/{location}/tagTemplates/{tag_template}/fields/{field}" }; - // Output only. The resource name of the tag template field in URL format. Example: + // Output only. The resource name of the tag template field in URL format. + // Example: // // `projects/{PROJECT_ID}/locations/{LOCATION}/tagTemplates/{TAG_TEMPLATE}/fields/{FIELD}` // @@ -248,7 +251,8 @@ message FieldType { message EnumType { message EnumValue { - // Required. The display name of the enum value. Must not be an empty string. + // Required. The display name of the enum value. Must not be an empty + // string. // // The name must contain only Unicode letters, numbers (0-9), underscores // (_), dashes (-), spaces ( ), and can't start or end with spaces. The diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/timestamps.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/timestamps.proto index cab8776cc60..9c5e2aa0112 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/timestamps.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/timestamps.proto @@ -44,5 +44,6 @@ message SystemTimestamps { // Output only. Expiration timestamp of the resource within the given system. // // Currently only applicable to BigQuery resources. - google.protobuf.Timestamp expire_time = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + google.protobuf.Timestamp expire_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; } diff --git a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/usage.proto b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/usage.proto index 07c3b140dac..aa7921abf5b 100644 --- a/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/usage.proto +++ b/packages/google-cloud-datacatalog/protos/google/cloud/datacatalog/v1/usage.proto @@ -51,6 +51,14 @@ message UsageStats { float total_execution_time_for_completions_millis = 4; } +// Common statistics on the entry's usage. +// +// They can be set on any system. +message CommonUsageStats { + // View count in source system. + optional int64 view_count = 1; +} + // The set of all usage signals that Data Catalog stores. // // Note: Usually, these signals are updated daily. In rare cases, an update may @@ -59,8 +67,18 @@ message UsageSignal { // The end timestamp of the duration of usage statistics. google.protobuf.Timestamp update_time = 1; - // Output only. BigQuery usage statistics over each of the predefined time ranges. + // Output only. BigQuery usage statistics over each of the predefined time + // ranges. // // Supported time ranges are `{"24H", "7D", "30D"}`. - map usage_within_time_range = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + map usage_within_time_range = 2 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Common usage statistics over each of the predefined time ranges. + // + // Supported time ranges are `{"24H", "7D", "30D", "Lifetime"}`. + map common_usage_within_time_range = 3; + + // Favorite count in the source system. + optional int64 favorite_count = 4; } diff --git a/packages/google-cloud-datacatalog/protos/protos.d.ts b/packages/google-cloud-datacatalog/protos/protos.d.ts index d4df1a9c44b..17d7a510418 100644 --- a/packages/google-cloud-datacatalog/protos/protos.d.ts +++ b/packages/google-cloud-datacatalog/protos/protos.d.ts @@ -472,7 +472,16 @@ export namespace google { BIGQUERY = 1, CLOUD_PUBSUB = 2, DATAPROC_METASTORE = 3, - DATAPLEX = 4 + DATAPLEX = 4, + CLOUD_SQL = 8, + LOOKER = 9 + } + + /** ManagingSystem enum. */ + enum ManagingSystem { + MANAGING_SYSTEM_UNSPECIFIED = 0, + MANAGING_SYSTEM_DATAPLEX = 1, + MANAGING_SYSTEM_OTHER = 2 } /** Properties of a DataSource. */ @@ -1104,6 +1113,20 @@ export namespace google { */ public listTags(request: google.cloud.datacatalog.v1.IListTagsRequest): Promise; + /** + * Calls ReconcileTags. + * @param request ReconcileTagsRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Operation + */ + public reconcileTags(request: google.cloud.datacatalog.v1.IReconcileTagsRequest, callback: google.cloud.datacatalog.v1.DataCatalog.ReconcileTagsCallback): void; + + /** + * Calls ReconcileTags. + * @param request ReconcileTagsRequest message or plain object + * @returns Promise + */ + public reconcileTags(request: google.cloud.datacatalog.v1.IReconcileTagsRequest): Promise; + /** * Calls StarEntry. * @param request StarEntryRequest message or plain object @@ -1173,6 +1196,20 @@ export namespace google { * @returns Promise */ public testIamPermissions(request: google.iam.v1.ITestIamPermissionsRequest): Promise; + + /** + * Calls ImportEntries. + * @param request ImportEntriesRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Operation + */ + public importEntries(request: google.cloud.datacatalog.v1.IImportEntriesRequest, callback: google.cloud.datacatalog.v1.DataCatalog.ImportEntriesCallback): void; + + /** + * Calls ImportEntries. + * @param request ImportEntriesRequest message or plain object + * @returns Promise + */ + public importEntries(request: google.cloud.datacatalog.v1.IImportEntriesRequest): Promise; } namespace DataCatalog { @@ -1366,6 +1403,13 @@ export namespace google { */ type ListTagsCallback = (error: (Error|null), response?: google.cloud.datacatalog.v1.ListTagsResponse) => void; + /** + * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|reconcileTags}. + * @param error Error, if any + * @param [response] Operation + */ + type ReconcileTagsCallback = (error: (Error|null), response?: google.longrunning.Operation) => void; + /** * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|starEntry}. * @param error Error, if any @@ -1400,6 +1444,13 @@ export namespace google { * @param [response] TestIamPermissionsResponse */ type TestIamPermissionsCallback = (error: (Error|null), response?: google.iam.v1.TestIamPermissionsResponse) => void; + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|importEntries}. + * @param error Error, if any + * @param [response] Operation + */ + type ImportEntriesCallback = (error: (Error|null), response?: google.longrunning.Operation) => void; } /** Properties of a SearchCatalogRequest. */ @@ -2934,6 +2985,12 @@ export namespace google { /** Entry userSpecifiedSystem */ userSpecifiedSystem?: (string|null); + /** Entry sqlDatabaseSystemSpec */ + sqlDatabaseSystemSpec?: (google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec|null); + + /** Entry lookerSystemSpec */ + lookerSystemSpec?: (google.cloud.datacatalog.v1.ILookerSystemSpec|null); + /** Entry gcsFilesetSpec */ gcsFilesetSpec?: (google.cloud.datacatalog.v1.IGcsFilesetSpec|null); @@ -3013,6 +3070,12 @@ export namespace google { /** Entry userSpecifiedSystem. */ public userSpecifiedSystem?: (string|null); + /** Entry sqlDatabaseSystemSpec. */ + public sqlDatabaseSystemSpec?: (google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec|null); + + /** Entry lookerSystemSpec. */ + public lookerSystemSpec?: (google.cloud.datacatalog.v1.ILookerSystemSpec|null); + /** Entry gcsFilesetSpec. */ public gcsFilesetSpec?: (google.cloud.datacatalog.v1.IGcsFilesetSpec|null); @@ -3067,6 +3130,9 @@ export namespace google { /** Entry system. */ public system?: ("integratedSystem"|"userSpecifiedSystem"); + /** Entry systemSpec. */ + public systemSpec?: ("sqlDatabaseSystemSpec"|"lookerSystemSpec"); + /** Entry typeSpec. */ public typeSpec?: ("gcsFilesetSpec"|"bigqueryTableSpec"|"bigqueryDateShardedSpec"); @@ -3159,6 +3225,9 @@ export namespace google { /** DatabaseTableSpec dataplexTable */ dataplexTable?: (google.cloud.datacatalog.v1.IDataplexTableSpec|null); + + /** DatabaseTableSpec databaseViewSpec */ + databaseViewSpec?: (google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec|null); } /** Represents a DatabaseTableSpec. */ @@ -3176,6 +3245,9 @@ export namespace google { /** DatabaseTableSpec dataplexTable. */ public dataplexTable?: (google.cloud.datacatalog.v1.IDataplexTableSpec|null); + /** DatabaseTableSpec databaseViewSpec. */ + public databaseViewSpec?: (google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec|null); + /** * Creates a new DatabaseTableSpec instance using the specified properties. * @param [properties] Properties to set @@ -3262,6 +3334,128 @@ export namespace google { NATIVE = 1, EXTERNAL = 2 } + + /** Properties of a DatabaseViewSpec. */ + interface IDatabaseViewSpec { + + /** DatabaseViewSpec viewType */ + viewType?: (google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType|keyof typeof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType|null); + + /** DatabaseViewSpec baseTable */ + baseTable?: (string|null); + + /** DatabaseViewSpec sqlQuery */ + sqlQuery?: (string|null); + } + + /** Represents a DatabaseViewSpec. */ + class DatabaseViewSpec implements IDatabaseViewSpec { + + /** + * Constructs a new DatabaseViewSpec. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec); + + /** DatabaseViewSpec viewType. */ + public viewType: (google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType|keyof typeof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType); + + /** DatabaseViewSpec baseTable. */ + public baseTable?: (string|null); + + /** DatabaseViewSpec sqlQuery. */ + public sqlQuery?: (string|null); + + /** DatabaseViewSpec sourceDefinition. */ + public sourceDefinition?: ("baseTable"|"sqlQuery"); + + /** + * Creates a new DatabaseViewSpec instance using the specified properties. + * @param [properties] Properties to set + * @returns DatabaseViewSpec instance + */ + public static create(properties?: google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec): google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec; + + /** + * Encodes the specified DatabaseViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.verify|verify} messages. + * @param message DatabaseViewSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified DatabaseViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.verify|verify} messages. + * @param message DatabaseViewSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a DatabaseViewSpec message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns DatabaseViewSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec; + + /** + * Decodes a DatabaseViewSpec message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns DatabaseViewSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec; + + /** + * Verifies a DatabaseViewSpec message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a DatabaseViewSpec message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns DatabaseViewSpec + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec; + + /** + * Creates a plain object from a DatabaseViewSpec message. Also converts values to other types if specified. + * @param message DatabaseViewSpec + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this DatabaseViewSpec to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for DatabaseViewSpec + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + namespace DatabaseViewSpec { + + /** ViewType enum. */ + enum ViewType { + VIEW_TYPE_UNSPECIFIED = 0, + STANDARD_VIEW = 1, + MATERIALIZED_VIEW = 2 + } + } } /** Properties of a FilesetSpec. */ @@ -3718,6 +3912,242 @@ export namespace google { } } + /** Properties of a SqlDatabaseSystemSpec. */ + interface ISqlDatabaseSystemSpec { + + /** SqlDatabaseSystemSpec sqlEngine */ + sqlEngine?: (string|null); + + /** SqlDatabaseSystemSpec databaseVersion */ + databaseVersion?: (string|null); + + /** SqlDatabaseSystemSpec instanceHost */ + instanceHost?: (string|null); + } + + /** Represents a SqlDatabaseSystemSpec. */ + class SqlDatabaseSystemSpec implements ISqlDatabaseSystemSpec { + + /** + * Constructs a new SqlDatabaseSystemSpec. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec); + + /** SqlDatabaseSystemSpec sqlEngine. */ + public sqlEngine: string; + + /** SqlDatabaseSystemSpec databaseVersion. */ + public databaseVersion: string; + + /** SqlDatabaseSystemSpec instanceHost. */ + public instanceHost: string; + + /** + * Creates a new SqlDatabaseSystemSpec instance using the specified properties. + * @param [properties] Properties to set + * @returns SqlDatabaseSystemSpec instance + */ + public static create(properties?: google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec): google.cloud.datacatalog.v1.SqlDatabaseSystemSpec; + + /** + * Encodes the specified SqlDatabaseSystemSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.verify|verify} messages. + * @param message SqlDatabaseSystemSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified SqlDatabaseSystemSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.verify|verify} messages. + * @param message SqlDatabaseSystemSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a SqlDatabaseSystemSpec message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns SqlDatabaseSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.SqlDatabaseSystemSpec; + + /** + * Decodes a SqlDatabaseSystemSpec message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns SqlDatabaseSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.SqlDatabaseSystemSpec; + + /** + * Verifies a SqlDatabaseSystemSpec message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a SqlDatabaseSystemSpec message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns SqlDatabaseSystemSpec + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.SqlDatabaseSystemSpec; + + /** + * Creates a plain object from a SqlDatabaseSystemSpec message. Also converts values to other types if specified. + * @param message SqlDatabaseSystemSpec + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.SqlDatabaseSystemSpec, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this SqlDatabaseSystemSpec to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for SqlDatabaseSystemSpec + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a LookerSystemSpec. */ + interface ILookerSystemSpec { + + /** LookerSystemSpec parentInstanceId */ + parentInstanceId?: (string|null); + + /** LookerSystemSpec parentInstanceDisplayName */ + parentInstanceDisplayName?: (string|null); + + /** LookerSystemSpec parentModelId */ + parentModelId?: (string|null); + + /** LookerSystemSpec parentModelDisplayName */ + parentModelDisplayName?: (string|null); + + /** LookerSystemSpec parentViewId */ + parentViewId?: (string|null); + + /** LookerSystemSpec parentViewDisplayName */ + parentViewDisplayName?: (string|null); + } + + /** Represents a LookerSystemSpec. */ + class LookerSystemSpec implements ILookerSystemSpec { + + /** + * Constructs a new LookerSystemSpec. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.ILookerSystemSpec); + + /** LookerSystemSpec parentInstanceId. */ + public parentInstanceId: string; + + /** LookerSystemSpec parentInstanceDisplayName. */ + public parentInstanceDisplayName: string; + + /** LookerSystemSpec parentModelId. */ + public parentModelId: string; + + /** LookerSystemSpec parentModelDisplayName. */ + public parentModelDisplayName: string; + + /** LookerSystemSpec parentViewId. */ + public parentViewId: string; + + /** LookerSystemSpec parentViewDisplayName. */ + public parentViewDisplayName: string; + + /** + * Creates a new LookerSystemSpec instance using the specified properties. + * @param [properties] Properties to set + * @returns LookerSystemSpec instance + */ + public static create(properties?: google.cloud.datacatalog.v1.ILookerSystemSpec): google.cloud.datacatalog.v1.LookerSystemSpec; + + /** + * Encodes the specified LookerSystemSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.LookerSystemSpec.verify|verify} messages. + * @param message LookerSystemSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.ILookerSystemSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified LookerSystemSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.LookerSystemSpec.verify|verify} messages. + * @param message LookerSystemSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.ILookerSystemSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a LookerSystemSpec message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns LookerSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.LookerSystemSpec; + + /** + * Decodes a LookerSystemSpec message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns LookerSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.LookerSystemSpec; + + /** + * Verifies a LookerSystemSpec message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a LookerSystemSpec message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns LookerSystemSpec + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.LookerSystemSpec; + + /** + * Creates a plain object from a LookerSystemSpec message. Also converts values to other types if specified. + * @param message LookerSystemSpec + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.LookerSystemSpec, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this LookerSystemSpec to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for LookerSystemSpec + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + /** Properties of a BusinessContext. */ interface IBusinessContext { @@ -5690,27 +6120,365 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a ListEntriesRequest. */ - interface IListEntriesRequest { + /** Properties of a ReconcileTagsRequest. */ + interface IReconcileTagsRequest { - /** ListEntriesRequest parent */ + /** ReconcileTagsRequest parent */ parent?: (string|null); - /** ListEntriesRequest pageSize */ - pageSize?: (number|null); + /** ReconcileTagsRequest tagTemplate */ + tagTemplate?: (string|null); - /** ListEntriesRequest pageToken */ - pageToken?: (string|null); + /** ReconcileTagsRequest forceDeleteMissing */ + forceDeleteMissing?: (boolean|null); - /** ListEntriesRequest readMask */ - readMask?: (google.protobuf.IFieldMask|null); + /** ReconcileTagsRequest tags */ + tags?: (google.cloud.datacatalog.v1.ITag[]|null); } - /** Represents a ListEntriesRequest. */ - class ListEntriesRequest implements IListEntriesRequest { + /** Represents a ReconcileTagsRequest. */ + class ReconcileTagsRequest implements IReconcileTagsRequest { /** - * Constructs a new ListEntriesRequest. + * Constructs a new ReconcileTagsRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IReconcileTagsRequest); + + /** ReconcileTagsRequest parent. */ + public parent: string; + + /** ReconcileTagsRequest tagTemplate. */ + public tagTemplate: string; + + /** ReconcileTagsRequest forceDeleteMissing. */ + public forceDeleteMissing: boolean; + + /** ReconcileTagsRequest tags. */ + public tags: google.cloud.datacatalog.v1.ITag[]; + + /** + * Creates a new ReconcileTagsRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns ReconcileTagsRequest instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IReconcileTagsRequest): google.cloud.datacatalog.v1.ReconcileTagsRequest; + + /** + * Encodes the specified ReconcileTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsRequest.verify|verify} messages. + * @param message ReconcileTagsRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IReconcileTagsRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ReconcileTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsRequest.verify|verify} messages. + * @param message ReconcileTagsRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IReconcileTagsRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ReconcileTagsRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ReconcileTagsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ReconcileTagsRequest; + + /** + * Decodes a ReconcileTagsRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ReconcileTagsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ReconcileTagsRequest; + + /** + * Verifies a ReconcileTagsRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ReconcileTagsRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ReconcileTagsRequest + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ReconcileTagsRequest; + + /** + * Creates a plain object from a ReconcileTagsRequest message. Also converts values to other types if specified. + * @param message ReconcileTagsRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ReconcileTagsRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ReconcileTagsRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ReconcileTagsRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a ReconcileTagsResponse. */ + interface IReconcileTagsResponse { + + /** ReconcileTagsResponse createdTagsCount */ + createdTagsCount?: (number|Long|string|null); + + /** ReconcileTagsResponse updatedTagsCount */ + updatedTagsCount?: (number|Long|string|null); + + /** ReconcileTagsResponse deletedTagsCount */ + deletedTagsCount?: (number|Long|string|null); + } + + /** Represents a ReconcileTagsResponse. */ + class ReconcileTagsResponse implements IReconcileTagsResponse { + + /** + * Constructs a new ReconcileTagsResponse. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IReconcileTagsResponse); + + /** ReconcileTagsResponse createdTagsCount. */ + public createdTagsCount: (number|Long|string); + + /** ReconcileTagsResponse updatedTagsCount. */ + public updatedTagsCount: (number|Long|string); + + /** ReconcileTagsResponse deletedTagsCount. */ + public deletedTagsCount: (number|Long|string); + + /** + * Creates a new ReconcileTagsResponse instance using the specified properties. + * @param [properties] Properties to set + * @returns ReconcileTagsResponse instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IReconcileTagsResponse): google.cloud.datacatalog.v1.ReconcileTagsResponse; + + /** + * Encodes the specified ReconcileTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsResponse.verify|verify} messages. + * @param message ReconcileTagsResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IReconcileTagsResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ReconcileTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsResponse.verify|verify} messages. + * @param message ReconcileTagsResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IReconcileTagsResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ReconcileTagsResponse message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ReconcileTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ReconcileTagsResponse; + + /** + * Decodes a ReconcileTagsResponse message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ReconcileTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ReconcileTagsResponse; + + /** + * Verifies a ReconcileTagsResponse message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ReconcileTagsResponse message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ReconcileTagsResponse + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ReconcileTagsResponse; + + /** + * Creates a plain object from a ReconcileTagsResponse message. Also converts values to other types if specified. + * @param message ReconcileTagsResponse + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ReconcileTagsResponse, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ReconcileTagsResponse to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ReconcileTagsResponse + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a ReconcileTagsMetadata. */ + interface IReconcileTagsMetadata { + + /** ReconcileTagsMetadata state */ + state?: (google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState|keyof typeof google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState|null); + + /** ReconcileTagsMetadata errors */ + errors?: ({ [k: string]: google.rpc.IStatus }|null); + } + + /** Represents a ReconcileTagsMetadata. */ + class ReconcileTagsMetadata implements IReconcileTagsMetadata { + + /** + * Constructs a new ReconcileTagsMetadata. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IReconcileTagsMetadata); + + /** ReconcileTagsMetadata state. */ + public state: (google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState|keyof typeof google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState); + + /** ReconcileTagsMetadata errors. */ + public errors: { [k: string]: google.rpc.IStatus }; + + /** + * Creates a new ReconcileTagsMetadata instance using the specified properties. + * @param [properties] Properties to set + * @returns ReconcileTagsMetadata instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IReconcileTagsMetadata): google.cloud.datacatalog.v1.ReconcileTagsMetadata; + + /** + * Encodes the specified ReconcileTagsMetadata message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsMetadata.verify|verify} messages. + * @param message ReconcileTagsMetadata message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IReconcileTagsMetadata, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ReconcileTagsMetadata message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsMetadata.verify|verify} messages. + * @param message ReconcileTagsMetadata message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IReconcileTagsMetadata, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ReconcileTagsMetadata message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ReconcileTagsMetadata + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ReconcileTagsMetadata; + + /** + * Decodes a ReconcileTagsMetadata message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ReconcileTagsMetadata + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ReconcileTagsMetadata; + + /** + * Verifies a ReconcileTagsMetadata message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ReconcileTagsMetadata message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ReconcileTagsMetadata + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ReconcileTagsMetadata; + + /** + * Creates a plain object from a ReconcileTagsMetadata message. Also converts values to other types if specified. + * @param message ReconcileTagsMetadata + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ReconcileTagsMetadata, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ReconcileTagsMetadata to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ReconcileTagsMetadata + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + namespace ReconcileTagsMetadata { + + /** ReconciliationState enum. */ + enum ReconciliationState { + RECONCILIATION_STATE_UNSPECIFIED = 0, + RECONCILIATION_QUEUED = 1, + RECONCILIATION_IN_PROGRESS = 2, + RECONCILIATION_DONE = 3 + } + } + + /** Properties of a ListEntriesRequest. */ + interface IListEntriesRequest { + + /** ListEntriesRequest parent */ + parent?: (string|null); + + /** ListEntriesRequest pageSize */ + pageSize?: (number|null); + + /** ListEntriesRequest pageToken */ + pageToken?: (string|null); + + /** ListEntriesRequest readMask */ + readMask?: (google.protobuf.IFieldMask|null); + } + + /** Represents a ListEntriesRequest. */ + class ListEntriesRequest implements IListEntriesRequest { + + /** + * Constructs a new ListEntriesRequest. * @param [properties] Properties to set */ constructor(properties?: google.cloud.datacatalog.v1.IListEntriesRequest); @@ -6284,86 +7052,416 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a ModifyEntryOverviewRequest. */ - interface IModifyEntryOverviewRequest { + /** Properties of an ImportEntriesRequest. */ + interface IImportEntriesRequest { - /** ModifyEntryOverviewRequest name */ - name?: (string|null); + /** ImportEntriesRequest parent */ + parent?: (string|null); - /** ModifyEntryOverviewRequest entryOverview */ - entryOverview?: (google.cloud.datacatalog.v1.IEntryOverview|null); + /** ImportEntriesRequest gcsBucketPath */ + gcsBucketPath?: (string|null); } - /** Represents a ModifyEntryOverviewRequest. */ - class ModifyEntryOverviewRequest implements IModifyEntryOverviewRequest { + /** Represents an ImportEntriesRequest. */ + class ImportEntriesRequest implements IImportEntriesRequest { /** - * Constructs a new ModifyEntryOverviewRequest. + * Constructs a new ImportEntriesRequest. * @param [properties] Properties to set */ - constructor(properties?: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest); + constructor(properties?: google.cloud.datacatalog.v1.IImportEntriesRequest); - /** ModifyEntryOverviewRequest name. */ - public name: string; + /** ImportEntriesRequest parent. */ + public parent: string; - /** ModifyEntryOverviewRequest entryOverview. */ - public entryOverview?: (google.cloud.datacatalog.v1.IEntryOverview|null); + /** ImportEntriesRequest gcsBucketPath. */ + public gcsBucketPath?: (string|null); + + /** ImportEntriesRequest source. */ + public source?: "gcsBucketPath"; /** - * Creates a new ModifyEntryOverviewRequest instance using the specified properties. + * Creates a new ImportEntriesRequest instance using the specified properties. * @param [properties] Properties to set - * @returns ModifyEntryOverviewRequest instance + * @returns ImportEntriesRequest instance */ - public static create(properties?: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + public static create(properties?: google.cloud.datacatalog.v1.IImportEntriesRequest): google.cloud.datacatalog.v1.ImportEntriesRequest; /** - * Encodes the specified ModifyEntryOverviewRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. - * @param message ModifyEntryOverviewRequest message or plain object to encode + * Encodes the specified ImportEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesRequest.verify|verify} messages. + * @param message ImportEntriesRequest message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encode(message: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest, writer?: $protobuf.Writer): $protobuf.Writer; + public static encode(message: google.cloud.datacatalog.v1.IImportEntriesRequest, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified ModifyEntryOverviewRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. - * @param message ModifyEntryOverviewRequest message or plain object to encode + * Encodes the specified ImportEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesRequest.verify|verify} messages. + * @param message ImportEntriesRequest message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encodeDelimited(message: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest, writer?: $protobuf.Writer): $protobuf.Writer; + public static encodeDelimited(message: google.cloud.datacatalog.v1.IImportEntriesRequest, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer. + * Decodes an ImportEntriesRequest message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns ModifyEntryOverviewRequest + * @returns ImportEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ImportEntriesRequest; /** - * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer, length delimited. + * Decodes an ImportEntriesRequest message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns ModifyEntryOverviewRequest + * @returns ImportEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ImportEntriesRequest; /** - * Verifies a ModifyEntryOverviewRequest message. + * Verifies an ImportEntriesRequest message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ public static verify(message: { [k: string]: any }): (string|null); /** - * Creates a ModifyEntryOverviewRequest message from a plain object. Also converts values to their respective internal types. + * Creates an ImportEntriesRequest message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns ModifyEntryOverviewRequest + * @returns ImportEntriesRequest */ - public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ImportEntriesRequest; + + /** + * Creates a plain object from an ImportEntriesRequest message. Also converts values to other types if specified. + * @param message ImportEntriesRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ImportEntriesRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ImportEntriesRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ImportEntriesRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of an ImportEntriesResponse. */ + interface IImportEntriesResponse { + + /** ImportEntriesResponse upsertedEntriesCount */ + upsertedEntriesCount?: (number|Long|string|null); + + /** ImportEntriesResponse deletedEntriesCount */ + deletedEntriesCount?: (number|Long|string|null); + } + + /** Represents an ImportEntriesResponse. */ + class ImportEntriesResponse implements IImportEntriesResponse { + + /** + * Constructs a new ImportEntriesResponse. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IImportEntriesResponse); + + /** ImportEntriesResponse upsertedEntriesCount. */ + public upsertedEntriesCount?: (number|Long|string|null); + + /** ImportEntriesResponse deletedEntriesCount. */ + public deletedEntriesCount?: (number|Long|string|null); + + /** ImportEntriesResponse _upsertedEntriesCount. */ + public _upsertedEntriesCount?: "upsertedEntriesCount"; + + /** ImportEntriesResponse _deletedEntriesCount. */ + public _deletedEntriesCount?: "deletedEntriesCount"; + + /** + * Creates a new ImportEntriesResponse instance using the specified properties. + * @param [properties] Properties to set + * @returns ImportEntriesResponse instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IImportEntriesResponse): google.cloud.datacatalog.v1.ImportEntriesResponse; + + /** + * Encodes the specified ImportEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesResponse.verify|verify} messages. + * @param message ImportEntriesResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IImportEntriesResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ImportEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesResponse.verify|verify} messages. + * @param message ImportEntriesResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IImportEntriesResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes an ImportEntriesResponse message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ImportEntriesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ImportEntriesResponse; + + /** + * Decodes an ImportEntriesResponse message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ImportEntriesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ImportEntriesResponse; + + /** + * Verifies an ImportEntriesResponse message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates an ImportEntriesResponse message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ImportEntriesResponse + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ImportEntriesResponse; + + /** + * Creates a plain object from an ImportEntriesResponse message. Also converts values to other types if specified. + * @param message ImportEntriesResponse + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ImportEntriesResponse, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ImportEntriesResponse to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ImportEntriesResponse + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of an ImportEntriesMetadata. */ + interface IImportEntriesMetadata { + + /** ImportEntriesMetadata state */ + state?: (google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState|keyof typeof google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState|null); + + /** ImportEntriesMetadata errors */ + errors?: (google.rpc.IStatus[]|null); + } + + /** Represents an ImportEntriesMetadata. */ + class ImportEntriesMetadata implements IImportEntriesMetadata { + + /** + * Constructs a new ImportEntriesMetadata. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IImportEntriesMetadata); + + /** ImportEntriesMetadata state. */ + public state: (google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState|keyof typeof google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState); + + /** ImportEntriesMetadata errors. */ + public errors: google.rpc.IStatus[]; + + /** + * Creates a new ImportEntriesMetadata instance using the specified properties. + * @param [properties] Properties to set + * @returns ImportEntriesMetadata instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IImportEntriesMetadata): google.cloud.datacatalog.v1.ImportEntriesMetadata; + + /** + * Encodes the specified ImportEntriesMetadata message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesMetadata.verify|verify} messages. + * @param message ImportEntriesMetadata message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IImportEntriesMetadata, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ImportEntriesMetadata message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesMetadata.verify|verify} messages. + * @param message ImportEntriesMetadata message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IImportEntriesMetadata, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes an ImportEntriesMetadata message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ImportEntriesMetadata + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ImportEntriesMetadata; + + /** + * Decodes an ImportEntriesMetadata message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ImportEntriesMetadata + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ImportEntriesMetadata; + + /** + * Verifies an ImportEntriesMetadata message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates an ImportEntriesMetadata message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ImportEntriesMetadata + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ImportEntriesMetadata; + + /** + * Creates a plain object from an ImportEntriesMetadata message. Also converts values to other types if specified. + * @param message ImportEntriesMetadata + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ImportEntriesMetadata, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ImportEntriesMetadata to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ImportEntriesMetadata + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + namespace ImportEntriesMetadata { + + /** ImportState enum. */ + enum ImportState { + IMPORT_STATE_UNSPECIFIED = 0, + IMPORT_QUEUED = 1, + IMPORT_IN_PROGRESS = 2, + IMPORT_DONE = 3, + IMPORT_OBSOLETE = 4 + } + } + + /** Properties of a ModifyEntryOverviewRequest. */ + interface IModifyEntryOverviewRequest { + + /** ModifyEntryOverviewRequest name */ + name?: (string|null); + + /** ModifyEntryOverviewRequest entryOverview */ + entryOverview?: (google.cloud.datacatalog.v1.IEntryOverview|null); + } + + /** Represents a ModifyEntryOverviewRequest. */ + class ModifyEntryOverviewRequest implements IModifyEntryOverviewRequest { + + /** + * Constructs a new ModifyEntryOverviewRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest); + + /** ModifyEntryOverviewRequest name. */ + public name: string; + + /** ModifyEntryOverviewRequest entryOverview. */ + public entryOverview?: (google.cloud.datacatalog.v1.IEntryOverview|null); + + /** + * Creates a new ModifyEntryOverviewRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns ModifyEntryOverviewRequest instance + */ + public static create(properties?: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + + /** + * Encodes the specified ModifyEntryOverviewRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. + * @param message ModifyEntryOverviewRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ModifyEntryOverviewRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. + * @param message ModifyEntryOverviewRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IModifyEntryOverviewRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ModifyEntryOverviewRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + + /** + * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ModifyEntryOverviewRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; + + /** + * Verifies a ModifyEntryOverviewRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ModifyEntryOverviewRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ModifyEntryOverviewRequest + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ModifyEntryOverviewRequest; /** * Creates a plain object from a ModifyEntryOverviewRequest message. Also converts values to other types if specified. @@ -6503,7 +7601,11 @@ export namespace google { ROUTINE = 9, LAKE = 10, ZONE = 11, - SERVICE = 14 + SERVICE = 14, + DATABASE_SCHEMA = 15, + DASHBOARD = 16, + EXPLORE = 17, + LOOK = 18 } /** Properties of a DataplexSpec. */ @@ -8072,8 +9174,23 @@ export namespace google { /** ColumnSchema mode */ mode?: (string|null); + /** ColumnSchema defaultValue */ + defaultValue?: (string|null); + + /** ColumnSchema ordinalPosition */ + ordinalPosition?: (number|null); + + /** ColumnSchema highestIndexingType */ + highestIndexingType?: (google.cloud.datacatalog.v1.ColumnSchema.IndexingType|keyof typeof google.cloud.datacatalog.v1.ColumnSchema.IndexingType|null); + /** ColumnSchema subcolumns */ subcolumns?: (google.cloud.datacatalog.v1.IColumnSchema[]|null); + + /** ColumnSchema lookerColumnSpec */ + lookerColumnSpec?: (google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec|null); + + /** ColumnSchema gcRule */ + gcRule?: (string|null); } /** Represents a ColumnSchema. */ @@ -8097,9 +9214,27 @@ export namespace google { /** ColumnSchema mode. */ public mode: string; + /** ColumnSchema defaultValue. */ + public defaultValue: string; + + /** ColumnSchema ordinalPosition. */ + public ordinalPosition: number; + + /** ColumnSchema highestIndexingType. */ + public highestIndexingType: (google.cloud.datacatalog.v1.ColumnSchema.IndexingType|keyof typeof google.cloud.datacatalog.v1.ColumnSchema.IndexingType); + /** ColumnSchema subcolumns. */ public subcolumns: google.cloud.datacatalog.v1.IColumnSchema[]; + /** ColumnSchema lookerColumnSpec. */ + public lookerColumnSpec?: (google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec|null); + + /** ColumnSchema gcRule. */ + public gcRule: string; + + /** ColumnSchema systemSpec. */ + public systemSpec?: "lookerColumnSpec"; + /** * Creates a new ColumnSchema instance using the specified properties. * @param [properties] Properties to set @@ -8178,19 +9313,141 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of a SearchCatalogResult. */ - interface ISearchCatalogResult { + namespace ColumnSchema { - /** SearchCatalogResult searchResultType */ - searchResultType?: (google.cloud.datacatalog.v1.SearchResultType|keyof typeof google.cloud.datacatalog.v1.SearchResultType|null); + /** IndexingType enum. */ + enum IndexingType { + INDEXING_TYPE_UNSPECIFIED = 0, + INDEXING_TYPE_NONE = 1, + INDEXING_TYPE_NON_UNIQUE = 2, + INDEXING_TYPE_UNIQUE = 3, + INDEXING_TYPE_PRIMARY_KEY = 4 + } - /** SearchCatalogResult searchResultSubtype */ - searchResultSubtype?: (string|null); + /** Properties of a LookerColumnSpec. */ + interface ILookerColumnSpec { - /** SearchCatalogResult relativeResourceName */ - relativeResourceName?: (string|null); + /** LookerColumnSpec type */ + type?: (google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType|keyof typeof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType|null); + } - /** SearchCatalogResult linkedResource */ + /** Represents a LookerColumnSpec. */ + class LookerColumnSpec implements ILookerColumnSpec { + + /** + * Constructs a new LookerColumnSpec. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec); + + /** LookerColumnSpec type. */ + public type: (google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType|keyof typeof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType); + + /** + * Creates a new LookerColumnSpec instance using the specified properties. + * @param [properties] Properties to set + * @returns LookerColumnSpec instance + */ + public static create(properties?: google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec): google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec; + + /** + * Encodes the specified LookerColumnSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.verify|verify} messages. + * @param message LookerColumnSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified LookerColumnSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.verify|verify} messages. + * @param message LookerColumnSpec message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a LookerColumnSpec message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns LookerColumnSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec; + + /** + * Decodes a LookerColumnSpec message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns LookerColumnSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec; + + /** + * Verifies a LookerColumnSpec message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a LookerColumnSpec message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns LookerColumnSpec + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec; + + /** + * Creates a plain object from a LookerColumnSpec message. Also converts values to other types if specified. + * @param message LookerColumnSpec + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this LookerColumnSpec to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for LookerColumnSpec + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + namespace LookerColumnSpec { + + /** LookerColumnType enum. */ + enum LookerColumnType { + LOOKER_COLUMN_TYPE_UNSPECIFIED = 0, + DIMENSION = 1, + DIMENSION_GROUP = 2, + FILTER = 3, + MEASURE = 4, + PARAMETER = 5 + } + } + } + + /** Properties of a SearchCatalogResult. */ + interface ISearchCatalogResult { + + /** SearchCatalogResult searchResultType */ + searchResultType?: (google.cloud.datacatalog.v1.SearchResultType|keyof typeof google.cloud.datacatalog.v1.SearchResultType|null); + + /** SearchCatalogResult searchResultSubtype */ + searchResultSubtype?: (string|null); + + /** SearchCatalogResult relativeResourceName */ + relativeResourceName?: (string|null); + + /** SearchCatalogResult linkedResource */ linkedResource?: (string|null); /** SearchCatalogResult modifyTime */ @@ -9808,6 +11065,106 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } + /** Properties of a CommonUsageStats. */ + interface ICommonUsageStats { + + /** CommonUsageStats viewCount */ + viewCount?: (number|Long|string|null); + } + + /** Represents a CommonUsageStats. */ + class CommonUsageStats implements ICommonUsageStats { + + /** + * Constructs a new CommonUsageStats. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.ICommonUsageStats); + + /** CommonUsageStats viewCount. */ + public viewCount?: (number|Long|string|null); + + /** CommonUsageStats _viewCount. */ + public _viewCount?: "viewCount"; + + /** + * Creates a new CommonUsageStats instance using the specified properties. + * @param [properties] Properties to set + * @returns CommonUsageStats instance + */ + public static create(properties?: google.cloud.datacatalog.v1.ICommonUsageStats): google.cloud.datacatalog.v1.CommonUsageStats; + + /** + * Encodes the specified CommonUsageStats message. Does not implicitly {@link google.cloud.datacatalog.v1.CommonUsageStats.verify|verify} messages. + * @param message CommonUsageStats message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.ICommonUsageStats, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified CommonUsageStats message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CommonUsageStats.verify|verify} messages. + * @param message CommonUsageStats message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.ICommonUsageStats, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a CommonUsageStats message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CommonUsageStats + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.CommonUsageStats; + + /** + * Decodes a CommonUsageStats message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CommonUsageStats + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.CommonUsageStats; + + /** + * Verifies a CommonUsageStats message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a CommonUsageStats message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CommonUsageStats + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.CommonUsageStats; + + /** + * Creates a plain object from a CommonUsageStats message. Also converts values to other types if specified. + * @param message CommonUsageStats + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.CommonUsageStats, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this CommonUsageStats to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for CommonUsageStats + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + /** Properties of a UsageSignal. */ interface IUsageSignal { @@ -9816,6 +11173,12 @@ export namespace google { /** UsageSignal usageWithinTimeRange */ usageWithinTimeRange?: ({ [k: string]: google.cloud.datacatalog.v1.IUsageStats }|null); + + /** UsageSignal commonUsageWithinTimeRange */ + commonUsageWithinTimeRange?: ({ [k: string]: google.cloud.datacatalog.v1.ICommonUsageStats }|null); + + /** UsageSignal favoriteCount */ + favoriteCount?: (number|Long|string|null); } /** Represents a UsageSignal. */ @@ -9833,6 +11196,15 @@ export namespace google { /** UsageSignal usageWithinTimeRange. */ public usageWithinTimeRange: { [k: string]: google.cloud.datacatalog.v1.IUsageStats }; + /** UsageSignal commonUsageWithinTimeRange. */ + public commonUsageWithinTimeRange: { [k: string]: google.cloud.datacatalog.v1.ICommonUsageStats }; + + /** UsageSignal favoriteCount. */ + public favoriteCount?: (number|Long|string|null); + + /** UsageSignal _favoriteCount. */ + public _favoriteCount?: "favoriteCount"; + /** * Creates a new UsageSignal instance using the specified properties. * @param [properties] Properties to set @@ -9911,115 +11283,327 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Represents a PolicyTagManager */ - class PolicyTagManager extends $protobuf.rpc.Service { + /** Properties of a TaggedEntry. */ + interface ITaggedEntry { + + /** TaggedEntry v1Entry */ + v1Entry?: (google.cloud.datacatalog.v1.IEntry|null); + + /** TaggedEntry presentTags */ + presentTags?: (google.cloud.datacatalog.v1.ITag[]|null); + + /** TaggedEntry absentTags */ + absentTags?: (google.cloud.datacatalog.v1.ITag[]|null); + } + + /** Represents a TaggedEntry. */ + class TaggedEntry implements ITaggedEntry { /** - * Constructs a new PolicyTagManager service. - * @param rpcImpl RPC implementation - * @param [requestDelimited=false] Whether requests are length-delimited - * @param [responseDelimited=false] Whether responses are length-delimited + * Constructs a new TaggedEntry. + * @param [properties] Properties to set */ - constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean); + constructor(properties?: google.cloud.datacatalog.v1.ITaggedEntry); + + /** TaggedEntry v1Entry. */ + public v1Entry?: (google.cloud.datacatalog.v1.IEntry|null); + + /** TaggedEntry presentTags. */ + public presentTags: google.cloud.datacatalog.v1.ITag[]; + + /** TaggedEntry absentTags. */ + public absentTags: google.cloud.datacatalog.v1.ITag[]; + + /** TaggedEntry entry. */ + public entry?: "v1Entry"; /** - * Creates new PolicyTagManager service using the specified rpc implementation. - * @param rpcImpl RPC implementation - * @param [requestDelimited=false] Whether requests are length-delimited - * @param [responseDelimited=false] Whether responses are length-delimited - * @returns RPC service. Useful where requests and/or responses are streamed. + * Creates a new TaggedEntry instance using the specified properties. + * @param [properties] Properties to set + * @returns TaggedEntry instance */ - public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): PolicyTagManager; + public static create(properties?: google.cloud.datacatalog.v1.ITaggedEntry): google.cloud.datacatalog.v1.TaggedEntry; /** - * Calls CreateTaxonomy. - * @param request CreateTaxonomyRequest message or plain object - * @param callback Node-style callback called with the error, if any, and Taxonomy + * Encodes the specified TaggedEntry message. Does not implicitly {@link google.cloud.datacatalog.v1.TaggedEntry.verify|verify} messages. + * @param message TaggedEntry message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer */ - public createTaxonomy(request: google.cloud.datacatalog.v1.ICreateTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.CreateTaxonomyCallback): void; + public static encode(message: google.cloud.datacatalog.v1.ITaggedEntry, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Calls CreateTaxonomy. - * @param request CreateTaxonomyRequest message or plain object - * @returns Promise + * Encodes the specified TaggedEntry message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TaggedEntry.verify|verify} messages. + * @param message TaggedEntry message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer */ - public createTaxonomy(request: google.cloud.datacatalog.v1.ICreateTaxonomyRequest): Promise; + public static encodeDelimited(message: google.cloud.datacatalog.v1.ITaggedEntry, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Calls DeleteTaxonomy. - * @param request DeleteTaxonomyRequest message or plain object - * @param callback Node-style callback called with the error, if any, and Empty + * Decodes a TaggedEntry message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns TaggedEntry + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public deleteTaxonomy(request: google.cloud.datacatalog.v1.IDeleteTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.DeleteTaxonomyCallback): void; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.TaggedEntry; /** - * Calls DeleteTaxonomy. - * @param request DeleteTaxonomyRequest message or plain object - * @returns Promise + * Decodes a TaggedEntry message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns TaggedEntry + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public deleteTaxonomy(request: google.cloud.datacatalog.v1.IDeleteTaxonomyRequest): Promise; + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.TaggedEntry; /** - * Calls UpdateTaxonomy. - * @param request UpdateTaxonomyRequest message or plain object - * @param callback Node-style callback called with the error, if any, and Taxonomy + * Verifies a TaggedEntry message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not */ - public updateTaxonomy(request: google.cloud.datacatalog.v1.IUpdateTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.UpdateTaxonomyCallback): void; + public static verify(message: { [k: string]: any }): (string|null); /** - * Calls UpdateTaxonomy. - * @param request UpdateTaxonomyRequest message or plain object - * @returns Promise + * Creates a TaggedEntry message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns TaggedEntry */ - public updateTaxonomy(request: google.cloud.datacatalog.v1.IUpdateTaxonomyRequest): Promise; + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.TaggedEntry; /** - * Calls ListTaxonomies. - * @param request ListTaxonomiesRequest message or plain object - * @param callback Node-style callback called with the error, if any, and ListTaxonomiesResponse + * Creates a plain object from a TaggedEntry message. Also converts values to other types if specified. + * @param message TaggedEntry + * @param [options] Conversion options + * @returns Plain object */ - public listTaxonomies(request: google.cloud.datacatalog.v1.IListTaxonomiesRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.ListTaxonomiesCallback): void; + public static toObject(message: google.cloud.datacatalog.v1.TaggedEntry, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Calls ListTaxonomies. - * @param request ListTaxonomiesRequest message or plain object - * @returns Promise + * Converts this TaggedEntry to JSON. + * @returns JSON object */ - public listTaxonomies(request: google.cloud.datacatalog.v1.IListTaxonomiesRequest): Promise; + public toJSON(): { [k: string]: any }; /** - * Calls GetTaxonomy. - * @param request GetTaxonomyRequest message or plain object - * @param callback Node-style callback called with the error, if any, and Taxonomy + * Gets the default type url for TaggedEntry + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url */ - public getTaxonomy(request: google.cloud.datacatalog.v1.IGetTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.GetTaxonomyCallback): void; + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a DumpItem. */ + interface IDumpItem { + + /** DumpItem taggedEntry */ + taggedEntry?: (google.cloud.datacatalog.v1.ITaggedEntry|null); + } + + /** Represents a DumpItem. */ + class DumpItem implements IDumpItem { /** - * Calls GetTaxonomy. - * @param request GetTaxonomyRequest message or plain object - * @returns Promise + * Constructs a new DumpItem. + * @param [properties] Properties to set */ - public getTaxonomy(request: google.cloud.datacatalog.v1.IGetTaxonomyRequest): Promise; + constructor(properties?: google.cloud.datacatalog.v1.IDumpItem); + + /** DumpItem taggedEntry. */ + public taggedEntry?: (google.cloud.datacatalog.v1.ITaggedEntry|null); + + /** DumpItem item. */ + public item?: "taggedEntry"; /** - * Calls CreatePolicyTag. - * @param request CreatePolicyTagRequest message or plain object - * @param callback Node-style callback called with the error, if any, and PolicyTag + * Creates a new DumpItem instance using the specified properties. + * @param [properties] Properties to set + * @returns DumpItem instance */ - public createPolicyTag(request: google.cloud.datacatalog.v1.ICreatePolicyTagRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.CreatePolicyTagCallback): void; + public static create(properties?: google.cloud.datacatalog.v1.IDumpItem): google.cloud.datacatalog.v1.DumpItem; /** - * Calls CreatePolicyTag. - * @param request CreatePolicyTagRequest message or plain object - * @returns Promise + * Encodes the specified DumpItem message. Does not implicitly {@link google.cloud.datacatalog.v1.DumpItem.verify|verify} messages. + * @param message DumpItem message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer */ - public createPolicyTag(request: google.cloud.datacatalog.v1.ICreatePolicyTagRequest): Promise; + public static encode(message: google.cloud.datacatalog.v1.IDumpItem, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Calls DeletePolicyTag. - * @param request DeletePolicyTagRequest message or plain object - * @param callback Node-style callback called with the error, if any, and Empty - */ + * Encodes the specified DumpItem message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DumpItem.verify|verify} messages. + * @param message DumpItem message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.IDumpItem, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a DumpItem message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns DumpItem + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.DumpItem; + + /** + * Decodes a DumpItem message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns DumpItem + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.DumpItem; + + /** + * Verifies a DumpItem message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a DumpItem message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns DumpItem + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.DumpItem; + + /** + * Creates a plain object from a DumpItem message. Also converts values to other types if specified. + * @param message DumpItem + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.DumpItem, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this DumpItem to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for DumpItem + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Represents a PolicyTagManager */ + class PolicyTagManager extends $protobuf.rpc.Service { + + /** + * Constructs a new PolicyTagManager service. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + */ + constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean); + + /** + * Creates new PolicyTagManager service using the specified rpc implementation. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + * @returns RPC service. Useful where requests and/or responses are streamed. + */ + public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): PolicyTagManager; + + /** + * Calls CreateTaxonomy. + * @param request CreateTaxonomyRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Taxonomy + */ + public createTaxonomy(request: google.cloud.datacatalog.v1.ICreateTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.CreateTaxonomyCallback): void; + + /** + * Calls CreateTaxonomy. + * @param request CreateTaxonomyRequest message or plain object + * @returns Promise + */ + public createTaxonomy(request: google.cloud.datacatalog.v1.ICreateTaxonomyRequest): Promise; + + /** + * Calls DeleteTaxonomy. + * @param request DeleteTaxonomyRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Empty + */ + public deleteTaxonomy(request: google.cloud.datacatalog.v1.IDeleteTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.DeleteTaxonomyCallback): void; + + /** + * Calls DeleteTaxonomy. + * @param request DeleteTaxonomyRequest message or plain object + * @returns Promise + */ + public deleteTaxonomy(request: google.cloud.datacatalog.v1.IDeleteTaxonomyRequest): Promise; + + /** + * Calls UpdateTaxonomy. + * @param request UpdateTaxonomyRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Taxonomy + */ + public updateTaxonomy(request: google.cloud.datacatalog.v1.IUpdateTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.UpdateTaxonomyCallback): void; + + /** + * Calls UpdateTaxonomy. + * @param request UpdateTaxonomyRequest message or plain object + * @returns Promise + */ + public updateTaxonomy(request: google.cloud.datacatalog.v1.IUpdateTaxonomyRequest): Promise; + + /** + * Calls ListTaxonomies. + * @param request ListTaxonomiesRequest message or plain object + * @param callback Node-style callback called with the error, if any, and ListTaxonomiesResponse + */ + public listTaxonomies(request: google.cloud.datacatalog.v1.IListTaxonomiesRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.ListTaxonomiesCallback): void; + + /** + * Calls ListTaxonomies. + * @param request ListTaxonomiesRequest message or plain object + * @returns Promise + */ + public listTaxonomies(request: google.cloud.datacatalog.v1.IListTaxonomiesRequest): Promise; + + /** + * Calls GetTaxonomy. + * @param request GetTaxonomyRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Taxonomy + */ + public getTaxonomy(request: google.cloud.datacatalog.v1.IGetTaxonomyRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.GetTaxonomyCallback): void; + + /** + * Calls GetTaxonomy. + * @param request GetTaxonomyRequest message or plain object + * @returns Promise + */ + public getTaxonomy(request: google.cloud.datacatalog.v1.IGetTaxonomyRequest): Promise; + + /** + * Calls CreatePolicyTag. + * @param request CreatePolicyTagRequest message or plain object + * @param callback Node-style callback called with the error, if any, and PolicyTag + */ + public createPolicyTag(request: google.cloud.datacatalog.v1.ICreatePolicyTagRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.CreatePolicyTagCallback): void; + + /** + * Calls CreatePolicyTag. + * @param request CreatePolicyTagRequest message or plain object + * @returns Promise + */ + public createPolicyTag(request: google.cloud.datacatalog.v1.ICreatePolicyTagRequest): Promise; + + /** + * Calls DeletePolicyTag. + * @param request DeletePolicyTagRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Empty + */ public deletePolicyTag(request: google.cloud.datacatalog.v1.IDeletePolicyTagRequest, callback: google.cloud.datacatalog.v1.PolicyTagManager.DeletePolicyTagCallback): void; /** @@ -10228,6 +11812,9 @@ export namespace google { /** Taxonomy activatedPolicyTypes */ activatedPolicyTypes?: (google.cloud.datacatalog.v1.Taxonomy.PolicyType[]|null); + + /** Taxonomy service */ + service?: (google.cloud.datacatalog.v1.Taxonomy.IService|null); } /** Represents a Taxonomy. */ @@ -10257,6 +11844,9 @@ export namespace google { /** Taxonomy activatedPolicyTypes. */ public activatedPolicyTypes: google.cloud.datacatalog.v1.Taxonomy.PolicyType[]; + /** Taxonomy service. */ + public service?: (google.cloud.datacatalog.v1.Taxonomy.IService|null); + /** * Creates a new Taxonomy instance using the specified properties. * @param [properties] Properties to set @@ -10342,6 +11932,109 @@ export namespace google { POLICY_TYPE_UNSPECIFIED = 0, FINE_GRAINED_ACCESS_CONTROL = 1 } + + /** Properties of a Service. */ + interface IService { + + /** Service name */ + name?: (google.cloud.datacatalog.v1.ManagingSystem|keyof typeof google.cloud.datacatalog.v1.ManagingSystem|null); + + /** Service identity */ + identity?: (string|null); + } + + /** Represents a Service. */ + class Service implements IService { + + /** + * Constructs a new Service. + * @param [properties] Properties to set + */ + constructor(properties?: google.cloud.datacatalog.v1.Taxonomy.IService); + + /** Service name. */ + public name: (google.cloud.datacatalog.v1.ManagingSystem|keyof typeof google.cloud.datacatalog.v1.ManagingSystem); + + /** Service identity. */ + public identity: string; + + /** + * Creates a new Service instance using the specified properties. + * @param [properties] Properties to set + * @returns Service instance + */ + public static create(properties?: google.cloud.datacatalog.v1.Taxonomy.IService): google.cloud.datacatalog.v1.Taxonomy.Service; + + /** + * Encodes the specified Service message. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.Service.verify|verify} messages. + * @param message Service message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.cloud.datacatalog.v1.Taxonomy.IService, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified Service message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.Service.verify|verify} messages. + * @param message Service message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.cloud.datacatalog.v1.Taxonomy.IService, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a Service message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Service + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.cloud.datacatalog.v1.Taxonomy.Service; + + /** + * Decodes a Service message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Service + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.cloud.datacatalog.v1.Taxonomy.Service; + + /** + * Verifies a Service message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a Service message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Service + */ + public static fromObject(object: { [k: string]: any }): google.cloud.datacatalog.v1.Taxonomy.Service; + + /** + * Creates a plain object from a Service message. Also converts values to other types if specified. + * @param message Service + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.cloud.datacatalog.v1.Taxonomy.Service, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this Service to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for Service + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } } /** Properties of a PolicyTag. */ @@ -10779,6 +12472,9 @@ export namespace google { /** ListTaxonomiesRequest pageToken */ pageToken?: (string|null); + + /** ListTaxonomiesRequest filter */ + filter?: (string|null); } /** Represents a ListTaxonomiesRequest. */ @@ -10799,6 +12495,9 @@ export namespace google { /** ListTaxonomiesRequest pageToken. */ public pageToken: string; + /** ListTaxonomiesRequest filter. */ + public filter: string; + /** * Creates a new ListTaxonomiesRequest instance using the specified properties. * @param [properties] Properties to set @@ -24398,6 +26097,9 @@ export namespace google { /** MethodOptions .google.api.methodSignature */ ".google.api.methodSignature"?: (string[]|null); + + /** MethodOptions .google.longrunning.operationInfo */ + ".google.longrunning.operationInfo"?: (google.longrunning.IOperationInfo|null); } /** Represents a MethodOptions. */ @@ -25397,85 +27099,291 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } - /** Properties of an Empty. */ - interface IEmpty { + /** Properties of an Any. */ + interface IAny { + + /** Any type_url */ + type_url?: (string|null); + + /** Any value */ + value?: (Uint8Array|string|null); } - /** Represents an Empty. */ - class Empty implements IEmpty { + /** Represents an Any. */ + class Any implements IAny { /** - * Constructs a new Empty. + * Constructs a new Any. * @param [properties] Properties to set */ - constructor(properties?: google.protobuf.IEmpty); + constructor(properties?: google.protobuf.IAny); + + /** Any type_url. */ + public type_url: string; + + /** Any value. */ + public value: (Uint8Array|string); /** - * Creates a new Empty instance using the specified properties. + * Creates a new Any instance using the specified properties. * @param [properties] Properties to set - * @returns Empty instance + * @returns Any instance */ - public static create(properties?: google.protobuf.IEmpty): google.protobuf.Empty; + public static create(properties?: google.protobuf.IAny): google.protobuf.Any; /** - * Encodes the specified Empty message. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. - * @param message Empty message or plain object to encode + * Encodes the specified Any message. Does not implicitly {@link google.protobuf.Any.verify|verify} messages. + * @param message Any message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encode(message: google.protobuf.IEmpty, writer?: $protobuf.Writer): $protobuf.Writer; + public static encode(message: google.protobuf.IAny, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified Empty message, length delimited. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. - * @param message Empty message or plain object to encode + * Encodes the specified Any message, length delimited. Does not implicitly {@link google.protobuf.Any.verify|verify} messages. + * @param message Any message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encodeDelimited(message: google.protobuf.IEmpty, writer?: $protobuf.Writer): $protobuf.Writer; + public static encodeDelimited(message: google.protobuf.IAny, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes an Empty message from the specified reader or buffer. + * Decodes an Any message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns Empty + * @returns Any * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.Empty; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.Any; /** - * Decodes an Empty message from the specified reader or buffer, length delimited. + * Decodes an Any message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns Empty + * @returns Any * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.Empty; + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.Any; /** - * Verifies an Empty message. + * Verifies an Any message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ public static verify(message: { [k: string]: any }): (string|null); /** - * Creates an Empty message from a plain object. Also converts values to their respective internal types. + * Creates an Any message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns Empty + * @returns Any */ - public static fromObject(object: { [k: string]: any }): google.protobuf.Empty; + public static fromObject(object: { [k: string]: any }): google.protobuf.Any; /** - * Creates a plain object from an Empty message. Also converts values to other types if specified. - * @param message Empty + * Creates a plain object from an Any message. Also converts values to other types if specified. + * @param message Any * @param [options] Conversion options * @returns Plain object */ - public static toObject(message: google.protobuf.Empty, options?: $protobuf.IConversionOptions): { [k: string]: any }; + public static toObject(message: google.protobuf.Any, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this Empty to JSON. + * Converts this Any to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for Any + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a Duration. */ + interface IDuration { + + /** Duration seconds */ + seconds?: (number|Long|string|null); + + /** Duration nanos */ + nanos?: (number|null); + } + + /** Represents a Duration. */ + class Duration implements IDuration { + + /** + * Constructs a new Duration. + * @param [properties] Properties to set + */ + constructor(properties?: google.protobuf.IDuration); + + /** Duration seconds. */ + public seconds: (number|Long|string); + + /** Duration nanos. */ + public nanos: number; + + /** + * Creates a new Duration instance using the specified properties. + * @param [properties] Properties to set + * @returns Duration instance + */ + public static create(properties?: google.protobuf.IDuration): google.protobuf.Duration; + + /** + * Encodes the specified Duration message. Does not implicitly {@link google.protobuf.Duration.verify|verify} messages. + * @param message Duration message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.protobuf.IDuration, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified Duration message, length delimited. Does not implicitly {@link google.protobuf.Duration.verify|verify} messages. + * @param message Duration message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.protobuf.IDuration, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a Duration message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Duration + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.Duration; + + /** + * Decodes a Duration message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Duration + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.Duration; + + /** + * Verifies a Duration message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a Duration message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Duration + */ + public static fromObject(object: { [k: string]: any }): google.protobuf.Duration; + + /** + * Creates a plain object from a Duration message. Also converts values to other types if specified. + * @param message Duration + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.protobuf.Duration, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this Duration to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for Duration + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of an Empty. */ + interface IEmpty { + } + + /** Represents an Empty. */ + class Empty implements IEmpty { + + /** + * Constructs a new Empty. + * @param [properties] Properties to set + */ + constructor(properties?: google.protobuf.IEmpty); + + /** + * Creates a new Empty instance using the specified properties. + * @param [properties] Properties to set + * @returns Empty instance + */ + public static create(properties?: google.protobuf.IEmpty): google.protobuf.Empty; + + /** + * Encodes the specified Empty message. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. + * @param message Empty message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.protobuf.IEmpty, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified Empty message, length delimited. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. + * @param message Empty message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.protobuf.IEmpty, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes an Empty message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Empty + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.protobuf.Empty; + + /** + * Decodes an Empty message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Empty + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.protobuf.Empty; + + /** + * Verifies an Empty message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates an Empty message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Empty + */ + public static fromObject(object: { [k: string]: any }): google.protobuf.Empty; + + /** + * Creates a plain object from an Empty message. Also converts values to other types if specified. + * @param message Empty + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.protobuf.Empty, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this Empty to JSON. * @returns JSON object */ public toJSON(): { [k: string]: any }; @@ -27005,4 +28913,1089 @@ export namespace google { public static getTypeUrl(typeUrlPrefix?: string): string; } } + + /** Namespace longrunning. */ + namespace longrunning { + + /** Represents an Operations */ + class Operations extends $protobuf.rpc.Service { + + /** + * Constructs a new Operations service. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + */ + constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean); + + /** + * Creates new Operations service using the specified rpc implementation. + * @param rpcImpl RPC implementation + * @param [requestDelimited=false] Whether requests are length-delimited + * @param [responseDelimited=false] Whether responses are length-delimited + * @returns RPC service. Useful where requests and/or responses are streamed. + */ + public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): Operations; + + /** + * Calls ListOperations. + * @param request ListOperationsRequest message or plain object + * @param callback Node-style callback called with the error, if any, and ListOperationsResponse + */ + public listOperations(request: google.longrunning.IListOperationsRequest, callback: google.longrunning.Operations.ListOperationsCallback): void; + + /** + * Calls ListOperations. + * @param request ListOperationsRequest message or plain object + * @returns Promise + */ + public listOperations(request: google.longrunning.IListOperationsRequest): Promise; + + /** + * Calls GetOperation. + * @param request GetOperationRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Operation + */ + public getOperation(request: google.longrunning.IGetOperationRequest, callback: google.longrunning.Operations.GetOperationCallback): void; + + /** + * Calls GetOperation. + * @param request GetOperationRequest message or plain object + * @returns Promise + */ + public getOperation(request: google.longrunning.IGetOperationRequest): Promise; + + /** + * Calls DeleteOperation. + * @param request DeleteOperationRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Empty + */ + public deleteOperation(request: google.longrunning.IDeleteOperationRequest, callback: google.longrunning.Operations.DeleteOperationCallback): void; + + /** + * Calls DeleteOperation. + * @param request DeleteOperationRequest message or plain object + * @returns Promise + */ + public deleteOperation(request: google.longrunning.IDeleteOperationRequest): Promise; + + /** + * Calls CancelOperation. + * @param request CancelOperationRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Empty + */ + public cancelOperation(request: google.longrunning.ICancelOperationRequest, callback: google.longrunning.Operations.CancelOperationCallback): void; + + /** + * Calls CancelOperation. + * @param request CancelOperationRequest message or plain object + * @returns Promise + */ + public cancelOperation(request: google.longrunning.ICancelOperationRequest): Promise; + + /** + * Calls WaitOperation. + * @param request WaitOperationRequest message or plain object + * @param callback Node-style callback called with the error, if any, and Operation + */ + public waitOperation(request: google.longrunning.IWaitOperationRequest, callback: google.longrunning.Operations.WaitOperationCallback): void; + + /** + * Calls WaitOperation. + * @param request WaitOperationRequest message or plain object + * @returns Promise + */ + public waitOperation(request: google.longrunning.IWaitOperationRequest): Promise; + } + + namespace Operations { + + /** + * Callback as used by {@link google.longrunning.Operations|listOperations}. + * @param error Error, if any + * @param [response] ListOperationsResponse + */ + type ListOperationsCallback = (error: (Error|null), response?: google.longrunning.ListOperationsResponse) => void; + + /** + * Callback as used by {@link google.longrunning.Operations|getOperation}. + * @param error Error, if any + * @param [response] Operation + */ + type GetOperationCallback = (error: (Error|null), response?: google.longrunning.Operation) => void; + + /** + * Callback as used by {@link google.longrunning.Operations|deleteOperation}. + * @param error Error, if any + * @param [response] Empty + */ + type DeleteOperationCallback = (error: (Error|null), response?: google.protobuf.Empty) => void; + + /** + * Callback as used by {@link google.longrunning.Operations|cancelOperation}. + * @param error Error, if any + * @param [response] Empty + */ + type CancelOperationCallback = (error: (Error|null), response?: google.protobuf.Empty) => void; + + /** + * Callback as used by {@link google.longrunning.Operations|waitOperation}. + * @param error Error, if any + * @param [response] Operation + */ + type WaitOperationCallback = (error: (Error|null), response?: google.longrunning.Operation) => void; + } + + /** Properties of an Operation. */ + interface IOperation { + + /** Operation name */ + name?: (string|null); + + /** Operation metadata */ + metadata?: (google.protobuf.IAny|null); + + /** Operation done */ + done?: (boolean|null); + + /** Operation error */ + error?: (google.rpc.IStatus|null); + + /** Operation response */ + response?: (google.protobuf.IAny|null); + } + + /** Represents an Operation. */ + class Operation implements IOperation { + + /** + * Constructs a new Operation. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IOperation); + + /** Operation name. */ + public name: string; + + /** Operation metadata. */ + public metadata?: (google.protobuf.IAny|null); + + /** Operation done. */ + public done: boolean; + + /** Operation error. */ + public error?: (google.rpc.IStatus|null); + + /** Operation response. */ + public response?: (google.protobuf.IAny|null); + + /** Operation result. */ + public result?: ("error"|"response"); + + /** + * Creates a new Operation instance using the specified properties. + * @param [properties] Properties to set + * @returns Operation instance + */ + public static create(properties?: google.longrunning.IOperation): google.longrunning.Operation; + + /** + * Encodes the specified Operation message. Does not implicitly {@link google.longrunning.Operation.verify|verify} messages. + * @param message Operation message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IOperation, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified Operation message, length delimited. Does not implicitly {@link google.longrunning.Operation.verify|verify} messages. + * @param message Operation message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IOperation, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes an Operation message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Operation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.Operation; + + /** + * Decodes an Operation message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Operation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.Operation; + + /** + * Verifies an Operation message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates an Operation message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Operation + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.Operation; + + /** + * Creates a plain object from an Operation message. Also converts values to other types if specified. + * @param message Operation + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.Operation, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this Operation to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for Operation + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a GetOperationRequest. */ + interface IGetOperationRequest { + + /** GetOperationRequest name */ + name?: (string|null); + } + + /** Represents a GetOperationRequest. */ + class GetOperationRequest implements IGetOperationRequest { + + /** + * Constructs a new GetOperationRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IGetOperationRequest); + + /** GetOperationRequest name. */ + public name: string; + + /** + * Creates a new GetOperationRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns GetOperationRequest instance + */ + public static create(properties?: google.longrunning.IGetOperationRequest): google.longrunning.GetOperationRequest; + + /** + * Encodes the specified GetOperationRequest message. Does not implicitly {@link google.longrunning.GetOperationRequest.verify|verify} messages. + * @param message GetOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IGetOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified GetOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.GetOperationRequest.verify|verify} messages. + * @param message GetOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IGetOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a GetOperationRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns GetOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.GetOperationRequest; + + /** + * Decodes a GetOperationRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns GetOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.GetOperationRequest; + + /** + * Verifies a GetOperationRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a GetOperationRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns GetOperationRequest + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.GetOperationRequest; + + /** + * Creates a plain object from a GetOperationRequest message. Also converts values to other types if specified. + * @param message GetOperationRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.GetOperationRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this GetOperationRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for GetOperationRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a ListOperationsRequest. */ + interface IListOperationsRequest { + + /** ListOperationsRequest name */ + name?: (string|null); + + /** ListOperationsRequest filter */ + filter?: (string|null); + + /** ListOperationsRequest pageSize */ + pageSize?: (number|null); + + /** ListOperationsRequest pageToken */ + pageToken?: (string|null); + } + + /** Represents a ListOperationsRequest. */ + class ListOperationsRequest implements IListOperationsRequest { + + /** + * Constructs a new ListOperationsRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IListOperationsRequest); + + /** ListOperationsRequest name. */ + public name: string; + + /** ListOperationsRequest filter. */ + public filter: string; + + /** ListOperationsRequest pageSize. */ + public pageSize: number; + + /** ListOperationsRequest pageToken. */ + public pageToken: string; + + /** + * Creates a new ListOperationsRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns ListOperationsRequest instance + */ + public static create(properties?: google.longrunning.IListOperationsRequest): google.longrunning.ListOperationsRequest; + + /** + * Encodes the specified ListOperationsRequest message. Does not implicitly {@link google.longrunning.ListOperationsRequest.verify|verify} messages. + * @param message ListOperationsRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IListOperationsRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ListOperationsRequest message, length delimited. Does not implicitly {@link google.longrunning.ListOperationsRequest.verify|verify} messages. + * @param message ListOperationsRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IListOperationsRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ListOperationsRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ListOperationsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.ListOperationsRequest; + + /** + * Decodes a ListOperationsRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ListOperationsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.ListOperationsRequest; + + /** + * Verifies a ListOperationsRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ListOperationsRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ListOperationsRequest + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.ListOperationsRequest; + + /** + * Creates a plain object from a ListOperationsRequest message. Also converts values to other types if specified. + * @param message ListOperationsRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.ListOperationsRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ListOperationsRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ListOperationsRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a ListOperationsResponse. */ + interface IListOperationsResponse { + + /** ListOperationsResponse operations */ + operations?: (google.longrunning.IOperation[]|null); + + /** ListOperationsResponse nextPageToken */ + nextPageToken?: (string|null); + } + + /** Represents a ListOperationsResponse. */ + class ListOperationsResponse implements IListOperationsResponse { + + /** + * Constructs a new ListOperationsResponse. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IListOperationsResponse); + + /** ListOperationsResponse operations. */ + public operations: google.longrunning.IOperation[]; + + /** ListOperationsResponse nextPageToken. */ + public nextPageToken: string; + + /** + * Creates a new ListOperationsResponse instance using the specified properties. + * @param [properties] Properties to set + * @returns ListOperationsResponse instance + */ + public static create(properties?: google.longrunning.IListOperationsResponse): google.longrunning.ListOperationsResponse; + + /** + * Encodes the specified ListOperationsResponse message. Does not implicitly {@link google.longrunning.ListOperationsResponse.verify|verify} messages. + * @param message ListOperationsResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IListOperationsResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified ListOperationsResponse message, length delimited. Does not implicitly {@link google.longrunning.ListOperationsResponse.verify|verify} messages. + * @param message ListOperationsResponse message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IListOperationsResponse, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a ListOperationsResponse message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns ListOperationsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.ListOperationsResponse; + + /** + * Decodes a ListOperationsResponse message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns ListOperationsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.ListOperationsResponse; + + /** + * Verifies a ListOperationsResponse message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a ListOperationsResponse message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns ListOperationsResponse + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.ListOperationsResponse; + + /** + * Creates a plain object from a ListOperationsResponse message. Also converts values to other types if specified. + * @param message ListOperationsResponse + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.ListOperationsResponse, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this ListOperationsResponse to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for ListOperationsResponse + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a CancelOperationRequest. */ + interface ICancelOperationRequest { + + /** CancelOperationRequest name */ + name?: (string|null); + } + + /** Represents a CancelOperationRequest. */ + class CancelOperationRequest implements ICancelOperationRequest { + + /** + * Constructs a new CancelOperationRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.ICancelOperationRequest); + + /** CancelOperationRequest name. */ + public name: string; + + /** + * Creates a new CancelOperationRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns CancelOperationRequest instance + */ + public static create(properties?: google.longrunning.ICancelOperationRequest): google.longrunning.CancelOperationRequest; + + /** + * Encodes the specified CancelOperationRequest message. Does not implicitly {@link google.longrunning.CancelOperationRequest.verify|verify} messages. + * @param message CancelOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.ICancelOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified CancelOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.CancelOperationRequest.verify|verify} messages. + * @param message CancelOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.ICancelOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a CancelOperationRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns CancelOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.CancelOperationRequest; + + /** + * Decodes a CancelOperationRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns CancelOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.CancelOperationRequest; + + /** + * Verifies a CancelOperationRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a CancelOperationRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns CancelOperationRequest + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.CancelOperationRequest; + + /** + * Creates a plain object from a CancelOperationRequest message. Also converts values to other types if specified. + * @param message CancelOperationRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.CancelOperationRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this CancelOperationRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for CancelOperationRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a DeleteOperationRequest. */ + interface IDeleteOperationRequest { + + /** DeleteOperationRequest name */ + name?: (string|null); + } + + /** Represents a DeleteOperationRequest. */ + class DeleteOperationRequest implements IDeleteOperationRequest { + + /** + * Constructs a new DeleteOperationRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IDeleteOperationRequest); + + /** DeleteOperationRequest name. */ + public name: string; + + /** + * Creates a new DeleteOperationRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns DeleteOperationRequest instance + */ + public static create(properties?: google.longrunning.IDeleteOperationRequest): google.longrunning.DeleteOperationRequest; + + /** + * Encodes the specified DeleteOperationRequest message. Does not implicitly {@link google.longrunning.DeleteOperationRequest.verify|verify} messages. + * @param message DeleteOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IDeleteOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified DeleteOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.DeleteOperationRequest.verify|verify} messages. + * @param message DeleteOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IDeleteOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a DeleteOperationRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns DeleteOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.DeleteOperationRequest; + + /** + * Decodes a DeleteOperationRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns DeleteOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.DeleteOperationRequest; + + /** + * Verifies a DeleteOperationRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a DeleteOperationRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns DeleteOperationRequest + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.DeleteOperationRequest; + + /** + * Creates a plain object from a DeleteOperationRequest message. Also converts values to other types if specified. + * @param message DeleteOperationRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.DeleteOperationRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this DeleteOperationRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for DeleteOperationRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of a WaitOperationRequest. */ + interface IWaitOperationRequest { + + /** WaitOperationRequest name */ + name?: (string|null); + + /** WaitOperationRequest timeout */ + timeout?: (google.protobuf.IDuration|null); + } + + /** Represents a WaitOperationRequest. */ + class WaitOperationRequest implements IWaitOperationRequest { + + /** + * Constructs a new WaitOperationRequest. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IWaitOperationRequest); + + /** WaitOperationRequest name. */ + public name: string; + + /** WaitOperationRequest timeout. */ + public timeout?: (google.protobuf.IDuration|null); + + /** + * Creates a new WaitOperationRequest instance using the specified properties. + * @param [properties] Properties to set + * @returns WaitOperationRequest instance + */ + public static create(properties?: google.longrunning.IWaitOperationRequest): google.longrunning.WaitOperationRequest; + + /** + * Encodes the specified WaitOperationRequest message. Does not implicitly {@link google.longrunning.WaitOperationRequest.verify|verify} messages. + * @param message WaitOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IWaitOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified WaitOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.WaitOperationRequest.verify|verify} messages. + * @param message WaitOperationRequest message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IWaitOperationRequest, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a WaitOperationRequest message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns WaitOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.WaitOperationRequest; + + /** + * Decodes a WaitOperationRequest message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns WaitOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.WaitOperationRequest; + + /** + * Verifies a WaitOperationRequest message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a WaitOperationRequest message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns WaitOperationRequest + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.WaitOperationRequest; + + /** + * Creates a plain object from a WaitOperationRequest message. Also converts values to other types if specified. + * @param message WaitOperationRequest + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.WaitOperationRequest, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this WaitOperationRequest to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for WaitOperationRequest + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + + /** Properties of an OperationInfo. */ + interface IOperationInfo { + + /** OperationInfo responseType */ + responseType?: (string|null); + + /** OperationInfo metadataType */ + metadataType?: (string|null); + } + + /** Represents an OperationInfo. */ + class OperationInfo implements IOperationInfo { + + /** + * Constructs a new OperationInfo. + * @param [properties] Properties to set + */ + constructor(properties?: google.longrunning.IOperationInfo); + + /** OperationInfo responseType. */ + public responseType: string; + + /** OperationInfo metadataType. */ + public metadataType: string; + + /** + * Creates a new OperationInfo instance using the specified properties. + * @param [properties] Properties to set + * @returns OperationInfo instance + */ + public static create(properties?: google.longrunning.IOperationInfo): google.longrunning.OperationInfo; + + /** + * Encodes the specified OperationInfo message. Does not implicitly {@link google.longrunning.OperationInfo.verify|verify} messages. + * @param message OperationInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.longrunning.IOperationInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified OperationInfo message, length delimited. Does not implicitly {@link google.longrunning.OperationInfo.verify|verify} messages. + * @param message OperationInfo message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.longrunning.IOperationInfo, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes an OperationInfo message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns OperationInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.longrunning.OperationInfo; + + /** + * Decodes an OperationInfo message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns OperationInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.longrunning.OperationInfo; + + /** + * Verifies an OperationInfo message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates an OperationInfo message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns OperationInfo + */ + public static fromObject(object: { [k: string]: any }): google.longrunning.OperationInfo; + + /** + * Creates a plain object from an OperationInfo message. Also converts values to other types if specified. + * @param message OperationInfo + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.longrunning.OperationInfo, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this OperationInfo to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for OperationInfo + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + } + + /** Namespace rpc. */ + namespace rpc { + + /** Properties of a Status. */ + interface IStatus { + + /** Status code */ + code?: (number|null); + + /** Status message */ + message?: (string|null); + + /** Status details */ + details?: (google.protobuf.IAny[]|null); + } + + /** Represents a Status. */ + class Status implements IStatus { + + /** + * Constructs a new Status. + * @param [properties] Properties to set + */ + constructor(properties?: google.rpc.IStatus); + + /** Status code. */ + public code: number; + + /** Status message. */ + public message: string; + + /** Status details. */ + public details: google.protobuf.IAny[]; + + /** + * Creates a new Status instance using the specified properties. + * @param [properties] Properties to set + * @returns Status instance + */ + public static create(properties?: google.rpc.IStatus): google.rpc.Status; + + /** + * Encodes the specified Status message. Does not implicitly {@link google.rpc.Status.verify|verify} messages. + * @param message Status message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: google.rpc.IStatus, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified Status message, length delimited. Does not implicitly {@link google.rpc.Status.verify|verify} messages. + * @param message Status message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: google.rpc.IStatus, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a Status message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns Status + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): google.rpc.Status; + + /** + * Decodes a Status message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns Status + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): google.rpc.Status; + + /** + * Verifies a Status message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a Status message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns Status + */ + public static fromObject(object: { [k: string]: any }): google.rpc.Status; + + /** + * Creates a plain object from a Status message. Also converts values to other types if specified. + * @param message Status + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: google.rpc.Status, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this Status to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + + /** + * Gets the default type url for Status + * @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns The default type url + */ + public static getTypeUrl(typeUrlPrefix?: string): string; + } + } } diff --git a/packages/google-cloud-datacatalog/protos/protos.js b/packages/google-cloud-datacatalog/protos/protos.js index df0201bb427..5b8153718d7 100644 --- a/packages/google-cloud-datacatalog/protos/protos.js +++ b/packages/google-cloud-datacatalog/protos/protos.js @@ -1124,6 +1124,8 @@ * @property {number} CLOUD_PUBSUB=2 CLOUD_PUBSUB value * @property {number} DATAPROC_METASTORE=3 DATAPROC_METASTORE value * @property {number} DATAPLEX=4 DATAPLEX value + * @property {number} CLOUD_SQL=8 CLOUD_SQL value + * @property {number} LOOKER=9 LOOKER value */ v1.IntegratedSystem = (function() { var valuesById = {}, values = Object.create(valuesById); @@ -1132,6 +1134,24 @@ values[valuesById[2] = "CLOUD_PUBSUB"] = 2; values[valuesById[3] = "DATAPROC_METASTORE"] = 3; values[valuesById[4] = "DATAPLEX"] = 4; + values[valuesById[8] = "CLOUD_SQL"] = 8; + values[valuesById[9] = "LOOKER"] = 9; + return values; + })(); + + /** + * ManagingSystem enum. + * @name google.cloud.datacatalog.v1.ManagingSystem + * @enum {number} + * @property {number} MANAGING_SYSTEM_UNSPECIFIED=0 MANAGING_SYSTEM_UNSPECIFIED value + * @property {number} MANAGING_SYSTEM_DATAPLEX=1 MANAGING_SYSTEM_DATAPLEX value + * @property {number} MANAGING_SYSTEM_OTHER=2 MANAGING_SYSTEM_OTHER value + */ + v1.ManagingSystem = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "MANAGING_SYSTEM_UNSPECIFIED"] = 0; + values[valuesById[1] = "MANAGING_SYSTEM_DATAPLEX"] = 1; + values[valuesById[2] = "MANAGING_SYSTEM_OTHER"] = 2; return values; })(); @@ -2639,6 +2659,39 @@ * @variation 2 */ + /** + * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|reconcileTags}. + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @typedef ReconcileTagsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation + */ + + /** + * Calls ReconcileTags. + * @function reconcileTags + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest} request ReconcileTagsRequest message or plain object + * @param {google.cloud.datacatalog.v1.DataCatalog.ReconcileTagsCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(DataCatalog.prototype.reconcileTags = function reconcileTags(request, callback) { + return this.rpcCall(reconcileTags, $root.google.cloud.datacatalog.v1.ReconcileTagsRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "ReconcileTags" }); + + /** + * Calls ReconcileTags. + * @function reconcileTags + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest} request ReconcileTagsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + /** * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|starEntry}. * @memberof google.cloud.datacatalog.v1.DataCatalog @@ -2804,6 +2857,39 @@ * @variation 2 */ + /** + * Callback as used by {@link google.cloud.datacatalog.v1.DataCatalog|importEntries}. + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @typedef ImportEntriesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation + */ + + /** + * Calls ImportEntries. + * @function importEntries + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest} request ImportEntriesRequest message or plain object + * @param {google.cloud.datacatalog.v1.DataCatalog.ImportEntriesCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(DataCatalog.prototype.importEntries = function importEntries(request, callback) { + return this.rpcCall(importEntries, $root.google.cloud.datacatalog.v1.ImportEntriesRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "ImportEntries" }); + + /** + * Calls ImportEntries. + * @function importEntries + * @memberof google.cloud.datacatalog.v1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest} request ImportEntriesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + return DataCatalog; })(); @@ -6404,6 +6490,8 @@ * @property {string|null} [userSpecifiedType] Entry userSpecifiedType * @property {google.cloud.datacatalog.v1.IntegratedSystem|null} [integratedSystem] Entry integratedSystem * @property {string|null} [userSpecifiedSystem] Entry userSpecifiedSystem + * @property {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec|null} [sqlDatabaseSystemSpec] Entry sqlDatabaseSystemSpec + * @property {google.cloud.datacatalog.v1.ILookerSystemSpec|null} [lookerSystemSpec] Entry lookerSystemSpec * @property {google.cloud.datacatalog.v1.IGcsFilesetSpec|null} [gcsFilesetSpec] Entry gcsFilesetSpec * @property {google.cloud.datacatalog.v1.IBigQueryTableSpec|null} [bigqueryTableSpec] Entry bigqueryTableSpec * @property {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec|null} [bigqueryDateShardedSpec] Entry bigqueryDateShardedSpec @@ -6494,6 +6582,22 @@ */ Entry.prototype.userSpecifiedSystem = null; + /** + * Entry sqlDatabaseSystemSpec. + * @member {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec|null|undefined} sqlDatabaseSystemSpec + * @memberof google.cloud.datacatalog.v1.Entry + * @instance + */ + Entry.prototype.sqlDatabaseSystemSpec = null; + + /** + * Entry lookerSystemSpec. + * @member {google.cloud.datacatalog.v1.ILookerSystemSpec|null|undefined} lookerSystemSpec + * @memberof google.cloud.datacatalog.v1.Entry + * @instance + */ + Entry.prototype.lookerSystemSpec = null; + /** * Entry gcsFilesetSpec. * @member {google.cloud.datacatalog.v1.IGcsFilesetSpec|null|undefined} gcsFilesetSpec @@ -6647,6 +6751,17 @@ set: $util.oneOfSetter($oneOfFields) }); + /** + * Entry systemSpec. + * @member {"sqlDatabaseSystemSpec"|"lookerSystemSpec"|undefined} systemSpec + * @memberof google.cloud.datacatalog.v1.Entry + * @instance + */ + Object.defineProperty(Entry.prototype, "systemSpec", { + get: $util.oneOfGetter($oneOfFields = ["sqlDatabaseSystemSpec", "lookerSystemSpec"]), + set: $util.oneOfSetter($oneOfFields) + }); + /** * Entry typeSpec. * @member {"gcsFilesetSpec"|"bigqueryTableSpec"|"bigqueryDateShardedSpec"|undefined} typeSpec @@ -6740,6 +6855,10 @@ $root.google.cloud.datacatalog.v1.FilesetSpec.encode(message.filesetSpec, writer.uint32(/* id 33, wireType 2 =*/266).fork()).ldelim(); if (message.businessContext != null && Object.hasOwnProperty.call(message, "businessContext")) $root.google.cloud.datacatalog.v1.BusinessContext.encode(message.businessContext, writer.uint32(/* id 37, wireType 2 =*/298).fork()).ldelim(); + if (message.sqlDatabaseSystemSpec != null && Object.hasOwnProperty.call(message, "sqlDatabaseSystemSpec")) + $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.encode(message.sqlDatabaseSystemSpec, writer.uint32(/* id 39, wireType 2 =*/314).fork()).ldelim(); + if (message.lookerSystemSpec != null && Object.hasOwnProperty.call(message, "lookerSystemSpec")) + $root.google.cloud.datacatalog.v1.LookerSystemSpec.encode(message.lookerSystemSpec, writer.uint32(/* id 40, wireType 2 =*/322).fork()).ldelim(); return writer; }; @@ -6802,6 +6921,14 @@ message.userSpecifiedSystem = reader.string(); break; } + case 39: { + message.sqlDatabaseSystemSpec = $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.decode(reader, reader.uint32()); + break; + } + case 40: { + message.lookerSystemSpec = $root.google.cloud.datacatalog.v1.LookerSystemSpec.decode(reader, reader.uint32()); + break; + } case 6: { message.gcsFilesetSpec = $root.google.cloud.datacatalog.v1.GcsFilesetSpec.decode(reader, reader.uint32()); break; @@ -6947,6 +7074,10 @@ case 10: case 11: case 14: + case 15: + case 16: + case 17: + case 18: break; } } @@ -6967,6 +7098,8 @@ case 2: case 3: case 4: + case 8: + case 9: break; } } @@ -6977,6 +7110,24 @@ if (!$util.isString(message.userSpecifiedSystem)) return "userSpecifiedSystem: string expected"; } + if (message.sqlDatabaseSystemSpec != null && message.hasOwnProperty("sqlDatabaseSystemSpec")) { + properties.systemSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.verify(message.sqlDatabaseSystemSpec); + if (error) + return "sqlDatabaseSystemSpec." + error; + } + } + if (message.lookerSystemSpec != null && message.hasOwnProperty("lookerSystemSpec")) { + if (properties.systemSpec === 1) + return "systemSpec: multiple values"; + properties.systemSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1.LookerSystemSpec.verify(message.lookerSystemSpec); + if (error) + return "lookerSystemSpec." + error; + } + } if (message.gcsFilesetSpec != null && message.hasOwnProperty("gcsFilesetSpec")) { properties.typeSpec = 1; { @@ -7163,6 +7314,22 @@ case 14: message.type = 14; break; + case "DATABASE_SCHEMA": + case 15: + message.type = 15; + break; + case "DASHBOARD": + case 16: + message.type = 16; + break; + case "EXPLORE": + case 17: + message.type = 17; + break; + case "LOOK": + case 18: + message.type = 18; + break; } if (object.userSpecifiedType != null) message.userSpecifiedType = String(object.userSpecifiedType); @@ -7193,9 +7360,27 @@ case 4: message.integratedSystem = 4; break; + case "CLOUD_SQL": + case 8: + message.integratedSystem = 8; + break; + case "LOOKER": + case 9: + message.integratedSystem = 9; + break; } if (object.userSpecifiedSystem != null) message.userSpecifiedSystem = String(object.userSpecifiedSystem); + if (object.sqlDatabaseSystemSpec != null) { + if (typeof object.sqlDatabaseSystemSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Entry.sqlDatabaseSystemSpec: object expected"); + message.sqlDatabaseSystemSpec = $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.fromObject(object.sqlDatabaseSystemSpec); + } + if (object.lookerSystemSpec != null) { + if (typeof object.lookerSystemSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Entry.lookerSystemSpec: object expected"); + message.lookerSystemSpec = $root.google.cloud.datacatalog.v1.LookerSystemSpec.fromObject(object.lookerSystemSpec); + } if (object.gcsFilesetSpec != null) { if (typeof object.gcsFilesetSpec !== "object") throw TypeError(".google.cloud.datacatalog.v1.Entry.gcsFilesetSpec: object expected"); @@ -7386,6 +7571,16 @@ } if (message.businessContext != null && message.hasOwnProperty("businessContext")) object.businessContext = $root.google.cloud.datacatalog.v1.BusinessContext.toObject(message.businessContext, options); + if (message.sqlDatabaseSystemSpec != null && message.hasOwnProperty("sqlDatabaseSystemSpec")) { + object.sqlDatabaseSystemSpec = $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.toObject(message.sqlDatabaseSystemSpec, options); + if (options.oneofs) + object.systemSpec = "sqlDatabaseSystemSpec"; + } + if (message.lookerSystemSpec != null && message.hasOwnProperty("lookerSystemSpec")) { + object.lookerSystemSpec = $root.google.cloud.datacatalog.v1.LookerSystemSpec.toObject(message.lookerSystemSpec, options); + if (options.oneofs) + object.systemSpec = "lookerSystemSpec"; + } return object; }; @@ -7426,6 +7621,7 @@ * @interface IDatabaseTableSpec * @property {google.cloud.datacatalog.v1.DatabaseTableSpec.TableType|null} [type] DatabaseTableSpec type * @property {google.cloud.datacatalog.v1.IDataplexTableSpec|null} [dataplexTable] DatabaseTableSpec dataplexTable + * @property {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec|null} [databaseViewSpec] DatabaseTableSpec databaseViewSpec */ /** @@ -7459,6 +7655,14 @@ */ DatabaseTableSpec.prototype.dataplexTable = null; + /** + * DatabaseTableSpec databaseViewSpec. + * @member {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec|null|undefined} databaseViewSpec + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec + * @instance + */ + DatabaseTableSpec.prototype.databaseViewSpec = null; + /** * Creates a new DatabaseTableSpec instance using the specified properties. * @function create @@ -7487,6 +7691,8 @@ writer.uint32(/* id 1, wireType 0 =*/8).int32(message.type); if (message.dataplexTable != null && Object.hasOwnProperty.call(message, "dataplexTable")) $root.google.cloud.datacatalog.v1.DataplexTableSpec.encode(message.dataplexTable, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.databaseViewSpec != null && Object.hasOwnProperty.call(message, "databaseViewSpec")) + $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.encode(message.databaseViewSpec, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; @@ -7529,6 +7735,10 @@ message.dataplexTable = $root.google.cloud.datacatalog.v1.DataplexTableSpec.decode(reader, reader.uint32()); break; } + case 3: { + message.databaseViewSpec = $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.decode(reader, reader.uint32()); + break; + } default: reader.skipType(tag & 7); break; @@ -7578,6 +7788,11 @@ if (error) return "dataplexTable." + error; } + if (message.databaseViewSpec != null && message.hasOwnProperty("databaseViewSpec")) { + var error = $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.verify(message.databaseViewSpec); + if (error) + return "databaseViewSpec." + error; + } return null; }; @@ -7618,6 +7833,11 @@ throw TypeError(".google.cloud.datacatalog.v1.DatabaseTableSpec.dataplexTable: object expected"); message.dataplexTable = $root.google.cloud.datacatalog.v1.DataplexTableSpec.fromObject(object.dataplexTable); } + if (object.databaseViewSpec != null) { + if (typeof object.databaseViewSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DatabaseTableSpec.databaseViewSpec: object expected"); + message.databaseViewSpec = $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.fromObject(object.databaseViewSpec); + } return message; }; @@ -7637,11 +7857,14 @@ if (options.defaults) { object.type = options.enums === String ? "TABLE_TYPE_UNSPECIFIED" : 0; object.dataplexTable = null; + object.databaseViewSpec = null; } if (message.type != null && message.hasOwnProperty("type")) object.type = options.enums === String ? $root.google.cloud.datacatalog.v1.DatabaseTableSpec.TableType[message.type] === undefined ? message.type : $root.google.cloud.datacatalog.v1.DatabaseTableSpec.TableType[message.type] : message.type; if (message.dataplexTable != null && message.hasOwnProperty("dataplexTable")) object.dataplexTable = $root.google.cloud.datacatalog.v1.DataplexTableSpec.toObject(message.dataplexTable, options); + if (message.databaseViewSpec != null && message.hasOwnProperty("databaseViewSpec")) + object.databaseViewSpec = $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.toObject(message.databaseViewSpec, options); return object; }; @@ -7687,6 +7910,320 @@ return values; })(); + DatabaseTableSpec.DatabaseViewSpec = (function() { + + /** + * Properties of a DatabaseViewSpec. + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec + * @interface IDatabaseViewSpec + * @property {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType|null} [viewType] DatabaseViewSpec viewType + * @property {string|null} [baseTable] DatabaseViewSpec baseTable + * @property {string|null} [sqlQuery] DatabaseViewSpec sqlQuery + */ + + /** + * Constructs a new DatabaseViewSpec. + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec + * @classdesc Represents a DatabaseViewSpec. + * @implements IDatabaseViewSpec + * @constructor + * @param {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec=} [properties] Properties to set + */ + function DatabaseViewSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * DatabaseViewSpec viewType. + * @member {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType} viewType + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @instance + */ + DatabaseViewSpec.prototype.viewType = 0; + + /** + * DatabaseViewSpec baseTable. + * @member {string|null|undefined} baseTable + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @instance + */ + DatabaseViewSpec.prototype.baseTable = null; + + /** + * DatabaseViewSpec sqlQuery. + * @member {string|null|undefined} sqlQuery + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @instance + */ + DatabaseViewSpec.prototype.sqlQuery = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * DatabaseViewSpec sourceDefinition. + * @member {"baseTable"|"sqlQuery"|undefined} sourceDefinition + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @instance + */ + Object.defineProperty(DatabaseViewSpec.prototype, "sourceDefinition", { + get: $util.oneOfGetter($oneOfFields = ["baseTable", "sqlQuery"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new DatabaseViewSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec} DatabaseViewSpec instance + */ + DatabaseViewSpec.create = function create(properties) { + return new DatabaseViewSpec(properties); + }; + + /** + * Encodes the specified DatabaseViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec} message DatabaseViewSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DatabaseViewSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.viewType != null && Object.hasOwnProperty.call(message, "viewType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.viewType); + if (message.baseTable != null && Object.hasOwnProperty.call(message, "baseTable")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.baseTable); + if (message.sqlQuery != null && Object.hasOwnProperty.call(message, "sqlQuery")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.sqlQuery); + return writer; + }; + + /** + * Encodes the specified DatabaseViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {google.cloud.datacatalog.v1.DatabaseTableSpec.IDatabaseViewSpec} message DatabaseViewSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DatabaseViewSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a DatabaseViewSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec} DatabaseViewSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DatabaseViewSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.viewType = reader.int32(); + break; + } + case 2: { + message.baseTable = reader.string(); + break; + } + case 3: { + message.sqlQuery = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a DatabaseViewSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec} DatabaseViewSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DatabaseViewSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a DatabaseViewSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DatabaseViewSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.viewType != null && message.hasOwnProperty("viewType")) + switch (message.viewType) { + default: + return "viewType: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.baseTable != null && message.hasOwnProperty("baseTable")) { + properties.sourceDefinition = 1; + if (!$util.isString(message.baseTable)) + return "baseTable: string expected"; + } + if (message.sqlQuery != null && message.hasOwnProperty("sqlQuery")) { + if (properties.sourceDefinition === 1) + return "sourceDefinition: multiple values"; + properties.sourceDefinition = 1; + if (!$util.isString(message.sqlQuery)) + return "sqlQuery: string expected"; + } + return null; + }; + + /** + * Creates a DatabaseViewSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec} DatabaseViewSpec + */ + DatabaseViewSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec(); + switch (object.viewType) { + default: + if (typeof object.viewType === "number") { + message.viewType = object.viewType; + break; + } + break; + case "VIEW_TYPE_UNSPECIFIED": + case 0: + message.viewType = 0; + break; + case "STANDARD_VIEW": + case 1: + message.viewType = 1; + break; + case "MATERIALIZED_VIEW": + case 2: + message.viewType = 2; + break; + } + if (object.baseTable != null) + message.baseTable = String(object.baseTable); + if (object.sqlQuery != null) + message.sqlQuery = String(object.sqlQuery); + return message; + }; + + /** + * Creates a plain object from a DatabaseViewSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec} message DatabaseViewSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DatabaseViewSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.viewType = options.enums === String ? "VIEW_TYPE_UNSPECIFIED" : 0; + if (message.viewType != null && message.hasOwnProperty("viewType")) + object.viewType = options.enums === String ? $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType[message.viewType] === undefined ? message.viewType : $root.google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType[message.viewType] : message.viewType; + if (message.baseTable != null && message.hasOwnProperty("baseTable")) { + object.baseTable = message.baseTable; + if (options.oneofs) + object.sourceDefinition = "baseTable"; + } + if (message.sqlQuery != null && message.hasOwnProperty("sqlQuery")) { + object.sqlQuery = message.sqlQuery; + if (options.oneofs) + object.sourceDefinition = "sqlQuery"; + } + return object; + }; + + /** + * Converts this DatabaseViewSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @instance + * @returns {Object.} JSON object + */ + DatabaseViewSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for DatabaseViewSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DatabaseViewSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec"; + }; + + /** + * ViewType enum. + * @name google.cloud.datacatalog.v1.DatabaseTableSpec.DatabaseViewSpec.ViewType + * @enum {number} + * @property {number} VIEW_TYPE_UNSPECIFIED=0 VIEW_TYPE_UNSPECIFIED value + * @property {number} STANDARD_VIEW=1 STANDARD_VIEW value + * @property {number} MATERIALIZED_VIEW=2 MATERIALIZED_VIEW value + */ + DatabaseViewSpec.ViewType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "VIEW_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "STANDARD_VIEW"] = 1; + values[valuesById[2] = "MATERIALIZED_VIEW"] = 2; + return values; + })(); + + return DatabaseViewSpec; + })(); + return DatabaseTableSpec; })(); @@ -8809,6 +9346,575 @@ return RoutineSpec; })(); + v1.SqlDatabaseSystemSpec = (function() { + + /** + * Properties of a SqlDatabaseSystemSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface ISqlDatabaseSystemSpec + * @property {string|null} [sqlEngine] SqlDatabaseSystemSpec sqlEngine + * @property {string|null} [databaseVersion] SqlDatabaseSystemSpec databaseVersion + * @property {string|null} [instanceHost] SqlDatabaseSystemSpec instanceHost + */ + + /** + * Constructs a new SqlDatabaseSystemSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a SqlDatabaseSystemSpec. + * @implements ISqlDatabaseSystemSpec + * @constructor + * @param {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec=} [properties] Properties to set + */ + function SqlDatabaseSystemSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * SqlDatabaseSystemSpec sqlEngine. + * @member {string} sqlEngine + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @instance + */ + SqlDatabaseSystemSpec.prototype.sqlEngine = ""; + + /** + * SqlDatabaseSystemSpec databaseVersion. + * @member {string} databaseVersion + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @instance + */ + SqlDatabaseSystemSpec.prototype.databaseVersion = ""; + + /** + * SqlDatabaseSystemSpec instanceHost. + * @member {string} instanceHost + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @instance + */ + SqlDatabaseSystemSpec.prototype.instanceHost = ""; + + /** + * Creates a new SqlDatabaseSystemSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.SqlDatabaseSystemSpec} SqlDatabaseSystemSpec instance + */ + SqlDatabaseSystemSpec.create = function create(properties) { + return new SqlDatabaseSystemSpec(properties); + }; + + /** + * Encodes the specified SqlDatabaseSystemSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec} message SqlDatabaseSystemSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SqlDatabaseSystemSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.sqlEngine != null && Object.hasOwnProperty.call(message, "sqlEngine")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.sqlEngine); + if (message.databaseVersion != null && Object.hasOwnProperty.call(message, "databaseVersion")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.databaseVersion); + if (message.instanceHost != null && Object.hasOwnProperty.call(message, "instanceHost")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.instanceHost); + return writer; + }; + + /** + * Encodes the specified SqlDatabaseSystemSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SqlDatabaseSystemSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ISqlDatabaseSystemSpec} message SqlDatabaseSystemSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SqlDatabaseSystemSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a SqlDatabaseSystemSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.SqlDatabaseSystemSpec} SqlDatabaseSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SqlDatabaseSystemSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.sqlEngine = reader.string(); + break; + } + case 2: { + message.databaseVersion = reader.string(); + break; + } + case 3: { + message.instanceHost = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a SqlDatabaseSystemSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.SqlDatabaseSystemSpec} SqlDatabaseSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SqlDatabaseSystemSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a SqlDatabaseSystemSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + SqlDatabaseSystemSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.sqlEngine != null && message.hasOwnProperty("sqlEngine")) + if (!$util.isString(message.sqlEngine)) + return "sqlEngine: string expected"; + if (message.databaseVersion != null && message.hasOwnProperty("databaseVersion")) + if (!$util.isString(message.databaseVersion)) + return "databaseVersion: string expected"; + if (message.instanceHost != null && message.hasOwnProperty("instanceHost")) + if (!$util.isString(message.instanceHost)) + return "instanceHost: string expected"; + return null; + }; + + /** + * Creates a SqlDatabaseSystemSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.SqlDatabaseSystemSpec} SqlDatabaseSystemSpec + */ + SqlDatabaseSystemSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.SqlDatabaseSystemSpec(); + if (object.sqlEngine != null) + message.sqlEngine = String(object.sqlEngine); + if (object.databaseVersion != null) + message.databaseVersion = String(object.databaseVersion); + if (object.instanceHost != null) + message.instanceHost = String(object.instanceHost); + return message; + }; + + /** + * Creates a plain object from a SqlDatabaseSystemSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.SqlDatabaseSystemSpec} message SqlDatabaseSystemSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + SqlDatabaseSystemSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.sqlEngine = ""; + object.databaseVersion = ""; + object.instanceHost = ""; + } + if (message.sqlEngine != null && message.hasOwnProperty("sqlEngine")) + object.sqlEngine = message.sqlEngine; + if (message.databaseVersion != null && message.hasOwnProperty("databaseVersion")) + object.databaseVersion = message.databaseVersion; + if (message.instanceHost != null && message.hasOwnProperty("instanceHost")) + object.instanceHost = message.instanceHost; + return object; + }; + + /** + * Converts this SqlDatabaseSystemSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @instance + * @returns {Object.} JSON object + */ + SqlDatabaseSystemSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for SqlDatabaseSystemSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.SqlDatabaseSystemSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + SqlDatabaseSystemSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.SqlDatabaseSystemSpec"; + }; + + return SqlDatabaseSystemSpec; + })(); + + v1.LookerSystemSpec = (function() { + + /** + * Properties of a LookerSystemSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface ILookerSystemSpec + * @property {string|null} [parentInstanceId] LookerSystemSpec parentInstanceId + * @property {string|null} [parentInstanceDisplayName] LookerSystemSpec parentInstanceDisplayName + * @property {string|null} [parentModelId] LookerSystemSpec parentModelId + * @property {string|null} [parentModelDisplayName] LookerSystemSpec parentModelDisplayName + * @property {string|null} [parentViewId] LookerSystemSpec parentViewId + * @property {string|null} [parentViewDisplayName] LookerSystemSpec parentViewDisplayName + */ + + /** + * Constructs a new LookerSystemSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a LookerSystemSpec. + * @implements ILookerSystemSpec + * @constructor + * @param {google.cloud.datacatalog.v1.ILookerSystemSpec=} [properties] Properties to set + */ + function LookerSystemSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * LookerSystemSpec parentInstanceId. + * @member {string} parentInstanceId + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentInstanceId = ""; + + /** + * LookerSystemSpec parentInstanceDisplayName. + * @member {string} parentInstanceDisplayName + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentInstanceDisplayName = ""; + + /** + * LookerSystemSpec parentModelId. + * @member {string} parentModelId + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentModelId = ""; + + /** + * LookerSystemSpec parentModelDisplayName. + * @member {string} parentModelDisplayName + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentModelDisplayName = ""; + + /** + * LookerSystemSpec parentViewId. + * @member {string} parentViewId + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentViewId = ""; + + /** + * LookerSystemSpec parentViewDisplayName. + * @member {string} parentViewDisplayName + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + */ + LookerSystemSpec.prototype.parentViewDisplayName = ""; + + /** + * Creates a new LookerSystemSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ILookerSystemSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.LookerSystemSpec} LookerSystemSpec instance + */ + LookerSystemSpec.create = function create(properties) { + return new LookerSystemSpec(properties); + }; + + /** + * Encodes the specified LookerSystemSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.LookerSystemSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ILookerSystemSpec} message LookerSystemSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LookerSystemSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.parentInstanceId != null && Object.hasOwnProperty.call(message, "parentInstanceId")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parentInstanceId); + if (message.parentInstanceDisplayName != null && Object.hasOwnProperty.call(message, "parentInstanceDisplayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.parentInstanceDisplayName); + if (message.parentModelId != null && Object.hasOwnProperty.call(message, "parentModelId")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.parentModelId); + if (message.parentModelDisplayName != null && Object.hasOwnProperty.call(message, "parentModelDisplayName")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.parentModelDisplayName); + if (message.parentViewId != null && Object.hasOwnProperty.call(message, "parentViewId")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.parentViewId); + if (message.parentViewDisplayName != null && Object.hasOwnProperty.call(message, "parentViewDisplayName")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.parentViewDisplayName); + return writer; + }; + + /** + * Encodes the specified LookerSystemSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.LookerSystemSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.ILookerSystemSpec} message LookerSystemSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LookerSystemSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a LookerSystemSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.LookerSystemSpec} LookerSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LookerSystemSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.LookerSystemSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.parentInstanceId = reader.string(); + break; + } + case 2: { + message.parentInstanceDisplayName = reader.string(); + break; + } + case 3: { + message.parentModelId = reader.string(); + break; + } + case 4: { + message.parentModelDisplayName = reader.string(); + break; + } + case 5: { + message.parentViewId = reader.string(); + break; + } + case 6: { + message.parentViewDisplayName = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a LookerSystemSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.LookerSystemSpec} LookerSystemSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LookerSystemSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a LookerSystemSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + LookerSystemSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.parentInstanceId != null && message.hasOwnProperty("parentInstanceId")) + if (!$util.isString(message.parentInstanceId)) + return "parentInstanceId: string expected"; + if (message.parentInstanceDisplayName != null && message.hasOwnProperty("parentInstanceDisplayName")) + if (!$util.isString(message.parentInstanceDisplayName)) + return "parentInstanceDisplayName: string expected"; + if (message.parentModelId != null && message.hasOwnProperty("parentModelId")) + if (!$util.isString(message.parentModelId)) + return "parentModelId: string expected"; + if (message.parentModelDisplayName != null && message.hasOwnProperty("parentModelDisplayName")) + if (!$util.isString(message.parentModelDisplayName)) + return "parentModelDisplayName: string expected"; + if (message.parentViewId != null && message.hasOwnProperty("parentViewId")) + if (!$util.isString(message.parentViewId)) + return "parentViewId: string expected"; + if (message.parentViewDisplayName != null && message.hasOwnProperty("parentViewDisplayName")) + if (!$util.isString(message.parentViewDisplayName)) + return "parentViewDisplayName: string expected"; + return null; + }; + + /** + * Creates a LookerSystemSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.LookerSystemSpec} LookerSystemSpec + */ + LookerSystemSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.LookerSystemSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.LookerSystemSpec(); + if (object.parentInstanceId != null) + message.parentInstanceId = String(object.parentInstanceId); + if (object.parentInstanceDisplayName != null) + message.parentInstanceDisplayName = String(object.parentInstanceDisplayName); + if (object.parentModelId != null) + message.parentModelId = String(object.parentModelId); + if (object.parentModelDisplayName != null) + message.parentModelDisplayName = String(object.parentModelDisplayName); + if (object.parentViewId != null) + message.parentViewId = String(object.parentViewId); + if (object.parentViewDisplayName != null) + message.parentViewDisplayName = String(object.parentViewDisplayName); + return message; + }; + + /** + * Creates a plain object from a LookerSystemSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {google.cloud.datacatalog.v1.LookerSystemSpec} message LookerSystemSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + LookerSystemSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.parentInstanceId = ""; + object.parentInstanceDisplayName = ""; + object.parentModelId = ""; + object.parentModelDisplayName = ""; + object.parentViewId = ""; + object.parentViewDisplayName = ""; + } + if (message.parentInstanceId != null && message.hasOwnProperty("parentInstanceId")) + object.parentInstanceId = message.parentInstanceId; + if (message.parentInstanceDisplayName != null && message.hasOwnProperty("parentInstanceDisplayName")) + object.parentInstanceDisplayName = message.parentInstanceDisplayName; + if (message.parentModelId != null && message.hasOwnProperty("parentModelId")) + object.parentModelId = message.parentModelId; + if (message.parentModelDisplayName != null && message.hasOwnProperty("parentModelDisplayName")) + object.parentModelDisplayName = message.parentModelDisplayName; + if (message.parentViewId != null && message.hasOwnProperty("parentViewId")) + object.parentViewId = message.parentViewId; + if (message.parentViewDisplayName != null && message.hasOwnProperty("parentViewDisplayName")) + object.parentViewDisplayName = message.parentViewDisplayName; + return object; + }; + + /** + * Converts this LookerSystemSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @instance + * @returns {Object.} JSON object + */ + LookerSystemSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for LookerSystemSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.LookerSystemSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + LookerSystemSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.LookerSystemSpec"; + }; + + return LookerSystemSpec; + })(); + v1.BusinessContext = (function() { /** @@ -13266,27 +14372,28 @@ return ListTagsResponse; })(); - v1.ListEntriesRequest = (function() { + v1.ReconcileTagsRequest = (function() { /** - * Properties of a ListEntriesRequest. + * Properties of a ReconcileTagsRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IListEntriesRequest - * @property {string|null} [parent] ListEntriesRequest parent - * @property {number|null} [pageSize] ListEntriesRequest pageSize - * @property {string|null} [pageToken] ListEntriesRequest pageToken - * @property {google.protobuf.IFieldMask|null} [readMask] ListEntriesRequest readMask + * @interface IReconcileTagsRequest + * @property {string|null} [parent] ReconcileTagsRequest parent + * @property {string|null} [tagTemplate] ReconcileTagsRequest tagTemplate + * @property {boolean|null} [forceDeleteMissing] ReconcileTagsRequest forceDeleteMissing + * @property {Array.|null} [tags] ReconcileTagsRequest tags */ /** - * Constructs a new ListEntriesRequest. + * Constructs a new ReconcileTagsRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListEntriesRequest. - * @implements IListEntriesRequest + * @classdesc Represents a ReconcileTagsRequest. + * @implements IReconcileTagsRequest * @constructor - * @param {google.cloud.datacatalog.v1.IListEntriesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest=} [properties] Properties to set */ - function ListEntriesRequest(properties) { + function ReconcileTagsRequest(properties) { + this.tags = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13294,100 +14401,101 @@ } /** - * ListEntriesRequest parent. + * ReconcileTagsRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @instance */ - ListEntriesRequest.prototype.parent = ""; + ReconcileTagsRequest.prototype.parent = ""; /** - * ListEntriesRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * ReconcileTagsRequest tagTemplate. + * @member {string} tagTemplate + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @instance */ - ListEntriesRequest.prototype.pageSize = 0; + ReconcileTagsRequest.prototype.tagTemplate = ""; /** - * ListEntriesRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * ReconcileTagsRequest forceDeleteMissing. + * @member {boolean} forceDeleteMissing + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @instance */ - ListEntriesRequest.prototype.pageToken = ""; + ReconcileTagsRequest.prototype.forceDeleteMissing = false; /** - * ListEntriesRequest readMask. - * @member {google.protobuf.IFieldMask|null|undefined} readMask - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * ReconcileTagsRequest tags. + * @member {Array.} tags + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @instance */ - ListEntriesRequest.prototype.readMask = null; + ReconcileTagsRequest.prototype.tags = $util.emptyArray; /** - * Creates a new ListEntriesRequest instance using the specified properties. + * Creates a new ReconcileTagsRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IListEntriesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest instance + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ReconcileTagsRequest} ReconcileTagsRequest instance */ - ListEntriesRequest.create = function create(properties) { - return new ListEntriesRequest(properties); + ReconcileTagsRequest.create = function create(properties) { + return new ReconcileTagsRequest(properties); }; /** - * Encodes the specified ListEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesRequest.verify|verify} messages. + * Encodes the specified ReconcileTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest} message ReconcileTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesRequest.encode = function encode(message, writer) { + ReconcileTagsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); - if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) - $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.tagTemplate != null && Object.hasOwnProperty.call(message, "tagTemplate")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.tagTemplate); + if (message.forceDeleteMissing != null && Object.hasOwnProperty.call(message, "forceDeleteMissing")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.forceDeleteMissing); + if (message.tags != null && message.tags.length) + for (var i = 0; i < message.tags.length; ++i) + $root.google.cloud.datacatalog.v1.Tag.encode(message.tags[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified ListEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesRequest.verify|verify} messages. + * Encodes the specified ReconcileTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsRequest} message ReconcileTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesRequest.encodeDelimited = function encodeDelimited(message, writer) { + ReconcileTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntriesRequest message from the specified reader or buffer. + * Decodes a ReconcileTagsRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsRequest} ReconcileTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesRequest.decode = function decode(reader, length) { + ReconcileTagsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListEntriesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ReconcileTagsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -13396,15 +14504,17 @@ break; } case 2: { - message.pageSize = reader.int32(); + message.tagTemplate = reader.string(); break; } case 3: { - message.pageToken = reader.string(); + message.forceDeleteMissing = reader.bool(); break; } case 4: { - message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + if (!(message.tags && message.tags.length)) + message.tags = []; + message.tags.push($root.google.cloud.datacatalog.v1.Tag.decode(reader, reader.uint32())); break; } default: @@ -13416,154 +14526,167 @@ }; /** - * Decodes a ListEntriesRequest message from the specified reader or buffer, length delimited. + * Decodes a ReconcileTagsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsRequest} ReconcileTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesRequest.decodeDelimited = function decodeDelimited(reader) { + ReconcileTagsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntriesRequest message. + * Verifies a ReconcileTagsRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntriesRequest.verify = function verify(message) { + ReconcileTagsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; - if (message.readMask != null && message.hasOwnProperty("readMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.readMask); - if (error) - return "readMask." + error; + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) + if (!$util.isString(message.tagTemplate)) + return "tagTemplate: string expected"; + if (message.forceDeleteMissing != null && message.hasOwnProperty("forceDeleteMissing")) + if (typeof message.forceDeleteMissing !== "boolean") + return "forceDeleteMissing: boolean expected"; + if (message.tags != null && message.hasOwnProperty("tags")) { + if (!Array.isArray(message.tags)) + return "tags: array expected"; + for (var i = 0; i < message.tags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Tag.verify(message.tags[i]); + if (error) + return "tags." + error; + } } return null; }; /** - * Creates a ListEntriesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ReconcileTagsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsRequest} ReconcileTagsRequest */ - ListEntriesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListEntriesRequest) + ReconcileTagsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ReconcileTagsRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ListEntriesRequest(); + var message = new $root.google.cloud.datacatalog.v1.ReconcileTagsRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); - if (object.readMask != null) { - if (typeof object.readMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ListEntriesRequest.readMask: object expected"); - message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); + if (object.tagTemplate != null) + message.tagTemplate = String(object.tagTemplate); + if (object.forceDeleteMissing != null) + message.forceDeleteMissing = Boolean(object.forceDeleteMissing); + if (object.tags) { + if (!Array.isArray(object.tags)) + throw TypeError(".google.cloud.datacatalog.v1.ReconcileTagsRequest.tags: array expected"); + message.tags = []; + for (var i = 0; i < object.tags.length; ++i) { + if (typeof object.tags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ReconcileTagsRequest.tags: object expected"); + message.tags[i] = $root.google.cloud.datacatalog.v1.Tag.fromObject(object.tags[i]); + } } return message; }; /** - * Creates a plain object from a ListEntriesRequest message. Also converts values to other types if specified. + * Creates a plain object from a ReconcileTagsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static - * @param {google.cloud.datacatalog.v1.ListEntriesRequest} message ListEntriesRequest + * @param {google.cloud.datacatalog.v1.ReconcileTagsRequest} message ReconcileTagsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntriesRequest.toObject = function toObject(message, options) { + ReconcileTagsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.tags = []; if (options.defaults) { object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; - object.readMask = null; + object.tagTemplate = ""; + object.forceDeleteMissing = false; } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; - if (message.readMask != null && message.hasOwnProperty("readMask")) - object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) + object.tagTemplate = message.tagTemplate; + if (message.forceDeleteMissing != null && message.hasOwnProperty("forceDeleteMissing")) + object.forceDeleteMissing = message.forceDeleteMissing; + if (message.tags && message.tags.length) { + object.tags = []; + for (var j = 0; j < message.tags.length; ++j) + object.tags[j] = $root.google.cloud.datacatalog.v1.Tag.toObject(message.tags[j], options); + } return object; }; /** - * Converts this ListEntriesRequest to JSON. + * Converts this ReconcileTagsRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @instance * @returns {Object.} JSON object */ - ListEntriesRequest.prototype.toJSON = function toJSON() { + ReconcileTagsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntriesRequest + * Gets the default type url for ReconcileTagsRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntriesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ReconcileTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListEntriesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ReconcileTagsRequest"; }; - return ListEntriesRequest; + return ReconcileTagsRequest; })(); - v1.ListEntriesResponse = (function() { + v1.ReconcileTagsResponse = (function() { /** - * Properties of a ListEntriesResponse. + * Properties of a ReconcileTagsResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IListEntriesResponse - * @property {Array.|null} [entries] ListEntriesResponse entries - * @property {string|null} [nextPageToken] ListEntriesResponse nextPageToken + * @interface IReconcileTagsResponse + * @property {number|Long|null} [createdTagsCount] ReconcileTagsResponse createdTagsCount + * @property {number|Long|null} [updatedTagsCount] ReconcileTagsResponse updatedTagsCount + * @property {number|Long|null} [deletedTagsCount] ReconcileTagsResponse deletedTagsCount */ /** - * Constructs a new ListEntriesResponse. + * Constructs a new ReconcileTagsResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListEntriesResponse. - * @implements IListEntriesResponse + * @classdesc Represents a ReconcileTagsResponse. + * @implements IReconcileTagsResponse * @constructor - * @param {google.cloud.datacatalog.v1.IListEntriesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IReconcileTagsResponse=} [properties] Properties to set */ - function ListEntriesResponse(properties) { - this.entries = []; + function ReconcileTagsResponse(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13571,92 +14694,103 @@ } /** - * ListEntriesResponse entries. - * @member {Array.} entries - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * ReconcileTagsResponse createdTagsCount. + * @member {number|Long} createdTagsCount + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @instance */ - ListEntriesResponse.prototype.entries = $util.emptyArray; + ReconcileTagsResponse.prototype.createdTagsCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * ListEntriesResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * ReconcileTagsResponse updatedTagsCount. + * @member {number|Long} updatedTagsCount + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @instance */ - ListEntriesResponse.prototype.nextPageToken = ""; + ReconcileTagsResponse.prototype.updatedTagsCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * Creates a new ListEntriesResponse instance using the specified properties. + * ReconcileTagsResponse deletedTagsCount. + * @member {number|Long} deletedTagsCount + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse + * @instance + */ + ReconcileTagsResponse.prototype.deletedTagsCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + + /** + * Creates a new ReconcileTagsResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static - * @param {google.cloud.datacatalog.v1.IListEntriesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse instance + * @param {google.cloud.datacatalog.v1.IReconcileTagsResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ReconcileTagsResponse} ReconcileTagsResponse instance */ - ListEntriesResponse.create = function create(properties) { - return new ListEntriesResponse(properties); + ReconcileTagsResponse.create = function create(properties) { + return new ReconcileTagsResponse(properties); }; /** - * Encodes the specified ListEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesResponse.verify|verify} messages. + * Encodes the specified ReconcileTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static - * @param {google.cloud.datacatalog.v1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsResponse} message ReconcileTagsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesResponse.encode = function encode(message, writer) { + ReconcileTagsResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.entries != null && message.entries.length) - for (var i = 0; i < message.entries.length; ++i) - $root.google.cloud.datacatalog.v1.Entry.encode(message.entries[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.createdTagsCount != null && Object.hasOwnProperty.call(message, "createdTagsCount")) + writer.uint32(/* id 1, wireType 0 =*/8).int64(message.createdTagsCount); + if (message.updatedTagsCount != null && Object.hasOwnProperty.call(message, "updatedTagsCount")) + writer.uint32(/* id 2, wireType 0 =*/16).int64(message.updatedTagsCount); + if (message.deletedTagsCount != null && Object.hasOwnProperty.call(message, "deletedTagsCount")) + writer.uint32(/* id 3, wireType 0 =*/24).int64(message.deletedTagsCount); return writer; }; /** - * Encodes the specified ListEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesResponse.verify|verify} messages. + * Encodes the specified ReconcileTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static - * @param {google.cloud.datacatalog.v1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsResponse} message ReconcileTagsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesResponse.encodeDelimited = function encodeDelimited(message, writer) { + ReconcileTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntriesResponse message from the specified reader or buffer. + * Decodes a ReconcileTagsResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1.ReconcileTagsResponse} ReconcileTagsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesResponse.decode = function decode(reader, length) { + ReconcileTagsResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListEntriesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ReconcileTagsResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.entries && message.entries.length)) - message.entries = []; - message.entries.push($root.google.cloud.datacatalog.v1.Entry.decode(reader, reader.uint32())); + message.createdTagsCount = reader.int64(); break; } case 2: { - message.nextPageToken = reader.string(); + message.updatedTagsCount = reader.int64(); + break; + } + case 3: { + message.deletedTagsCount = reader.int64(); break; } default: @@ -13668,148 +14802,183 @@ }; /** - * Decodes a ListEntriesResponse message from the specified reader or buffer, length delimited. + * Decodes a ReconcileTagsResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1.ReconcileTagsResponse} ReconcileTagsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesResponse.decodeDelimited = function decodeDelimited(reader) { + ReconcileTagsResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntriesResponse message. + * Verifies a ReconcileTagsResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntriesResponse.verify = function verify(message) { + ReconcileTagsResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.entries != null && message.hasOwnProperty("entries")) { - if (!Array.isArray(message.entries)) - return "entries: array expected"; - for (var i = 0; i < message.entries.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.Entry.verify(message.entries[i]); - if (error) - return "entries." + error; - } - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; + if (message.createdTagsCount != null && message.hasOwnProperty("createdTagsCount")) + if (!$util.isInteger(message.createdTagsCount) && !(message.createdTagsCount && $util.isInteger(message.createdTagsCount.low) && $util.isInteger(message.createdTagsCount.high))) + return "createdTagsCount: integer|Long expected"; + if (message.updatedTagsCount != null && message.hasOwnProperty("updatedTagsCount")) + if (!$util.isInteger(message.updatedTagsCount) && !(message.updatedTagsCount && $util.isInteger(message.updatedTagsCount.low) && $util.isInteger(message.updatedTagsCount.high))) + return "updatedTagsCount: integer|Long expected"; + if (message.deletedTagsCount != null && message.hasOwnProperty("deletedTagsCount")) + if (!$util.isInteger(message.deletedTagsCount) && !(message.deletedTagsCount && $util.isInteger(message.deletedTagsCount.low) && $util.isInteger(message.deletedTagsCount.high))) + return "deletedTagsCount: integer|Long expected"; return null; }; /** - * Creates a ListEntriesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a ReconcileTagsResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1.ReconcileTagsResponse} ReconcileTagsResponse */ - ListEntriesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListEntriesResponse) + ReconcileTagsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ReconcileTagsResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.ListEntriesResponse(); - if (object.entries) { - if (!Array.isArray(object.entries)) - throw TypeError(".google.cloud.datacatalog.v1.ListEntriesResponse.entries: array expected"); - message.entries = []; - for (var i = 0; i < object.entries.length; ++i) { - if (typeof object.entries[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ListEntriesResponse.entries: object expected"); - message.entries[i] = $root.google.cloud.datacatalog.v1.Entry.fromObject(object.entries[i]); - } - } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); + var message = new $root.google.cloud.datacatalog.v1.ReconcileTagsResponse(); + if (object.createdTagsCount != null) + if ($util.Long) + (message.createdTagsCount = $util.Long.fromValue(object.createdTagsCount)).unsigned = false; + else if (typeof object.createdTagsCount === "string") + message.createdTagsCount = parseInt(object.createdTagsCount, 10); + else if (typeof object.createdTagsCount === "number") + message.createdTagsCount = object.createdTagsCount; + else if (typeof object.createdTagsCount === "object") + message.createdTagsCount = new $util.LongBits(object.createdTagsCount.low >>> 0, object.createdTagsCount.high >>> 0).toNumber(); + if (object.updatedTagsCount != null) + if ($util.Long) + (message.updatedTagsCount = $util.Long.fromValue(object.updatedTagsCount)).unsigned = false; + else if (typeof object.updatedTagsCount === "string") + message.updatedTagsCount = parseInt(object.updatedTagsCount, 10); + else if (typeof object.updatedTagsCount === "number") + message.updatedTagsCount = object.updatedTagsCount; + else if (typeof object.updatedTagsCount === "object") + message.updatedTagsCount = new $util.LongBits(object.updatedTagsCount.low >>> 0, object.updatedTagsCount.high >>> 0).toNumber(); + if (object.deletedTagsCount != null) + if ($util.Long) + (message.deletedTagsCount = $util.Long.fromValue(object.deletedTagsCount)).unsigned = false; + else if (typeof object.deletedTagsCount === "string") + message.deletedTagsCount = parseInt(object.deletedTagsCount, 10); + else if (typeof object.deletedTagsCount === "number") + message.deletedTagsCount = object.deletedTagsCount; + else if (typeof object.deletedTagsCount === "object") + message.deletedTagsCount = new $util.LongBits(object.deletedTagsCount.low >>> 0, object.deletedTagsCount.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a ListEntriesResponse message. Also converts values to other types if specified. + * Creates a plain object from a ReconcileTagsResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static - * @param {google.cloud.datacatalog.v1.ListEntriesResponse} message ListEntriesResponse + * @param {google.cloud.datacatalog.v1.ReconcileTagsResponse} message ReconcileTagsResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntriesResponse.toObject = function toObject(message, options) { + ReconcileTagsResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.entries = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.entries && message.entries.length) { - object.entries = []; - for (var j = 0; j < message.entries.length; ++j) - object.entries[j] = $root.google.cloud.datacatalog.v1.Entry.toObject(message.entries[j], options); + if (options.defaults) { + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.createdTagsCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.createdTagsCount = options.longs === String ? "0" : 0; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.updatedTagsCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.updatedTagsCount = options.longs === String ? "0" : 0; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.deletedTagsCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.deletedTagsCount = options.longs === String ? "0" : 0; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; + if (message.createdTagsCount != null && message.hasOwnProperty("createdTagsCount")) + if (typeof message.createdTagsCount === "number") + object.createdTagsCount = options.longs === String ? String(message.createdTagsCount) : message.createdTagsCount; + else + object.createdTagsCount = options.longs === String ? $util.Long.prototype.toString.call(message.createdTagsCount) : options.longs === Number ? new $util.LongBits(message.createdTagsCount.low >>> 0, message.createdTagsCount.high >>> 0).toNumber() : message.createdTagsCount; + if (message.updatedTagsCount != null && message.hasOwnProperty("updatedTagsCount")) + if (typeof message.updatedTagsCount === "number") + object.updatedTagsCount = options.longs === String ? String(message.updatedTagsCount) : message.updatedTagsCount; + else + object.updatedTagsCount = options.longs === String ? $util.Long.prototype.toString.call(message.updatedTagsCount) : options.longs === Number ? new $util.LongBits(message.updatedTagsCount.low >>> 0, message.updatedTagsCount.high >>> 0).toNumber() : message.updatedTagsCount; + if (message.deletedTagsCount != null && message.hasOwnProperty("deletedTagsCount")) + if (typeof message.deletedTagsCount === "number") + object.deletedTagsCount = options.longs === String ? String(message.deletedTagsCount) : message.deletedTagsCount; + else + object.deletedTagsCount = options.longs === String ? $util.Long.prototype.toString.call(message.deletedTagsCount) : options.longs === Number ? new $util.LongBits(message.deletedTagsCount.low >>> 0, message.deletedTagsCount.high >>> 0).toNumber() : message.deletedTagsCount; return object; }; /** - * Converts this ListEntriesResponse to JSON. + * Converts this ReconcileTagsResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @instance * @returns {Object.} JSON object */ - ListEntriesResponse.prototype.toJSON = function toJSON() { + ReconcileTagsResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntriesResponse + * Gets the default type url for ReconcileTagsResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1.ReconcileTagsResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntriesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ReconcileTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListEntriesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ReconcileTagsResponse"; }; - return ListEntriesResponse; + return ReconcileTagsResponse; })(); - v1.StarEntryRequest = (function() { + v1.ReconcileTagsMetadata = (function() { /** - * Properties of a StarEntryRequest. + * Properties of a ReconcileTagsMetadata. * @memberof google.cloud.datacatalog.v1 - * @interface IStarEntryRequest - * @property {string|null} [name] StarEntryRequest name + * @interface IReconcileTagsMetadata + * @property {google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState|null} [state] ReconcileTagsMetadata state + * @property {Object.|null} [errors] ReconcileTagsMetadata errors */ /** - * Constructs a new StarEntryRequest. + * Constructs a new ReconcileTagsMetadata. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a StarEntryRequest. - * @implements IStarEntryRequest + * @classdesc Represents a ReconcileTagsMetadata. + * @implements IReconcileTagsMetadata * @constructor - * @param {google.cloud.datacatalog.v1.IStarEntryRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IReconcileTagsMetadata=} [properties] Properties to set */ - function StarEntryRequest(properties) { + function ReconcileTagsMetadata(properties) { + this.errors = {}; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -13817,75 +14986,111 @@ } /** - * StarEntryRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * ReconcileTagsMetadata state. + * @member {google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState} state + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @instance */ - StarEntryRequest.prototype.name = ""; + ReconcileTagsMetadata.prototype.state = 0; /** - * Creates a new StarEntryRequest instance using the specified properties. + * ReconcileTagsMetadata errors. + * @member {Object.} errors + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata + * @instance + */ + ReconcileTagsMetadata.prototype.errors = $util.emptyObject; + + /** + * Creates a new ReconcileTagsMetadata instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static - * @param {google.cloud.datacatalog.v1.IStarEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest instance + * @param {google.cloud.datacatalog.v1.IReconcileTagsMetadata=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ReconcileTagsMetadata} ReconcileTagsMetadata instance */ - StarEntryRequest.create = function create(properties) { - return new StarEntryRequest(properties); + ReconcileTagsMetadata.create = function create(properties) { + return new ReconcileTagsMetadata(properties); }; /** - * Encodes the specified StarEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryRequest.verify|verify} messages. + * Encodes the specified ReconcileTagsMetadata message. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsMetadata.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static - * @param {google.cloud.datacatalog.v1.IStarEntryRequest} message StarEntryRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsMetadata} message ReconcileTagsMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - StarEntryRequest.encode = function encode(message, writer) { + ReconcileTagsMetadata.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.state != null && Object.hasOwnProperty.call(message, "state")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.state); + if (message.errors != null && Object.hasOwnProperty.call(message, "errors")) + for (var keys = Object.keys(message.errors), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 2, wireType 2 =*/18).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.rpc.Status.encode(message.errors[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } return writer; }; /** - * Encodes the specified StarEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryRequest.verify|verify} messages. + * Encodes the specified ReconcileTagsMetadata message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReconcileTagsMetadata.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static - * @param {google.cloud.datacatalog.v1.IStarEntryRequest} message StarEntryRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReconcileTagsMetadata} message ReconcileTagsMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - StarEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { + ReconcileTagsMetadata.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a StarEntryRequest message from the specified reader or buffer. + * Decodes a ReconcileTagsMetadata message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsMetadata} ReconcileTagsMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - StarEntryRequest.decode = function decode(reader, length) { + ReconcileTagsMetadata.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.StarEntryRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ReconcileTagsMetadata(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.state = reader.int32(); + break; + } + case 2: { + if (message.errors === $util.emptyObject) + message.errors = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.rpc.Status.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.errors[key] = value; break; } default: @@ -13897,121 +15102,200 @@ }; /** - * Decodes a StarEntryRequest message from the specified reader or buffer, length delimited. + * Decodes a ReconcileTagsMetadata message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsMetadata} ReconcileTagsMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - StarEntryRequest.decodeDelimited = function decodeDelimited(reader) { + ReconcileTagsMetadata.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a StarEntryRequest message. + * Verifies a ReconcileTagsMetadata message. * @function verify - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - StarEntryRequest.verify = function verify(message) { + ReconcileTagsMetadata.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.state != null && message.hasOwnProperty("state")) + switch (message.state) { + default: + return "state: enum value expected"; + case 0: + case 1: + case 2: + case 3: + break; + } + if (message.errors != null && message.hasOwnProperty("errors")) { + if (!$util.isObject(message.errors)) + return "errors: object expected"; + var key = Object.keys(message.errors); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.rpc.Status.verify(message.errors[key[i]]); + if (error) + return "errors." + error; + } + } return null; }; /** - * Creates a StarEntryRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ReconcileTagsMetadata message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest + * @returns {google.cloud.datacatalog.v1.ReconcileTagsMetadata} ReconcileTagsMetadata */ - StarEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.StarEntryRequest) + ReconcileTagsMetadata.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ReconcileTagsMetadata) return object; - var message = new $root.google.cloud.datacatalog.v1.StarEntryRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.ReconcileTagsMetadata(); + switch (object.state) { + default: + if (typeof object.state === "number") { + message.state = object.state; + break; + } + break; + case "RECONCILIATION_STATE_UNSPECIFIED": + case 0: + message.state = 0; + break; + case "RECONCILIATION_QUEUED": + case 1: + message.state = 1; + break; + case "RECONCILIATION_IN_PROGRESS": + case 2: + message.state = 2; + break; + case "RECONCILIATION_DONE": + case 3: + message.state = 3; + break; + } + if (object.errors) { + if (typeof object.errors !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ReconcileTagsMetadata.errors: object expected"); + message.errors = {}; + for (var keys = Object.keys(object.errors), i = 0; i < keys.length; ++i) { + if (typeof object.errors[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ReconcileTagsMetadata.errors: object expected"); + message.errors[keys[i]] = $root.google.rpc.Status.fromObject(object.errors[keys[i]]); + } + } return message; }; /** - * Creates a plain object from a StarEntryRequest message. Also converts values to other types if specified. + * Creates a plain object from a ReconcileTagsMetadata message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static - * @param {google.cloud.datacatalog.v1.StarEntryRequest} message StarEntryRequest + * @param {google.cloud.datacatalog.v1.ReconcileTagsMetadata} message ReconcileTagsMetadata * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - StarEntryRequest.toObject = function toObject(message, options) { + ReconcileTagsMetadata.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.objects || options.defaults) + object.errors = {}; if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.state = options.enums === String ? "RECONCILIATION_STATE_UNSPECIFIED" : 0; + if (message.state != null && message.hasOwnProperty("state")) + object.state = options.enums === String ? $root.google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState[message.state] === undefined ? message.state : $root.google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState[message.state] : message.state; + var keys2; + if (message.errors && (keys2 = Object.keys(message.errors)).length) { + object.errors = {}; + for (var j = 0; j < keys2.length; ++j) + object.errors[keys2[j]] = $root.google.rpc.Status.toObject(message.errors[keys2[j]], options); + } return object; }; /** - * Converts this StarEntryRequest to JSON. + * Converts this ReconcileTagsMetadata to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @instance * @returns {Object.} JSON object */ - StarEntryRequest.prototype.toJSON = function toJSON() { + ReconcileTagsMetadata.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for StarEntryRequest + * Gets the default type url for ReconcileTagsMetadata * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @memberof google.cloud.datacatalog.v1.ReconcileTagsMetadata * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - StarEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ReconcileTagsMetadata.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.StarEntryRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ReconcileTagsMetadata"; }; - return StarEntryRequest; + /** + * ReconciliationState enum. + * @name google.cloud.datacatalog.v1.ReconcileTagsMetadata.ReconciliationState + * @enum {number} + * @property {number} RECONCILIATION_STATE_UNSPECIFIED=0 RECONCILIATION_STATE_UNSPECIFIED value + * @property {number} RECONCILIATION_QUEUED=1 RECONCILIATION_QUEUED value + * @property {number} RECONCILIATION_IN_PROGRESS=2 RECONCILIATION_IN_PROGRESS value + * @property {number} RECONCILIATION_DONE=3 RECONCILIATION_DONE value + */ + ReconcileTagsMetadata.ReconciliationState = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "RECONCILIATION_STATE_UNSPECIFIED"] = 0; + values[valuesById[1] = "RECONCILIATION_QUEUED"] = 1; + values[valuesById[2] = "RECONCILIATION_IN_PROGRESS"] = 2; + values[valuesById[3] = "RECONCILIATION_DONE"] = 3; + return values; + })(); + + return ReconcileTagsMetadata; })(); - v1.StarEntryResponse = (function() { + v1.ListEntriesRequest = (function() { /** - * Properties of a StarEntryResponse. + * Properties of a ListEntriesRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IStarEntryResponse + * @interface IListEntriesRequest + * @property {string|null} [parent] ListEntriesRequest parent + * @property {number|null} [pageSize] ListEntriesRequest pageSize + * @property {string|null} [pageToken] ListEntriesRequest pageToken + * @property {google.protobuf.IFieldMask|null} [readMask] ListEntriesRequest readMask */ /** - * Constructs a new StarEntryResponse. + * Constructs a new ListEntriesRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a StarEntryResponse. - * @implements IStarEntryResponse + * @classdesc Represents a ListEntriesRequest. + * @implements IListEntriesRequest * @constructor - * @param {google.cloud.datacatalog.v1.IStarEntryResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IListEntriesRequest=} [properties] Properties to set */ - function StarEntryResponse(properties) { + function ListEntriesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14019,63 +15303,119 @@ } /** - * Creates a new StarEntryResponse instance using the specified properties. + * ListEntriesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @instance + */ + ListEntriesRequest.prototype.parent = ""; + + /** + * ListEntriesRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @instance + */ + ListEntriesRequest.prototype.pageSize = 0; + + /** + * ListEntriesRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @instance + */ + ListEntriesRequest.prototype.pageToken = ""; + + /** + * ListEntriesRequest readMask. + * @member {google.protobuf.IFieldMask|null|undefined} readMask + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest + * @instance + */ + ListEntriesRequest.prototype.readMask = null; + + /** + * Creates a new ListEntriesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IStarEntryResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse instance + * @param {google.cloud.datacatalog.v1.IListEntriesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest instance */ - StarEntryResponse.create = function create(properties) { - return new StarEntryResponse(properties); + ListEntriesRequest.create = function create(properties) { + return new ListEntriesRequest(properties); }; /** - * Encodes the specified StarEntryResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryResponse.verify|verify} messages. + * Encodes the specified ListEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IStarEntryResponse} message StarEntryResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - StarEntryResponse.encode = function encode(message, writer) { + ListEntriesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) + $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified StarEntryResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryResponse.verify|verify} messages. + * Encodes the specified ListEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IStarEntryResponse} message StarEntryResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - StarEntryResponse.encodeDelimited = function encodeDelimited(message, writer) { + ListEntriesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a StarEntryResponse message from the specified reader or buffer. + * Decodes a ListEntriesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse + * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - StarEntryResponse.decode = function decode(reader, length) { + ListEntriesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.StarEntryResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListEntriesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.parent = reader.string(); + break; + } + case 2: { + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); + break; + } + case 4: { + message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + break; + } default: reader.skipType(tag & 7); break; @@ -14085,109 +15425,154 @@ }; /** - * Decodes a StarEntryResponse message from the specified reader or buffer, length delimited. + * Decodes a ListEntriesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse + * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - StarEntryResponse.decodeDelimited = function decodeDelimited(reader) { + ListEntriesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a StarEntryResponse message. + * Verifies a ListEntriesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - StarEntryResponse.verify = function verify(message) { + ListEntriesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + if (message.readMask != null && message.hasOwnProperty("readMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.readMask); + if (error) + return "readMask." + error; + } return null; }; /** - * Creates a StarEntryResponse message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntriesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse + * @returns {google.cloud.datacatalog.v1.ListEntriesRequest} ListEntriesRequest */ - StarEntryResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.StarEntryResponse) + ListEntriesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListEntriesRequest) return object; - return new $root.google.cloud.datacatalog.v1.StarEntryResponse(); + var message = new $root.google.cloud.datacatalog.v1.ListEntriesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + if (object.readMask != null) { + if (typeof object.readMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ListEntriesRequest.readMask: object expected"); + message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); + } + return message; }; /** - * Creates a plain object from a StarEntryResponse message. Also converts values to other types if specified. + * Creates a plain object from a ListEntriesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.StarEntryResponse} message StarEntryResponse + * @param {google.cloud.datacatalog.v1.ListEntriesRequest} message ListEntriesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - StarEntryResponse.toObject = function toObject() { - return {}; + ListEntriesRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; + object.readMask = null; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.readMask != null && message.hasOwnProperty("readMask")) + object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); + return object; }; /** - * Converts this StarEntryResponse to JSON. + * Converts this ListEntriesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @instance * @returns {Object.} JSON object */ - StarEntryResponse.prototype.toJSON = function toJSON() { + ListEntriesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for StarEntryResponse + * Gets the default type url for ListEntriesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.StarEntryResponse + * @memberof google.cloud.datacatalog.v1.ListEntriesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - StarEntryResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntriesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.StarEntryResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListEntriesRequest"; }; - return StarEntryResponse; + return ListEntriesRequest; })(); - v1.UnstarEntryRequest = (function() { + v1.ListEntriesResponse = (function() { /** - * Properties of an UnstarEntryRequest. + * Properties of a ListEntriesResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IUnstarEntryRequest - * @property {string|null} [name] UnstarEntryRequest name + * @interface IListEntriesResponse + * @property {Array.|null} [entries] ListEntriesResponse entries + * @property {string|null} [nextPageToken] ListEntriesResponse nextPageToken */ /** - * Constructs a new UnstarEntryRequest. + * Constructs a new ListEntriesResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an UnstarEntryRequest. - * @implements IUnstarEntryRequest + * @classdesc Represents a ListEntriesResponse. + * @implements IListEntriesResponse * @constructor - * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IListEntriesResponse=} [properties] Properties to set */ - function UnstarEntryRequest(properties) { + function ListEntriesResponse(properties) { + this.entries = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14195,75 +15580,92 @@ } /** - * UnstarEntryRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * ListEntriesResponse entries. + * @member {Array.} entries + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @instance */ - UnstarEntryRequest.prototype.name = ""; + ListEntriesResponse.prototype.entries = $util.emptyArray; /** - * Creates a new UnstarEntryRequest instance using the specified properties. + * ListEntriesResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse + * @instance + */ + ListEntriesResponse.prototype.nextPageToken = ""; + + /** + * Creates a new ListEntriesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest instance + * @param {google.cloud.datacatalog.v1.IListEntriesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse instance */ - UnstarEntryRequest.create = function create(properties) { - return new UnstarEntryRequest(properties); + ListEntriesResponse.create = function create(properties) { + return new ListEntriesResponse(properties); }; /** - * Encodes the specified UnstarEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryRequest.verify|verify} messages. + * Encodes the specified ListEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest} message UnstarEntryRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UnstarEntryRequest.encode = function encode(message, writer) { + ListEntriesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.entries != null && message.entries.length) + for (var i = 0; i < message.entries.length; ++i) + $root.google.cloud.datacatalog.v1.Entry.encode(message.entries[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); return writer; }; /** - * Encodes the specified UnstarEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryRequest.verify|verify} messages. + * Encodes the specified ListEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListEntriesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest} message UnstarEntryRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UnstarEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListEntriesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UnstarEntryRequest message from the specified reader or buffer. + * Decodes a ListEntriesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest + * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UnstarEntryRequest.decode = function decode(reader, length) { + ListEntriesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UnstarEntryRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListEntriesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + if (!(message.entries && message.entries.length)) + message.entries = []; + message.entries.push($root.google.cloud.datacatalog.v1.Entry.decode(reader, reader.uint32())); + break; + } + case 2: { + message.nextPageToken = reader.string(); break; } default: @@ -14275,121 +15677,148 @@ }; /** - * Decodes an UnstarEntryRequest message from the specified reader or buffer, length delimited. + * Decodes a ListEntriesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest + * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UnstarEntryRequest.decodeDelimited = function decodeDelimited(reader) { + ListEntriesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UnstarEntryRequest message. + * Verifies a ListEntriesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UnstarEntryRequest.verify = function verify(message) { + ListEntriesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.entries != null && message.hasOwnProperty("entries")) { + if (!Array.isArray(message.entries)) + return "entries: array expected"; + for (var i = 0; i < message.entries.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Entry.verify(message.entries[i]); + if (error) + return "entries." + error; + } + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates an UnstarEntryRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntriesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest + * @returns {google.cloud.datacatalog.v1.ListEntriesResponse} ListEntriesResponse */ - UnstarEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UnstarEntryRequest) + ListEntriesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListEntriesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.UnstarEntryRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.ListEntriesResponse(); + if (object.entries) { + if (!Array.isArray(object.entries)) + throw TypeError(".google.cloud.datacatalog.v1.ListEntriesResponse.entries: array expected"); + message.entries = []; + for (var i = 0; i < object.entries.length; ++i) { + if (typeof object.entries[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ListEntriesResponse.entries: object expected"); + message.entries[i] = $root.google.cloud.datacatalog.v1.Entry.fromObject(object.entries[i]); + } + } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from an UnstarEntryRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListEntriesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.UnstarEntryRequest} message UnstarEntryRequest + * @param {google.cloud.datacatalog.v1.ListEntriesResponse} message ListEntriesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UnstarEntryRequest.toObject = function toObject(message, options) { + ListEntriesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.entries = []; if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.nextPageToken = ""; + if (message.entries && message.entries.length) { + object.entries = []; + for (var j = 0; j < message.entries.length; ++j) + object.entries[j] = $root.google.cloud.datacatalog.v1.Entry.toObject(message.entries[j], options); + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this UnstarEntryRequest to JSON. + * Converts this ListEntriesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @instance * @returns {Object.} JSON object */ - UnstarEntryRequest.prototype.toJSON = function toJSON() { + ListEntriesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UnstarEntryRequest + * Gets the default type url for ListEntriesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest + * @memberof google.cloud.datacatalog.v1.ListEntriesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UnstarEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntriesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UnstarEntryRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListEntriesResponse"; }; - return UnstarEntryRequest; + return ListEntriesResponse; })(); - v1.UnstarEntryResponse = (function() { + v1.StarEntryRequest = (function() { /** - * Properties of an UnstarEntryResponse. + * Properties of a StarEntryRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IUnstarEntryResponse + * @interface IStarEntryRequest + * @property {string|null} [name] StarEntryRequest name */ /** - * Constructs a new UnstarEntryResponse. + * Constructs a new StarEntryRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an UnstarEntryResponse. - * @implements IUnstarEntryResponse + * @classdesc Represents a StarEntryRequest. + * @implements IStarEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IStarEntryRequest=} [properties] Properties to set */ - function UnstarEntryResponse(properties) { + function StarEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14397,63 +15826,77 @@ } /** - * Creates a new UnstarEntryResponse instance using the specified properties. + * StarEntryRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.StarEntryRequest + * @instance + */ + StarEntryRequest.prototype.name = ""; + + /** + * Creates a new StarEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse instance + * @param {google.cloud.datacatalog.v1.IStarEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest instance */ - UnstarEntryResponse.create = function create(properties) { - return new UnstarEntryResponse(properties); + StarEntryRequest.create = function create(properties) { + return new StarEntryRequest(properties); }; /** - * Encodes the specified UnstarEntryResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryResponse.verify|verify} messages. + * Encodes the specified StarEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse} message UnstarEntryResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IStarEntryRequest} message StarEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UnstarEntryResponse.encode = function encode(message, writer) { + StarEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified UnstarEntryResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryResponse.verify|verify} messages. + * Encodes the specified StarEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse} message UnstarEntryResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IStarEntryRequest} message StarEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UnstarEntryResponse.encodeDelimited = function encodeDelimited(message, writer) { + StarEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UnstarEntryResponse message from the specified reader or buffer. + * Decodes a StarEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse + * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UnstarEntryResponse.decode = function decode(reader, length) { + StarEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UnstarEntryResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.StarEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -14463,110 +15906,121 @@ }; /** - * Decodes an UnstarEntryResponse message from the specified reader or buffer, length delimited. + * Decodes a StarEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse + * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UnstarEntryResponse.decodeDelimited = function decodeDelimited(reader) { + StarEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UnstarEntryResponse message. + * Verifies a StarEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UnstarEntryResponse.verify = function verify(message) { + StarEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates an UnstarEntryResponse message from a plain object. Also converts values to their respective internal types. + * Creates a StarEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse + * @returns {google.cloud.datacatalog.v1.StarEntryRequest} StarEntryRequest */ - UnstarEntryResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UnstarEntryResponse) + StarEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.StarEntryRequest) return object; - return new $root.google.cloud.datacatalog.v1.UnstarEntryResponse(); + var message = new $root.google.cloud.datacatalog.v1.StarEntryRequest(); + if (object.name != null) + message.name = String(object.name); + return message; }; /** - * Creates a plain object from an UnstarEntryResponse message. Also converts values to other types if specified. + * Creates a plain object from a StarEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.UnstarEntryResponse} message UnstarEntryResponse + * @param {google.cloud.datacatalog.v1.StarEntryRequest} message StarEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UnstarEntryResponse.toObject = function toObject() { - return {}; + StarEntryRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; }; /** - * Converts this UnstarEntryResponse to JSON. + * Converts this StarEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @instance * @returns {Object.} JSON object */ - UnstarEntryResponse.prototype.toJSON = function toJSON() { + StarEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UnstarEntryResponse + * Gets the default type url for StarEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse + * @memberof google.cloud.datacatalog.v1.StarEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UnstarEntryResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + StarEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UnstarEntryResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.StarEntryRequest"; }; - return UnstarEntryResponse; + return StarEntryRequest; })(); - v1.ModifyEntryOverviewRequest = (function() { + v1.StarEntryResponse = (function() { /** - * Properties of a ModifyEntryOverviewRequest. + * Properties of a StarEntryResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IModifyEntryOverviewRequest - * @property {string|null} [name] ModifyEntryOverviewRequest name - * @property {google.cloud.datacatalog.v1.IEntryOverview|null} [entryOverview] ModifyEntryOverviewRequest entryOverview + * @interface IStarEntryResponse */ /** - * Constructs a new ModifyEntryOverviewRequest. + * Constructs a new StarEntryResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ModifyEntryOverviewRequest. - * @implements IModifyEntryOverviewRequest + * @classdesc Represents a StarEntryResponse. + * @implements IStarEntryResponse * @constructor - * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IStarEntryResponse=} [properties] Properties to set */ - function ModifyEntryOverviewRequest(properties) { + function StarEntryResponse(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14574,91 +16028,63 @@ } /** - * ModifyEntryOverviewRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest - * @instance - */ - ModifyEntryOverviewRequest.prototype.name = ""; - - /** - * ModifyEntryOverviewRequest entryOverview. - * @member {google.cloud.datacatalog.v1.IEntryOverview|null|undefined} entryOverview - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest - * @instance - */ - ModifyEntryOverviewRequest.prototype.entryOverview = null; - - /** - * Creates a new ModifyEntryOverviewRequest instance using the specified properties. + * Creates a new StarEntryResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest instance + * @param {google.cloud.datacatalog.v1.IStarEntryResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse instance */ - ModifyEntryOverviewRequest.create = function create(properties) { - return new ModifyEntryOverviewRequest(properties); + StarEntryResponse.create = function create(properties) { + return new StarEntryResponse(properties); }; /** - * Encodes the specified ModifyEntryOverviewRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. + * Encodes the specified StarEntryResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest} message ModifyEntryOverviewRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IStarEntryResponse} message StarEntryResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ModifyEntryOverviewRequest.encode = function encode(message, writer) { + StarEntryResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.entryOverview != null && Object.hasOwnProperty.call(message, "entryOverview")) - $root.google.cloud.datacatalog.v1.EntryOverview.encode(message.entryOverview, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified ModifyEntryOverviewRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. + * Encodes the specified StarEntryResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.StarEntryResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest} message ModifyEntryOverviewRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IStarEntryResponse} message StarEntryResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ModifyEntryOverviewRequest.encodeDelimited = function encodeDelimited(message, writer) { + StarEntryResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer. + * Decodes a StarEntryResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest + * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ModifyEntryOverviewRequest.decode = function decode(reader, length) { + StarEntryResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.StarEntryResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.decode(reader, reader.uint32()); - break; - } default: reader.skipType(tag & 7); break; @@ -14668,137 +16094,109 @@ }; /** - * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer, length delimited. + * Decodes a StarEntryResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest + * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ModifyEntryOverviewRequest.decodeDelimited = function decodeDelimited(reader) { + StarEntryResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ModifyEntryOverviewRequest message. + * Verifies a StarEntryResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ModifyEntryOverviewRequest.verify = function verify(message) { + StarEntryResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.entryOverview != null && message.hasOwnProperty("entryOverview")) { - var error = $root.google.cloud.datacatalog.v1.EntryOverview.verify(message.entryOverview); - if (error) - return "entryOverview." + error; - } return null; }; /** - * Creates a ModifyEntryOverviewRequest message from a plain object. Also converts values to their respective internal types. + * Creates a StarEntryResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest + * @returns {google.cloud.datacatalog.v1.StarEntryResponse} StarEntryResponse */ - ModifyEntryOverviewRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest) + StarEntryResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.StarEntryResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest(); - if (object.name != null) - message.name = String(object.name); - if (object.entryOverview != null) { - if (typeof object.entryOverview !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.entryOverview: object expected"); - message.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.fromObject(object.entryOverview); - } - return message; + return new $root.google.cloud.datacatalog.v1.StarEntryResponse(); }; /** - * Creates a plain object from a ModifyEntryOverviewRequest message. Also converts values to other types if specified. + * Creates a plain object from a StarEntryResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} message ModifyEntryOverviewRequest + * @param {google.cloud.datacatalog.v1.StarEntryResponse} message StarEntryResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ModifyEntryOverviewRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.name = ""; - object.entryOverview = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.entryOverview != null && message.hasOwnProperty("entryOverview")) - object.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.toObject(message.entryOverview, options); - return object; + StarEntryResponse.toObject = function toObject() { + return {}; }; /** - * Converts this ModifyEntryOverviewRequest to JSON. + * Converts this StarEntryResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @instance * @returns {Object.} JSON object */ - ModifyEntryOverviewRequest.prototype.toJSON = function toJSON() { + StarEntryResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ModifyEntryOverviewRequest + * Gets the default type url for StarEntryResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest + * @memberof google.cloud.datacatalog.v1.StarEntryResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ModifyEntryOverviewRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + StarEntryResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ModifyEntryOverviewRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.StarEntryResponse"; }; - return ModifyEntryOverviewRequest; + return StarEntryResponse; })(); - v1.ModifyEntryContactsRequest = (function() { + v1.UnstarEntryRequest = (function() { /** - * Properties of a ModifyEntryContactsRequest. + * Properties of an UnstarEntryRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IModifyEntryContactsRequest - * @property {string|null} [name] ModifyEntryContactsRequest name - * @property {google.cloud.datacatalog.v1.IContacts|null} [contacts] ModifyEntryContactsRequest contacts + * @interface IUnstarEntryRequest + * @property {string|null} [name] UnstarEntryRequest name */ /** - * Constructs a new ModifyEntryContactsRequest. + * Constructs a new UnstarEntryRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ModifyEntryContactsRequest. - * @implements IModifyEntryContactsRequest + * @classdesc Represents an UnstarEntryRequest. + * @implements IUnstarEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest=} [properties] Properties to set */ - function ModifyEntryContactsRequest(properties) { + function UnstarEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -14806,80 +16204,70 @@ } /** - * ModifyEntryContactsRequest name. + * UnstarEntryRequest name. * @member {string} name - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest - * @instance - */ - ModifyEntryContactsRequest.prototype.name = ""; - - /** - * ModifyEntryContactsRequest contacts. - * @member {google.cloud.datacatalog.v1.IContacts|null|undefined} contacts - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @instance */ - ModifyEntryContactsRequest.prototype.contacts = null; + UnstarEntryRequest.prototype.name = ""; /** - * Creates a new ModifyEntryContactsRequest instance using the specified properties. + * Creates a new UnstarEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest instance + * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest instance */ - ModifyEntryContactsRequest.create = function create(properties) { - return new ModifyEntryContactsRequest(properties); + UnstarEntryRequest.create = function create(properties) { + return new UnstarEntryRequest(properties); }; /** - * Encodes the specified ModifyEntryContactsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryContactsRequest.verify|verify} messages. + * Encodes the specified UnstarEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest} message ModifyEntryContactsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest} message UnstarEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ModifyEntryContactsRequest.encode = function encode(message, writer) { + UnstarEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.contacts != null && Object.hasOwnProperty.call(message, "contacts")) - $root.google.cloud.datacatalog.v1.Contacts.encode(message.contacts, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified ModifyEntryContactsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryContactsRequest.verify|verify} messages. + * Encodes the specified UnstarEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest} message ModifyEntryContactsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUnstarEntryRequest} message UnstarEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ModifyEntryContactsRequest.encodeDelimited = function encodeDelimited(message, writer) { + UnstarEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ModifyEntryContactsRequest message from the specified reader or buffer. + * Decodes an UnstarEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ModifyEntryContactsRequest.decode = function decode(reader, length) { + UnstarEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UnstarEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -14887,10 +16275,6 @@ message.name = reader.string(); break; } - case 2: { - message.contacts = $root.google.cloud.datacatalog.v1.Contacts.decode(reader, reader.uint32()); - break; - } default: reader.skipType(tag & 7); break; @@ -14900,173 +16284,121 @@ }; /** - * Decodes a ModifyEntryContactsRequest message from the specified reader or buffer, length delimited. + * Decodes an UnstarEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ModifyEntryContactsRequest.decodeDelimited = function decodeDelimited(reader) { + UnstarEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ModifyEntryContactsRequest message. + * Verifies an UnstarEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ModifyEntryContactsRequest.verify = function verify(message) { + UnstarEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; - if (message.contacts != null && message.hasOwnProperty("contacts")) { - var error = $root.google.cloud.datacatalog.v1.Contacts.verify(message.contacts); - if (error) - return "contacts." + error; - } return null; }; /** - * Creates a ModifyEntryContactsRequest message from a plain object. Also converts values to their respective internal types. + * Creates an UnstarEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + * @returns {google.cloud.datacatalog.v1.UnstarEntryRequest} UnstarEntryRequest */ - ModifyEntryContactsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest) + UnstarEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UnstarEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest(); + var message = new $root.google.cloud.datacatalog.v1.UnstarEntryRequest(); if (object.name != null) message.name = String(object.name); - if (object.contacts != null) { - if (typeof object.contacts !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ModifyEntryContactsRequest.contacts: object expected"); - message.contacts = $root.google.cloud.datacatalog.v1.Contacts.fromObject(object.contacts); - } return message; }; /** - * Creates a plain object from a ModifyEntryContactsRequest message. Also converts values to other types if specified. + * Creates a plain object from an UnstarEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static - * @param {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} message ModifyEntryContactsRequest + * @param {google.cloud.datacatalog.v1.UnstarEntryRequest} message UnstarEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ModifyEntryContactsRequest.toObject = function toObject(message, options) { + UnstarEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { + if (options.defaults) object.name = ""; - object.contacts = null; - } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message.contacts != null && message.hasOwnProperty("contacts")) - object.contacts = $root.google.cloud.datacatalog.v1.Contacts.toObject(message.contacts, options); return object; }; /** - * Converts this ModifyEntryContactsRequest to JSON. + * Converts this UnstarEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @instance * @returns {Object.} JSON object */ - ModifyEntryContactsRequest.prototype.toJSON = function toJSON() { + UnstarEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ModifyEntryContactsRequest + * Gets the default type url for UnstarEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @memberof google.cloud.datacatalog.v1.UnstarEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ModifyEntryContactsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UnstarEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ModifyEntryContactsRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UnstarEntryRequest"; }; - return ModifyEntryContactsRequest; - })(); - - /** - * EntryType enum. - * @name google.cloud.datacatalog.v1.EntryType - * @enum {number} - * @property {number} ENTRY_TYPE_UNSPECIFIED=0 ENTRY_TYPE_UNSPECIFIED value - * @property {number} TABLE=2 TABLE value - * @property {number} MODEL=5 MODEL value - * @property {number} DATA_STREAM=3 DATA_STREAM value - * @property {number} FILESET=4 FILESET value - * @property {number} CLUSTER=6 CLUSTER value - * @property {number} DATABASE=7 DATABASE value - * @property {number} DATA_SOURCE_CONNECTION=8 DATA_SOURCE_CONNECTION value - * @property {number} ROUTINE=9 ROUTINE value - * @property {number} LAKE=10 LAKE value - * @property {number} ZONE=11 ZONE value - * @property {number} SERVICE=14 SERVICE value - */ - v1.EntryType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ENTRY_TYPE_UNSPECIFIED"] = 0; - values[valuesById[2] = "TABLE"] = 2; - values[valuesById[5] = "MODEL"] = 5; - values[valuesById[3] = "DATA_STREAM"] = 3; - values[valuesById[4] = "FILESET"] = 4; - values[valuesById[6] = "CLUSTER"] = 6; - values[valuesById[7] = "DATABASE"] = 7; - values[valuesById[8] = "DATA_SOURCE_CONNECTION"] = 8; - values[valuesById[9] = "ROUTINE"] = 9; - values[valuesById[10] = "LAKE"] = 10; - values[valuesById[11] = "ZONE"] = 11; - values[valuesById[14] = "SERVICE"] = 14; - return values; + return UnstarEntryRequest; })(); - v1.DataplexSpec = (function() { + v1.UnstarEntryResponse = (function() { /** - * Properties of a DataplexSpec. + * Properties of an UnstarEntryResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IDataplexSpec - * @property {string|null} [asset] DataplexSpec asset - * @property {google.cloud.datacatalog.v1.IPhysicalSchema|null} [dataFormat] DataplexSpec dataFormat - * @property {string|null} [compressionFormat] DataplexSpec compressionFormat - * @property {string|null} [projectId] DataplexSpec projectId + * @interface IUnstarEntryResponse */ /** - * Constructs a new DataplexSpec. + * Constructs a new UnstarEntryResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DataplexSpec. - * @implements IDataplexSpec + * @classdesc Represents an UnstarEntryResponse. + * @implements IUnstarEntryResponse * @constructor - * @param {google.cloud.datacatalog.v1.IDataplexSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse=} [properties] Properties to set */ - function DataplexSpec(properties) { + function UnstarEntryResponse(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15074,119 +16406,63 @@ } /** - * DataplexSpec asset. - * @member {string} asset - * @memberof google.cloud.datacatalog.v1.DataplexSpec - * @instance - */ - DataplexSpec.prototype.asset = ""; - - /** - * DataplexSpec dataFormat. - * @member {google.cloud.datacatalog.v1.IPhysicalSchema|null|undefined} dataFormat - * @memberof google.cloud.datacatalog.v1.DataplexSpec - * @instance - */ - DataplexSpec.prototype.dataFormat = null; - - /** - * DataplexSpec compressionFormat. - * @member {string} compressionFormat - * @memberof google.cloud.datacatalog.v1.DataplexSpec - * @instance - */ - DataplexSpec.prototype.compressionFormat = ""; - - /** - * DataplexSpec projectId. - * @member {string} projectId - * @memberof google.cloud.datacatalog.v1.DataplexSpec - * @instance - */ - DataplexSpec.prototype.projectId = ""; - - /** - * Creates a new DataplexSpec instance using the specified properties. + * Creates a new UnstarEntryResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec instance + * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse instance */ - DataplexSpec.create = function create(properties) { - return new DataplexSpec(properties); + UnstarEntryResponse.create = function create(properties) { + return new UnstarEntryResponse(properties); }; /** - * Encodes the specified DataplexSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexSpec.verify|verify} messages. + * Encodes the specified UnstarEntryResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexSpec} message DataplexSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse} message UnstarEntryResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexSpec.encode = function encode(message, writer) { + UnstarEntryResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.asset != null && Object.hasOwnProperty.call(message, "asset")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.asset); - if (message.dataFormat != null && Object.hasOwnProperty.call(message, "dataFormat")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.encode(message.dataFormat, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.compressionFormat != null && Object.hasOwnProperty.call(message, "compressionFormat")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.compressionFormat); - if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.projectId); return writer; }; /** - * Encodes the specified DataplexSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexSpec.verify|verify} messages. + * Encodes the specified UnstarEntryResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UnstarEntryResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexSpec} message DataplexSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUnstarEntryResponse} message UnstarEntryResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexSpec.encodeDelimited = function encodeDelimited(message, writer) { + UnstarEntryResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DataplexSpec message from the specified reader or buffer. + * Decodes an UnstarEntryResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexSpec.decode = function decode(reader, length) { + UnstarEntryResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UnstarEntryResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.asset = reader.string(); - break; - } - case 2: { - message.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.decode(reader, reader.uint32()); - break; - } - case 3: { - message.compressionFormat = reader.string(); - break; - } - case 4: { - message.projectId = reader.string(); - break; - } default: reader.skipType(tag & 7); break; @@ -15196,152 +16472,110 @@ }; /** - * Decodes a DataplexSpec message from the specified reader or buffer, length delimited. + * Decodes an UnstarEntryResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexSpec.decodeDelimited = function decodeDelimited(reader) { + UnstarEntryResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DataplexSpec message. + * Verifies an UnstarEntryResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DataplexSpec.verify = function verify(message) { + UnstarEntryResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.asset != null && message.hasOwnProperty("asset")) - if (!$util.isString(message.asset)) - return "asset: string expected"; - if (message.dataFormat != null && message.hasOwnProperty("dataFormat")) { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.verify(message.dataFormat); - if (error) - return "dataFormat." + error; - } - if (message.compressionFormat != null && message.hasOwnProperty("compressionFormat")) - if (!$util.isString(message.compressionFormat)) - return "compressionFormat: string expected"; - if (message.projectId != null && message.hasOwnProperty("projectId")) - if (!$util.isString(message.projectId)) - return "projectId: string expected"; return null; }; /** - * Creates a DataplexSpec message from a plain object. Also converts values to their respective internal types. + * Creates an UnstarEntryResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + * @returns {google.cloud.datacatalog.v1.UnstarEntryResponse} UnstarEntryResponse */ - DataplexSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DataplexSpec) + UnstarEntryResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UnstarEntryResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.DataplexSpec(); - if (object.asset != null) - message.asset = String(object.asset); - if (object.dataFormat != null) { - if (typeof object.dataFormat !== "object") - throw TypeError(".google.cloud.datacatalog.v1.DataplexSpec.dataFormat: object expected"); - message.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.fromObject(object.dataFormat); - } - if (object.compressionFormat != null) - message.compressionFormat = String(object.compressionFormat); - if (object.projectId != null) - message.projectId = String(object.projectId); - return message; + return new $root.google.cloud.datacatalog.v1.UnstarEntryResponse(); }; /** - * Creates a plain object from a DataplexSpec message. Also converts values to other types if specified. + * Creates a plain object from an UnstarEntryResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static - * @param {google.cloud.datacatalog.v1.DataplexSpec} message DataplexSpec + * @param {google.cloud.datacatalog.v1.UnstarEntryResponse} message UnstarEntryResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DataplexSpec.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.asset = ""; - object.dataFormat = null; - object.compressionFormat = ""; - object.projectId = ""; - } - if (message.asset != null && message.hasOwnProperty("asset")) - object.asset = message.asset; - if (message.dataFormat != null && message.hasOwnProperty("dataFormat")) - object.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.toObject(message.dataFormat, options); - if (message.compressionFormat != null && message.hasOwnProperty("compressionFormat")) - object.compressionFormat = message.compressionFormat; - if (message.projectId != null && message.hasOwnProperty("projectId")) - object.projectId = message.projectId; - return object; + UnstarEntryResponse.toObject = function toObject() { + return {}; }; /** - * Converts this DataplexSpec to JSON. + * Converts this UnstarEntryResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @instance * @returns {Object.} JSON object */ - DataplexSpec.prototype.toJSON = function toJSON() { + UnstarEntryResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DataplexSpec + * Gets the default type url for UnstarEntryResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @memberof google.cloud.datacatalog.v1.UnstarEntryResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DataplexSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UnstarEntryResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UnstarEntryResponse"; }; - return DataplexSpec; + return UnstarEntryResponse; })(); - v1.DataplexFilesetSpec = (function() { + v1.ImportEntriesRequest = (function() { /** - * Properties of a DataplexFilesetSpec. + * Properties of an ImportEntriesRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IDataplexFilesetSpec - * @property {google.cloud.datacatalog.v1.IDataplexSpec|null} [dataplexSpec] DataplexFilesetSpec dataplexSpec + * @interface IImportEntriesRequest + * @property {string|null} [parent] ImportEntriesRequest parent + * @property {string|null} [gcsBucketPath] ImportEntriesRequest gcsBucketPath */ /** - * Constructs a new DataplexFilesetSpec. + * Constructs a new ImportEntriesRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DataplexFilesetSpec. - * @implements IDataplexFilesetSpec + * @classdesc Represents an ImportEntriesRequest. + * @implements IImportEntriesRequest * @constructor - * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest=} [properties] Properties to set */ - function DataplexFilesetSpec(properties) { + function ImportEntriesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15349,75 +16583,103 @@ } /** - * DataplexFilesetSpec dataplexSpec. - * @member {google.cloud.datacatalog.v1.IDataplexSpec|null|undefined} dataplexSpec - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * ImportEntriesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @instance */ - DataplexFilesetSpec.prototype.dataplexSpec = null; + ImportEntriesRequest.prototype.parent = ""; /** - * Creates a new DataplexFilesetSpec instance using the specified properties. + * ImportEntriesRequest gcsBucketPath. + * @member {string|null|undefined} gcsBucketPath + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest + * @instance + */ + ImportEntriesRequest.prototype.gcsBucketPath = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * ImportEntriesRequest source. + * @member {"gcsBucketPath"|undefined} source + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest + * @instance + */ + Object.defineProperty(ImportEntriesRequest.prototype, "source", { + get: $util.oneOfGetter($oneOfFields = ["gcsBucketPath"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ImportEntriesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec instance + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ImportEntriesRequest} ImportEntriesRequest instance */ - DataplexFilesetSpec.create = function create(properties) { - return new DataplexFilesetSpec(properties); + ImportEntriesRequest.create = function create(properties) { + return new ImportEntriesRequest(properties); }; /** - * Encodes the specified DataplexFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexFilesetSpec.verify|verify} messages. + * Encodes the specified ImportEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec} message DataplexFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest} message ImportEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexFilesetSpec.encode = function encode(message, writer) { + ImportEntriesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.dataplexSpec != null && Object.hasOwnProperty.call(message, "dataplexSpec")) - $root.google.cloud.datacatalog.v1.DataplexSpec.encode(message.dataplexSpec, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.gcsBucketPath != null && Object.hasOwnProperty.call(message, "gcsBucketPath")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.gcsBucketPath); return writer; }; /** - * Encodes the specified DataplexFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexFilesetSpec.verify|verify} messages. + * Encodes the specified ImportEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec} message DataplexFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesRequest} message ImportEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { + ImportEntriesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DataplexFilesetSpec message from the specified reader or buffer. + * Decodes an ImportEntriesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesRequest} ImportEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexFilesetSpec.decode = function decode(reader, length) { + ImportEntriesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexFilesetSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportEntriesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.decode(reader, reader.uint32()); + message.parent = reader.string(); + break; + } + case 2: { + message.gcsBucketPath = reader.string(); break; } default: @@ -15429,130 +16691,136 @@ }; /** - * Decodes a DataplexFilesetSpec message from the specified reader or buffer, length delimited. + * Decodes an ImportEntriesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesRequest} ImportEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexFilesetSpec.decodeDelimited = function decodeDelimited(reader) { + ImportEntriesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DataplexFilesetSpec message. + * Verifies an ImportEntriesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DataplexFilesetSpec.verify = function verify(message) { + ImportEntriesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) { - var error = $root.google.cloud.datacatalog.v1.DataplexSpec.verify(message.dataplexSpec); - if (error) - return "dataplexSpec." + error; + var properties = {}; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.gcsBucketPath != null && message.hasOwnProperty("gcsBucketPath")) { + properties.source = 1; + if (!$util.isString(message.gcsBucketPath)) + return "gcsBucketPath: string expected"; } return null; }; /** - * Creates a DataplexFilesetSpec message from a plain object. Also converts values to their respective internal types. + * Creates an ImportEntriesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesRequest} ImportEntriesRequest */ - DataplexFilesetSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DataplexFilesetSpec) + ImportEntriesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ImportEntriesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.DataplexFilesetSpec(); - if (object.dataplexSpec != null) { - if (typeof object.dataplexSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1.DataplexFilesetSpec.dataplexSpec: object expected"); - message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.fromObject(object.dataplexSpec); - } + var message = new $root.google.cloud.datacatalog.v1.ImportEntriesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.gcsBucketPath != null) + message.gcsBucketPath = String(object.gcsBucketPath); return message; }; /** - * Creates a plain object from a DataplexFilesetSpec message. Also converts values to other types if specified. + * Creates a plain object from an ImportEntriesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static - * @param {google.cloud.datacatalog.v1.DataplexFilesetSpec} message DataplexFilesetSpec + * @param {google.cloud.datacatalog.v1.ImportEntriesRequest} message ImportEntriesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DataplexFilesetSpec.toObject = function toObject(message, options) { + ImportEntriesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) - object.dataplexSpec = null; - if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) - object.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.toObject(message.dataplexSpec, options); + object.parent = ""; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.gcsBucketPath != null && message.hasOwnProperty("gcsBucketPath")) { + object.gcsBucketPath = message.gcsBucketPath; + if (options.oneofs) + object.source = "gcsBucketPath"; + } return object; }; /** - * Converts this DataplexFilesetSpec to JSON. + * Converts this ImportEntriesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @instance * @returns {Object.} JSON object */ - DataplexFilesetSpec.prototype.toJSON = function toJSON() { + ImportEntriesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DataplexFilesetSpec + * Gets the default type url for ImportEntriesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DataplexFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ImportEntriesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexFilesetSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportEntriesRequest"; }; - return DataplexFilesetSpec; + return ImportEntriesRequest; })(); - v1.DataplexTableSpec = (function() { + v1.ImportEntriesResponse = (function() { /** - * Properties of a DataplexTableSpec. + * Properties of an ImportEntriesResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IDataplexTableSpec - * @property {Array.|null} [externalTables] DataplexTableSpec externalTables - * @property {google.cloud.datacatalog.v1.IDataplexSpec|null} [dataplexSpec] DataplexTableSpec dataplexSpec - * @property {boolean|null} [userManaged] DataplexTableSpec userManaged + * @interface IImportEntriesResponse + * @property {number|Long|null} [upsertedEntriesCount] ImportEntriesResponse upsertedEntriesCount + * @property {number|Long|null} [deletedEntriesCount] ImportEntriesResponse deletedEntriesCount */ /** - * Constructs a new DataplexTableSpec. + * Constructs a new ImportEntriesResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DataplexTableSpec. - * @implements IDataplexTableSpec + * @classdesc Represents an ImportEntriesResponse. + * @implements IImportEntriesResponse * @constructor - * @param {google.cloud.datacatalog.v1.IDataplexTableSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IImportEntriesResponse=} [properties] Properties to set */ - function DataplexTableSpec(properties) { - this.externalTables = []; + function ImportEntriesResponse(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15560,106 +16828,114 @@ } /** - * DataplexTableSpec externalTables. - * @member {Array.} externalTables - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * ImportEntriesResponse upsertedEntriesCount. + * @member {number|Long|null|undefined} upsertedEntriesCount + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @instance */ - DataplexTableSpec.prototype.externalTables = $util.emptyArray; + ImportEntriesResponse.prototype.upsertedEntriesCount = null; /** - * DataplexTableSpec dataplexSpec. - * @member {google.cloud.datacatalog.v1.IDataplexSpec|null|undefined} dataplexSpec - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * ImportEntriesResponse deletedEntriesCount. + * @member {number|Long|null|undefined} deletedEntriesCount + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @instance */ - DataplexTableSpec.prototype.dataplexSpec = null; + ImportEntriesResponse.prototype.deletedEntriesCount = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * DataplexTableSpec userManaged. - * @member {boolean} userManaged - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * ImportEntriesResponse _upsertedEntriesCount. + * @member {"upsertedEntriesCount"|undefined} _upsertedEntriesCount + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @instance */ - DataplexTableSpec.prototype.userManaged = false; + Object.defineProperty(ImportEntriesResponse.prototype, "_upsertedEntriesCount", { + get: $util.oneOfGetter($oneOfFields = ["upsertedEntriesCount"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new DataplexTableSpec instance using the specified properties. + * ImportEntriesResponse _deletedEntriesCount. + * @member {"deletedEntriesCount"|undefined} _deletedEntriesCount + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse + * @instance + */ + Object.defineProperty(ImportEntriesResponse.prototype, "_deletedEntriesCount", { + get: $util.oneOfGetter($oneOfFields = ["deletedEntriesCount"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ImportEntriesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexTableSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec instance + * @param {google.cloud.datacatalog.v1.IImportEntriesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ImportEntriesResponse} ImportEntriesResponse instance */ - DataplexTableSpec.create = function create(properties) { - return new DataplexTableSpec(properties); + ImportEntriesResponse.create = function create(properties) { + return new ImportEntriesResponse(properties); }; /** - * Encodes the specified DataplexTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexTableSpec.verify|verify} messages. + * Encodes the specified ImportEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexTableSpec} message DataplexTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesResponse} message ImportEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexTableSpec.encode = function encode(message, writer) { + ImportEntriesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.externalTables != null && message.externalTables.length) - for (var i = 0; i < message.externalTables.length; ++i) - $root.google.cloud.datacatalog.v1.DataplexExternalTable.encode(message.externalTables[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.dataplexSpec != null && Object.hasOwnProperty.call(message, "dataplexSpec")) - $root.google.cloud.datacatalog.v1.DataplexSpec.encode(message.dataplexSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.userManaged != null && Object.hasOwnProperty.call(message, "userManaged")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.userManaged); + if (message.upsertedEntriesCount != null && Object.hasOwnProperty.call(message, "upsertedEntriesCount")) + writer.uint32(/* id 5, wireType 0 =*/40).int64(message.upsertedEntriesCount); + if (message.deletedEntriesCount != null && Object.hasOwnProperty.call(message, "deletedEntriesCount")) + writer.uint32(/* id 6, wireType 0 =*/48).int64(message.deletedEntriesCount); return writer; }; /** - * Encodes the specified DataplexTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexTableSpec.verify|verify} messages. + * Encodes the specified ImportEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.IDataplexTableSpec} message DataplexTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesResponse} message ImportEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexTableSpec.encodeDelimited = function encodeDelimited(message, writer) { + ImportEntriesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DataplexTableSpec message from the specified reader or buffer. + * Decodes an ImportEntriesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesResponse} ImportEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexTableSpec.decode = function decode(reader, length) { + ImportEntriesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexTableSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportEntriesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - if (!(message.externalTables && message.externalTables.length)) - message.externalTables = []; - message.externalTables.push($root.google.cloud.datacatalog.v1.DataplexExternalTable.decode(reader, reader.uint32())); - break; - } - case 2: { - message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.decode(reader, reader.uint32()); + case 5: { + message.upsertedEntriesCount = reader.int64(); break; } - case 3: { - message.userManaged = reader.bool(); + case 6: { + message.deletedEntriesCount = reader.int64(); break; } default: @@ -15671,165 +16947,160 @@ }; /** - * Decodes a DataplexTableSpec message from the specified reader or buffer, length delimited. + * Decodes an ImportEntriesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesResponse} ImportEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexTableSpec.decodeDelimited = function decodeDelimited(reader) { + ImportEntriesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DataplexTableSpec message. + * Verifies an ImportEntriesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DataplexTableSpec.verify = function verify(message) { + ImportEntriesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.externalTables != null && message.hasOwnProperty("externalTables")) { - if (!Array.isArray(message.externalTables)) - return "externalTables: array expected"; - for (var i = 0; i < message.externalTables.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.DataplexExternalTable.verify(message.externalTables[i]); - if (error) - return "externalTables." + error; - } + var properties = {}; + if (message.upsertedEntriesCount != null && message.hasOwnProperty("upsertedEntriesCount")) { + properties._upsertedEntriesCount = 1; + if (!$util.isInteger(message.upsertedEntriesCount) && !(message.upsertedEntriesCount && $util.isInteger(message.upsertedEntriesCount.low) && $util.isInteger(message.upsertedEntriesCount.high))) + return "upsertedEntriesCount: integer|Long expected"; } - if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) { - var error = $root.google.cloud.datacatalog.v1.DataplexSpec.verify(message.dataplexSpec); - if (error) - return "dataplexSpec." + error; + if (message.deletedEntriesCount != null && message.hasOwnProperty("deletedEntriesCount")) { + properties._deletedEntriesCount = 1; + if (!$util.isInteger(message.deletedEntriesCount) && !(message.deletedEntriesCount && $util.isInteger(message.deletedEntriesCount.low) && $util.isInteger(message.deletedEntriesCount.high))) + return "deletedEntriesCount: integer|Long expected"; } - if (message.userManaged != null && message.hasOwnProperty("userManaged")) - if (typeof message.userManaged !== "boolean") - return "userManaged: boolean expected"; return null; }; /** - * Creates a DataplexTableSpec message from a plain object. Also converts values to their respective internal types. + * Creates an ImportEntriesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec + * @returns {google.cloud.datacatalog.v1.ImportEntriesResponse} ImportEntriesResponse */ - DataplexTableSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DataplexTableSpec) + ImportEntriesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ImportEntriesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.DataplexTableSpec(); - if (object.externalTables) { - if (!Array.isArray(object.externalTables)) - throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.externalTables: array expected"); - message.externalTables = []; - for (var i = 0; i < object.externalTables.length; ++i) { - if (typeof object.externalTables[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.externalTables: object expected"); - message.externalTables[i] = $root.google.cloud.datacatalog.v1.DataplexExternalTable.fromObject(object.externalTables[i]); - } - } - if (object.dataplexSpec != null) { - if (typeof object.dataplexSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.dataplexSpec: object expected"); - message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.fromObject(object.dataplexSpec); - } - if (object.userManaged != null) - message.userManaged = Boolean(object.userManaged); + var message = new $root.google.cloud.datacatalog.v1.ImportEntriesResponse(); + if (object.upsertedEntriesCount != null) + if ($util.Long) + (message.upsertedEntriesCount = $util.Long.fromValue(object.upsertedEntriesCount)).unsigned = false; + else if (typeof object.upsertedEntriesCount === "string") + message.upsertedEntriesCount = parseInt(object.upsertedEntriesCount, 10); + else if (typeof object.upsertedEntriesCount === "number") + message.upsertedEntriesCount = object.upsertedEntriesCount; + else if (typeof object.upsertedEntriesCount === "object") + message.upsertedEntriesCount = new $util.LongBits(object.upsertedEntriesCount.low >>> 0, object.upsertedEntriesCount.high >>> 0).toNumber(); + if (object.deletedEntriesCount != null) + if ($util.Long) + (message.deletedEntriesCount = $util.Long.fromValue(object.deletedEntriesCount)).unsigned = false; + else if (typeof object.deletedEntriesCount === "string") + message.deletedEntriesCount = parseInt(object.deletedEntriesCount, 10); + else if (typeof object.deletedEntriesCount === "number") + message.deletedEntriesCount = object.deletedEntriesCount; + else if (typeof object.deletedEntriesCount === "object") + message.deletedEntriesCount = new $util.LongBits(object.deletedEntriesCount.low >>> 0, object.deletedEntriesCount.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a DataplexTableSpec message. Also converts values to other types if specified. + * Creates a plain object from an ImportEntriesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static - * @param {google.cloud.datacatalog.v1.DataplexTableSpec} message DataplexTableSpec + * @param {google.cloud.datacatalog.v1.ImportEntriesResponse} message ImportEntriesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DataplexTableSpec.toObject = function toObject(message, options) { + ImportEntriesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.externalTables = []; - if (options.defaults) { - object.dataplexSpec = null; - object.userManaged = false; + if (message.upsertedEntriesCount != null && message.hasOwnProperty("upsertedEntriesCount")) { + if (typeof message.upsertedEntriesCount === "number") + object.upsertedEntriesCount = options.longs === String ? String(message.upsertedEntriesCount) : message.upsertedEntriesCount; + else + object.upsertedEntriesCount = options.longs === String ? $util.Long.prototype.toString.call(message.upsertedEntriesCount) : options.longs === Number ? new $util.LongBits(message.upsertedEntriesCount.low >>> 0, message.upsertedEntriesCount.high >>> 0).toNumber() : message.upsertedEntriesCount; + if (options.oneofs) + object._upsertedEntriesCount = "upsertedEntriesCount"; } - if (message.externalTables && message.externalTables.length) { - object.externalTables = []; - for (var j = 0; j < message.externalTables.length; ++j) - object.externalTables[j] = $root.google.cloud.datacatalog.v1.DataplexExternalTable.toObject(message.externalTables[j], options); + if (message.deletedEntriesCount != null && message.hasOwnProperty("deletedEntriesCount")) { + if (typeof message.deletedEntriesCount === "number") + object.deletedEntriesCount = options.longs === String ? String(message.deletedEntriesCount) : message.deletedEntriesCount; + else + object.deletedEntriesCount = options.longs === String ? $util.Long.prototype.toString.call(message.deletedEntriesCount) : options.longs === Number ? new $util.LongBits(message.deletedEntriesCount.low >>> 0, message.deletedEntriesCount.high >>> 0).toNumber() : message.deletedEntriesCount; + if (options.oneofs) + object._deletedEntriesCount = "deletedEntriesCount"; } - if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) - object.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.toObject(message.dataplexSpec, options); - if (message.userManaged != null && message.hasOwnProperty("userManaged")) - object.userManaged = message.userManaged; return object; }; /** - * Converts this DataplexTableSpec to JSON. + * Converts this ImportEntriesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @instance * @returns {Object.} JSON object */ - DataplexTableSpec.prototype.toJSON = function toJSON() { + ImportEntriesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DataplexTableSpec + * Gets the default type url for ImportEntriesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @memberof google.cloud.datacatalog.v1.ImportEntriesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DataplexTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ImportEntriesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexTableSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportEntriesResponse"; }; - return DataplexTableSpec; + return ImportEntriesResponse; })(); - v1.DataplexExternalTable = (function() { + v1.ImportEntriesMetadata = (function() { /** - * Properties of a DataplexExternalTable. + * Properties of an ImportEntriesMetadata. * @memberof google.cloud.datacatalog.v1 - * @interface IDataplexExternalTable - * @property {google.cloud.datacatalog.v1.IntegratedSystem|null} [system] DataplexExternalTable system - * @property {string|null} [fullyQualifiedName] DataplexExternalTable fullyQualifiedName - * @property {string|null} [googleCloudResource] DataplexExternalTable googleCloudResource - * @property {string|null} [dataCatalogEntry] DataplexExternalTable dataCatalogEntry + * @interface IImportEntriesMetadata + * @property {google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState|null} [state] ImportEntriesMetadata state + * @property {Array.|null} [errors] ImportEntriesMetadata errors */ /** - * Constructs a new DataplexExternalTable. + * Constructs a new ImportEntriesMetadata. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DataplexExternalTable. - * @implements IDataplexExternalTable + * @classdesc Represents an ImportEntriesMetadata. + * @implements IImportEntriesMetadata * @constructor - * @param {google.cloud.datacatalog.v1.IDataplexExternalTable=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IImportEntriesMetadata=} [properties] Properties to set */ - function DataplexExternalTable(properties) { + function ImportEntriesMetadata(properties) { + this.errors = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -15837,117 +17108,92 @@ } /** - * DataplexExternalTable system. - * @member {google.cloud.datacatalog.v1.IntegratedSystem} system - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable - * @instance - */ - DataplexExternalTable.prototype.system = 0; - - /** - * DataplexExternalTable fullyQualifiedName. - * @member {string} fullyQualifiedName - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable - * @instance - */ - DataplexExternalTable.prototype.fullyQualifiedName = ""; - - /** - * DataplexExternalTable googleCloudResource. - * @member {string} googleCloudResource - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * ImportEntriesMetadata state. + * @member {google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState} state + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @instance */ - DataplexExternalTable.prototype.googleCloudResource = ""; + ImportEntriesMetadata.prototype.state = 0; /** - * DataplexExternalTable dataCatalogEntry. - * @member {string} dataCatalogEntry - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * ImportEntriesMetadata errors. + * @member {Array.} errors + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @instance */ - DataplexExternalTable.prototype.dataCatalogEntry = ""; + ImportEntriesMetadata.prototype.errors = $util.emptyArray; /** - * Creates a new DataplexExternalTable instance using the specified properties. + * Creates a new ImportEntriesMetadata instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static - * @param {google.cloud.datacatalog.v1.IDataplexExternalTable=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable instance + * @param {google.cloud.datacatalog.v1.IImportEntriesMetadata=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ImportEntriesMetadata} ImportEntriesMetadata instance */ - DataplexExternalTable.create = function create(properties) { - return new DataplexExternalTable(properties); + ImportEntriesMetadata.create = function create(properties) { + return new ImportEntriesMetadata(properties); }; /** - * Encodes the specified DataplexExternalTable message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexExternalTable.verify|verify} messages. + * Encodes the specified ImportEntriesMetadata message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesMetadata.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static - * @param {google.cloud.datacatalog.v1.IDataplexExternalTable} message DataplexExternalTable message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesMetadata} message ImportEntriesMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexExternalTable.encode = function encode(message, writer) { + ImportEntriesMetadata.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.system != null && Object.hasOwnProperty.call(message, "system")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.system); - if (message.googleCloudResource != null && Object.hasOwnProperty.call(message, "googleCloudResource")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.googleCloudResource); - if (message.dataCatalogEntry != null && Object.hasOwnProperty.call(message, "dataCatalogEntry")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.dataCatalogEntry); - if (message.fullyQualifiedName != null && Object.hasOwnProperty.call(message, "fullyQualifiedName")) - writer.uint32(/* id 28, wireType 2 =*/226).string(message.fullyQualifiedName); + if (message.state != null && Object.hasOwnProperty.call(message, "state")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.state); + if (message.errors != null && message.errors.length) + for (var i = 0; i < message.errors.length; ++i) + $root.google.rpc.Status.encode(message.errors[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified DataplexExternalTable message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexExternalTable.verify|verify} messages. + * Encodes the specified ImportEntriesMetadata message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportEntriesMetadata.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static - * @param {google.cloud.datacatalog.v1.IDataplexExternalTable} message DataplexExternalTable message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportEntriesMetadata} message ImportEntriesMetadata message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DataplexExternalTable.encodeDelimited = function encodeDelimited(message, writer) { + ImportEntriesMetadata.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DataplexExternalTable message from the specified reader or buffer. + * Decodes an ImportEntriesMetadata message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable + * @returns {google.cloud.datacatalog.v1.ImportEntriesMetadata} ImportEntriesMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexExternalTable.decode = function decode(reader, length) { + ImportEntriesMetadata.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexExternalTable(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportEntriesMetadata(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.system = reader.int32(); - break; - } - case 28: { - message.fullyQualifiedName = reader.string(); - break; - } - case 3: { - message.googleCloudResource = reader.string(); + message.state = reader.int32(); break; } - case 4: { - message.dataCatalogEntry = reader.string(); + case 2: { + if (!(message.errors && message.errors.length)) + message.errors = []; + message.errors.push($root.google.rpc.Status.decode(reader, reader.uint32())); break; } default: @@ -15959,36 +17205,36 @@ }; /** - * Decodes a DataplexExternalTable message from the specified reader or buffer, length delimited. + * Decodes an ImportEntriesMetadata message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable + * @returns {google.cloud.datacatalog.v1.ImportEntriesMetadata} ImportEntriesMetadata * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DataplexExternalTable.decodeDelimited = function decodeDelimited(reader) { + ImportEntriesMetadata.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DataplexExternalTable message. + * Verifies an ImportEntriesMetadata message. * @function verify - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DataplexExternalTable.verify = function verify(message) { + ImportEntriesMetadata.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.system != null && message.hasOwnProperty("system")) - switch (message.system) { + if (message.state != null && message.hasOwnProperty("state")) + switch (message.state) { default: - return "system: enum value expected"; + return "state: enum value expected"; case 0: case 1: case 2: @@ -15996,149 +17242,166 @@ case 4: break; } - if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) - if (!$util.isString(message.fullyQualifiedName)) - return "fullyQualifiedName: string expected"; - if (message.googleCloudResource != null && message.hasOwnProperty("googleCloudResource")) - if (!$util.isString(message.googleCloudResource)) - return "googleCloudResource: string expected"; - if (message.dataCatalogEntry != null && message.hasOwnProperty("dataCatalogEntry")) - if (!$util.isString(message.dataCatalogEntry)) - return "dataCatalogEntry: string expected"; + if (message.errors != null && message.hasOwnProperty("errors")) { + if (!Array.isArray(message.errors)) + return "errors: array expected"; + for (var i = 0; i < message.errors.length; ++i) { + var error = $root.google.rpc.Status.verify(message.errors[i]); + if (error) + return "errors." + error; + } + } return null; }; /** - * Creates a DataplexExternalTable message from a plain object. Also converts values to their respective internal types. + * Creates an ImportEntriesMetadata message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable + * @returns {google.cloud.datacatalog.v1.ImportEntriesMetadata} ImportEntriesMetadata */ - DataplexExternalTable.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DataplexExternalTable) + ImportEntriesMetadata.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ImportEntriesMetadata) return object; - var message = new $root.google.cloud.datacatalog.v1.DataplexExternalTable(); - switch (object.system) { + var message = new $root.google.cloud.datacatalog.v1.ImportEntriesMetadata(); + switch (object.state) { default: - if (typeof object.system === "number") { - message.system = object.system; + if (typeof object.state === "number") { + message.state = object.state; break; } break; - case "INTEGRATED_SYSTEM_UNSPECIFIED": + case "IMPORT_STATE_UNSPECIFIED": case 0: - message.system = 0; + message.state = 0; break; - case "BIGQUERY": + case "IMPORT_QUEUED": case 1: - message.system = 1; + message.state = 1; break; - case "CLOUD_PUBSUB": + case "IMPORT_IN_PROGRESS": case 2: - message.system = 2; + message.state = 2; break; - case "DATAPROC_METASTORE": + case "IMPORT_DONE": case 3: - message.system = 3; + message.state = 3; break; - case "DATAPLEX": + case "IMPORT_OBSOLETE": case 4: - message.system = 4; + message.state = 4; break; } - if (object.fullyQualifiedName != null) - message.fullyQualifiedName = String(object.fullyQualifiedName); - if (object.googleCloudResource != null) - message.googleCloudResource = String(object.googleCloudResource); - if (object.dataCatalogEntry != null) - message.dataCatalogEntry = String(object.dataCatalogEntry); + if (object.errors) { + if (!Array.isArray(object.errors)) + throw TypeError(".google.cloud.datacatalog.v1.ImportEntriesMetadata.errors: array expected"); + message.errors = []; + for (var i = 0; i < object.errors.length; ++i) { + if (typeof object.errors[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ImportEntriesMetadata.errors: object expected"); + message.errors[i] = $root.google.rpc.Status.fromObject(object.errors[i]); + } + } return message; }; /** - * Creates a plain object from a DataplexExternalTable message. Also converts values to other types if specified. + * Creates a plain object from an ImportEntriesMetadata message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static - * @param {google.cloud.datacatalog.v1.DataplexExternalTable} message DataplexExternalTable + * @param {google.cloud.datacatalog.v1.ImportEntriesMetadata} message ImportEntriesMetadata * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DataplexExternalTable.toObject = function toObject(message, options) { + ImportEntriesMetadata.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.system = options.enums === String ? "INTEGRATED_SYSTEM_UNSPECIFIED" : 0; - object.googleCloudResource = ""; - object.dataCatalogEntry = ""; - object.fullyQualifiedName = ""; + if (options.arrays || options.defaults) + object.errors = []; + if (options.defaults) + object.state = options.enums === String ? "IMPORT_STATE_UNSPECIFIED" : 0; + if (message.state != null && message.hasOwnProperty("state")) + object.state = options.enums === String ? $root.google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState[message.state] === undefined ? message.state : $root.google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState[message.state] : message.state; + if (message.errors && message.errors.length) { + object.errors = []; + for (var j = 0; j < message.errors.length; ++j) + object.errors[j] = $root.google.rpc.Status.toObject(message.errors[j], options); } - if (message.system != null && message.hasOwnProperty("system")) - object.system = options.enums === String ? $root.google.cloud.datacatalog.v1.IntegratedSystem[message.system] === undefined ? message.system : $root.google.cloud.datacatalog.v1.IntegratedSystem[message.system] : message.system; - if (message.googleCloudResource != null && message.hasOwnProperty("googleCloudResource")) - object.googleCloudResource = message.googleCloudResource; - if (message.dataCatalogEntry != null && message.hasOwnProperty("dataCatalogEntry")) - object.dataCatalogEntry = message.dataCatalogEntry; - if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) - object.fullyQualifiedName = message.fullyQualifiedName; return object; }; /** - * Converts this DataplexExternalTable to JSON. + * Converts this ImportEntriesMetadata to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @instance * @returns {Object.} JSON object */ - DataplexExternalTable.prototype.toJSON = function toJSON() { + ImportEntriesMetadata.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DataplexExternalTable + * Gets the default type url for ImportEntriesMetadata * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @memberof google.cloud.datacatalog.v1.ImportEntriesMetadata * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DataplexExternalTable.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ImportEntriesMetadata.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexExternalTable"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportEntriesMetadata"; }; - return DataplexExternalTable; + /** + * ImportState enum. + * @name google.cloud.datacatalog.v1.ImportEntriesMetadata.ImportState + * @enum {number} + * @property {number} IMPORT_STATE_UNSPECIFIED=0 IMPORT_STATE_UNSPECIFIED value + * @property {number} IMPORT_QUEUED=1 IMPORT_QUEUED value + * @property {number} IMPORT_IN_PROGRESS=2 IMPORT_IN_PROGRESS value + * @property {number} IMPORT_DONE=3 IMPORT_DONE value + * @property {number} IMPORT_OBSOLETE=4 IMPORT_OBSOLETE value + */ + ImportEntriesMetadata.ImportState = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "IMPORT_STATE_UNSPECIFIED"] = 0; + values[valuesById[1] = "IMPORT_QUEUED"] = 1; + values[valuesById[2] = "IMPORT_IN_PROGRESS"] = 2; + values[valuesById[3] = "IMPORT_DONE"] = 3; + values[valuesById[4] = "IMPORT_OBSOLETE"] = 4; + return values; + })(); + + return ImportEntriesMetadata; })(); - v1.PhysicalSchema = (function() { + v1.ModifyEntryOverviewRequest = (function() { /** - * Properties of a PhysicalSchema. + * Properties of a ModifyEntryOverviewRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IPhysicalSchema - * @property {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema|null} [avro] PhysicalSchema avro - * @property {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema|null} [thrift] PhysicalSchema thrift - * @property {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema|null} [protobuf] PhysicalSchema protobuf - * @property {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema|null} [parquet] PhysicalSchema parquet - * @property {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema|null} [orc] PhysicalSchema orc - * @property {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema|null} [csv] PhysicalSchema csv + * @interface IModifyEntryOverviewRequest + * @property {string|null} [name] ModifyEntryOverviewRequest name + * @property {google.cloud.datacatalog.v1.IEntryOverview|null} [entryOverview] ModifyEntryOverviewRequest entryOverview */ /** - * Constructs a new PhysicalSchema. + * Constructs a new ModifyEntryOverviewRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a PhysicalSchema. - * @implements IPhysicalSchema + * @classdesc Represents a ModifyEntryOverviewRequest. + * @implements IModifyEntryOverviewRequest * @constructor - * @param {google.cloud.datacatalog.v1.IPhysicalSchema=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest=} [properties] Properties to set */ - function PhysicalSchema(properties) { + function ModifyEntryOverviewRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -16146,159 +17409,89 @@ } /** - * PhysicalSchema avro. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema|null|undefined} avro - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @instance - */ - PhysicalSchema.prototype.avro = null; - - /** - * PhysicalSchema thrift. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema|null|undefined} thrift - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @instance - */ - PhysicalSchema.prototype.thrift = null; - - /** - * PhysicalSchema protobuf. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema|null|undefined} protobuf - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @instance - */ - PhysicalSchema.prototype.protobuf = null; - - /** - * PhysicalSchema parquet. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema|null|undefined} parquet - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @instance - */ - PhysicalSchema.prototype.parquet = null; - - /** - * PhysicalSchema orc. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema|null|undefined} orc - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @instance - */ - PhysicalSchema.prototype.orc = null; - - /** - * PhysicalSchema csv. - * @member {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema|null|undefined} csv - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * ModifyEntryOverviewRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @instance */ - PhysicalSchema.prototype.csv = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + ModifyEntryOverviewRequest.prototype.name = ""; /** - * PhysicalSchema schema. - * @member {"avro"|"thrift"|"protobuf"|"parquet"|"orc"|"csv"|undefined} schema - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * ModifyEntryOverviewRequest entryOverview. + * @member {google.cloud.datacatalog.v1.IEntryOverview|null|undefined} entryOverview + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @instance */ - Object.defineProperty(PhysicalSchema.prototype, "schema", { - get: $util.oneOfGetter($oneOfFields = ["avro", "thrift", "protobuf", "parquet", "orc", "csv"]), - set: $util.oneOfSetter($oneOfFields) - }); + ModifyEntryOverviewRequest.prototype.entryOverview = null; /** - * Creates a new PhysicalSchema instance using the specified properties. + * Creates a new ModifyEntryOverviewRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static - * @param {google.cloud.datacatalog.v1.IPhysicalSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema instance + * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest instance */ - PhysicalSchema.create = function create(properties) { - return new PhysicalSchema(properties); + ModifyEntryOverviewRequest.create = function create(properties) { + return new ModifyEntryOverviewRequest(properties); }; /** - * Encodes the specified PhysicalSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.verify|verify} messages. + * Encodes the specified ModifyEntryOverviewRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static - * @param {google.cloud.datacatalog.v1.IPhysicalSchema} message PhysicalSchema message or plain object to encode + * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest} message ModifyEntryOverviewRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PhysicalSchema.encode = function encode(message, writer) { + ModifyEntryOverviewRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.avro != null && Object.hasOwnProperty.call(message, "avro")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.encode(message.avro, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.thrift != null && Object.hasOwnProperty.call(message, "thrift")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.encode(message.thrift, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.protobuf != null && Object.hasOwnProperty.call(message, "protobuf")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.encode(message.protobuf, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.parquet != null && Object.hasOwnProperty.call(message, "parquet")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.encode(message.parquet, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.orc != null && Object.hasOwnProperty.call(message, "orc")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.encode(message.orc, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.csv != null && Object.hasOwnProperty.call(message, "csv")) - $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.encode(message.csv, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.entryOverview != null && Object.hasOwnProperty.call(message, "entryOverview")) + $root.google.cloud.datacatalog.v1.EntryOverview.encode(message.entryOverview, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified PhysicalSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.verify|verify} messages. + * Encodes the specified ModifyEntryOverviewRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static - * @param {google.cloud.datacatalog.v1.IPhysicalSchema} message PhysicalSchema message or plain object to encode + * @param {google.cloud.datacatalog.v1.IModifyEntryOverviewRequest} message ModifyEntryOverviewRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PhysicalSchema.encodeDelimited = function encodeDelimited(message, writer) { + ModifyEntryOverviewRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a PhysicalSchema message from the specified reader or buffer. + * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema + * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PhysicalSchema.decode = function decode(reader, length) { + ModifyEntryOverviewRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.decode(reader, reader.uint32()); + message.name = reader.string(); break; } case 2: { - message.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.decode(reader, reader.uint32()); - break; - } - case 3: { - message.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.decode(reader, reader.uint32()); - break; - } - case 4: { - message.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.decode(reader, reader.uint32()); - break; - } - case 5: { - message.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.decode(reader, reader.uint32()); - break; - } - case 6: { - message.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.decode(reader, reader.uint32()); + message.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.decode(reader, reader.uint32()); break; } default: @@ -16310,1369 +17503,899 @@ }; /** - * Decodes a PhysicalSchema message from the specified reader or buffer, length delimited. + * Decodes a ModifyEntryOverviewRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema + * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PhysicalSchema.decodeDelimited = function decodeDelimited(reader) { + ModifyEntryOverviewRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a PhysicalSchema message. + * Verifies a ModifyEntryOverviewRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - PhysicalSchema.verify = function verify(message) { + ModifyEntryOverviewRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.avro != null && message.hasOwnProperty("avro")) { - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify(message.avro); - if (error) - return "avro." + error; - } - } - if (message.thrift != null && message.hasOwnProperty("thrift")) { - if (properties.schema === 1) - return "schema: multiple values"; - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify(message.thrift); - if (error) - return "thrift." + error; - } - } - if (message.protobuf != null && message.hasOwnProperty("protobuf")) { - if (properties.schema === 1) - return "schema: multiple values"; - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify(message.protobuf); - if (error) - return "protobuf." + error; - } - } - if (message.parquet != null && message.hasOwnProperty("parquet")) { - if (properties.schema === 1) - return "schema: multiple values"; - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify(message.parquet); - if (error) - return "parquet." + error; - } - } - if (message.orc != null && message.hasOwnProperty("orc")) { - if (properties.schema === 1) - return "schema: multiple values"; - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify(message.orc); - if (error) - return "orc." + error; - } - } - if (message.csv != null && message.hasOwnProperty("csv")) { - if (properties.schema === 1) - return "schema: multiple values"; - properties.schema = 1; - { - var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify(message.csv); - if (error) - return "csv." + error; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.entryOverview != null && message.hasOwnProperty("entryOverview")) { + var error = $root.google.cloud.datacatalog.v1.EntryOverview.verify(message.entryOverview); + if (error) + return "entryOverview." + error; } return null; }; /** - * Creates a PhysicalSchema message from a plain object. Also converts values to their respective internal types. + * Creates a ModifyEntryOverviewRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema + * @returns {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} ModifyEntryOverviewRequest */ - PhysicalSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema) + ModifyEntryOverviewRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema(); - if (object.avro != null) { - if (typeof object.avro !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.avro: object expected"); - message.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.fromObject(object.avro); - } - if (object.thrift != null) { - if (typeof object.thrift !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.thrift: object expected"); - message.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.fromObject(object.thrift); - } - if (object.protobuf != null) { - if (typeof object.protobuf !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.protobuf: object expected"); - message.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.fromObject(object.protobuf); - } - if (object.parquet != null) { - if (typeof object.parquet !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.parquet: object expected"); - message.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.fromObject(object.parquet); - } - if (object.orc != null) { - if (typeof object.orc !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.orc: object expected"); - message.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.fromObject(object.orc); - } - if (object.csv != null) { - if (typeof object.csv !== "object") - throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.csv: object expected"); - message.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.fromObject(object.csv); + var message = new $root.google.cloud.datacatalog.v1.ModifyEntryOverviewRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.entryOverview != null) { + if (typeof object.entryOverview !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ModifyEntryOverviewRequest.entryOverview: object expected"); + message.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.fromObject(object.entryOverview); } return message; }; /** - * Creates a plain object from a PhysicalSchema message. Also converts values to other types if specified. + * Creates a plain object from a ModifyEntryOverviewRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema} message PhysicalSchema + * @param {google.cloud.datacatalog.v1.ModifyEntryOverviewRequest} message ModifyEntryOverviewRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - PhysicalSchema.toObject = function toObject(message, options) { + ModifyEntryOverviewRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (message.avro != null && message.hasOwnProperty("avro")) { - object.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.toObject(message.avro, options); - if (options.oneofs) - object.schema = "avro"; - } - if (message.thrift != null && message.hasOwnProperty("thrift")) { - object.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.toObject(message.thrift, options); - if (options.oneofs) - object.schema = "thrift"; - } - if (message.protobuf != null && message.hasOwnProperty("protobuf")) { - object.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.toObject(message.protobuf, options); - if (options.oneofs) - object.schema = "protobuf"; - } - if (message.parquet != null && message.hasOwnProperty("parquet")) { - object.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.toObject(message.parquet, options); - if (options.oneofs) - object.schema = "parquet"; - } - if (message.orc != null && message.hasOwnProperty("orc")) { - object.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.toObject(message.orc, options); - if (options.oneofs) - object.schema = "orc"; - } - if (message.csv != null && message.hasOwnProperty("csv")) { - object.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.toObject(message.csv, options); - if (options.oneofs) - object.schema = "csv"; + if (options.defaults) { + object.name = ""; + object.entryOverview = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.entryOverview != null && message.hasOwnProperty("entryOverview")) + object.entryOverview = $root.google.cloud.datacatalog.v1.EntryOverview.toObject(message.entryOverview, options); return object; }; /** - * Converts this PhysicalSchema to JSON. + * Converts this ModifyEntryOverviewRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @instance * @returns {Object.} JSON object */ - PhysicalSchema.prototype.toJSON = function toJSON() { + ModifyEntryOverviewRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for PhysicalSchema + * Gets the default type url for ModifyEntryOverviewRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @memberof google.cloud.datacatalog.v1.ModifyEntryOverviewRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - PhysicalSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ModifyEntryOverviewRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ModifyEntryOverviewRequest"; }; - PhysicalSchema.AvroSchema = (function() { + return ModifyEntryOverviewRequest; + })(); - /** - * Properties of an AvroSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface IAvroSchema - * @property {string|null} [text] AvroSchema text - */ + v1.ModifyEntryContactsRequest = (function() { - /** - * Constructs a new AvroSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents an AvroSchema. - * @implements IAvroSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema=} [properties] Properties to set - */ - function AvroSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Properties of a ModifyEntryContactsRequest. + * @memberof google.cloud.datacatalog.v1 + * @interface IModifyEntryContactsRequest + * @property {string|null} [name] ModifyEntryContactsRequest name + * @property {google.cloud.datacatalog.v1.IContacts|null} [contacts] ModifyEntryContactsRequest contacts + */ - /** - * AvroSchema text. - * @member {string} text - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @instance - */ - AvroSchema.prototype.text = ""; + /** + * Constructs a new ModifyEntryContactsRequest. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a ModifyEntryContactsRequest. + * @implements IModifyEntryContactsRequest + * @constructor + * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest=} [properties] Properties to set + */ + function ModifyEntryContactsRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new AvroSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema instance - */ - AvroSchema.create = function create(properties) { - return new AvroSchema(properties); - }; + /** + * ModifyEntryContactsRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @instance + */ + ModifyEntryContactsRequest.prototype.name = ""; - /** - * Encodes the specified AvroSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema} message AvroSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AvroSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.text != null && Object.hasOwnProperty.call(message, "text")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); - return writer; - }; + /** + * ModifyEntryContactsRequest contacts. + * @member {google.cloud.datacatalog.v1.IContacts|null|undefined} contacts + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @instance + */ + ModifyEntryContactsRequest.prototype.contacts = null; - /** - * Encodes the specified AvroSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema} message AvroSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AvroSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Creates a new ModifyEntryContactsRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest instance + */ + ModifyEntryContactsRequest.create = function create(properties) { + return new ModifyEntryContactsRequest(properties); + }; - /** - * Decodes an AvroSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AvroSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.text = reader.string(); - break; - } - default: - reader.skipType(tag & 7); + /** + * Encodes the specified ModifyEntryContactsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryContactsRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest} message ModifyEntryContactsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ModifyEntryContactsRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.contacts != null && Object.hasOwnProperty.call(message, "contacts")) + $root.google.cloud.datacatalog.v1.Contacts.encode(message.contacts, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ModifyEntryContactsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ModifyEntryContactsRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {google.cloud.datacatalog.v1.IModifyEntryContactsRequest} message ModifyEntryContactsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ModifyEntryContactsRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ModifyEntryContactsRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ModifyEntryContactsRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + case 2: { + message.contacts = $root.google.cloud.datacatalog.v1.Contacts.decode(reader, reader.uint32()); break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes an AvroSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AvroSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + } + return message; + }; - /** - * Verifies an AvroSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - AvroSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.text != null && message.hasOwnProperty("text")) - if (!$util.isString(message.text)) - return "text: string expected"; - return null; - }; + /** + * Decodes a ModifyEntryContactsRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ModifyEntryContactsRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates an AvroSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema - */ - AvroSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema) - return object; - var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema(); - if (object.text != null) - message.text = String(object.text); - return message; - }; + /** + * Verifies a ModifyEntryContactsRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ModifyEntryContactsRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.contacts != null && message.hasOwnProperty("contacts")) { + var error = $root.google.cloud.datacatalog.v1.Contacts.verify(message.contacts); + if (error) + return "contacts." + error; + } + return null; + }; - /** - * Creates a plain object from an AvroSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} message AvroSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - AvroSchema.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.text = ""; - if (message.text != null && message.hasOwnProperty("text")) - object.text = message.text; + /** + * Creates a ModifyEntryContactsRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} ModifyEntryContactsRequest + */ + ModifyEntryContactsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest) return object; - }; + var message = new $root.google.cloud.datacatalog.v1.ModifyEntryContactsRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.contacts != null) { + if (typeof object.contacts !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ModifyEntryContactsRequest.contacts: object expected"); + message.contacts = $root.google.cloud.datacatalog.v1.Contacts.fromObject(object.contacts); + } + return message; + }; - /** - * Converts this AvroSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @instance - * @returns {Object.} JSON object - */ - AvroSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for AvroSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - AvroSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema"; - }; - - return AvroSchema; - })(); - - PhysicalSchema.ThriftSchema = (function() { - - /** - * Properties of a ThriftSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface IThriftSchema - * @property {string|null} [text] ThriftSchema text - */ - - /** - * Constructs a new ThriftSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents a ThriftSchema. - * @implements IThriftSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema=} [properties] Properties to set - */ - function ThriftSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Creates a plain object from a ModifyEntryContactsRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {google.cloud.datacatalog.v1.ModifyEntryContactsRequest} message ModifyEntryContactsRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ModifyEntryContactsRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.name = ""; + object.contacts = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.contacts != null && message.hasOwnProperty("contacts")) + object.contacts = $root.google.cloud.datacatalog.v1.Contacts.toObject(message.contacts, options); + return object; + }; - /** - * ThriftSchema text. - * @member {string} text - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @instance - */ - ThriftSchema.prototype.text = ""; + /** + * Converts this ModifyEntryContactsRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @instance + * @returns {Object.} JSON object + */ + ModifyEntryContactsRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Creates a new ThriftSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema instance - */ - ThriftSchema.create = function create(properties) { - return new ThriftSchema(properties); - }; + /** + * Gets the default type url for ModifyEntryContactsRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.ModifyEntryContactsRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ModifyEntryContactsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ModifyEntryContactsRequest"; + }; - /** - * Encodes the specified ThriftSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema} message ThriftSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ThriftSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.text != null && Object.hasOwnProperty.call(message, "text")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); - return writer; - }; + return ModifyEntryContactsRequest; + })(); - /** - * Encodes the specified ThriftSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema} message ThriftSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ThriftSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * EntryType enum. + * @name google.cloud.datacatalog.v1.EntryType + * @enum {number} + * @property {number} ENTRY_TYPE_UNSPECIFIED=0 ENTRY_TYPE_UNSPECIFIED value + * @property {number} TABLE=2 TABLE value + * @property {number} MODEL=5 MODEL value + * @property {number} DATA_STREAM=3 DATA_STREAM value + * @property {number} FILESET=4 FILESET value + * @property {number} CLUSTER=6 CLUSTER value + * @property {number} DATABASE=7 DATABASE value + * @property {number} DATA_SOURCE_CONNECTION=8 DATA_SOURCE_CONNECTION value + * @property {number} ROUTINE=9 ROUTINE value + * @property {number} LAKE=10 LAKE value + * @property {number} ZONE=11 ZONE value + * @property {number} SERVICE=14 SERVICE value + * @property {number} DATABASE_SCHEMA=15 DATABASE_SCHEMA value + * @property {number} DASHBOARD=16 DASHBOARD value + * @property {number} EXPLORE=17 EXPLORE value + * @property {number} LOOK=18 LOOK value + */ + v1.EntryType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "ENTRY_TYPE_UNSPECIFIED"] = 0; + values[valuesById[2] = "TABLE"] = 2; + values[valuesById[5] = "MODEL"] = 5; + values[valuesById[3] = "DATA_STREAM"] = 3; + values[valuesById[4] = "FILESET"] = 4; + values[valuesById[6] = "CLUSTER"] = 6; + values[valuesById[7] = "DATABASE"] = 7; + values[valuesById[8] = "DATA_SOURCE_CONNECTION"] = 8; + values[valuesById[9] = "ROUTINE"] = 9; + values[valuesById[10] = "LAKE"] = 10; + values[valuesById[11] = "ZONE"] = 11; + values[valuesById[14] = "SERVICE"] = 14; + values[valuesById[15] = "DATABASE_SCHEMA"] = 15; + values[valuesById[16] = "DASHBOARD"] = 16; + values[valuesById[17] = "EXPLORE"] = 17; + values[valuesById[18] = "LOOK"] = 18; + return values; + })(); - /** - * Decodes a ThriftSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ThriftSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.text = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + v1.DataplexSpec = (function() { - /** - * Decodes a ThriftSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ThriftSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Properties of a DataplexSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface IDataplexSpec + * @property {string|null} [asset] DataplexSpec asset + * @property {google.cloud.datacatalog.v1.IPhysicalSchema|null} [dataFormat] DataplexSpec dataFormat + * @property {string|null} [compressionFormat] DataplexSpec compressionFormat + * @property {string|null} [projectId] DataplexSpec projectId + */ - /** - * Verifies a ThriftSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ThriftSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.text != null && message.hasOwnProperty("text")) - if (!$util.isString(message.text)) - return "text: string expected"; - return null; - }; + /** + * Constructs a new DataplexSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a DataplexSpec. + * @implements IDataplexSpec + * @constructor + * @param {google.cloud.datacatalog.v1.IDataplexSpec=} [properties] Properties to set + */ + function DataplexSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a ThriftSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema - */ - ThriftSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema) - return object; - var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema(); - if (object.text != null) - message.text = String(object.text); - return message; - }; + /** + * DataplexSpec asset. + * @member {string} asset + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @instance + */ + DataplexSpec.prototype.asset = ""; - /** - * Creates a plain object from a ThriftSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} message ThriftSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ThriftSchema.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.text = ""; - if (message.text != null && message.hasOwnProperty("text")) - object.text = message.text; - return object; - }; + /** + * DataplexSpec dataFormat. + * @member {google.cloud.datacatalog.v1.IPhysicalSchema|null|undefined} dataFormat + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @instance + */ + DataplexSpec.prototype.dataFormat = null; - /** - * Converts this ThriftSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @instance - * @returns {Object.} JSON object - */ - ThriftSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * DataplexSpec compressionFormat. + * @member {string} compressionFormat + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @instance + */ + DataplexSpec.prototype.compressionFormat = ""; - /** - * Gets the default type url for ThriftSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ThriftSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema"; - }; + /** + * DataplexSpec projectId. + * @member {string} projectId + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @instance + */ + DataplexSpec.prototype.projectId = ""; - return ThriftSchema; - })(); + /** + * Creates a new DataplexSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec instance + */ + DataplexSpec.create = function create(properties) { + return new DataplexSpec(properties); + }; - PhysicalSchema.ProtobufSchema = (function() { + /** + * Encodes the specified DataplexSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexSpec} message DataplexSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DataplexSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.asset != null && Object.hasOwnProperty.call(message, "asset")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.asset); + if (message.dataFormat != null && Object.hasOwnProperty.call(message, "dataFormat")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.encode(message.dataFormat, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.compressionFormat != null && Object.hasOwnProperty.call(message, "compressionFormat")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.compressionFormat); + if (message.projectId != null && Object.hasOwnProperty.call(message, "projectId")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.projectId); + return writer; + }; - /** - * Properties of a ProtobufSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface IProtobufSchema - * @property {string|null} [text] ProtobufSchema text - */ + /** + * Encodes the specified DataplexSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexSpec} message DataplexSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DataplexSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Constructs a new ProtobufSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents a ProtobufSchema. - * @implements IProtobufSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema=} [properties] Properties to set - */ - function ProtobufSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Decodes a DataplexSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DataplexSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.asset = reader.string(); + break; + } + case 2: { + message.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.decode(reader, reader.uint32()); + break; + } + case 3: { + message.compressionFormat = reader.string(); + break; + } + case 4: { + message.projectId = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } } + return message; + }; - /** - * ProtobufSchema text. - * @member {string} text - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @instance - */ - ProtobufSchema.prototype.text = ""; + /** + * Decodes a DataplexSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DataplexSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates a new ProtobufSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema instance - */ - ProtobufSchema.create = function create(properties) { - return new ProtobufSchema(properties); - }; + /** + * Verifies a DataplexSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DataplexSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.asset != null && message.hasOwnProperty("asset")) + if (!$util.isString(message.asset)) + return "asset: string expected"; + if (message.dataFormat != null && message.hasOwnProperty("dataFormat")) { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.verify(message.dataFormat); + if (error) + return "dataFormat." + error; + } + if (message.compressionFormat != null && message.hasOwnProperty("compressionFormat")) + if (!$util.isString(message.compressionFormat)) + return "compressionFormat: string expected"; + if (message.projectId != null && message.hasOwnProperty("projectId")) + if (!$util.isString(message.projectId)) + return "projectId: string expected"; + return null; + }; - /** - * Encodes the specified ProtobufSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema} message ProtobufSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ProtobufSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.text != null && Object.hasOwnProperty.call(message, "text")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); - return writer; - }; - - /** - * Encodes the specified ProtobufSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema} message ProtobufSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ProtobufSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a ProtobufSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ProtobufSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.text = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ProtobufSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ProtobufSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ProtobufSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ProtobufSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.text != null && message.hasOwnProperty("text")) - if (!$util.isString(message.text)) - return "text: string expected"; - return null; - }; + /** + * Creates a DataplexSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.DataplexSpec} DataplexSpec + */ + DataplexSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DataplexSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.DataplexSpec(); + if (object.asset != null) + message.asset = String(object.asset); + if (object.dataFormat != null) { + if (typeof object.dataFormat !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DataplexSpec.dataFormat: object expected"); + message.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.fromObject(object.dataFormat); + } + if (object.compressionFormat != null) + message.compressionFormat = String(object.compressionFormat); + if (object.projectId != null) + message.projectId = String(object.projectId); + return message; + }; - /** - * Creates a ProtobufSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema - */ - ProtobufSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema) - return object; - var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema(); - if (object.text != null) - message.text = String(object.text); - return message; - }; + /** + * Creates a plain object from a DataplexSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {google.cloud.datacatalog.v1.DataplexSpec} message DataplexSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DataplexSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.asset = ""; + object.dataFormat = null; + object.compressionFormat = ""; + object.projectId = ""; + } + if (message.asset != null && message.hasOwnProperty("asset")) + object.asset = message.asset; + if (message.dataFormat != null && message.hasOwnProperty("dataFormat")) + object.dataFormat = $root.google.cloud.datacatalog.v1.PhysicalSchema.toObject(message.dataFormat, options); + if (message.compressionFormat != null && message.hasOwnProperty("compressionFormat")) + object.compressionFormat = message.compressionFormat; + if (message.projectId != null && message.hasOwnProperty("projectId")) + object.projectId = message.projectId; + return object; + }; - /** - * Creates a plain object from a ProtobufSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} message ProtobufSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ProtobufSchema.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.text = ""; - if (message.text != null && message.hasOwnProperty("text")) - object.text = message.text; - return object; - }; + /** + * Converts this DataplexSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @instance + * @returns {Object.} JSON object + */ + DataplexSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Converts this ProtobufSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @instance - * @returns {Object.} JSON object - */ - ProtobufSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Gets the default type url for DataplexSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.DataplexSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DataplexSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexSpec"; + }; - /** - * Gets the default type url for ProtobufSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ProtobufSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema"; - }; + return DataplexSpec; + })(); - return ProtobufSchema; - })(); + v1.DataplexFilesetSpec = (function() { - PhysicalSchema.ParquetSchema = (function() { + /** + * Properties of a DataplexFilesetSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface IDataplexFilesetSpec + * @property {google.cloud.datacatalog.v1.IDataplexSpec|null} [dataplexSpec] DataplexFilesetSpec dataplexSpec + */ - /** - * Properties of a ParquetSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface IParquetSchema - */ + /** + * Constructs a new DataplexFilesetSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a DataplexFilesetSpec. + * @implements IDataplexFilesetSpec + * @constructor + * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec=} [properties] Properties to set + */ + function DataplexFilesetSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Constructs a new ParquetSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents a ParquetSchema. - * @implements IParquetSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema=} [properties] Properties to set - */ - function ParquetSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * DataplexFilesetSpec dataplexSpec. + * @member {google.cloud.datacatalog.v1.IDataplexSpec|null|undefined} dataplexSpec + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @instance + */ + DataplexFilesetSpec.prototype.dataplexSpec = null; - /** - * Creates a new ParquetSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema instance - */ - ParquetSchema.create = function create(properties) { - return new ParquetSchema(properties); - }; + /** + * Creates a new DataplexFilesetSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec instance + */ + DataplexFilesetSpec.create = function create(properties) { + return new DataplexFilesetSpec(properties); + }; - /** - * Encodes the specified ParquetSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema} message ParquetSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ParquetSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - return writer; - }; + /** + * Encodes the specified DataplexFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexFilesetSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec} message DataplexFilesetSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DataplexFilesetSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.dataplexSpec != null && Object.hasOwnProperty.call(message, "dataplexSpec")) + $root.google.cloud.datacatalog.v1.DataplexSpec.encode(message.dataplexSpec, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; - /** - * Encodes the specified ParquetSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema} message ParquetSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ParquetSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified DataplexFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexFilesetSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {google.cloud.datacatalog.v1.IDataplexFilesetSpec} message DataplexFilesetSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DataplexFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a ParquetSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ParquetSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - default: - reader.skipType(tag & 7); + /** + * Decodes a DataplexFilesetSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DataplexFilesetSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexFilesetSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.decode(reader, reader.uint32()); break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes a ParquetSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ParquetSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + } + return message; + }; - /** - * Verifies a ParquetSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ParquetSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - return null; - }; + /** + * Decodes a DataplexFilesetSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DataplexFilesetSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates a ParquetSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema - */ - ParquetSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema) - return object; - return new $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema(); - }; + /** + * Verifies a DataplexFilesetSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DataplexFilesetSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) { + var error = $root.google.cloud.datacatalog.v1.DataplexSpec.verify(message.dataplexSpec); + if (error) + return "dataplexSpec." + error; + } + return null; + }; - /** - * Creates a plain object from a ParquetSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} message ParquetSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ParquetSchema.toObject = function toObject() { - return {}; - }; + /** + * Creates a DataplexFilesetSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.DataplexFilesetSpec} DataplexFilesetSpec + */ + DataplexFilesetSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DataplexFilesetSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.DataplexFilesetSpec(); + if (object.dataplexSpec != null) { + if (typeof object.dataplexSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DataplexFilesetSpec.dataplexSpec: object expected"); + message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.fromObject(object.dataplexSpec); + } + return message; + }; - /** - * Converts this ParquetSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @instance - * @returns {Object.} JSON object - */ - ParquetSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for ParquetSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ParquetSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema"; - }; - - return ParquetSchema; - })(); - - PhysicalSchema.OrcSchema = (function() { - - /** - * Properties of an OrcSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface IOrcSchema - */ - - /** - * Constructs a new OrcSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents an OrcSchema. - * @implements IOrcSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema=} [properties] Properties to set - */ - function OrcSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * Creates a new OrcSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema instance - */ - OrcSchema.create = function create(properties) { - return new OrcSchema(properties); - }; - - /** - * Encodes the specified OrcSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema} message OrcSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OrcSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - return writer; - }; - - /** - * Encodes the specified OrcSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema} message OrcSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - OrcSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an OrcSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OrcSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an OrcSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - OrcSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an OrcSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - OrcSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - return null; - }; - - /** - * Creates an OrcSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema - */ - OrcSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema) - return object; - return new $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema(); - }; - - /** - * Creates a plain object from an OrcSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} message OrcSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - OrcSchema.toObject = function toObject() { - return {}; - }; - - /** - * Converts this OrcSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @instance - * @returns {Object.} JSON object - */ - OrcSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for OrcSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - OrcSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema"; - }; - - return OrcSchema; - })(); - - PhysicalSchema.CsvSchema = (function() { + /** + * Creates a plain object from a DataplexFilesetSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {google.cloud.datacatalog.v1.DataplexFilesetSpec} message DataplexFilesetSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DataplexFilesetSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.dataplexSpec = null; + if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) + object.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.toObject(message.dataplexSpec, options); + return object; + }; - /** - * Properties of a CsvSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @interface ICsvSchema - */ + /** + * Converts this DataplexFilesetSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @instance + * @returns {Object.} JSON object + */ + DataplexFilesetSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new CsvSchema. - * @memberof google.cloud.datacatalog.v1.PhysicalSchema - * @classdesc Represents a CsvSchema. - * @implements ICsvSchema - * @constructor - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema=} [properties] Properties to set - */ - function CsvSchema(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Gets the default type url for DataplexFilesetSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.DataplexFilesetSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DataplexFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexFilesetSpec"; + }; - /** - * Creates a new CsvSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema instance - */ - CsvSchema.create = function create(properties) { - return new CsvSchema(properties); - }; - - /** - * Encodes the specified CsvSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema} message CsvSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CsvSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - return writer; - }; - - /** - * Encodes the specified CsvSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema} message CsvSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - CsvSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a CsvSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CsvSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a CsvSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - CsvSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a CsvSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - CsvSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - return null; - }; - - /** - * Creates a CsvSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema - */ - CsvSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema) - return object; - return new $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema(); - }; - - /** - * Creates a plain object from a CsvSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} message CsvSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - CsvSchema.toObject = function toObject() { - return {}; - }; - - /** - * Converts this CsvSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @instance - * @returns {Object.} JSON object - */ - CsvSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for CsvSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - CsvSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema"; - }; - - return CsvSchema; - })(); - - return PhysicalSchema; + return DataplexFilesetSpec; })(); - v1.GcsFilesetSpec = (function() { + v1.DataplexTableSpec = (function() { /** - * Properties of a GcsFilesetSpec. + * Properties of a DataplexTableSpec. * @memberof google.cloud.datacatalog.v1 - * @interface IGcsFilesetSpec - * @property {Array.|null} [filePatterns] GcsFilesetSpec filePatterns - * @property {Array.|null} [sampleGcsFileSpecs] GcsFilesetSpec sampleGcsFileSpecs + * @interface IDataplexTableSpec + * @property {Array.|null} [externalTables] DataplexTableSpec externalTables + * @property {google.cloud.datacatalog.v1.IDataplexSpec|null} [dataplexSpec] DataplexTableSpec dataplexSpec + * @property {boolean|null} [userManaged] DataplexTableSpec userManaged */ /** - * Constructs a new GcsFilesetSpec. + * Constructs a new DataplexTableSpec. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a GcsFilesetSpec. - * @implements IGcsFilesetSpec + * @classdesc Represents a DataplexTableSpec. + * @implements IDataplexTableSpec * @constructor - * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IDataplexTableSpec=} [properties] Properties to set */ - function GcsFilesetSpec(properties) { - this.filePatterns = []; - this.sampleGcsFileSpecs = []; + function DataplexTableSpec(properties) { + this.externalTables = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -17680,95 +18403,106 @@ } /** - * GcsFilesetSpec filePatterns. - * @member {Array.} filePatterns - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * DataplexTableSpec externalTables. + * @member {Array.} externalTables + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @instance */ - GcsFilesetSpec.prototype.filePatterns = $util.emptyArray; + DataplexTableSpec.prototype.externalTables = $util.emptyArray; /** - * GcsFilesetSpec sampleGcsFileSpecs. - * @member {Array.} sampleGcsFileSpecs - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * DataplexTableSpec dataplexSpec. + * @member {google.cloud.datacatalog.v1.IDataplexSpec|null|undefined} dataplexSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @instance */ - GcsFilesetSpec.prototype.sampleGcsFileSpecs = $util.emptyArray; + DataplexTableSpec.prototype.dataplexSpec = null; /** - * Creates a new GcsFilesetSpec instance using the specified properties. + * DataplexTableSpec userManaged. + * @member {boolean} userManaged + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec + * @instance + */ + DataplexTableSpec.prototype.userManaged = false; + + /** + * Creates a new DataplexTableSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static - * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec instance + * @param {google.cloud.datacatalog.v1.IDataplexTableSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec instance */ - GcsFilesetSpec.create = function create(properties) { - return new GcsFilesetSpec(properties); + DataplexTableSpec.create = function create(properties) { + return new DataplexTableSpec(properties); }; /** - * Encodes the specified GcsFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFilesetSpec.verify|verify} messages. + * Encodes the specified DataplexTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexTableSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static - * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDataplexTableSpec} message DataplexTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFilesetSpec.encode = function encode(message, writer) { + DataplexTableSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.filePatterns != null && message.filePatterns.length) - for (var i = 0; i < message.filePatterns.length; ++i) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePatterns[i]); - if (message.sampleGcsFileSpecs != null && message.sampleGcsFileSpecs.length) - for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) - $root.google.cloud.datacatalog.v1.GcsFileSpec.encode(message.sampleGcsFileSpecs[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.externalTables != null && message.externalTables.length) + for (var i = 0; i < message.externalTables.length; ++i) + $root.google.cloud.datacatalog.v1.DataplexExternalTable.encode(message.externalTables[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.dataplexSpec != null && Object.hasOwnProperty.call(message, "dataplexSpec")) + $root.google.cloud.datacatalog.v1.DataplexSpec.encode(message.dataplexSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.userManaged != null && Object.hasOwnProperty.call(message, "userManaged")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.userManaged); return writer; }; /** - * Encodes the specified GcsFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFilesetSpec.verify|verify} messages. + * Encodes the specified DataplexTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexTableSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static - * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDataplexTableSpec} message DataplexTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { + DataplexTableSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GcsFilesetSpec message from the specified reader or buffer. + * Decodes a DataplexTableSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFilesetSpec.decode = function decode(reader, length) { + DataplexTableSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GcsFilesetSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexTableSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.filePatterns && message.filePatterns.length)) - message.filePatterns = []; - message.filePatterns.push(reader.string()); + if (!(message.externalTables && message.externalTables.length)) + message.externalTables = []; + message.externalTables.push($root.google.cloud.datacatalog.v1.DataplexExternalTable.decode(reader, reader.uint32())); break; } case 2: { - if (!(message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length)) - message.sampleGcsFileSpecs = []; - message.sampleGcsFileSpecs.push($root.google.cloud.datacatalog.v1.GcsFileSpec.decode(reader, reader.uint32())); + message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.decode(reader, reader.uint32()); + break; + } + case 3: { + message.userManaged = reader.bool(); break; } default: @@ -17780,162 +18514,165 @@ }; /** - * Decodes a GcsFilesetSpec message from the specified reader or buffer, length delimited. + * Decodes a DataplexTableSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFilesetSpec.decodeDelimited = function decodeDelimited(reader) { + DataplexTableSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GcsFilesetSpec message. + * Verifies a DataplexTableSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GcsFilesetSpec.verify = function verify(message) { + DataplexTableSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.filePatterns != null && message.hasOwnProperty("filePatterns")) { - if (!Array.isArray(message.filePatterns)) - return "filePatterns: array expected"; - for (var i = 0; i < message.filePatterns.length; ++i) - if (!$util.isString(message.filePatterns[i])) - return "filePatterns: string[] expected"; - } - if (message.sampleGcsFileSpecs != null && message.hasOwnProperty("sampleGcsFileSpecs")) { - if (!Array.isArray(message.sampleGcsFileSpecs)) - return "sampleGcsFileSpecs: array expected"; - for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.GcsFileSpec.verify(message.sampleGcsFileSpecs[i]); + if (message.externalTables != null && message.hasOwnProperty("externalTables")) { + if (!Array.isArray(message.externalTables)) + return "externalTables: array expected"; + for (var i = 0; i < message.externalTables.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.DataplexExternalTable.verify(message.externalTables[i]); if (error) - return "sampleGcsFileSpecs." + error; + return "externalTables." + error; } } + if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) { + var error = $root.google.cloud.datacatalog.v1.DataplexSpec.verify(message.dataplexSpec); + if (error) + return "dataplexSpec." + error; + } + if (message.userManaged != null && message.hasOwnProperty("userManaged")) + if (typeof message.userManaged !== "boolean") + return "userManaged: boolean expected"; return null; }; /** - * Creates a GcsFilesetSpec message from a plain object. Also converts values to their respective internal types. + * Creates a DataplexTableSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1.DataplexTableSpec} DataplexTableSpec */ - GcsFilesetSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.GcsFilesetSpec) + DataplexTableSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DataplexTableSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.GcsFilesetSpec(); - if (object.filePatterns) { - if (!Array.isArray(object.filePatterns)) - throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.filePatterns: array expected"); - message.filePatterns = []; - for (var i = 0; i < object.filePatterns.length; ++i) - message.filePatterns[i] = String(object.filePatterns[i]); - } - if (object.sampleGcsFileSpecs) { - if (!Array.isArray(object.sampleGcsFileSpecs)) - throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.sampleGcsFileSpecs: array expected"); - message.sampleGcsFileSpecs = []; - for (var i = 0; i < object.sampleGcsFileSpecs.length; ++i) { - if (typeof object.sampleGcsFileSpecs[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.sampleGcsFileSpecs: object expected"); - message.sampleGcsFileSpecs[i] = $root.google.cloud.datacatalog.v1.GcsFileSpec.fromObject(object.sampleGcsFileSpecs[i]); + var message = new $root.google.cloud.datacatalog.v1.DataplexTableSpec(); + if (object.externalTables) { + if (!Array.isArray(object.externalTables)) + throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.externalTables: array expected"); + message.externalTables = []; + for (var i = 0; i < object.externalTables.length; ++i) { + if (typeof object.externalTables[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.externalTables: object expected"); + message.externalTables[i] = $root.google.cloud.datacatalog.v1.DataplexExternalTable.fromObject(object.externalTables[i]); } } + if (object.dataplexSpec != null) { + if (typeof object.dataplexSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DataplexTableSpec.dataplexSpec: object expected"); + message.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.fromObject(object.dataplexSpec); + } + if (object.userManaged != null) + message.userManaged = Boolean(object.userManaged); return message; }; /** - * Creates a plain object from a GcsFilesetSpec message. Also converts values to other types if specified. + * Creates a plain object from a DataplexTableSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static - * @param {google.cloud.datacatalog.v1.GcsFilesetSpec} message GcsFilesetSpec + * @param {google.cloud.datacatalog.v1.DataplexTableSpec} message DataplexTableSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GcsFilesetSpec.toObject = function toObject(message, options) { + DataplexTableSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.filePatterns = []; - object.sampleGcsFileSpecs = []; - } - if (message.filePatterns && message.filePatterns.length) { - object.filePatterns = []; - for (var j = 0; j < message.filePatterns.length; ++j) - object.filePatterns[j] = message.filePatterns[j]; + if (options.arrays || options.defaults) + object.externalTables = []; + if (options.defaults) { + object.dataplexSpec = null; + object.userManaged = false; } - if (message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length) { - object.sampleGcsFileSpecs = []; - for (var j = 0; j < message.sampleGcsFileSpecs.length; ++j) - object.sampleGcsFileSpecs[j] = $root.google.cloud.datacatalog.v1.GcsFileSpec.toObject(message.sampleGcsFileSpecs[j], options); + if (message.externalTables && message.externalTables.length) { + object.externalTables = []; + for (var j = 0; j < message.externalTables.length; ++j) + object.externalTables[j] = $root.google.cloud.datacatalog.v1.DataplexExternalTable.toObject(message.externalTables[j], options); } + if (message.dataplexSpec != null && message.hasOwnProperty("dataplexSpec")) + object.dataplexSpec = $root.google.cloud.datacatalog.v1.DataplexSpec.toObject(message.dataplexSpec, options); + if (message.userManaged != null && message.hasOwnProperty("userManaged")) + object.userManaged = message.userManaged; return object; }; /** - * Converts this GcsFilesetSpec to JSON. + * Converts this DataplexTableSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @instance * @returns {Object.} JSON object */ - GcsFilesetSpec.prototype.toJSON = function toJSON() { + DataplexTableSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GcsFilesetSpec + * Gets the default type url for DataplexTableSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1.DataplexTableSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GcsFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DataplexTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.GcsFilesetSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexTableSpec"; }; - return GcsFilesetSpec; + return DataplexTableSpec; })(); - v1.GcsFileSpec = (function() { + v1.DataplexExternalTable = (function() { /** - * Properties of a GcsFileSpec. + * Properties of a DataplexExternalTable. * @memberof google.cloud.datacatalog.v1 - * @interface IGcsFileSpec - * @property {string|null} [filePath] GcsFileSpec filePath - * @property {google.cloud.datacatalog.v1.ISystemTimestamps|null} [gcsTimestamps] GcsFileSpec gcsTimestamps - * @property {number|Long|null} [sizeBytes] GcsFileSpec sizeBytes + * @interface IDataplexExternalTable + * @property {google.cloud.datacatalog.v1.IntegratedSystem|null} [system] DataplexExternalTable system + * @property {string|null} [fullyQualifiedName] DataplexExternalTable fullyQualifiedName + * @property {string|null} [googleCloudResource] DataplexExternalTable googleCloudResource + * @property {string|null} [dataCatalogEntry] DataplexExternalTable dataCatalogEntry */ /** - * Constructs a new GcsFileSpec. + * Constructs a new DataplexExternalTable. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a GcsFileSpec. - * @implements IGcsFileSpec + * @classdesc Represents a DataplexExternalTable. + * @implements IDataplexExternalTable * @constructor - * @param {google.cloud.datacatalog.v1.IGcsFileSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IDataplexExternalTable=} [properties] Properties to set */ - function GcsFileSpec(properties) { + function DataplexExternalTable(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -17943,103 +18680,117 @@ } /** - * GcsFileSpec filePath. - * @member {string} filePath - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * DataplexExternalTable system. + * @member {google.cloud.datacatalog.v1.IntegratedSystem} system + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @instance */ - GcsFileSpec.prototype.filePath = ""; + DataplexExternalTable.prototype.system = 0; /** - * GcsFileSpec gcsTimestamps. - * @member {google.cloud.datacatalog.v1.ISystemTimestamps|null|undefined} gcsTimestamps - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * DataplexExternalTable fullyQualifiedName. + * @member {string} fullyQualifiedName + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @instance */ - GcsFileSpec.prototype.gcsTimestamps = null; + DataplexExternalTable.prototype.fullyQualifiedName = ""; /** - * GcsFileSpec sizeBytes. - * @member {number|Long} sizeBytes - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * DataplexExternalTable googleCloudResource. + * @member {string} googleCloudResource + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @instance */ - GcsFileSpec.prototype.sizeBytes = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + DataplexExternalTable.prototype.googleCloudResource = ""; /** - * Creates a new GcsFileSpec instance using the specified properties. + * DataplexExternalTable dataCatalogEntry. + * @member {string} dataCatalogEntry + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable + * @instance + */ + DataplexExternalTable.prototype.dataCatalogEntry = ""; + + /** + * Creates a new DataplexExternalTable instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static - * @param {google.cloud.datacatalog.v1.IGcsFileSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec instance + * @param {google.cloud.datacatalog.v1.IDataplexExternalTable=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable instance */ - GcsFileSpec.create = function create(properties) { - return new GcsFileSpec(properties); + DataplexExternalTable.create = function create(properties) { + return new DataplexExternalTable(properties); }; /** - * Encodes the specified GcsFileSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFileSpec.verify|verify} messages. + * Encodes the specified DataplexExternalTable message. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexExternalTable.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static - * @param {google.cloud.datacatalog.v1.IGcsFileSpec} message GcsFileSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDataplexExternalTable} message DataplexExternalTable message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFileSpec.encode = function encode(message, writer) { + DataplexExternalTable.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.filePath != null && Object.hasOwnProperty.call(message, "filePath")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePath); - if (message.gcsTimestamps != null && Object.hasOwnProperty.call(message, "gcsTimestamps")) - $root.google.cloud.datacatalog.v1.SystemTimestamps.encode(message.gcsTimestamps, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.sizeBytes != null && Object.hasOwnProperty.call(message, "sizeBytes")) - writer.uint32(/* id 4, wireType 0 =*/32).int64(message.sizeBytes); + if (message.system != null && Object.hasOwnProperty.call(message, "system")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.system); + if (message.googleCloudResource != null && Object.hasOwnProperty.call(message, "googleCloudResource")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.googleCloudResource); + if (message.dataCatalogEntry != null && Object.hasOwnProperty.call(message, "dataCatalogEntry")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.dataCatalogEntry); + if (message.fullyQualifiedName != null && Object.hasOwnProperty.call(message, "fullyQualifiedName")) + writer.uint32(/* id 28, wireType 2 =*/226).string(message.fullyQualifiedName); return writer; }; /** - * Encodes the specified GcsFileSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFileSpec.verify|verify} messages. + * Encodes the specified DataplexExternalTable message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DataplexExternalTable.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static - * @param {google.cloud.datacatalog.v1.IGcsFileSpec} message GcsFileSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDataplexExternalTable} message DataplexExternalTable message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFileSpec.encodeDelimited = function encodeDelimited(message, writer) { + DataplexExternalTable.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GcsFileSpec message from the specified reader or buffer. + * Decodes a DataplexExternalTable message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFileSpec.decode = function decode(reader, length) { + DataplexExternalTable.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GcsFileSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DataplexExternalTable(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.filePath = reader.string(); + message.system = reader.int32(); break; } - case 2: { - message.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.decode(reader, reader.uint32()); + case 28: { + message.fullyQualifiedName = reader.string(); + break; + } + case 3: { + message.googleCloudResource = reader.string(); break; } case 4: { - message.sizeBytes = reader.int64(); + message.dataCatalogEntry = reader.string(); break; } default: @@ -18051,160 +18802,196 @@ }; /** - * Decodes a GcsFileSpec message from the specified reader or buffer, length delimited. + * Decodes a DataplexExternalTable message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFileSpec.decodeDelimited = function decodeDelimited(reader) { + DataplexExternalTable.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GcsFileSpec message. + * Verifies a DataplexExternalTable message. * @function verify - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GcsFileSpec.verify = function verify(message) { + DataplexExternalTable.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.filePath != null && message.hasOwnProperty("filePath")) - if (!$util.isString(message.filePath)) - return "filePath: string expected"; - if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) { - var error = $root.google.cloud.datacatalog.v1.SystemTimestamps.verify(message.gcsTimestamps); - if (error) - return "gcsTimestamps." + error; - } - if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) - if (!$util.isInteger(message.sizeBytes) && !(message.sizeBytes && $util.isInteger(message.sizeBytes.low) && $util.isInteger(message.sizeBytes.high))) - return "sizeBytes: integer|Long expected"; + if (message.system != null && message.hasOwnProperty("system")) + switch (message.system) { + default: + return "system: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 8: + case 9: + break; + } + if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) + if (!$util.isString(message.fullyQualifiedName)) + return "fullyQualifiedName: string expected"; + if (message.googleCloudResource != null && message.hasOwnProperty("googleCloudResource")) + if (!$util.isString(message.googleCloudResource)) + return "googleCloudResource: string expected"; + if (message.dataCatalogEntry != null && message.hasOwnProperty("dataCatalogEntry")) + if (!$util.isString(message.dataCatalogEntry)) + return "dataCatalogEntry: string expected"; return null; }; /** - * Creates a GcsFileSpec message from a plain object. Also converts values to their respective internal types. + * Creates a DataplexExternalTable message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1.DataplexExternalTable} DataplexExternalTable */ - GcsFileSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.GcsFileSpec) + DataplexExternalTable.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DataplexExternalTable) return object; - var message = new $root.google.cloud.datacatalog.v1.GcsFileSpec(); - if (object.filePath != null) - message.filePath = String(object.filePath); - if (object.gcsTimestamps != null) { - if (typeof object.gcsTimestamps !== "object") - throw TypeError(".google.cloud.datacatalog.v1.GcsFileSpec.gcsTimestamps: object expected"); - message.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.fromObject(object.gcsTimestamps); + var message = new $root.google.cloud.datacatalog.v1.DataplexExternalTable(); + switch (object.system) { + default: + if (typeof object.system === "number") { + message.system = object.system; + break; + } + break; + case "INTEGRATED_SYSTEM_UNSPECIFIED": + case 0: + message.system = 0; + break; + case "BIGQUERY": + case 1: + message.system = 1; + break; + case "CLOUD_PUBSUB": + case 2: + message.system = 2; + break; + case "DATAPROC_METASTORE": + case 3: + message.system = 3; + break; + case "DATAPLEX": + case 4: + message.system = 4; + break; + case "CLOUD_SQL": + case 8: + message.system = 8; + break; + case "LOOKER": + case 9: + message.system = 9; + break; } - if (object.sizeBytes != null) - if ($util.Long) - (message.sizeBytes = $util.Long.fromValue(object.sizeBytes)).unsigned = false; - else if (typeof object.sizeBytes === "string") - message.sizeBytes = parseInt(object.sizeBytes, 10); - else if (typeof object.sizeBytes === "number") - message.sizeBytes = object.sizeBytes; - else if (typeof object.sizeBytes === "object") - message.sizeBytes = new $util.LongBits(object.sizeBytes.low >>> 0, object.sizeBytes.high >>> 0).toNumber(); + if (object.fullyQualifiedName != null) + message.fullyQualifiedName = String(object.fullyQualifiedName); + if (object.googleCloudResource != null) + message.googleCloudResource = String(object.googleCloudResource); + if (object.dataCatalogEntry != null) + message.dataCatalogEntry = String(object.dataCatalogEntry); return message; }; /** - * Creates a plain object from a GcsFileSpec message. Also converts values to other types if specified. + * Creates a plain object from a DataplexExternalTable message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static - * @param {google.cloud.datacatalog.v1.GcsFileSpec} message GcsFileSpec + * @param {google.cloud.datacatalog.v1.DataplexExternalTable} message DataplexExternalTable * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GcsFileSpec.toObject = function toObject(message, options) { + DataplexExternalTable.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.filePath = ""; - object.gcsTimestamps = null; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.sizeBytes = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.sizeBytes = options.longs === String ? "0" : 0; + object.system = options.enums === String ? "INTEGRATED_SYSTEM_UNSPECIFIED" : 0; + object.googleCloudResource = ""; + object.dataCatalogEntry = ""; + object.fullyQualifiedName = ""; } - if (message.filePath != null && message.hasOwnProperty("filePath")) - object.filePath = message.filePath; - if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) - object.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.toObject(message.gcsTimestamps, options); - if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) - if (typeof message.sizeBytes === "number") - object.sizeBytes = options.longs === String ? String(message.sizeBytes) : message.sizeBytes; - else - object.sizeBytes = options.longs === String ? $util.Long.prototype.toString.call(message.sizeBytes) : options.longs === Number ? new $util.LongBits(message.sizeBytes.low >>> 0, message.sizeBytes.high >>> 0).toNumber() : message.sizeBytes; + if (message.system != null && message.hasOwnProperty("system")) + object.system = options.enums === String ? $root.google.cloud.datacatalog.v1.IntegratedSystem[message.system] === undefined ? message.system : $root.google.cloud.datacatalog.v1.IntegratedSystem[message.system] : message.system; + if (message.googleCloudResource != null && message.hasOwnProperty("googleCloudResource")) + object.googleCloudResource = message.googleCloudResource; + if (message.dataCatalogEntry != null && message.hasOwnProperty("dataCatalogEntry")) + object.dataCatalogEntry = message.dataCatalogEntry; + if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) + object.fullyQualifiedName = message.fullyQualifiedName; return object; }; /** - * Converts this GcsFileSpec to JSON. + * Converts this DataplexExternalTable to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @instance * @returns {Object.} JSON object */ - GcsFileSpec.prototype.toJSON = function toJSON() { + DataplexExternalTable.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GcsFileSpec + * Gets the default type url for DataplexExternalTable * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1.DataplexExternalTable * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GcsFileSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DataplexExternalTable.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.GcsFileSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DataplexExternalTable"; }; - return GcsFileSpec; + return DataplexExternalTable; })(); - v1.SystemTimestamps = (function() { + v1.PhysicalSchema = (function() { /** - * Properties of a SystemTimestamps. + * Properties of a PhysicalSchema. * @memberof google.cloud.datacatalog.v1 - * @interface ISystemTimestamps - * @property {google.protobuf.ITimestamp|null} [createTime] SystemTimestamps createTime - * @property {google.protobuf.ITimestamp|null} [updateTime] SystemTimestamps updateTime - * @property {google.protobuf.ITimestamp|null} [expireTime] SystemTimestamps expireTime + * @interface IPhysicalSchema + * @property {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema|null} [avro] PhysicalSchema avro + * @property {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema|null} [thrift] PhysicalSchema thrift + * @property {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema|null} [protobuf] PhysicalSchema protobuf + * @property {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema|null} [parquet] PhysicalSchema parquet + * @property {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema|null} [orc] PhysicalSchema orc + * @property {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema|null} [csv] PhysicalSchema csv */ /** - * Constructs a new SystemTimestamps. + * Constructs a new PhysicalSchema. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a SystemTimestamps. - * @implements ISystemTimestamps + * @classdesc Represents a PhysicalSchema. + * @implements IPhysicalSchema * @constructor - * @param {google.cloud.datacatalog.v1.ISystemTimestamps=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IPhysicalSchema=} [properties] Properties to set */ - function SystemTimestamps(properties) { + function PhysicalSchema(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -18212,342 +18999,159 @@ } /** - * SystemTimestamps createTime. - * @member {google.protobuf.ITimestamp|null|undefined} createTime - * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * PhysicalSchema avro. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema|null|undefined} avro + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance */ - SystemTimestamps.prototype.createTime = null; + PhysicalSchema.prototype.avro = null; /** - * SystemTimestamps updateTime. - * @member {google.protobuf.ITimestamp|null|undefined} updateTime - * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * PhysicalSchema thrift. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema|null|undefined} thrift + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance */ - SystemTimestamps.prototype.updateTime = null; + PhysicalSchema.prototype.thrift = null; /** - * SystemTimestamps expireTime. - * @member {google.protobuf.ITimestamp|null|undefined} expireTime - * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * PhysicalSchema protobuf. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema|null|undefined} protobuf + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance */ - SystemTimestamps.prototype.expireTime = null; + PhysicalSchema.prototype.protobuf = null; /** - * Creates a new SystemTimestamps instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {google.cloud.datacatalog.v1.ISystemTimestamps=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps instance + * PhysicalSchema parquet. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema|null|undefined} parquet + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @instance */ - SystemTimestamps.create = function create(properties) { - return new SystemTimestamps(properties); - }; + PhysicalSchema.prototype.parquet = null; /** - * Encodes the specified SystemTimestamps message. Does not implicitly {@link google.cloud.datacatalog.v1.SystemTimestamps.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {google.cloud.datacatalog.v1.ISystemTimestamps} message SystemTimestamps message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * PhysicalSchema orc. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema|null|undefined} orc + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @instance */ - SystemTimestamps.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) - $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) - $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.expireTime != null && Object.hasOwnProperty.call(message, "expireTime")) - $root.google.protobuf.Timestamp.encode(message.expireTime, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - return writer; - }; - - /** - * Encodes the specified SystemTimestamps message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SystemTimestamps.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {google.cloud.datacatalog.v1.ISystemTimestamps} message SystemTimestamps message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SystemTimestamps.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a SystemTimestamps message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SystemTimestamps.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SystemTimestamps(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 2: { - message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 3: { - message.expireTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a SystemTimestamps message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SystemTimestamps.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a SystemTimestamps message. - * @function verify - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SystemTimestamps.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.createTime != null && message.hasOwnProperty("createTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.createTime); - if (error) - return "createTime." + error; - } - if (message.updateTime != null && message.hasOwnProperty("updateTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.updateTime); - if (error) - return "updateTime." + error; - } - if (message.expireTime != null && message.hasOwnProperty("expireTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.expireTime); - if (error) - return "expireTime." + error; - } - return null; - }; - - /** - * Creates a SystemTimestamps message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps - */ - SystemTimestamps.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.SystemTimestamps) - return object; - var message = new $root.google.cloud.datacatalog.v1.SystemTimestamps(); - if (object.createTime != null) { - if (typeof object.createTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.createTime: object expected"); - message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); - } - if (object.updateTime != null) { - if (typeof object.updateTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.updateTime: object expected"); - message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); - } - if (object.expireTime != null) { - if (typeof object.expireTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.expireTime: object expected"); - message.expireTime = $root.google.protobuf.Timestamp.fromObject(object.expireTime); - } - return message; - }; - - /** - * Creates a plain object from a SystemTimestamps message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {google.cloud.datacatalog.v1.SystemTimestamps} message SystemTimestamps - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SystemTimestamps.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.createTime = null; - object.updateTime = null; - object.expireTime = null; - } - if (message.createTime != null && message.hasOwnProperty("createTime")) - object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); - if (message.updateTime != null && message.hasOwnProperty("updateTime")) - object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); - if (message.expireTime != null && message.hasOwnProperty("expireTime")) - object.expireTime = $root.google.protobuf.Timestamp.toObject(message.expireTime, options); - return object; - }; + PhysicalSchema.prototype.orc = null; /** - * Converts this SystemTimestamps to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * PhysicalSchema csv. + * @member {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema|null|undefined} csv + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance - * @returns {Object.} JSON object - */ - SystemTimestamps.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for SystemTimestamps - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.SystemTimestamps - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SystemTimestamps.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.SystemTimestamps"; - }; - - return SystemTimestamps; - })(); - - v1.Schema = (function() { - - /** - * Properties of a Schema. - * @memberof google.cloud.datacatalog.v1 - * @interface ISchema - * @property {Array.|null} [columns] Schema columns */ + PhysicalSchema.prototype.csv = null; - /** - * Constructs a new Schema. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a Schema. - * @implements ISchema - * @constructor - * @param {google.cloud.datacatalog.v1.ISchema=} [properties] Properties to set - */ - function Schema(properties) { - this.columns = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Schema columns. - * @member {Array.} columns - * @memberof google.cloud.datacatalog.v1.Schema + * PhysicalSchema schema. + * @member {"avro"|"thrift"|"protobuf"|"parquet"|"orc"|"csv"|undefined} schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance */ - Schema.prototype.columns = $util.emptyArray; + Object.defineProperty(PhysicalSchema.prototype, "schema", { + get: $util.oneOfGetter($oneOfFields = ["avro", "thrift", "protobuf", "parquet", "orc", "csv"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new Schema instance using the specified properties. + * Creates a new PhysicalSchema instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static - * @param {google.cloud.datacatalog.v1.ISchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.Schema} Schema instance + * @param {google.cloud.datacatalog.v1.IPhysicalSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema instance */ - Schema.create = function create(properties) { - return new Schema(properties); + PhysicalSchema.create = function create(properties) { + return new PhysicalSchema(properties); }; /** - * Encodes the specified Schema message. Does not implicitly {@link google.cloud.datacatalog.v1.Schema.verify|verify} messages. + * Encodes the specified PhysicalSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static - * @param {google.cloud.datacatalog.v1.ISchema} message Schema message or plain object to encode + * @param {google.cloud.datacatalog.v1.IPhysicalSchema} message PhysicalSchema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Schema.encode = function encode(message, writer) { + PhysicalSchema.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.columns != null && message.columns.length) - for (var i = 0; i < message.columns.length; ++i) - $root.google.cloud.datacatalog.v1.ColumnSchema.encode(message.columns[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.avro != null && Object.hasOwnProperty.call(message, "avro")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.encode(message.avro, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.thrift != null && Object.hasOwnProperty.call(message, "thrift")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.encode(message.thrift, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.protobuf != null && Object.hasOwnProperty.call(message, "protobuf")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.encode(message.protobuf, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.parquet != null && Object.hasOwnProperty.call(message, "parquet")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.encode(message.parquet, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.orc != null && Object.hasOwnProperty.call(message, "orc")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.encode(message.orc, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.csv != null && Object.hasOwnProperty.call(message, "csv")) + $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.encode(message.csv, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); return writer; }; /** - * Encodes the specified Schema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Schema.verify|verify} messages. + * Encodes the specified PhysicalSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static - * @param {google.cloud.datacatalog.v1.ISchema} message Schema message or plain object to encode + * @param {google.cloud.datacatalog.v1.IPhysicalSchema} message PhysicalSchema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Schema.encodeDelimited = function encodeDelimited(message, writer) { + PhysicalSchema.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Schema message from the specified reader or buffer. + * Decodes a PhysicalSchema message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.Schema} Schema + * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Schema.decode = function decode(reader, length) { + PhysicalSchema.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Schema(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.decode(reader, reader.uint32()); + break; + } case 2: { - if (!(message.columns && message.columns.length)) - message.columns = []; - message.columns.push($root.google.cloud.datacatalog.v1.ColumnSchema.decode(reader, reader.uint32())); + message.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.decode(reader, reader.uint32()); + break; + } + case 3: { + message.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.decode(reader, reader.uint32()); + break; + } + case 4: { + message.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.decode(reader, reader.uint32()); + break; + } + case 5: { + message.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.decode(reader, reader.uint32()); + break; + } + case 6: { + message.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.decode(reader, reader.uint32()); break; } default: @@ -18559,1099 +19163,1465 @@ }; /** - * Decodes a Schema message from the specified reader or buffer, length delimited. + * Decodes a PhysicalSchema message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.Schema} Schema + * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Schema.decodeDelimited = function decodeDelimited(reader) { + PhysicalSchema.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Schema message. + * Verifies a PhysicalSchema message. * @function verify - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Schema.verify = function verify(message) { + PhysicalSchema.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.columns != null && message.hasOwnProperty("columns")) { - if (!Array.isArray(message.columns)) - return "columns: array expected"; - for (var i = 0; i < message.columns.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.ColumnSchema.verify(message.columns[i]); + var properties = {}; + if (message.avro != null && message.hasOwnProperty("avro")) { + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify(message.avro); if (error) - return "columns." + error; + return "avro." + error; + } + } + if (message.thrift != null && message.hasOwnProperty("thrift")) { + if (properties.schema === 1) + return "schema: multiple values"; + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify(message.thrift); + if (error) + return "thrift." + error; + } + } + if (message.protobuf != null && message.hasOwnProperty("protobuf")) { + if (properties.schema === 1) + return "schema: multiple values"; + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify(message.protobuf); + if (error) + return "protobuf." + error; + } + } + if (message.parquet != null && message.hasOwnProperty("parquet")) { + if (properties.schema === 1) + return "schema: multiple values"; + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify(message.parquet); + if (error) + return "parquet." + error; + } + } + if (message.orc != null && message.hasOwnProperty("orc")) { + if (properties.schema === 1) + return "schema: multiple values"; + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify(message.orc); + if (error) + return "orc." + error; + } + } + if (message.csv != null && message.hasOwnProperty("csv")) { + if (properties.schema === 1) + return "schema: multiple values"; + properties.schema = 1; + { + var error = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify(message.csv); + if (error) + return "csv." + error; } } return null; }; /** - * Creates a Schema message from a plain object. Also converts values to their respective internal types. + * Creates a PhysicalSchema message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.Schema} Schema + * @returns {google.cloud.datacatalog.v1.PhysicalSchema} PhysicalSchema */ - Schema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.Schema) + PhysicalSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema) return object; - var message = new $root.google.cloud.datacatalog.v1.Schema(); - if (object.columns) { - if (!Array.isArray(object.columns)) - throw TypeError(".google.cloud.datacatalog.v1.Schema.columns: array expected"); - message.columns = []; - for (var i = 0; i < object.columns.length; ++i) { - if (typeof object.columns[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.Schema.columns: object expected"); - message.columns[i] = $root.google.cloud.datacatalog.v1.ColumnSchema.fromObject(object.columns[i]); - } + var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema(); + if (object.avro != null) { + if (typeof object.avro !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.avro: object expected"); + message.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.fromObject(object.avro); + } + if (object.thrift != null) { + if (typeof object.thrift !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.thrift: object expected"); + message.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.fromObject(object.thrift); + } + if (object.protobuf != null) { + if (typeof object.protobuf !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.protobuf: object expected"); + message.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.fromObject(object.protobuf); + } + if (object.parquet != null) { + if (typeof object.parquet !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.parquet: object expected"); + message.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.fromObject(object.parquet); + } + if (object.orc != null) { + if (typeof object.orc !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.orc: object expected"); + message.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.fromObject(object.orc); + } + if (object.csv != null) { + if (typeof object.csv !== "object") + throw TypeError(".google.cloud.datacatalog.v1.PhysicalSchema.csv: object expected"); + message.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.fromObject(object.csv); } return message; }; /** - * Creates a plain object from a Schema message. Also converts values to other types if specified. + * Creates a plain object from a PhysicalSchema message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static - * @param {google.cloud.datacatalog.v1.Schema} message Schema + * @param {google.cloud.datacatalog.v1.PhysicalSchema} message PhysicalSchema * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Schema.toObject = function toObject(message, options) { + PhysicalSchema.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.columns = []; - if (message.columns && message.columns.length) { - object.columns = []; - for (var j = 0; j < message.columns.length; ++j) - object.columns[j] = $root.google.cloud.datacatalog.v1.ColumnSchema.toObject(message.columns[j], options); + if (message.avro != null && message.hasOwnProperty("avro")) { + object.avro = $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.toObject(message.avro, options); + if (options.oneofs) + object.schema = "avro"; + } + if (message.thrift != null && message.hasOwnProperty("thrift")) { + object.thrift = $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.toObject(message.thrift, options); + if (options.oneofs) + object.schema = "thrift"; + } + if (message.protobuf != null && message.hasOwnProperty("protobuf")) { + object.protobuf = $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.toObject(message.protobuf, options); + if (options.oneofs) + object.schema = "protobuf"; + } + if (message.parquet != null && message.hasOwnProperty("parquet")) { + object.parquet = $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.toObject(message.parquet, options); + if (options.oneofs) + object.schema = "parquet"; + } + if (message.orc != null && message.hasOwnProperty("orc")) { + object.orc = $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.toObject(message.orc, options); + if (options.oneofs) + object.schema = "orc"; + } + if (message.csv != null && message.hasOwnProperty("csv")) { + object.csv = $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.toObject(message.csv, options); + if (options.oneofs) + object.schema = "csv"; } return object; }; /** - * Converts this Schema to JSON. + * Converts this PhysicalSchema to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @instance * @returns {Object.} JSON object */ - Schema.prototype.toJSON = function toJSON() { + PhysicalSchema.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Schema + * Gets the default type url for PhysicalSchema * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.Schema + * @memberof google.cloud.datacatalog.v1.PhysicalSchema * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Schema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + PhysicalSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.Schema"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema"; }; - return Schema; - })(); - - v1.ColumnSchema = (function() { + PhysicalSchema.AvroSchema = (function() { - /** - * Properties of a ColumnSchema. - * @memberof google.cloud.datacatalog.v1 - * @interface IColumnSchema - * @property {string|null} [column] ColumnSchema column - * @property {string|null} [type] ColumnSchema type - * @property {string|null} [description] ColumnSchema description - * @property {string|null} [mode] ColumnSchema mode - * @property {Array.|null} [subcolumns] ColumnSchema subcolumns - */ + /** + * Properties of an AvroSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface IAvroSchema + * @property {string|null} [text] AvroSchema text + */ - /** - * Constructs a new ColumnSchema. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ColumnSchema. - * @implements IColumnSchema - * @constructor - * @param {google.cloud.datacatalog.v1.IColumnSchema=} [properties] Properties to set - */ - function ColumnSchema(properties) { - this.subcolumns = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * ColumnSchema column. - * @member {string} column - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.column = ""; - - /** - * ColumnSchema type. - * @member {string} type - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.type = ""; - - /** - * ColumnSchema description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.description = ""; - - /** - * ColumnSchema mode. - * @member {string} mode - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.mode = ""; + /** + * Constructs a new AvroSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents an AvroSchema. + * @implements IAvroSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema=} [properties] Properties to set + */ + function AvroSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * ColumnSchema subcolumns. - * @member {Array.} subcolumns - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.subcolumns = $util.emptyArray; + /** + * AvroSchema text. + * @member {string} text + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @instance + */ + AvroSchema.prototype.text = ""; - /** - * Creates a new ColumnSchema instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {google.cloud.datacatalog.v1.IColumnSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema instance - */ - ColumnSchema.create = function create(properties) { - return new ColumnSchema(properties); - }; + /** + * Creates a new AvroSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema instance + */ + AvroSchema.create = function create(properties) { + return new AvroSchema(properties); + }; - /** - * Encodes the specified ColumnSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {google.cloud.datacatalog.v1.IColumnSchema} message ColumnSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ColumnSchema.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); - if (message.mode != null && Object.hasOwnProperty.call(message, "mode")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.mode); - if (message.column != null && Object.hasOwnProperty.call(message, "column")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.column); - if (message.subcolumns != null && message.subcolumns.length) - for (var i = 0; i < message.subcolumns.length; ++i) - $root.google.cloud.datacatalog.v1.ColumnSchema.encode(message.subcolumns[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - return writer; - }; + /** + * Encodes the specified AvroSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema} message AvroSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AvroSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.text != null && Object.hasOwnProperty.call(message, "text")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); + return writer; + }; - /** - * Encodes the specified ColumnSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {google.cloud.datacatalog.v1.IColumnSchema} message ColumnSchema message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ColumnSchema.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified AvroSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IAvroSchema} message AvroSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AvroSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a ColumnSchema message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ColumnSchema.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ColumnSchema(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 6: { - message.column = reader.string(); - break; - } - case 1: { - message.type = reader.string(); - break; - } - case 2: { - message.description = reader.string(); - break; - } - case 3: { - message.mode = reader.string(); - break; - } - case 7: { - if (!(message.subcolumns && message.subcolumns.length)) - message.subcolumns = []; - message.subcolumns.push($root.google.cloud.datacatalog.v1.ColumnSchema.decode(reader, reader.uint32())); + /** + * Decodes an AvroSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AvroSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.text = reader.string(); + break; + } + default: + reader.skipType(tag & 7); break; } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; - /** - * Decodes a ColumnSchema message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ColumnSchema.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes an AvroSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AvroSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Verifies a ColumnSchema message. - * @function verify - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ColumnSchema.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.column != null && message.hasOwnProperty("column")) - if (!$util.isString(message.column)) - return "column: string expected"; - if (message.type != null && message.hasOwnProperty("type")) - if (!$util.isString(message.type)) - return "type: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.mode != null && message.hasOwnProperty("mode")) - if (!$util.isString(message.mode)) - return "mode: string expected"; - if (message.subcolumns != null && message.hasOwnProperty("subcolumns")) { - if (!Array.isArray(message.subcolumns)) - return "subcolumns: array expected"; - for (var i = 0; i < message.subcolumns.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.ColumnSchema.verify(message.subcolumns[i]); - if (error) - return "subcolumns." + error; - } - } - return null; - }; + /** + * Verifies an AvroSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + AvroSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.text != null && message.hasOwnProperty("text")) + if (!$util.isString(message.text)) + return "text: string expected"; + return null; + }; - /** - * Creates a ColumnSchema message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema - */ - ColumnSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ColumnSchema) + /** + * Creates an AvroSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} AvroSchema + */ + AvroSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema) + return object; + var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema(); + if (object.text != null) + message.text = String(object.text); + return message; + }; + + /** + * Creates a plain object from an AvroSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema} message AvroSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + AvroSchema.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.text = ""; + if (message.text != null && message.hasOwnProperty("text")) + object.text = message.text; return object; - var message = new $root.google.cloud.datacatalog.v1.ColumnSchema(); - if (object.column != null) - message.column = String(object.column); - if (object.type != null) - message.type = String(object.type); - if (object.description != null) - message.description = String(object.description); - if (object.mode != null) - message.mode = String(object.mode); - if (object.subcolumns) { - if (!Array.isArray(object.subcolumns)) - throw TypeError(".google.cloud.datacatalog.v1.ColumnSchema.subcolumns: array expected"); - message.subcolumns = []; - for (var i = 0; i < object.subcolumns.length; ++i) { - if (typeof object.subcolumns[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ColumnSchema.subcolumns: object expected"); - message.subcolumns[i] = $root.google.cloud.datacatalog.v1.ColumnSchema.fromObject(object.subcolumns[i]); + }; + + /** + * Converts this AvroSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @instance + * @returns {Object.} JSON object + */ + AvroSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for AvroSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + AvroSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } - } - return message; - }; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.AvroSchema"; + }; - /** - * Creates a plain object from a ColumnSchema message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {google.cloud.datacatalog.v1.ColumnSchema} message ColumnSchema - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ColumnSchema.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.subcolumns = []; - if (options.defaults) { - object.type = ""; - object.description = ""; - object.mode = ""; - object.column = ""; - } - if (message.type != null && message.hasOwnProperty("type")) - object.type = message.type; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.mode != null && message.hasOwnProperty("mode")) - object.mode = message.mode; - if (message.column != null && message.hasOwnProperty("column")) - object.column = message.column; - if (message.subcolumns && message.subcolumns.length) { - object.subcolumns = []; - for (var j = 0; j < message.subcolumns.length; ++j) - object.subcolumns[j] = $root.google.cloud.datacatalog.v1.ColumnSchema.toObject(message.subcolumns[j], options); - } - return object; - }; + return AvroSchema; + })(); - /** - * Converts this ColumnSchema to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @instance - * @returns {Object.} JSON object - */ - ColumnSchema.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + PhysicalSchema.ThriftSchema = (function() { - /** - * Gets the default type url for ColumnSchema - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ColumnSchema - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ColumnSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + /** + * Properties of a ThriftSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface IThriftSchema + * @property {string|null} [text] ThriftSchema text + */ + + /** + * Constructs a new ThriftSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents a ThriftSchema. + * @implements IThriftSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema=} [properties] Properties to set + */ + function ThriftSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ColumnSchema"; - }; - return ColumnSchema; - })(); + /** + * ThriftSchema text. + * @member {string} text + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @instance + */ + ThriftSchema.prototype.text = ""; - v1.SearchCatalogResult = (function() { + /** + * Creates a new ThriftSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema instance + */ + ThriftSchema.create = function create(properties) { + return new ThriftSchema(properties); + }; - /** - * Properties of a SearchCatalogResult. - * @memberof google.cloud.datacatalog.v1 - * @interface ISearchCatalogResult - * @property {google.cloud.datacatalog.v1.SearchResultType|null} [searchResultType] SearchCatalogResult searchResultType - * @property {string|null} [searchResultSubtype] SearchCatalogResult searchResultSubtype - * @property {string|null} [relativeResourceName] SearchCatalogResult relativeResourceName - * @property {string|null} [linkedResource] SearchCatalogResult linkedResource - * @property {google.protobuf.ITimestamp|null} [modifyTime] SearchCatalogResult modifyTime - * @property {google.cloud.datacatalog.v1.IntegratedSystem|null} [integratedSystem] SearchCatalogResult integratedSystem - * @property {string|null} [userSpecifiedSystem] SearchCatalogResult userSpecifiedSystem - * @property {string|null} [fullyQualifiedName] SearchCatalogResult fullyQualifiedName - * @property {string|null} [displayName] SearchCatalogResult displayName - * @property {string|null} [description] SearchCatalogResult description - */ + /** + * Encodes the specified ThriftSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema} message ThriftSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ThriftSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.text != null && Object.hasOwnProperty.call(message, "text")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); + return writer; + }; - /** - * Constructs a new SearchCatalogResult. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a SearchCatalogResult. - * @implements ISearchCatalogResult - * @constructor - * @param {google.cloud.datacatalog.v1.ISearchCatalogResult=} [properties] Properties to set - */ - function SearchCatalogResult(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Encodes the specified ThriftSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IThriftSchema} message ThriftSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ThriftSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * SearchCatalogResult searchResultType. - * @member {google.cloud.datacatalog.v1.SearchResultType} searchResultType - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.searchResultType = 0; + /** + * Decodes a ThriftSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ThriftSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.text = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * SearchCatalogResult searchResultSubtype. - * @member {string} searchResultSubtype - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.searchResultSubtype = ""; + /** + * Decodes a ThriftSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ThriftSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * SearchCatalogResult relativeResourceName. - * @member {string} relativeResourceName - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.relativeResourceName = ""; + /** + * Verifies a ThriftSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ThriftSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.text != null && message.hasOwnProperty("text")) + if (!$util.isString(message.text)) + return "text: string expected"; + return null; + }; - /** - * SearchCatalogResult linkedResource. - * @member {string} linkedResource - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.linkedResource = ""; + /** + * Creates a ThriftSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} ThriftSchema + */ + ThriftSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema) + return object; + var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema(); + if (object.text != null) + message.text = String(object.text); + return message; + }; - /** - * SearchCatalogResult modifyTime. - * @member {google.protobuf.ITimestamp|null|undefined} modifyTime - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.modifyTime = null; + /** + * Creates a plain object from a ThriftSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema} message ThriftSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ThriftSchema.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.text = ""; + if (message.text != null && message.hasOwnProperty("text")) + object.text = message.text; + return object; + }; - /** - * SearchCatalogResult integratedSystem. - * @member {google.cloud.datacatalog.v1.IntegratedSystem|null|undefined} integratedSystem - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.integratedSystem = null; + /** + * Converts this ThriftSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @instance + * @returns {Object.} JSON object + */ + ThriftSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * SearchCatalogResult userSpecifiedSystem. - * @member {string|null|undefined} userSpecifiedSystem - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.userSpecifiedSystem = null; + /** + * Gets the default type url for ThriftSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ThriftSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ThriftSchema"; + }; - /** - * SearchCatalogResult fullyQualifiedName. - * @member {string} fullyQualifiedName - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.fullyQualifiedName = ""; + return ThriftSchema; + })(); - /** - * SearchCatalogResult displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.displayName = ""; + PhysicalSchema.ProtobufSchema = (function() { - /** - * SearchCatalogResult description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.description = ""; + /** + * Properties of a ProtobufSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface IProtobufSchema + * @property {string|null} [text] ProtobufSchema text + */ - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * Constructs a new ProtobufSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents a ProtobufSchema. + * @implements IProtobufSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema=} [properties] Properties to set + */ + function ProtobufSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * SearchCatalogResult system. - * @member {"integratedSystem"|"userSpecifiedSystem"|undefined} system - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - */ - Object.defineProperty(SearchCatalogResult.prototype, "system", { - get: $util.oneOfGetter($oneOfFields = ["integratedSystem", "userSpecifiedSystem"]), - set: $util.oneOfSetter($oneOfFields) - }); + /** + * ProtobufSchema text. + * @member {string} text + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @instance + */ + ProtobufSchema.prototype.text = ""; - /** - * Creates a new SearchCatalogResult instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {google.cloud.datacatalog.v1.ISearchCatalogResult=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult instance - */ - SearchCatalogResult.create = function create(properties) { - return new SearchCatalogResult(properties); - }; + /** + * Creates a new ProtobufSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema instance + */ + ProtobufSchema.create = function create(properties) { + return new ProtobufSchema(properties); + }; - /** - * Encodes the specified SearchCatalogResult message. Does not implicitly {@link google.cloud.datacatalog.v1.SearchCatalogResult.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {google.cloud.datacatalog.v1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SearchCatalogResult.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.searchResultType != null && Object.hasOwnProperty.call(message, "searchResultType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.searchResultType); - if (message.searchResultSubtype != null && Object.hasOwnProperty.call(message, "searchResultSubtype")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.searchResultSubtype); - if (message.relativeResourceName != null && Object.hasOwnProperty.call(message, "relativeResourceName")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.relativeResourceName); - if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.linkedResource); - if (message.modifyTime != null && Object.hasOwnProperty.call(message, "modifyTime")) - $root.google.protobuf.Timestamp.encode(message.modifyTime, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - if (message.integratedSystem != null && Object.hasOwnProperty.call(message, "integratedSystem")) - writer.uint32(/* id 8, wireType 0 =*/64).int32(message.integratedSystem); - if (message.userSpecifiedSystem != null && Object.hasOwnProperty.call(message, "userSpecifiedSystem")) - writer.uint32(/* id 9, wireType 2 =*/74).string(message.userSpecifiedSystem); - if (message.fullyQualifiedName != null && Object.hasOwnProperty.call(message, "fullyQualifiedName")) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.fullyQualifiedName); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 12, wireType 2 =*/98).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 13, wireType 2 =*/106).string(message.description); - return writer; - }; + /** + * Encodes the specified ProtobufSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema} message ProtobufSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ProtobufSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.text != null && Object.hasOwnProperty.call(message, "text")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.text); + return writer; + }; - /** - * Encodes the specified SearchCatalogResult message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SearchCatalogResult.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {google.cloud.datacatalog.v1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SearchCatalogResult.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified ProtobufSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IProtobufSchema} message ProtobufSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ProtobufSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a SearchCatalogResult message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SearchCatalogResult.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SearchCatalogResult(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.searchResultType = reader.int32(); - break; - } - case 2: { - message.searchResultSubtype = reader.string(); - break; - } - case 3: { - message.relativeResourceName = reader.string(); - break; - } - case 4: { - message.linkedResource = reader.string(); - break; - } - case 7: { - message.modifyTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 8: { - message.integratedSystem = reader.int32(); - break; - } - case 9: { - message.userSpecifiedSystem = reader.string(); - break; - } - case 10: { - message.fullyQualifiedName = reader.string(); - break; - } - case 12: { - message.displayName = reader.string(); - break; - } - case 13: { - message.description = reader.string(); + /** + * Decodes a ProtobufSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ProtobufSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.text = reader.string(); + break; + } + default: + reader.skipType(tag & 7); break; } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; - /** - * Decodes a SearchCatalogResult message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SearchCatalogResult.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes a ProtobufSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ProtobufSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Verifies a SearchCatalogResult message. - * @function verify - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SearchCatalogResult.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) - switch (message.searchResultType) { - default: - return "searchResultType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } - if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) - if (!$util.isString(message.searchResultSubtype)) - return "searchResultSubtype: string expected"; - if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) - if (!$util.isString(message.relativeResourceName)) - return "relativeResourceName: string expected"; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - if (!$util.isString(message.linkedResource)) - return "linkedResource: string expected"; - if (message.modifyTime != null && message.hasOwnProperty("modifyTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.modifyTime); - if (error) - return "modifyTime." + error; - } - if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { - properties.system = 1; - switch (message.integratedSystem) { - default: - return "integratedSystem: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - break; - } - } - if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { - if (properties.system === 1) - return "system: multiple values"; - properties.system = 1; - if (!$util.isString(message.userSpecifiedSystem)) - return "userSpecifiedSystem: string expected"; - } - if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) - if (!$util.isString(message.fullyQualifiedName)) - return "fullyQualifiedName: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - return null; - }; + /** + * Verifies a ProtobufSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ProtobufSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.text != null && message.hasOwnProperty("text")) + if (!$util.isString(message.text)) + return "text: string expected"; + return null; + }; - /** - * Creates a SearchCatalogResult message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult - */ - SearchCatalogResult.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.SearchCatalogResult) + /** + * Creates a ProtobufSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} ProtobufSchema + */ + ProtobufSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema) + return object; + var message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema(); + if (object.text != null) + message.text = String(object.text); + return message; + }; + + /** + * Creates a plain object from a ProtobufSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema} message ProtobufSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ProtobufSchema.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.text = ""; + if (message.text != null && message.hasOwnProperty("text")) + object.text = message.text; return object; - var message = new $root.google.cloud.datacatalog.v1.SearchCatalogResult(); - switch (object.searchResultType) { - default: - if (typeof object.searchResultType === "number") { - message.searchResultType = object.searchResultType; - break; - } - break; - case "SEARCH_RESULT_TYPE_UNSPECIFIED": - case 0: - message.searchResultType = 0; - break; - case "ENTRY": - case 1: - message.searchResultType = 1; - break; - case "TAG_TEMPLATE": - case 2: - message.searchResultType = 2; - break; - case "ENTRY_GROUP": - case 3: - message.searchResultType = 3; - break; - } - if (object.searchResultSubtype != null) - message.searchResultSubtype = String(object.searchResultSubtype); - if (object.relativeResourceName != null) - message.relativeResourceName = String(object.relativeResourceName); - if (object.linkedResource != null) - message.linkedResource = String(object.linkedResource); - if (object.modifyTime != null) { - if (typeof object.modifyTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SearchCatalogResult.modifyTime: object expected"); - message.modifyTime = $root.google.protobuf.Timestamp.fromObject(object.modifyTime); - } - switch (object.integratedSystem) { - default: - if (typeof object.integratedSystem === "number") { - message.integratedSystem = object.integratedSystem; - break; + }; + + /** + * Converts this ProtobufSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @instance + * @returns {Object.} JSON object + */ + ProtobufSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ProtobufSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ProtobufSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } - break; - case "INTEGRATED_SYSTEM_UNSPECIFIED": - case 0: - message.integratedSystem = 0; - break; - case "BIGQUERY": - case 1: - message.integratedSystem = 1; - break; - case "CLOUD_PUBSUB": - case 2: - message.integratedSystem = 2; - break; - case "DATAPROC_METASTORE": - case 3: - message.integratedSystem = 3; - break; - case "DATAPLEX": - case 4: - message.integratedSystem = 4; - break; - } - if (object.userSpecifiedSystem != null) - message.userSpecifiedSystem = String(object.userSpecifiedSystem); - if (object.fullyQualifiedName != null) - message.fullyQualifiedName = String(object.fullyQualifiedName); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - return message; - }; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ProtobufSchema"; + }; - /** - * Creates a plain object from a SearchCatalogResult message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {google.cloud.datacatalog.v1.SearchCatalogResult} message SearchCatalogResult - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SearchCatalogResult.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.searchResultType = options.enums === String ? "SEARCH_RESULT_TYPE_UNSPECIFIED" : 0; - object.searchResultSubtype = ""; - object.relativeResourceName = ""; - object.linkedResource = ""; - object.modifyTime = null; - object.fullyQualifiedName = ""; - object.displayName = ""; - object.description = ""; - } - if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) - object.searchResultType = options.enums === String ? $root.google.cloud.datacatalog.v1.SearchResultType[message.searchResultType] === undefined ? message.searchResultType : $root.google.cloud.datacatalog.v1.SearchResultType[message.searchResultType] : message.searchResultType; - if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) - object.searchResultSubtype = message.searchResultSubtype; - if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) - object.relativeResourceName = message.relativeResourceName; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - object.linkedResource = message.linkedResource; - if (message.modifyTime != null && message.hasOwnProperty("modifyTime")) - object.modifyTime = $root.google.protobuf.Timestamp.toObject(message.modifyTime, options); - if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { - object.integratedSystem = options.enums === String ? $root.google.cloud.datacatalog.v1.IntegratedSystem[message.integratedSystem] === undefined ? message.integratedSystem : $root.google.cloud.datacatalog.v1.IntegratedSystem[message.integratedSystem] : message.integratedSystem; - if (options.oneofs) - object.system = "integratedSystem"; - } - if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { - object.userSpecifiedSystem = message.userSpecifiedSystem; - if (options.oneofs) - object.system = "userSpecifiedSystem"; - } - if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) - object.fullyQualifiedName = message.fullyQualifiedName; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - return object; - }; + return ProtobufSchema; + })(); - /** - * Converts this SearchCatalogResult to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @instance - * @returns {Object.} JSON object - */ - SearchCatalogResult.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + PhysicalSchema.ParquetSchema = (function() { - /** - * Gets the default type url for SearchCatalogResult - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.SearchCatalogResult - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SearchCatalogResult.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + /** + * Properties of a ParquetSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface IParquetSchema + */ + + /** + * Constructs a new ParquetSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents a ParquetSchema. + * @implements IParquetSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema=} [properties] Properties to set + */ + function ParquetSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.SearchCatalogResult"; - }; - return SearchCatalogResult; - })(); + /** + * Creates a new ParquetSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema instance + */ + ParquetSchema.create = function create(properties) { + return new ParquetSchema(properties); + }; - /** - * SearchResultType enum. - * @name google.cloud.datacatalog.v1.SearchResultType - * @enum {number} - * @property {number} SEARCH_RESULT_TYPE_UNSPECIFIED=0 SEARCH_RESULT_TYPE_UNSPECIFIED value - * @property {number} ENTRY=1 ENTRY value - * @property {number} TAG_TEMPLATE=2 TAG_TEMPLATE value - * @property {number} ENTRY_GROUP=3 ENTRY_GROUP value - */ - v1.SearchResultType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "SEARCH_RESULT_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "ENTRY"] = 1; - values[valuesById[2] = "TAG_TEMPLATE"] = 2; - values[valuesById[3] = "ENTRY_GROUP"] = 3; - return values; - })(); + /** + * Encodes the specified ParquetSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema} message ParquetSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ParquetSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + return writer; + }; - v1.BigQueryTableSpec = (function() { + /** + * Encodes the specified ParquetSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IParquetSchema} message ParquetSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ParquetSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Properties of a BigQueryTableSpec. - * @memberof google.cloud.datacatalog.v1 - * @interface IBigQueryTableSpec - * @property {google.cloud.datacatalog.v1.TableSourceType|null} [tableSourceType] BigQueryTableSpec tableSourceType - * @property {google.cloud.datacatalog.v1.IViewSpec|null} [viewSpec] BigQueryTableSpec viewSpec - * @property {google.cloud.datacatalog.v1.ITableSpec|null} [tableSpec] BigQueryTableSpec tableSpec - */ + /** + * Decodes a ParquetSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ParquetSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Constructs a new BigQueryTableSpec. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a BigQueryTableSpec. - * @implements IBigQueryTableSpec - * @constructor - * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec=} [properties] Properties to set - */ - function BigQueryTableSpec(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Decodes a ParquetSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ParquetSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * BigQueryTableSpec tableSourceType. - * @member {google.cloud.datacatalog.v1.TableSourceType} tableSourceType - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec - * @instance - */ - BigQueryTableSpec.prototype.tableSourceType = 0; + /** + * Verifies a ParquetSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ParquetSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; + }; - /** - * BigQueryTableSpec viewSpec. - * @member {google.cloud.datacatalog.v1.IViewSpec|null|undefined} viewSpec - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec - * @instance - */ - BigQueryTableSpec.prototype.viewSpec = null; + /** + * Creates a ParquetSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} ParquetSchema + */ + ParquetSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema) + return object; + return new $root.google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema(); + }; - /** - * BigQueryTableSpec tableSpec. - * @member {google.cloud.datacatalog.v1.ITableSpec|null|undefined} tableSpec - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec - * @instance - */ - BigQueryTableSpec.prototype.tableSpec = null; + /** + * Creates a plain object from a ParquetSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema} message ParquetSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ParquetSchema.toObject = function toObject() { + return {}; + }; - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * Converts this ParquetSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @instance + * @returns {Object.} JSON object + */ + ParquetSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * BigQueryTableSpec typeSpec. - * @member {"viewSpec"|"tableSpec"|undefined} typeSpec - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec - * @instance - */ - Object.defineProperty(BigQueryTableSpec.prototype, "typeSpec", { - get: $util.oneOfGetter($oneOfFields = ["viewSpec", "tableSpec"]), - set: $util.oneOfSetter($oneOfFields) - }); + /** + * Gets the default type url for ParquetSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ParquetSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.ParquetSchema"; + }; + + return ParquetSchema; + })(); + + PhysicalSchema.OrcSchema = (function() { + + /** + * Properties of an OrcSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface IOrcSchema + */ + + /** + * Constructs a new OrcSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents an OrcSchema. + * @implements IOrcSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema=} [properties] Properties to set + */ + function OrcSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Creates a new OrcSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema instance + */ + OrcSchema.create = function create(properties) { + return new OrcSchema(properties); + }; + + /** + * Encodes the specified OrcSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema} message OrcSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + OrcSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + return writer; + }; + + /** + * Encodes the specified OrcSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.IOrcSchema} message OrcSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + OrcSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an OrcSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + OrcSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an OrcSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + OrcSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an OrcSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + OrcSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; + }; + + /** + * Creates an OrcSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} OrcSchema + */ + OrcSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema) + return object; + return new $root.google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema(); + }; + + /** + * Creates a plain object from an OrcSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema} message OrcSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + OrcSchema.toObject = function toObject() { + return {}; + }; + + /** + * Converts this OrcSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @instance + * @returns {Object.} JSON object + */ + OrcSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for OrcSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + OrcSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.OrcSchema"; + }; + + return OrcSchema; + })(); + + PhysicalSchema.CsvSchema = (function() { + + /** + * Properties of a CsvSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @interface ICsvSchema + */ + + /** + * Constructs a new CsvSchema. + * @memberof google.cloud.datacatalog.v1.PhysicalSchema + * @classdesc Represents a CsvSchema. + * @implements ICsvSchema + * @constructor + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema=} [properties] Properties to set + */ + function CsvSchema(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Creates a new CsvSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema instance + */ + CsvSchema.create = function create(properties) { + return new CsvSchema(properties); + }; + + /** + * Encodes the specified CsvSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema} message CsvSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CsvSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + return writer; + }; + + /** + * Encodes the specified CsvSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.ICsvSchema} message CsvSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CsvSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a CsvSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CsvSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a CsvSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CsvSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a CsvSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CsvSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; + }; + + /** + * Creates a CsvSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} CsvSchema + */ + CsvSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema) + return object; + return new $root.google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema(); + }; + + /** + * Creates a plain object from a CsvSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema} message CsvSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CsvSchema.toObject = function toObject() { + return {}; + }; + + /** + * Converts this CsvSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @instance + * @returns {Object.} JSON object + */ + CsvSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for CsvSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CsvSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PhysicalSchema.CsvSchema"; + }; + + return CsvSchema; + })(); + + return PhysicalSchema; + })(); + + v1.GcsFilesetSpec = (function() { /** - * Creates a new BigQueryTableSpec instance using the specified properties. + * Properties of a GcsFilesetSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface IGcsFilesetSpec + * @property {Array.|null} [filePatterns] GcsFilesetSpec filePatterns + * @property {Array.|null} [sampleGcsFileSpecs] GcsFilesetSpec sampleGcsFileSpecs + */ + + /** + * Constructs a new GcsFilesetSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a GcsFilesetSpec. + * @implements IGcsFilesetSpec + * @constructor + * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec=} [properties] Properties to set + */ + function GcsFilesetSpec(properties) { + this.filePatterns = []; + this.sampleGcsFileSpecs = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * GcsFilesetSpec filePatterns. + * @member {Array.} filePatterns + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @instance + */ + GcsFilesetSpec.prototype.filePatterns = $util.emptyArray; + + /** + * GcsFilesetSpec sampleGcsFileSpecs. + * @member {Array.} sampleGcsFileSpecs + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec + * @instance + */ + GcsFilesetSpec.prototype.sampleGcsFileSpecs = $util.emptyArray; + + /** + * Creates a new GcsFilesetSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec instance + * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec instance */ - BigQueryTableSpec.create = function create(properties) { - return new BigQueryTableSpec(properties); + GcsFilesetSpec.create = function create(properties) { + return new GcsFilesetSpec(properties); }; /** - * Encodes the specified BigQueryTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryTableSpec.verify|verify} messages. + * Encodes the specified GcsFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFilesetSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryTableSpec.encode = function encode(message, writer) { + GcsFilesetSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.tableSourceType != null && Object.hasOwnProperty.call(message, "tableSourceType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.tableSourceType); - if (message.viewSpec != null && Object.hasOwnProperty.call(message, "viewSpec")) - $root.google.cloud.datacatalog.v1.ViewSpec.encode(message.viewSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.tableSpec != null && Object.hasOwnProperty.call(message, "tableSpec")) - $root.google.cloud.datacatalog.v1.TableSpec.encode(message.tableSpec, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.filePatterns != null && message.filePatterns.length) + for (var i = 0; i < message.filePatterns.length; ++i) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePatterns[i]); + if (message.sampleGcsFileSpecs != null && message.sampleGcsFileSpecs.length) + for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) + $root.google.cloud.datacatalog.v1.GcsFileSpec.encode(message.sampleGcsFileSpecs[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified BigQueryTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryTableSpec.verify|verify} messages. + * Encodes the specified GcsFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFilesetSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryTableSpec.encodeDelimited = function encodeDelimited(message, writer) { + GcsFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a BigQueryTableSpec message from the specified reader or buffer. + * Decodes a GcsFilesetSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryTableSpec.decode = function decode(reader, length) { + GcsFilesetSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.BigQueryTableSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GcsFilesetSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.tableSourceType = reader.int32(); + if (!(message.filePatterns && message.filePatterns.length)) + message.filePatterns = []; + message.filePatterns.push(reader.string()); break; } case 2: { - message.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.decode(reader, reader.uint32()); - break; - } - case 3: { - message.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.decode(reader, reader.uint32()); + if (!(message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length)) + message.sampleGcsFileSpecs = []; + message.sampleGcsFileSpecs.push($root.google.cloud.datacatalog.v1.GcsFileSpec.decode(reader, reader.uint32())); break; } default: @@ -19663,208 +20633,162 @@ }; /** - * Decodes a BigQueryTableSpec message from the specified reader or buffer, length delimited. + * Decodes a GcsFilesetSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryTableSpec.decodeDelimited = function decodeDelimited(reader) { + GcsFilesetSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a BigQueryTableSpec message. + * Verifies a GcsFilesetSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - BigQueryTableSpec.verify = function verify(message) { + GcsFilesetSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) - switch (message.tableSourceType) { - default: - return "tableSourceType: enum value expected"; - case 0: - case 2: - case 5: - case 7: - break; - } - if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1.ViewSpec.verify(message.viewSpec); - if (error) - return "viewSpec." + error; - } + if (message.filePatterns != null && message.hasOwnProperty("filePatterns")) { + if (!Array.isArray(message.filePatterns)) + return "filePatterns: array expected"; + for (var i = 0; i < message.filePatterns.length; ++i) + if (!$util.isString(message.filePatterns[i])) + return "filePatterns: string[] expected"; } - if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { - if (properties.typeSpec === 1) - return "typeSpec: multiple values"; - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1.TableSpec.verify(message.tableSpec); + if (message.sampleGcsFileSpecs != null && message.hasOwnProperty("sampleGcsFileSpecs")) { + if (!Array.isArray(message.sampleGcsFileSpecs)) + return "sampleGcsFileSpecs: array expected"; + for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.GcsFileSpec.verify(message.sampleGcsFileSpecs[i]); if (error) - return "tableSpec." + error; + return "sampleGcsFileSpecs." + error; } } return null; }; /** - * Creates a BigQueryTableSpec message from a plain object. Also converts values to their respective internal types. + * Creates a GcsFilesetSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1.GcsFilesetSpec} GcsFilesetSpec */ - BigQueryTableSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.BigQueryTableSpec) + GcsFilesetSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.GcsFilesetSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.BigQueryTableSpec(); - switch (object.tableSourceType) { - default: - if (typeof object.tableSourceType === "number") { - message.tableSourceType = object.tableSourceType; - break; - } - break; - case "TABLE_SOURCE_TYPE_UNSPECIFIED": - case 0: - message.tableSourceType = 0; - break; - case "BIGQUERY_VIEW": - case 2: - message.tableSourceType = 2; - break; - case "BIGQUERY_TABLE": - case 5: - message.tableSourceType = 5; - break; - case "BIGQUERY_MATERIALIZED_VIEW": - case 7: - message.tableSourceType = 7; - break; - } - if (object.viewSpec != null) { - if (typeof object.viewSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1.BigQueryTableSpec.viewSpec: object expected"); - message.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.fromObject(object.viewSpec); + var message = new $root.google.cloud.datacatalog.v1.GcsFilesetSpec(); + if (object.filePatterns) { + if (!Array.isArray(object.filePatterns)) + throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.filePatterns: array expected"); + message.filePatterns = []; + for (var i = 0; i < object.filePatterns.length; ++i) + message.filePatterns[i] = String(object.filePatterns[i]); } - if (object.tableSpec != null) { - if (typeof object.tableSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1.BigQueryTableSpec.tableSpec: object expected"); - message.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.fromObject(object.tableSpec); + if (object.sampleGcsFileSpecs) { + if (!Array.isArray(object.sampleGcsFileSpecs)) + throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.sampleGcsFileSpecs: array expected"); + message.sampleGcsFileSpecs = []; + for (var i = 0; i < object.sampleGcsFileSpecs.length; ++i) { + if (typeof object.sampleGcsFileSpecs[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.GcsFilesetSpec.sampleGcsFileSpecs: object expected"); + message.sampleGcsFileSpecs[i] = $root.google.cloud.datacatalog.v1.GcsFileSpec.fromObject(object.sampleGcsFileSpecs[i]); + } } return message; }; /** - * Creates a plain object from a BigQueryTableSpec message. Also converts values to other types if specified. + * Creates a plain object from a GcsFilesetSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1.BigQueryTableSpec} message BigQueryTableSpec + * @param {google.cloud.datacatalog.v1.GcsFilesetSpec} message GcsFilesetSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - BigQueryTableSpec.toObject = function toObject(message, options) { + GcsFilesetSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.tableSourceType = options.enums === String ? "TABLE_SOURCE_TYPE_UNSPECIFIED" : 0; - if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) - object.tableSourceType = options.enums === String ? $root.google.cloud.datacatalog.v1.TableSourceType[message.tableSourceType] === undefined ? message.tableSourceType : $root.google.cloud.datacatalog.v1.TableSourceType[message.tableSourceType] : message.tableSourceType; - if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { - object.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.toObject(message.viewSpec, options); - if (options.oneofs) - object.typeSpec = "viewSpec"; + if (options.arrays || options.defaults) { + object.filePatterns = []; + object.sampleGcsFileSpecs = []; } - if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { - object.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.toObject(message.tableSpec, options); - if (options.oneofs) - object.typeSpec = "tableSpec"; + if (message.filePatterns && message.filePatterns.length) { + object.filePatterns = []; + for (var j = 0; j < message.filePatterns.length; ++j) + object.filePatterns[j] = message.filePatterns[j]; + } + if (message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length) { + object.sampleGcsFileSpecs = []; + for (var j = 0; j < message.sampleGcsFileSpecs.length; ++j) + object.sampleGcsFileSpecs[j] = $root.google.cloud.datacatalog.v1.GcsFileSpec.toObject(message.sampleGcsFileSpecs[j], options); } return object; }; /** - * Converts this BigQueryTableSpec to JSON. + * Converts this GcsFilesetSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @instance * @returns {Object.} JSON object */ - BigQueryTableSpec.prototype.toJSON = function toJSON() { + GcsFilesetSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for BigQueryTableSpec + * Gets the default type url for GcsFilesetSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1.GcsFilesetSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - BigQueryTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GcsFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.BigQueryTableSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.GcsFilesetSpec"; }; - return BigQueryTableSpec; - })(); - - /** - * TableSourceType enum. - * @name google.cloud.datacatalog.v1.TableSourceType - * @enum {number} - * @property {number} TABLE_SOURCE_TYPE_UNSPECIFIED=0 TABLE_SOURCE_TYPE_UNSPECIFIED value - * @property {number} BIGQUERY_VIEW=2 BIGQUERY_VIEW value - * @property {number} BIGQUERY_TABLE=5 BIGQUERY_TABLE value - * @property {number} BIGQUERY_MATERIALIZED_VIEW=7 BIGQUERY_MATERIALIZED_VIEW value - */ - v1.TableSourceType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "TABLE_SOURCE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[2] = "BIGQUERY_VIEW"] = 2; - values[valuesById[5] = "BIGQUERY_TABLE"] = 5; - values[valuesById[7] = "BIGQUERY_MATERIALIZED_VIEW"] = 7; - return values; + return GcsFilesetSpec; })(); - v1.ViewSpec = (function() { + v1.GcsFileSpec = (function() { /** - * Properties of a ViewSpec. + * Properties of a GcsFileSpec. * @memberof google.cloud.datacatalog.v1 - * @interface IViewSpec - * @property {string|null} [viewQuery] ViewSpec viewQuery + * @interface IGcsFileSpec + * @property {string|null} [filePath] GcsFileSpec filePath + * @property {google.cloud.datacatalog.v1.ISystemTimestamps|null} [gcsTimestamps] GcsFileSpec gcsTimestamps + * @property {number|Long|null} [sizeBytes] GcsFileSpec sizeBytes */ /** - * Constructs a new ViewSpec. + * Constructs a new GcsFileSpec. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ViewSpec. - * @implements IViewSpec + * @classdesc Represents a GcsFileSpec. + * @implements IGcsFileSpec * @constructor - * @param {google.cloud.datacatalog.v1.IViewSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IGcsFileSpec=} [properties] Properties to set */ - function ViewSpec(properties) { + function GcsFileSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -19872,75 +20796,103 @@ } /** - * ViewSpec viewQuery. - * @member {string} viewQuery - * @memberof google.cloud.datacatalog.v1.ViewSpec + * GcsFileSpec filePath. + * @member {string} filePath + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @instance */ - ViewSpec.prototype.viewQuery = ""; + GcsFileSpec.prototype.filePath = ""; /** - * Creates a new ViewSpec instance using the specified properties. + * GcsFileSpec gcsTimestamps. + * @member {google.cloud.datacatalog.v1.ISystemTimestamps|null|undefined} gcsTimestamps + * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @instance + */ + GcsFileSpec.prototype.gcsTimestamps = null; + + /** + * GcsFileSpec sizeBytes. + * @member {number|Long} sizeBytes + * @memberof google.cloud.datacatalog.v1.GcsFileSpec + * @instance + */ + GcsFileSpec.prototype.sizeBytes = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + + /** + * Creates a new GcsFileSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1.IViewSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec instance + * @param {google.cloud.datacatalog.v1.IGcsFileSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec instance */ - ViewSpec.create = function create(properties) { - return new ViewSpec(properties); + GcsFileSpec.create = function create(properties) { + return new GcsFileSpec(properties); }; /** - * Encodes the specified ViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.ViewSpec.verify|verify} messages. + * Encodes the specified GcsFileSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFileSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1.IViewSpec} message ViewSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGcsFileSpec} message GcsFileSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ViewSpec.encode = function encode(message, writer) { + GcsFileSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.viewQuery != null && Object.hasOwnProperty.call(message, "viewQuery")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.viewQuery); + if (message.filePath != null && Object.hasOwnProperty.call(message, "filePath")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePath); + if (message.gcsTimestamps != null && Object.hasOwnProperty.call(message, "gcsTimestamps")) + $root.google.cloud.datacatalog.v1.SystemTimestamps.encode(message.gcsTimestamps, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.sizeBytes != null && Object.hasOwnProperty.call(message, "sizeBytes")) + writer.uint32(/* id 4, wireType 0 =*/32).int64(message.sizeBytes); return writer; }; /** - * Encodes the specified ViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ViewSpec.verify|verify} messages. + * Encodes the specified GcsFileSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GcsFileSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1.IViewSpec} message ViewSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGcsFileSpec} message GcsFileSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ViewSpec.encodeDelimited = function encodeDelimited(message, writer) { + GcsFileSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ViewSpec message from the specified reader or buffer. + * Decodes a GcsFileSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ViewSpec.decode = function decode(reader, length) { + GcsFileSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ViewSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GcsFileSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.viewQuery = reader.string(); + message.filePath = reader.string(); + break; + } + case 2: { + message.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.decode(reader, reader.uint32()); + break; + } + case 4: { + message.sizeBytes = reader.int64(); break; } default: @@ -19952,122 +20904,160 @@ }; /** - * Decodes a ViewSpec message from the specified reader or buffer, length delimited. + * Decodes a GcsFileSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ViewSpec.decodeDelimited = function decodeDelimited(reader) { + GcsFileSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ViewSpec message. + * Verifies a GcsFileSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ViewSpec.verify = function verify(message) { + GcsFileSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) - if (!$util.isString(message.viewQuery)) - return "viewQuery: string expected"; + if (message.filePath != null && message.hasOwnProperty("filePath")) + if (!$util.isString(message.filePath)) + return "filePath: string expected"; + if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) { + var error = $root.google.cloud.datacatalog.v1.SystemTimestamps.verify(message.gcsTimestamps); + if (error) + return "gcsTimestamps." + error; + } + if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) + if (!$util.isInteger(message.sizeBytes) && !(message.sizeBytes && $util.isInteger(message.sizeBytes.low) && $util.isInteger(message.sizeBytes.high))) + return "sizeBytes: integer|Long expected"; return null; }; /** - * Creates a ViewSpec message from a plain object. Also converts values to their respective internal types. + * Creates a GcsFileSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1.GcsFileSpec} GcsFileSpec */ - ViewSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ViewSpec) + GcsFileSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.GcsFileSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.ViewSpec(); - if (object.viewQuery != null) - message.viewQuery = String(object.viewQuery); + var message = new $root.google.cloud.datacatalog.v1.GcsFileSpec(); + if (object.filePath != null) + message.filePath = String(object.filePath); + if (object.gcsTimestamps != null) { + if (typeof object.gcsTimestamps !== "object") + throw TypeError(".google.cloud.datacatalog.v1.GcsFileSpec.gcsTimestamps: object expected"); + message.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.fromObject(object.gcsTimestamps); + } + if (object.sizeBytes != null) + if ($util.Long) + (message.sizeBytes = $util.Long.fromValue(object.sizeBytes)).unsigned = false; + else if (typeof object.sizeBytes === "string") + message.sizeBytes = parseInt(object.sizeBytes, 10); + else if (typeof object.sizeBytes === "number") + message.sizeBytes = object.sizeBytes; + else if (typeof object.sizeBytes === "object") + message.sizeBytes = new $util.LongBits(object.sizeBytes.low >>> 0, object.sizeBytes.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a ViewSpec message. Also converts values to other types if specified. + * Creates a plain object from a GcsFileSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1.ViewSpec} message ViewSpec + * @param {google.cloud.datacatalog.v1.GcsFileSpec} message GcsFileSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ViewSpec.toObject = function toObject(message, options) { + GcsFileSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.viewQuery = ""; - if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) - object.viewQuery = message.viewQuery; + if (options.defaults) { + object.filePath = ""; + object.gcsTimestamps = null; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.sizeBytes = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.sizeBytes = options.longs === String ? "0" : 0; + } + if (message.filePath != null && message.hasOwnProperty("filePath")) + object.filePath = message.filePath; + if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) + object.gcsTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.toObject(message.gcsTimestamps, options); + if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) + if (typeof message.sizeBytes === "number") + object.sizeBytes = options.longs === String ? String(message.sizeBytes) : message.sizeBytes; + else + object.sizeBytes = options.longs === String ? $util.Long.prototype.toString.call(message.sizeBytes) : options.longs === Number ? new $util.LongBits(message.sizeBytes.low >>> 0, message.sizeBytes.high >>> 0).toNumber() : message.sizeBytes; return object; }; /** - * Converts this ViewSpec to JSON. + * Converts this GcsFileSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @instance * @returns {Object.} JSON object */ - ViewSpec.prototype.toJSON = function toJSON() { + GcsFileSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ViewSpec + * Gets the default type url for GcsFileSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ViewSpec + * @memberof google.cloud.datacatalog.v1.GcsFileSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ViewSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GcsFileSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ViewSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.GcsFileSpec"; }; - return ViewSpec; + return GcsFileSpec; })(); - v1.TableSpec = (function() { + v1.SystemTimestamps = (function() { /** - * Properties of a TableSpec. + * Properties of a SystemTimestamps. * @memberof google.cloud.datacatalog.v1 - * @interface ITableSpec - * @property {string|null} [groupedEntry] TableSpec groupedEntry + * @interface ISystemTimestamps + * @property {google.protobuf.ITimestamp|null} [createTime] SystemTimestamps createTime + * @property {google.protobuf.ITimestamp|null} [updateTime] SystemTimestamps updateTime + * @property {google.protobuf.ITimestamp|null} [expireTime] SystemTimestamps expireTime */ /** - * Constructs a new TableSpec. + * Constructs a new SystemTimestamps. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a TableSpec. - * @implements ITableSpec + * @classdesc Represents a SystemTimestamps. + * @implements ISystemTimestamps * @constructor - * @param {google.cloud.datacatalog.v1.ITableSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ISystemTimestamps=} [properties] Properties to set */ - function TableSpec(properties) { + function SystemTimestamps(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20075,75 +21065,103 @@ } /** - * TableSpec groupedEntry. - * @member {string} groupedEntry - * @memberof google.cloud.datacatalog.v1.TableSpec + * SystemTimestamps createTime. + * @member {google.protobuf.ITimestamp|null|undefined} createTime + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @instance */ - TableSpec.prototype.groupedEntry = ""; + SystemTimestamps.prototype.createTime = null; /** - * Creates a new TableSpec instance using the specified properties. + * SystemTimestamps updateTime. + * @member {google.protobuf.ITimestamp|null|undefined} updateTime + * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * @instance + */ + SystemTimestamps.prototype.updateTime = null; + + /** + * SystemTimestamps expireTime. + * @member {google.protobuf.ITimestamp|null|undefined} expireTime + * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * @instance + */ + SystemTimestamps.prototype.expireTime = null; + + /** + * Creates a new SystemTimestamps instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static - * @param {google.cloud.datacatalog.v1.ITableSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec instance + * @param {google.cloud.datacatalog.v1.ISystemTimestamps=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps instance */ - TableSpec.create = function create(properties) { - return new TableSpec(properties); + SystemTimestamps.create = function create(properties) { + return new SystemTimestamps(properties); }; /** - * Encodes the specified TableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.TableSpec.verify|verify} messages. + * Encodes the specified SystemTimestamps message. Does not implicitly {@link google.cloud.datacatalog.v1.SystemTimestamps.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static - * @param {google.cloud.datacatalog.v1.ITableSpec} message TableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISystemTimestamps} message SystemTimestamps message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TableSpec.encode = function encode(message, writer) { + SystemTimestamps.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.groupedEntry != null && Object.hasOwnProperty.call(message, "groupedEntry")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.groupedEntry); + if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) + $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) + $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.expireTime != null && Object.hasOwnProperty.call(message, "expireTime")) + $root.google.protobuf.Timestamp.encode(message.expireTime, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified TableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TableSpec.verify|verify} messages. + * Encodes the specified SystemTimestamps message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SystemTimestamps.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static - * @param {google.cloud.datacatalog.v1.ITableSpec} message TableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISystemTimestamps} message SystemTimestamps message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TableSpec.encodeDelimited = function encodeDelimited(message, writer) { + SystemTimestamps.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TableSpec message from the specified reader or buffer. + * Decodes a SystemTimestamps message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TableSpec.decode = function decode(reader, length) { + SystemTimestamps.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TableSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SystemTimestamps(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.groupedEntry = reader.string(); + message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 2: { + message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 3: { + message.expireTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); break; } default: @@ -20155,125 +21173,155 @@ }; /** - * Decodes a TableSpec message from the specified reader or buffer, length delimited. + * Decodes a SystemTimestamps message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TableSpec.decodeDelimited = function decodeDelimited(reader) { + SystemTimestamps.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TableSpec message. + * Verifies a SystemTimestamps message. * @function verify - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TableSpec.verify = function verify(message) { + SystemTimestamps.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) - if (!$util.isString(message.groupedEntry)) - return "groupedEntry: string expected"; + if (message.createTime != null && message.hasOwnProperty("createTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.createTime); + if (error) + return "createTime." + error; + } + if (message.updateTime != null && message.hasOwnProperty("updateTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.updateTime); + if (error) + return "updateTime." + error; + } + if (message.expireTime != null && message.hasOwnProperty("expireTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.expireTime); + if (error) + return "expireTime." + error; + } return null; }; /** - * Creates a TableSpec message from a plain object. Also converts values to their respective internal types. + * Creates a SystemTimestamps message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1.SystemTimestamps} SystemTimestamps */ - TableSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.TableSpec) + SystemTimestamps.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.SystemTimestamps) return object; - var message = new $root.google.cloud.datacatalog.v1.TableSpec(); - if (object.groupedEntry != null) - message.groupedEntry = String(object.groupedEntry); + var message = new $root.google.cloud.datacatalog.v1.SystemTimestamps(); + if (object.createTime != null) { + if (typeof object.createTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.createTime: object expected"); + message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); + } + if (object.updateTime != null) { + if (typeof object.updateTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.updateTime: object expected"); + message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); + } + if (object.expireTime != null) { + if (typeof object.expireTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SystemTimestamps.expireTime: object expected"); + message.expireTime = $root.google.protobuf.Timestamp.fromObject(object.expireTime); + } return message; }; /** - * Creates a plain object from a TableSpec message. Also converts values to other types if specified. + * Creates a plain object from a SystemTimestamps message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static - * @param {google.cloud.datacatalog.v1.TableSpec} message TableSpec + * @param {google.cloud.datacatalog.v1.SystemTimestamps} message SystemTimestamps * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TableSpec.toObject = function toObject(message, options) { + SystemTimestamps.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.groupedEntry = ""; - if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) - object.groupedEntry = message.groupedEntry; - return object; - }; - - /** - * Converts this TableSpec to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.TableSpec - * @instance - * @returns {Object.} JSON object - */ - TableSpec.prototype.toJSON = function toJSON() { + if (options.defaults) { + object.createTime = null; + object.updateTime = null; + object.expireTime = null; + } + if (message.createTime != null && message.hasOwnProperty("createTime")) + object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); + if (message.updateTime != null && message.hasOwnProperty("updateTime")) + object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); + if (message.expireTime != null && message.hasOwnProperty("expireTime")) + object.expireTime = $root.google.protobuf.Timestamp.toObject(message.expireTime, options); + return object; + }; + + /** + * Converts this SystemTimestamps to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.SystemTimestamps + * @instance + * @returns {Object.} JSON object + */ + SystemTimestamps.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TableSpec + * Gets the default type url for SystemTimestamps * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.TableSpec + * @memberof google.cloud.datacatalog.v1.SystemTimestamps * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SystemTimestamps.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.TableSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.SystemTimestamps"; }; - return TableSpec; + return SystemTimestamps; })(); - v1.BigQueryDateShardedSpec = (function() { + v1.Schema = (function() { /** - * Properties of a BigQueryDateShardedSpec. + * Properties of a Schema. * @memberof google.cloud.datacatalog.v1 - * @interface IBigQueryDateShardedSpec - * @property {string|null} [dataset] BigQueryDateShardedSpec dataset - * @property {string|null} [tablePrefix] BigQueryDateShardedSpec tablePrefix - * @property {number|Long|null} [shardCount] BigQueryDateShardedSpec shardCount - * @property {string|null} [latestShardResource] BigQueryDateShardedSpec latestShardResource + * @interface ISchema + * @property {Array.|null} [columns] Schema columns */ /** - * Constructs a new BigQueryDateShardedSpec. + * Constructs a new Schema. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a BigQueryDateShardedSpec. - * @implements IBigQueryDateShardedSpec + * @classdesc Represents a Schema. + * @implements ISchema * @constructor - * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ISchema=} [properties] Properties to set */ - function BigQueryDateShardedSpec(properties) { + function Schema(properties) { + this.columns = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20281,117 +21329,78 @@ } /** - * BigQueryDateShardedSpec dataset. - * @member {string} dataset - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec - * @instance - */ - BigQueryDateShardedSpec.prototype.dataset = ""; - - /** - * BigQueryDateShardedSpec tablePrefix. - * @member {string} tablePrefix - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec - * @instance - */ - BigQueryDateShardedSpec.prototype.tablePrefix = ""; - - /** - * BigQueryDateShardedSpec shardCount. - * @member {number|Long} shardCount - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec - * @instance - */ - BigQueryDateShardedSpec.prototype.shardCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; - - /** - * BigQueryDateShardedSpec latestShardResource. - * @member {string} latestShardResource - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * Schema columns. + * @member {Array.} columns + * @memberof google.cloud.datacatalog.v1.Schema * @instance */ - BigQueryDateShardedSpec.prototype.latestShardResource = ""; + Schema.prototype.columns = $util.emptyArray; /** - * Creates a new BigQueryDateShardedSpec instance using the specified properties. + * Creates a new Schema instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static - * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec instance + * @param {google.cloud.datacatalog.v1.ISchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.Schema} Schema instance */ - BigQueryDateShardedSpec.create = function create(properties) { - return new BigQueryDateShardedSpec(properties); + Schema.create = function create(properties) { + return new Schema(properties); }; /** - * Encodes the specified BigQueryDateShardedSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryDateShardedSpec.verify|verify} messages. + * Encodes the specified Schema message. Does not implicitly {@link google.cloud.datacatalog.v1.Schema.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static - * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISchema} message Schema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryDateShardedSpec.encode = function encode(message, writer) { + Schema.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.dataset != null && Object.hasOwnProperty.call(message, "dataset")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.dataset); - if (message.tablePrefix != null && Object.hasOwnProperty.call(message, "tablePrefix")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.tablePrefix); - if (message.shardCount != null && Object.hasOwnProperty.call(message, "shardCount")) - writer.uint32(/* id 3, wireType 0 =*/24).int64(message.shardCount); - if (message.latestShardResource != null && Object.hasOwnProperty.call(message, "latestShardResource")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.latestShardResource); + if (message.columns != null && message.columns.length) + for (var i = 0; i < message.columns.length; ++i) + $root.google.cloud.datacatalog.v1.ColumnSchema.encode(message.columns[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified BigQueryDateShardedSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryDateShardedSpec.verify|verify} messages. + * Encodes the specified Schema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Schema.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static - * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISchema} message Schema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryDateShardedSpec.encodeDelimited = function encodeDelimited(message, writer) { + Schema.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer. + * Decodes a Schema message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1.Schema} Schema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryDateShardedSpec.decode = function decode(reader, length) { + Schema.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Schema(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.dataset = reader.string(); - break; - } case 2: { - message.tablePrefix = reader.string(); - break; - } - case 3: { - message.shardCount = reader.int64(); - break; - } - case 4: { - message.latestShardResource = reader.string(); + if (!(message.columns && message.columns.length)) + message.columns = []; + message.columns.push($root.google.cloud.datacatalog.v1.ColumnSchema.decode(reader, reader.uint32())); break; } default: @@ -20403,166 +21412,149 @@ }; /** - * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer, length delimited. + * Decodes a Schema message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1.Schema} Schema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryDateShardedSpec.decodeDelimited = function decodeDelimited(reader) { + Schema.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a BigQueryDateShardedSpec message. + * Verifies a Schema message. * @function verify - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - BigQueryDateShardedSpec.verify = function verify(message) { + Schema.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.dataset != null && message.hasOwnProperty("dataset")) - if (!$util.isString(message.dataset)) - return "dataset: string expected"; - if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) - if (!$util.isString(message.tablePrefix)) - return "tablePrefix: string expected"; - if (message.shardCount != null && message.hasOwnProperty("shardCount")) - if (!$util.isInteger(message.shardCount) && !(message.shardCount && $util.isInteger(message.shardCount.low) && $util.isInteger(message.shardCount.high))) - return "shardCount: integer|Long expected"; - if (message.latestShardResource != null && message.hasOwnProperty("latestShardResource")) - if (!$util.isString(message.latestShardResource)) - return "latestShardResource: string expected"; + if (message.columns != null && message.hasOwnProperty("columns")) { + if (!Array.isArray(message.columns)) + return "columns: array expected"; + for (var i = 0; i < message.columns.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.ColumnSchema.verify(message.columns[i]); + if (error) + return "columns." + error; + } + } return null; }; /** - * Creates a BigQueryDateShardedSpec message from a plain object. Also converts values to their respective internal types. + * Creates a Schema message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1.Schema} Schema */ - BigQueryDateShardedSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec) + Schema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.Schema) return object; - var message = new $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec(); - if (object.dataset != null) - message.dataset = String(object.dataset); - if (object.tablePrefix != null) - message.tablePrefix = String(object.tablePrefix); - if (object.shardCount != null) - if ($util.Long) - (message.shardCount = $util.Long.fromValue(object.shardCount)).unsigned = false; - else if (typeof object.shardCount === "string") - message.shardCount = parseInt(object.shardCount, 10); - else if (typeof object.shardCount === "number") - message.shardCount = object.shardCount; - else if (typeof object.shardCount === "object") - message.shardCount = new $util.LongBits(object.shardCount.low >>> 0, object.shardCount.high >>> 0).toNumber(); - if (object.latestShardResource != null) - message.latestShardResource = String(object.latestShardResource); + var message = new $root.google.cloud.datacatalog.v1.Schema(); + if (object.columns) { + if (!Array.isArray(object.columns)) + throw TypeError(".google.cloud.datacatalog.v1.Schema.columns: array expected"); + message.columns = []; + for (var i = 0; i < object.columns.length; ++i) { + if (typeof object.columns[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Schema.columns: object expected"); + message.columns[i] = $root.google.cloud.datacatalog.v1.ColumnSchema.fromObject(object.columns[i]); + } + } return message; }; /** - * Creates a plain object from a BigQueryDateShardedSpec message. Also converts values to other types if specified. + * Creates a plain object from a Schema message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static - * @param {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} message BigQueryDateShardedSpec + * @param {google.cloud.datacatalog.v1.Schema} message Schema * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - BigQueryDateShardedSpec.toObject = function toObject(message, options) { + Schema.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.dataset = ""; - object.tablePrefix = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.shardCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.shardCount = options.longs === String ? "0" : 0; - object.latestShardResource = ""; + if (options.arrays || options.defaults) + object.columns = []; + if (message.columns && message.columns.length) { + object.columns = []; + for (var j = 0; j < message.columns.length; ++j) + object.columns[j] = $root.google.cloud.datacatalog.v1.ColumnSchema.toObject(message.columns[j], options); } - if (message.dataset != null && message.hasOwnProperty("dataset")) - object.dataset = message.dataset; - if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) - object.tablePrefix = message.tablePrefix; - if (message.shardCount != null && message.hasOwnProperty("shardCount")) - if (typeof message.shardCount === "number") - object.shardCount = options.longs === String ? String(message.shardCount) : message.shardCount; - else - object.shardCount = options.longs === String ? $util.Long.prototype.toString.call(message.shardCount) : options.longs === Number ? new $util.LongBits(message.shardCount.low >>> 0, message.shardCount.high >>> 0).toNumber() : message.shardCount; - if (message.latestShardResource != null && message.hasOwnProperty("latestShardResource")) - object.latestShardResource = message.latestShardResource; return object; }; /** - * Converts this BigQueryDateShardedSpec to JSON. + * Converts this Schema to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @instance * @returns {Object.} JSON object */ - BigQueryDateShardedSpec.prototype.toJSON = function toJSON() { + Schema.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for BigQueryDateShardedSpec + * Gets the default type url for Schema * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1.Schema * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - BigQueryDateShardedSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Schema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.BigQueryDateShardedSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.Schema"; }; - return BigQueryDateShardedSpec; + return Schema; })(); - v1.Tag = (function() { + v1.ColumnSchema = (function() { /** - * Properties of a Tag. + * Properties of a ColumnSchema. * @memberof google.cloud.datacatalog.v1 - * @interface ITag - * @property {string|null} [name] Tag name - * @property {string|null} [template] Tag template - * @property {string|null} [templateDisplayName] Tag templateDisplayName - * @property {string|null} [column] Tag column - * @property {Object.|null} [fields] Tag fields + * @interface IColumnSchema + * @property {string|null} [column] ColumnSchema column + * @property {string|null} [type] ColumnSchema type + * @property {string|null} [description] ColumnSchema description + * @property {string|null} [mode] ColumnSchema mode + * @property {string|null} [defaultValue] ColumnSchema defaultValue + * @property {number|null} [ordinalPosition] ColumnSchema ordinalPosition + * @property {google.cloud.datacatalog.v1.ColumnSchema.IndexingType|null} [highestIndexingType] ColumnSchema highestIndexingType + * @property {Array.|null} [subcolumns] ColumnSchema subcolumns + * @property {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec|null} [lookerColumnSpec] ColumnSchema lookerColumnSpec + * @property {string|null} [gcRule] ColumnSchema gcRule */ /** - * Constructs a new Tag. + * Constructs a new ColumnSchema. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a Tag. - * @implements ITag + * @classdesc Represents a ColumnSchema. + * @implements IColumnSchema * @constructor - * @param {google.cloud.datacatalog.v1.ITag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IColumnSchema=} [properties] Properties to set */ - function Tag(properties) { - this.fields = {}; + function ColumnSchema(properties) { + this.subcolumns = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20570,167 +21562,218 @@ } /** - * Tag name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema column. + * @member {string} column + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Tag.prototype.name = ""; + ColumnSchema.prototype.column = ""; /** - * Tag template. - * @member {string} template - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema type. + * @member {string} type + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Tag.prototype.template = ""; + ColumnSchema.prototype.type = ""; /** - * Tag templateDisplayName. - * @member {string} templateDisplayName - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Tag.prototype.templateDisplayName = ""; + ColumnSchema.prototype.description = ""; /** - * Tag column. - * @member {string|null|undefined} column - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema mode. + * @member {string} mode + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Tag.prototype.column = null; + ColumnSchema.prototype.mode = ""; /** - * Tag fields. - * @member {Object.} fields - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema defaultValue. + * @member {string} defaultValue + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Tag.prototype.fields = $util.emptyObject; + ColumnSchema.prototype.defaultValue = ""; + + /** + * ColumnSchema ordinalPosition. + * @member {number} ordinalPosition + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @instance + */ + ColumnSchema.prototype.ordinalPosition = 0; + + /** + * ColumnSchema highestIndexingType. + * @member {google.cloud.datacatalog.v1.ColumnSchema.IndexingType} highestIndexingType + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @instance + */ + ColumnSchema.prototype.highestIndexingType = 0; + + /** + * ColumnSchema subcolumns. + * @member {Array.} subcolumns + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @instance + */ + ColumnSchema.prototype.subcolumns = $util.emptyArray; + + /** + * ColumnSchema lookerColumnSpec. + * @member {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec|null|undefined} lookerColumnSpec + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @instance + */ + ColumnSchema.prototype.lookerColumnSpec = null; + + /** + * ColumnSchema gcRule. + * @member {string} gcRule + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @instance + */ + ColumnSchema.prototype.gcRule = ""; // OneOf field names bound to virtual getters and setters var $oneOfFields; /** - * Tag scope. - * @member {"column"|undefined} scope - * @memberof google.cloud.datacatalog.v1.Tag + * ColumnSchema systemSpec. + * @member {"lookerColumnSpec"|undefined} systemSpec + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance */ - Object.defineProperty(Tag.prototype, "scope", { - get: $util.oneOfGetter($oneOfFields = ["column"]), + Object.defineProperty(ColumnSchema.prototype, "systemSpec", { + get: $util.oneOfGetter($oneOfFields = ["lookerColumnSpec"]), set: $util.oneOfSetter($oneOfFields) }); /** - * Creates a new Tag instance using the specified properties. + * Creates a new ColumnSchema instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static - * @param {google.cloud.datacatalog.v1.ITag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.Tag} Tag instance + * @param {google.cloud.datacatalog.v1.IColumnSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema instance */ - Tag.create = function create(properties) { - return new Tag(properties); + ColumnSchema.create = function create(properties) { + return new ColumnSchema(properties); }; /** - * Encodes the specified Tag message. Does not implicitly {@link google.cloud.datacatalog.v1.Tag.verify|verify} messages. + * Encodes the specified ColumnSchema message. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static - * @param {google.cloud.datacatalog.v1.ITag} message Tag message or plain object to encode + * @param {google.cloud.datacatalog.v1.IColumnSchema} message ColumnSchema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Tag.encode = function encode(message, writer) { + ColumnSchema.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.template != null && Object.hasOwnProperty.call(message, "template")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.template); - if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) - for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { - writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); - $root.google.cloud.datacatalog.v1.TagField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); - } + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); + if (message.mode != null && Object.hasOwnProperty.call(message, "mode")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.mode); if (message.column != null && Object.hasOwnProperty.call(message, "column")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.column); - if (message.templateDisplayName != null && Object.hasOwnProperty.call(message, "templateDisplayName")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.templateDisplayName); + writer.uint32(/* id 6, wireType 2 =*/50).string(message.column); + if (message.subcolumns != null && message.subcolumns.length) + for (var i = 0; i < message.subcolumns.length; ++i) + $root.google.cloud.datacatalog.v1.ColumnSchema.encode(message.subcolumns[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.defaultValue != null && Object.hasOwnProperty.call(message, "defaultValue")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.defaultValue); + if (message.ordinalPosition != null && Object.hasOwnProperty.call(message, "ordinalPosition")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.ordinalPosition); + if (message.highestIndexingType != null && Object.hasOwnProperty.call(message, "highestIndexingType")) + writer.uint32(/* id 10, wireType 0 =*/80).int32(message.highestIndexingType); + if (message.gcRule != null && Object.hasOwnProperty.call(message, "gcRule")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.gcRule); + if (message.lookerColumnSpec != null && Object.hasOwnProperty.call(message, "lookerColumnSpec")) + $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.encode(message.lookerColumnSpec, writer.uint32(/* id 18, wireType 2 =*/146).fork()).ldelim(); return writer; }; /** - * Encodes the specified Tag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Tag.verify|verify} messages. + * Encodes the specified ColumnSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static - * @param {google.cloud.datacatalog.v1.ITag} message Tag message or plain object to encode + * @param {google.cloud.datacatalog.v1.IColumnSchema} message ColumnSchema message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Tag.encodeDelimited = function encodeDelimited(message, writer) { + ColumnSchema.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Tag message from the specified reader or buffer. + * Decodes a ColumnSchema message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.Tag} Tag + * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Tag.decode = function decode(reader, length) { + ColumnSchema.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Tag(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ColumnSchema(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 6: { + message.column = reader.string(); + break; + } case 1: { - message.name = reader.string(); + message.type = reader.string(); break; } case 2: { - message.template = reader.string(); + message.description = reader.string(); break; } - case 5: { - message.templateDisplayName = reader.string(); + case 3: { + message.mode = reader.string(); break; } - case 4: { - message.column = reader.string(); + case 8: { + message.defaultValue = reader.string(); break; } - case 3: { - if (message.fields === $util.emptyObject) - message.fields = {}; - var end2 = reader.uint32() + reader.pos; - key = ""; - value = null; - while (reader.pos < end2) { - var tag2 = reader.uint32(); - switch (tag2 >>> 3) { - case 1: - key = reader.string(); - break; - case 2: - value = $root.google.cloud.datacatalog.v1.TagField.decode(reader, reader.uint32()); - break; - default: - reader.skipType(tag2 & 7); - break; - } - } - message.fields[key] = value; + case 9: { + message.ordinalPosition = reader.int32(); + break; + } + case 10: { + message.highestIndexingType = reader.int32(); + break; + } + case 7: { + if (!(message.subcolumns && message.subcolumns.length)) + message.subcolumns = []; + message.subcolumns.push($root.google.cloud.datacatalog.v1.ColumnSchema.decode(reader, reader.uint32())); + break; + } + case 18: { + message.lookerColumnSpec = $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.decode(reader, reader.uint32()); + break; + } + case 11: { + message.gcRule = reader.string(); break; } default: @@ -20742,187 +21785,551 @@ }; /** - * Decodes a Tag message from the specified reader or buffer, length delimited. + * Decodes a ColumnSchema message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.Tag} Tag + * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Tag.decodeDelimited = function decodeDelimited(reader) { + ColumnSchema.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Tag message. + * Verifies a ColumnSchema message. * @function verify - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Tag.verify = function verify(message) { + ColumnSchema.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; var properties = {}; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.template != null && message.hasOwnProperty("template")) - if (!$util.isString(message.template)) - return "template: string expected"; - if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) - if (!$util.isString(message.templateDisplayName)) - return "templateDisplayName: string expected"; - if (message.column != null && message.hasOwnProperty("column")) { - properties.scope = 1; + if (message.column != null && message.hasOwnProperty("column")) if (!$util.isString(message.column)) return "column: string expected"; - } - if (message.fields != null && message.hasOwnProperty("fields")) { - if (!$util.isObject(message.fields)) - return "fields: object expected"; - var key = Object.keys(message.fields); - for (var i = 0; i < key.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.TagField.verify(message.fields[key[i]]); + if (message.type != null && message.hasOwnProperty("type")) + if (!$util.isString(message.type)) + return "type: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.mode != null && message.hasOwnProperty("mode")) + if (!$util.isString(message.mode)) + return "mode: string expected"; + if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) + if (!$util.isString(message.defaultValue)) + return "defaultValue: string expected"; + if (message.ordinalPosition != null && message.hasOwnProperty("ordinalPosition")) + if (!$util.isInteger(message.ordinalPosition)) + return "ordinalPosition: integer expected"; + if (message.highestIndexingType != null && message.hasOwnProperty("highestIndexingType")) + switch (message.highestIndexingType) { + default: + return "highestIndexingType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + break; + } + if (message.subcolumns != null && message.hasOwnProperty("subcolumns")) { + if (!Array.isArray(message.subcolumns)) + return "subcolumns: array expected"; + for (var i = 0; i < message.subcolumns.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.ColumnSchema.verify(message.subcolumns[i]); if (error) - return "fields." + error; + return "subcolumns." + error; + } + } + if (message.lookerColumnSpec != null && message.hasOwnProperty("lookerColumnSpec")) { + properties.systemSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.verify(message.lookerColumnSpec); + if (error) + return "lookerColumnSpec." + error; } } + if (message.gcRule != null && message.hasOwnProperty("gcRule")) + if (!$util.isString(message.gcRule)) + return "gcRule: string expected"; return null; }; /** - * Creates a Tag message from a plain object. Also converts values to their respective internal types. + * Creates a ColumnSchema message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.Tag} Tag + * @returns {google.cloud.datacatalog.v1.ColumnSchema} ColumnSchema */ - Tag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.Tag) + ColumnSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ColumnSchema) return object; - var message = new $root.google.cloud.datacatalog.v1.Tag(); - if (object.name != null) - message.name = String(object.name); - if (object.template != null) - message.template = String(object.template); - if (object.templateDisplayName != null) - message.templateDisplayName = String(object.templateDisplayName); + var message = new $root.google.cloud.datacatalog.v1.ColumnSchema(); if (object.column != null) message.column = String(object.column); - if (object.fields) { - if (typeof object.fields !== "object") - throw TypeError(".google.cloud.datacatalog.v1.Tag.fields: object expected"); - message.fields = {}; - for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { - if (typeof object.fields[keys[i]] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.Tag.fields: object expected"); - message.fields[keys[i]] = $root.google.cloud.datacatalog.v1.TagField.fromObject(object.fields[keys[i]]); + if (object.type != null) + message.type = String(object.type); + if (object.description != null) + message.description = String(object.description); + if (object.mode != null) + message.mode = String(object.mode); + if (object.defaultValue != null) + message.defaultValue = String(object.defaultValue); + if (object.ordinalPosition != null) + message.ordinalPosition = object.ordinalPosition | 0; + switch (object.highestIndexingType) { + default: + if (typeof object.highestIndexingType === "number") { + message.highestIndexingType = object.highestIndexingType; + break; + } + break; + case "INDEXING_TYPE_UNSPECIFIED": + case 0: + message.highestIndexingType = 0; + break; + case "INDEXING_TYPE_NONE": + case 1: + message.highestIndexingType = 1; + break; + case "INDEXING_TYPE_NON_UNIQUE": + case 2: + message.highestIndexingType = 2; + break; + case "INDEXING_TYPE_UNIQUE": + case 3: + message.highestIndexingType = 3; + break; + case "INDEXING_TYPE_PRIMARY_KEY": + case 4: + message.highestIndexingType = 4; + break; + } + if (object.subcolumns) { + if (!Array.isArray(object.subcolumns)) + throw TypeError(".google.cloud.datacatalog.v1.ColumnSchema.subcolumns: array expected"); + message.subcolumns = []; + for (var i = 0; i < object.subcolumns.length; ++i) { + if (typeof object.subcolumns[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ColumnSchema.subcolumns: object expected"); + message.subcolumns[i] = $root.google.cloud.datacatalog.v1.ColumnSchema.fromObject(object.subcolumns[i]); } } + if (object.lookerColumnSpec != null) { + if (typeof object.lookerColumnSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ColumnSchema.lookerColumnSpec: object expected"); + message.lookerColumnSpec = $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.fromObject(object.lookerColumnSpec); + } + if (object.gcRule != null) + message.gcRule = String(object.gcRule); return message; }; /** - * Creates a plain object from a Tag message. Also converts values to other types if specified. + * Creates a plain object from a ColumnSchema message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static - * @param {google.cloud.datacatalog.v1.Tag} message Tag + * @param {google.cloud.datacatalog.v1.ColumnSchema} message ColumnSchema * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Tag.toObject = function toObject(message, options) { + ColumnSchema.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.objects || options.defaults) - object.fields = {}; + if (options.arrays || options.defaults) + object.subcolumns = []; if (options.defaults) { - object.name = ""; - object.template = ""; - object.templateDisplayName = ""; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.template != null && message.hasOwnProperty("template")) - object.template = message.template; - var keys2; - if (message.fields && (keys2 = Object.keys(message.fields)).length) { - object.fields = {}; - for (var j = 0; j < keys2.length; ++j) - object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1.TagField.toObject(message.fields[keys2[j]], options); + object.type = ""; + object.description = ""; + object.mode = ""; + object.column = ""; + object.defaultValue = ""; + object.ordinalPosition = 0; + object.highestIndexingType = options.enums === String ? "INDEXING_TYPE_UNSPECIFIED" : 0; + object.gcRule = ""; } - if (message.column != null && message.hasOwnProperty("column")) { + if (message.type != null && message.hasOwnProperty("type")) + object.type = message.type; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.mode != null && message.hasOwnProperty("mode")) + object.mode = message.mode; + if (message.column != null && message.hasOwnProperty("column")) object.column = message.column; + if (message.subcolumns && message.subcolumns.length) { + object.subcolumns = []; + for (var j = 0; j < message.subcolumns.length; ++j) + object.subcolumns[j] = $root.google.cloud.datacatalog.v1.ColumnSchema.toObject(message.subcolumns[j], options); + } + if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) + object.defaultValue = message.defaultValue; + if (message.ordinalPosition != null && message.hasOwnProperty("ordinalPosition")) + object.ordinalPosition = message.ordinalPosition; + if (message.highestIndexingType != null && message.hasOwnProperty("highestIndexingType")) + object.highestIndexingType = options.enums === String ? $root.google.cloud.datacatalog.v1.ColumnSchema.IndexingType[message.highestIndexingType] === undefined ? message.highestIndexingType : $root.google.cloud.datacatalog.v1.ColumnSchema.IndexingType[message.highestIndexingType] : message.highestIndexingType; + if (message.gcRule != null && message.hasOwnProperty("gcRule")) + object.gcRule = message.gcRule; + if (message.lookerColumnSpec != null && message.hasOwnProperty("lookerColumnSpec")) { + object.lookerColumnSpec = $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.toObject(message.lookerColumnSpec, options); if (options.oneofs) - object.scope = "column"; + object.systemSpec = "lookerColumnSpec"; } - if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) - object.templateDisplayName = message.templateDisplayName; return object; }; /** - * Converts this Tag to JSON. + * Converts this ColumnSchema to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @instance * @returns {Object.} JSON object */ - Tag.prototype.toJSON = function toJSON() { + ColumnSchema.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Tag + * Gets the default type url for ColumnSchema * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.Tag + * @memberof google.cloud.datacatalog.v1.ColumnSchema * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Tag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ColumnSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.Tag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ColumnSchema"; }; - return Tag; + /** + * IndexingType enum. + * @name google.cloud.datacatalog.v1.ColumnSchema.IndexingType + * @enum {number} + * @property {number} INDEXING_TYPE_UNSPECIFIED=0 INDEXING_TYPE_UNSPECIFIED value + * @property {number} INDEXING_TYPE_NONE=1 INDEXING_TYPE_NONE value + * @property {number} INDEXING_TYPE_NON_UNIQUE=2 INDEXING_TYPE_NON_UNIQUE value + * @property {number} INDEXING_TYPE_UNIQUE=3 INDEXING_TYPE_UNIQUE value + * @property {number} INDEXING_TYPE_PRIMARY_KEY=4 INDEXING_TYPE_PRIMARY_KEY value + */ + ColumnSchema.IndexingType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "INDEXING_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "INDEXING_TYPE_NONE"] = 1; + values[valuesById[2] = "INDEXING_TYPE_NON_UNIQUE"] = 2; + values[valuesById[3] = "INDEXING_TYPE_UNIQUE"] = 3; + values[valuesById[4] = "INDEXING_TYPE_PRIMARY_KEY"] = 4; + return values; + })(); + + ColumnSchema.LookerColumnSpec = (function() { + + /** + * Properties of a LookerColumnSpec. + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @interface ILookerColumnSpec + * @property {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType|null} [type] LookerColumnSpec type + */ + + /** + * Constructs a new LookerColumnSpec. + * @memberof google.cloud.datacatalog.v1.ColumnSchema + * @classdesc Represents a LookerColumnSpec. + * @implements ILookerColumnSpec + * @constructor + * @param {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec=} [properties] Properties to set + */ + function LookerColumnSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * LookerColumnSpec type. + * @member {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType} type + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @instance + */ + LookerColumnSpec.prototype.type = 0; + + /** + * Creates a new LookerColumnSpec instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec} LookerColumnSpec instance + */ + LookerColumnSpec.create = function create(properties) { + return new LookerColumnSpec(properties); + }; + + /** + * Encodes the specified LookerColumnSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec} message LookerColumnSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LookerColumnSpec.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.type); + return writer; + }; + + /** + * Encodes the specified LookerColumnSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {google.cloud.datacatalog.v1.ColumnSchema.ILookerColumnSpec} message LookerColumnSpec message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + LookerColumnSpec.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a LookerColumnSpec message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec} LookerColumnSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LookerColumnSpec.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.type = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a LookerColumnSpec message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec} LookerColumnSpec + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + LookerColumnSpec.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a LookerColumnSpec message. + * @function verify + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + LookerColumnSpec.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.type != null && message.hasOwnProperty("type")) + switch (message.type) { + default: + return "type: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + break; + } + return null; + }; + + /** + * Creates a LookerColumnSpec message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec} LookerColumnSpec + */ + LookerColumnSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec) + return object; + var message = new $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec(); + switch (object.type) { + default: + if (typeof object.type === "number") { + message.type = object.type; + break; + } + break; + case "LOOKER_COLUMN_TYPE_UNSPECIFIED": + case 0: + message.type = 0; + break; + case "DIMENSION": + case 1: + message.type = 1; + break; + case "DIMENSION_GROUP": + case 2: + message.type = 2; + break; + case "FILTER": + case 3: + message.type = 3; + break; + case "MEASURE": + case 4: + message.type = 4; + break; + case "PARAMETER": + case 5: + message.type = 5; + break; + } + return message; + }; + + /** + * Creates a plain object from a LookerColumnSpec message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec} message LookerColumnSpec + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + LookerColumnSpec.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.type = options.enums === String ? "LOOKER_COLUMN_TYPE_UNSPECIFIED" : 0; + if (message.type != null && message.hasOwnProperty("type")) + object.type = options.enums === String ? $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType[message.type] === undefined ? message.type : $root.google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType[message.type] : message.type; + return object; + }; + + /** + * Converts this LookerColumnSpec to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @instance + * @returns {Object.} JSON object + */ + LookerColumnSpec.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for LookerColumnSpec + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + LookerColumnSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec"; + }; + + /** + * LookerColumnType enum. + * @name google.cloud.datacatalog.v1.ColumnSchema.LookerColumnSpec.LookerColumnType + * @enum {number} + * @property {number} LOOKER_COLUMN_TYPE_UNSPECIFIED=0 LOOKER_COLUMN_TYPE_UNSPECIFIED value + * @property {number} DIMENSION=1 DIMENSION value + * @property {number} DIMENSION_GROUP=2 DIMENSION_GROUP value + * @property {number} FILTER=3 FILTER value + * @property {number} MEASURE=4 MEASURE value + * @property {number} PARAMETER=5 PARAMETER value + */ + LookerColumnSpec.LookerColumnType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "LOOKER_COLUMN_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "DIMENSION"] = 1; + values[valuesById[2] = "DIMENSION_GROUP"] = 2; + values[valuesById[3] = "FILTER"] = 3; + values[valuesById[4] = "MEASURE"] = 4; + values[valuesById[5] = "PARAMETER"] = 5; + return values; + })(); + + return LookerColumnSpec; + })(); + + return ColumnSchema; })(); - v1.TagField = (function() { + v1.SearchCatalogResult = (function() { /** - * Properties of a TagField. + * Properties of a SearchCatalogResult. * @memberof google.cloud.datacatalog.v1 - * @interface ITagField - * @property {string|null} [displayName] TagField displayName - * @property {number|null} [doubleValue] TagField doubleValue - * @property {string|null} [stringValue] TagField stringValue - * @property {boolean|null} [boolValue] TagField boolValue - * @property {google.protobuf.ITimestamp|null} [timestampValue] TagField timestampValue - * @property {google.cloud.datacatalog.v1.TagField.IEnumValue|null} [enumValue] TagField enumValue - * @property {string|null} [richtextValue] TagField richtextValue - * @property {number|null} [order] TagField order + * @interface ISearchCatalogResult + * @property {google.cloud.datacatalog.v1.SearchResultType|null} [searchResultType] SearchCatalogResult searchResultType + * @property {string|null} [searchResultSubtype] SearchCatalogResult searchResultSubtype + * @property {string|null} [relativeResourceName] SearchCatalogResult relativeResourceName + * @property {string|null} [linkedResource] SearchCatalogResult linkedResource + * @property {google.protobuf.ITimestamp|null} [modifyTime] SearchCatalogResult modifyTime + * @property {google.cloud.datacatalog.v1.IntegratedSystem|null} [integratedSystem] SearchCatalogResult integratedSystem + * @property {string|null} [userSpecifiedSystem] SearchCatalogResult userSpecifiedSystem + * @property {string|null} [fullyQualifiedName] SearchCatalogResult fullyQualifiedName + * @property {string|null} [displayName] SearchCatalogResult displayName + * @property {string|null} [description] SearchCatalogResult description */ /** - * Constructs a new TagField. + * Constructs a new SearchCatalogResult. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a TagField. - * @implements ITagField + * @classdesc Represents a SearchCatalogResult. + * @implements ISearchCatalogResult * @constructor - * @param {google.cloud.datacatalog.v1.ITagField=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ISearchCatalogResult=} [properties] Properties to set */ - function TagField(properties) { + function SearchCatalogResult(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -20930,187 +22337,215 @@ } /** - * TagField displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult searchResultType. + * @member {google.cloud.datacatalog.v1.SearchResultType} searchResultType + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.displayName = ""; + SearchCatalogResult.prototype.searchResultType = 0; /** - * TagField doubleValue. - * @member {number|null|undefined} doubleValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult searchResultSubtype. + * @member {string} searchResultSubtype + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.doubleValue = null; + SearchCatalogResult.prototype.searchResultSubtype = ""; /** - * TagField stringValue. - * @member {string|null|undefined} stringValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult relativeResourceName. + * @member {string} relativeResourceName + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.stringValue = null; + SearchCatalogResult.prototype.relativeResourceName = ""; /** - * TagField boolValue. - * @member {boolean|null|undefined} boolValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult linkedResource. + * @member {string} linkedResource + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.boolValue = null; + SearchCatalogResult.prototype.linkedResource = ""; /** - * TagField timestampValue. - * @member {google.protobuf.ITimestamp|null|undefined} timestampValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult modifyTime. + * @member {google.protobuf.ITimestamp|null|undefined} modifyTime + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.timestampValue = null; + SearchCatalogResult.prototype.modifyTime = null; /** - * TagField enumValue. - * @member {google.cloud.datacatalog.v1.TagField.IEnumValue|null|undefined} enumValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult integratedSystem. + * @member {google.cloud.datacatalog.v1.IntegratedSystem|null|undefined} integratedSystem + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.enumValue = null; + SearchCatalogResult.prototype.integratedSystem = null; /** - * TagField richtextValue. - * @member {string|null|undefined} richtextValue - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult userSpecifiedSystem. + * @member {string|null|undefined} userSpecifiedSystem + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.richtextValue = null; + SearchCatalogResult.prototype.userSpecifiedSystem = null; /** - * TagField order. - * @member {number} order - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult fullyQualifiedName. + * @member {string} fullyQualifiedName + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - TagField.prototype.order = 0; + SearchCatalogResult.prototype.fullyQualifiedName = ""; + + /** + * SearchCatalogResult displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult + * @instance + */ + SearchCatalogResult.prototype.displayName = ""; + + /** + * SearchCatalogResult description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult + * @instance + */ + SearchCatalogResult.prototype.description = ""; // OneOf field names bound to virtual getters and setters var $oneOfFields; /** - * TagField kind. - * @member {"doubleValue"|"stringValue"|"boolValue"|"timestampValue"|"enumValue"|"richtextValue"|undefined} kind - * @memberof google.cloud.datacatalog.v1.TagField + * SearchCatalogResult system. + * @member {"integratedSystem"|"userSpecifiedSystem"|undefined} system + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance */ - Object.defineProperty(TagField.prototype, "kind", { - get: $util.oneOfGetter($oneOfFields = ["doubleValue", "stringValue", "boolValue", "timestampValue", "enumValue", "richtextValue"]), + Object.defineProperty(SearchCatalogResult.prototype, "system", { + get: $util.oneOfGetter($oneOfFields = ["integratedSystem", "userSpecifiedSystem"]), set: $util.oneOfSetter($oneOfFields) }); /** - * Creates a new TagField instance using the specified properties. + * Creates a new SearchCatalogResult instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1.ITagField=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.TagField} TagField instance + * @param {google.cloud.datacatalog.v1.ISearchCatalogResult=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult instance */ - TagField.create = function create(properties) { - return new TagField(properties); + SearchCatalogResult.create = function create(properties) { + return new SearchCatalogResult(properties); }; /** - * Encodes the specified TagField message. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.verify|verify} messages. + * Encodes the specified SearchCatalogResult message. Does not implicitly {@link google.cloud.datacatalog.v1.SearchCatalogResult.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1.ITagField} message TagField message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagField.encode = function encode(message, writer) { + SearchCatalogResult.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); + if (message.searchResultType != null && Object.hasOwnProperty.call(message, "searchResultType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.searchResultType); + if (message.searchResultSubtype != null && Object.hasOwnProperty.call(message, "searchResultSubtype")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.searchResultSubtype); + if (message.relativeResourceName != null && Object.hasOwnProperty.call(message, "relativeResourceName")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.relativeResourceName); + if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.linkedResource); + if (message.modifyTime != null && Object.hasOwnProperty.call(message, "modifyTime")) + $root.google.protobuf.Timestamp.encode(message.modifyTime, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.integratedSystem != null && Object.hasOwnProperty.call(message, "integratedSystem")) + writer.uint32(/* id 8, wireType 0 =*/64).int32(message.integratedSystem); + if (message.userSpecifiedSystem != null && Object.hasOwnProperty.call(message, "userSpecifiedSystem")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.userSpecifiedSystem); + if (message.fullyQualifiedName != null && Object.hasOwnProperty.call(message, "fullyQualifiedName")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.fullyQualifiedName); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) - writer.uint32(/* id 2, wireType 1 =*/17).double(message.doubleValue); - if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.stringValue); - if (message.boolValue != null && Object.hasOwnProperty.call(message, "boolValue")) - writer.uint32(/* id 4, wireType 0 =*/32).bool(message.boolValue); - if (message.timestampValue != null && Object.hasOwnProperty.call(message, "timestampValue")) - $root.google.protobuf.Timestamp.encode(message.timestampValue, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.enumValue != null && Object.hasOwnProperty.call(message, "enumValue")) - $root.google.cloud.datacatalog.v1.TagField.EnumValue.encode(message.enumValue, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - if (message.order != null && Object.hasOwnProperty.call(message, "order")) - writer.uint32(/* id 7, wireType 0 =*/56).int32(message.order); - if (message.richtextValue != null && Object.hasOwnProperty.call(message, "richtextValue")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.richtextValue); + writer.uint32(/* id 12, wireType 2 =*/98).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 13, wireType 2 =*/106).string(message.description); return writer; }; /** - * Encodes the specified TagField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.verify|verify} messages. + * Encodes the specified SearchCatalogResult message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SearchCatalogResult.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1.ITagField} message TagField message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagField.encodeDelimited = function encodeDelimited(message, writer) { + SearchCatalogResult.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagField message from the specified reader or buffer. + * Decodes a SearchCatalogResult message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.TagField} TagField + * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagField.decode = function decode(reader, length) { + SearchCatalogResult.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagField(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SearchCatalogResult(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); + message.searchResultType = reader.int32(); break; } case 2: { - message.doubleValue = reader.double(); + message.searchResultSubtype = reader.string(); break; } case 3: { - message.stringValue = reader.string(); + message.relativeResourceName = reader.string(); break; } case 4: { - message.boolValue = reader.bool(); + message.linkedResource = reader.string(); break; } - case 5: { - message.timestampValue = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + case 7: { + message.modifyTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); break; } - case 6: { - message.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.decode(reader, reader.uint32()); + case 8: { + message.integratedSystem = reader.int32(); break; } - case 8: { - message.richtextValue = reader.string(); + case 9: { + message.userSpecifiedSystem = reader.string(); break; } - case 7: { - message.order = reader.int32(); + case 10: { + message.fullyQualifiedName = reader.string(); + break; + } + case 12: { + message.displayName = reader.string(); + break; + } + case 13: { + message.description = reader.string(); break; } default: @@ -21122,573 +22557,422 @@ }; /** - * Decodes a TagField message from the specified reader or buffer, length delimited. + * Decodes a SearchCatalogResult message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.TagField} TagField + * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagField.decodeDelimited = function decodeDelimited(reader) { + SearchCatalogResult.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagField message. + * Verifies a SearchCatalogResult message. * @function verify - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagField.verify = function verify(message) { + SearchCatalogResult.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; var properties = {}; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { - properties.kind = 1; - if (typeof message.doubleValue !== "number") - return "doubleValue: number expected"; - } - if (message.stringValue != null && message.hasOwnProperty("stringValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - if (!$util.isString(message.stringValue)) - return "stringValue: string expected"; - } - if (message.boolValue != null && message.hasOwnProperty("boolValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - if (typeof message.boolValue !== "boolean") - return "boolValue: boolean expected"; - } - if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - { - var error = $root.google.protobuf.Timestamp.verify(message.timestampValue); - if (error) - return "timestampValue." + error; + if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) + switch (message.searchResultType) { + default: + return "searchResultType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + break; } + if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) + if (!$util.isString(message.searchResultSubtype)) + return "searchResultSubtype: string expected"; + if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) + if (!$util.isString(message.relativeResourceName)) + return "relativeResourceName: string expected"; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + if (!$util.isString(message.linkedResource)) + return "linkedResource: string expected"; + if (message.modifyTime != null && message.hasOwnProperty("modifyTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.modifyTime); + if (error) + return "modifyTime." + error; } - if (message.enumValue != null && message.hasOwnProperty("enumValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - { - var error = $root.google.cloud.datacatalog.v1.TagField.EnumValue.verify(message.enumValue); - if (error) - return "enumValue." + error; + if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { + properties.system = 1; + switch (message.integratedSystem) { + default: + return "integratedSystem: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 8: + case 9: + break; } } - if (message.richtextValue != null && message.hasOwnProperty("richtextValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - if (!$util.isString(message.richtextValue)) - return "richtextValue: string expected"; + if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { + if (properties.system === 1) + return "system: multiple values"; + properties.system = 1; + if (!$util.isString(message.userSpecifiedSystem)) + return "userSpecifiedSystem: string expected"; } - if (message.order != null && message.hasOwnProperty("order")) - if (!$util.isInteger(message.order)) - return "order: integer expected"; + if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) + if (!$util.isString(message.fullyQualifiedName)) + return "fullyQualifiedName: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; return null; }; /** - * Creates a TagField message from a plain object. Also converts values to their respective internal types. + * Creates a SearchCatalogResult message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.TagField} TagField + * @returns {google.cloud.datacatalog.v1.SearchCatalogResult} SearchCatalogResult */ - TagField.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.TagField) + SearchCatalogResult.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.SearchCatalogResult) return object; - var message = new $root.google.cloud.datacatalog.v1.TagField(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.doubleValue != null) - message.doubleValue = Number(object.doubleValue); - if (object.stringValue != null) - message.stringValue = String(object.stringValue); - if (object.boolValue != null) - message.boolValue = Boolean(object.boolValue); - if (object.timestampValue != null) { - if (typeof object.timestampValue !== "object") - throw TypeError(".google.cloud.datacatalog.v1.TagField.timestampValue: object expected"); - message.timestampValue = $root.google.protobuf.Timestamp.fromObject(object.timestampValue); + var message = new $root.google.cloud.datacatalog.v1.SearchCatalogResult(); + switch (object.searchResultType) { + default: + if (typeof object.searchResultType === "number") { + message.searchResultType = object.searchResultType; + break; + } + break; + case "SEARCH_RESULT_TYPE_UNSPECIFIED": + case 0: + message.searchResultType = 0; + break; + case "ENTRY": + case 1: + message.searchResultType = 1; + break; + case "TAG_TEMPLATE": + case 2: + message.searchResultType = 2; + break; + case "ENTRY_GROUP": + case 3: + message.searchResultType = 3; + break; } - if (object.enumValue != null) { - if (typeof object.enumValue !== "object") - throw TypeError(".google.cloud.datacatalog.v1.TagField.enumValue: object expected"); - message.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.fromObject(object.enumValue); + if (object.searchResultSubtype != null) + message.searchResultSubtype = String(object.searchResultSubtype); + if (object.relativeResourceName != null) + message.relativeResourceName = String(object.relativeResourceName); + if (object.linkedResource != null) + message.linkedResource = String(object.linkedResource); + if (object.modifyTime != null) { + if (typeof object.modifyTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SearchCatalogResult.modifyTime: object expected"); + message.modifyTime = $root.google.protobuf.Timestamp.fromObject(object.modifyTime); } - if (object.richtextValue != null) - message.richtextValue = String(object.richtextValue); - if (object.order != null) - message.order = object.order | 0; + switch (object.integratedSystem) { + default: + if (typeof object.integratedSystem === "number") { + message.integratedSystem = object.integratedSystem; + break; + } + break; + case "INTEGRATED_SYSTEM_UNSPECIFIED": + case 0: + message.integratedSystem = 0; + break; + case "BIGQUERY": + case 1: + message.integratedSystem = 1; + break; + case "CLOUD_PUBSUB": + case 2: + message.integratedSystem = 2; + break; + case "DATAPROC_METASTORE": + case 3: + message.integratedSystem = 3; + break; + case "DATAPLEX": + case 4: + message.integratedSystem = 4; + break; + case "CLOUD_SQL": + case 8: + message.integratedSystem = 8; + break; + case "LOOKER": + case 9: + message.integratedSystem = 9; + break; + } + if (object.userSpecifiedSystem != null) + message.userSpecifiedSystem = String(object.userSpecifiedSystem); + if (object.fullyQualifiedName != null) + message.fullyQualifiedName = String(object.fullyQualifiedName); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); return message; }; /** - * Creates a plain object from a TagField message. Also converts values to other types if specified. + * Creates a plain object from a SearchCatalogResult message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1.TagField} message TagField + * @param {google.cloud.datacatalog.v1.SearchCatalogResult} message SearchCatalogResult * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagField.toObject = function toObject(message, options) { + SearchCatalogResult.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { + object.searchResultType = options.enums === String ? "SEARCH_RESULT_TYPE_UNSPECIFIED" : 0; + object.searchResultSubtype = ""; + object.relativeResourceName = ""; + object.linkedResource = ""; + object.modifyTime = null; + object.fullyQualifiedName = ""; object.displayName = ""; - object.order = 0; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { - object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; - if (options.oneofs) - object.kind = "doubleValue"; - } - if (message.stringValue != null && message.hasOwnProperty("stringValue")) { - object.stringValue = message.stringValue; - if (options.oneofs) - object.kind = "stringValue"; - } - if (message.boolValue != null && message.hasOwnProperty("boolValue")) { - object.boolValue = message.boolValue; - if (options.oneofs) - object.kind = "boolValue"; - } - if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { - object.timestampValue = $root.google.protobuf.Timestamp.toObject(message.timestampValue, options); - if (options.oneofs) - object.kind = "timestampValue"; + object.description = ""; } - if (message.enumValue != null && message.hasOwnProperty("enumValue")) { - object.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.toObject(message.enumValue, options); + if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) + object.searchResultType = options.enums === String ? $root.google.cloud.datacatalog.v1.SearchResultType[message.searchResultType] === undefined ? message.searchResultType : $root.google.cloud.datacatalog.v1.SearchResultType[message.searchResultType] : message.searchResultType; + if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) + object.searchResultSubtype = message.searchResultSubtype; + if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) + object.relativeResourceName = message.relativeResourceName; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + object.linkedResource = message.linkedResource; + if (message.modifyTime != null && message.hasOwnProperty("modifyTime")) + object.modifyTime = $root.google.protobuf.Timestamp.toObject(message.modifyTime, options); + if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { + object.integratedSystem = options.enums === String ? $root.google.cloud.datacatalog.v1.IntegratedSystem[message.integratedSystem] === undefined ? message.integratedSystem : $root.google.cloud.datacatalog.v1.IntegratedSystem[message.integratedSystem] : message.integratedSystem; if (options.oneofs) - object.kind = "enumValue"; + object.system = "integratedSystem"; } - if (message.order != null && message.hasOwnProperty("order")) - object.order = message.order; - if (message.richtextValue != null && message.hasOwnProperty("richtextValue")) { - object.richtextValue = message.richtextValue; + if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { + object.userSpecifiedSystem = message.userSpecifiedSystem; if (options.oneofs) - object.kind = "richtextValue"; + object.system = "userSpecifiedSystem"; } + if (message.fullyQualifiedName != null && message.hasOwnProperty("fullyQualifiedName")) + object.fullyQualifiedName = message.fullyQualifiedName; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; return object; }; /** - * Converts this TagField to JSON. + * Converts this SearchCatalogResult to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @instance * @returns {Object.} JSON object */ - TagField.prototype.toJSON = function toJSON() { + SearchCatalogResult.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagField + * Gets the default type url for SearchCatalogResult * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.TagField + * @memberof google.cloud.datacatalog.v1.SearchCatalogResult * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SearchCatalogResult.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagField"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.SearchCatalogResult"; }; - TagField.EnumValue = (function() { + return SearchCatalogResult; + })(); - /** - * Properties of an EnumValue. - * @memberof google.cloud.datacatalog.v1.TagField - * @interface IEnumValue - * @property {string|null} [displayName] EnumValue displayName - */ + /** + * SearchResultType enum. + * @name google.cloud.datacatalog.v1.SearchResultType + * @enum {number} + * @property {number} SEARCH_RESULT_TYPE_UNSPECIFIED=0 SEARCH_RESULT_TYPE_UNSPECIFIED value + * @property {number} ENTRY=1 ENTRY value + * @property {number} TAG_TEMPLATE=2 TAG_TEMPLATE value + * @property {number} ENTRY_GROUP=3 ENTRY_GROUP value + */ + v1.SearchResultType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "SEARCH_RESULT_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "ENTRY"] = 1; + values[valuesById[2] = "TAG_TEMPLATE"] = 2; + values[valuesById[3] = "ENTRY_GROUP"] = 3; + return values; + })(); - /** - * Constructs a new EnumValue. - * @memberof google.cloud.datacatalog.v1.TagField - * @classdesc Represents an EnumValue. - * @implements IEnumValue - * @constructor - * @param {google.cloud.datacatalog.v1.TagField.IEnumValue=} [properties] Properties to set - */ - function EnumValue(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + v1.BigQueryTableSpec = (function() { - /** - * EnumValue displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @instance - */ - EnumValue.prototype.displayName = ""; + /** + * Properties of a BigQueryTableSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface IBigQueryTableSpec + * @property {google.cloud.datacatalog.v1.TableSourceType|null} [tableSourceType] BigQueryTableSpec tableSourceType + * @property {google.cloud.datacatalog.v1.IViewSpec|null} [viewSpec] BigQueryTableSpec viewSpec + * @property {google.cloud.datacatalog.v1.ITableSpec|null} [tableSpec] BigQueryTableSpec tableSpec + */ - /** - * Creates a new EnumValue instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.TagField.IEnumValue=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue instance - */ - EnumValue.create = function create(properties) { - return new EnumValue(properties); - }; + /** + * Constructs a new BigQueryTableSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a BigQueryTableSpec. + * @implements IBigQueryTableSpec + * @constructor + * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec=} [properties] Properties to set + */ + function BigQueryTableSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.EnumValue.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.TagField.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - return writer; - }; + /** + * BigQueryTableSpec tableSourceType. + * @member {google.cloud.datacatalog.v1.TableSourceType} tableSourceType + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @instance + */ + BigQueryTableSpec.prototype.tableSourceType = 0; - /** - * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.EnumValue.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.TagField.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * BigQueryTableSpec viewSpec. + * @member {google.cloud.datacatalog.v1.IViewSpec|null|undefined} viewSpec + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @instance + */ + BigQueryTableSpec.prototype.viewSpec = null; - /** - * Decodes an EnumValue message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagField.EnumValue(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * BigQueryTableSpec tableSpec. + * @member {google.cloud.datacatalog.v1.ITableSpec|null|undefined} tableSpec + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec + * @instance + */ + BigQueryTableSpec.prototype.tableSpec = null; - /** - * Decodes an EnumValue message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValue message. - * @function verify - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValue.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - return null; - }; - - /** - * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue - */ - EnumValue.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.TagField.EnumValue) - return object; - var message = new $root.google.cloud.datacatalog.v1.TagField.EnumValue(); - if (object.displayName != null) - message.displayName = String(object.displayName); - return message; - }; - - /** - * Creates a plain object from an EnumValue message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.TagField.EnumValue} message EnumValue - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValue.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.displayName = ""; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - return object; - }; - - /** - * Converts this EnumValue to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @instance - * @returns {Object.} JSON object - */ - EnumValue.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValue - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.TagField.EnumValue - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagField.EnumValue"; - }; - - return EnumValue; - })(); - - return TagField; - })(); - - v1.TagTemplate = (function() { - - /** - * Properties of a TagTemplate. - * @memberof google.cloud.datacatalog.v1 - * @interface ITagTemplate - * @property {string|null} [name] TagTemplate name - * @property {string|null} [displayName] TagTemplate displayName - * @property {boolean|null} [isPubliclyReadable] TagTemplate isPubliclyReadable - * @property {Object.|null} [fields] TagTemplate fields - */ - - /** - * Constructs a new TagTemplate. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a TagTemplate. - * @implements ITagTemplate - * @constructor - * @param {google.cloud.datacatalog.v1.ITagTemplate=} [properties] Properties to set - */ - function TagTemplate(properties) { - this.fields = {}; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * TagTemplate name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.TagTemplate - * @instance - */ - TagTemplate.prototype.name = ""; - - /** - * TagTemplate displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.TagTemplate - * @instance - */ - TagTemplate.prototype.displayName = ""; - - /** - * TagTemplate isPubliclyReadable. - * @member {boolean} isPubliclyReadable - * @memberof google.cloud.datacatalog.v1.TagTemplate - * @instance - */ - TagTemplate.prototype.isPubliclyReadable = false; + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * TagTemplate fields. - * @member {Object.} fields - * @memberof google.cloud.datacatalog.v1.TagTemplate + * BigQueryTableSpec typeSpec. + * @member {"viewSpec"|"tableSpec"|undefined} typeSpec + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @instance */ - TagTemplate.prototype.fields = $util.emptyObject; + Object.defineProperty(BigQueryTableSpec.prototype, "typeSpec", { + get: $util.oneOfGetter($oneOfFields = ["viewSpec", "tableSpec"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new TagTemplate instance using the specified properties. + * Creates a new BigQueryTableSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplate=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate instance + * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec instance */ - TagTemplate.create = function create(properties) { - return new TagTemplate(properties); + BigQueryTableSpec.create = function create(properties) { + return new BigQueryTableSpec(properties); }; /** - * Encodes the specified TagTemplate message. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplate.verify|verify} messages. + * Encodes the specified BigQueryTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryTableSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplate} message TagTemplate message or plain object to encode + * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplate.encode = function encode(message, writer) { + BigQueryTableSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) - for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { - writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); - $root.google.cloud.datacatalog.v1.TagTemplateField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); - } - if (message.isPubliclyReadable != null && Object.hasOwnProperty.call(message, "isPubliclyReadable")) - writer.uint32(/* id 5, wireType 0 =*/40).bool(message.isPubliclyReadable); + if (message.tableSourceType != null && Object.hasOwnProperty.call(message, "tableSourceType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.tableSourceType); + if (message.viewSpec != null && Object.hasOwnProperty.call(message, "viewSpec")) + $root.google.cloud.datacatalog.v1.ViewSpec.encode(message.viewSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.tableSpec != null && Object.hasOwnProperty.call(message, "tableSpec")) + $root.google.cloud.datacatalog.v1.TableSpec.encode(message.tableSpec, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified TagTemplate message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplate.verify|verify} messages. + * Encodes the specified BigQueryTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryTableSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplate} message TagTemplate message or plain object to encode + * @param {google.cloud.datacatalog.v1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplate.encodeDelimited = function encodeDelimited(message, writer) { + BigQueryTableSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagTemplate message from the specified reader or buffer. + * Decodes a BigQueryTableSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplate.decode = function decode(reader, length) { + BigQueryTableSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagTemplate(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.BigQueryTableSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.tableSourceType = reader.int32(); break; } case 2: { - message.displayName = reader.string(); - break; - } - case 5: { - message.isPubliclyReadable = reader.bool(); + message.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.decode(reader, reader.uint32()); break; } case 3: { - if (message.fields === $util.emptyObject) - message.fields = {}; - var end2 = reader.uint32() + reader.pos; - key = ""; - value = null; - while (reader.pos < end2) { - var tag2 = reader.uint32(); - switch (tag2 >>> 3) { - case 1: - key = reader.string(); - break; - case 2: - value = $root.google.cloud.datacatalog.v1.TagTemplateField.decode(reader, reader.uint32()); - break; - default: - reader.skipType(tag2 & 7); - break; - } - } - message.fields[key] = value; + message.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.decode(reader, reader.uint32()); break; } default: @@ -21700,172 +22984,208 @@ }; /** - * Decodes a TagTemplate message from the specified reader or buffer, length delimited. + * Decodes a BigQueryTableSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplate.decodeDelimited = function decodeDelimited(reader) { + BigQueryTableSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagTemplate message. + * Verifies a BigQueryTableSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagTemplate.verify = function verify(message) { + BigQueryTableSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.isPubliclyReadable != null && message.hasOwnProperty("isPubliclyReadable")) - if (typeof message.isPubliclyReadable !== "boolean") - return "isPubliclyReadable: boolean expected"; - if (message.fields != null && message.hasOwnProperty("fields")) { - if (!$util.isObject(message.fields)) - return "fields: object expected"; - var key = Object.keys(message.fields); - for (var i = 0; i < key.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.TagTemplateField.verify(message.fields[key[i]]); + var properties = {}; + if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) + switch (message.tableSourceType) { + default: + return "tableSourceType: enum value expected"; + case 0: + case 2: + case 5: + case 7: + break; + } + if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1.ViewSpec.verify(message.viewSpec); if (error) - return "fields." + error; + return "viewSpec." + error; + } + } + if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { + if (properties.typeSpec === 1) + return "typeSpec: multiple values"; + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1.TableSpec.verify(message.tableSpec); + if (error) + return "tableSpec." + error; } } return null; }; /** - * Creates a TagTemplate message from a plain object. Also converts values to their respective internal types. + * Creates a BigQueryTableSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1.BigQueryTableSpec} BigQueryTableSpec */ - TagTemplate.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.TagTemplate) + BigQueryTableSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.BigQueryTableSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.TagTemplate(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.isPubliclyReadable != null) - message.isPubliclyReadable = Boolean(object.isPubliclyReadable); - if (object.fields) { - if (typeof object.fields !== "object") - throw TypeError(".google.cloud.datacatalog.v1.TagTemplate.fields: object expected"); - message.fields = {}; - for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { - if (typeof object.fields[keys[i]] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.TagTemplate.fields: object expected"); - message.fields[keys[i]] = $root.google.cloud.datacatalog.v1.TagTemplateField.fromObject(object.fields[keys[i]]); + var message = new $root.google.cloud.datacatalog.v1.BigQueryTableSpec(); + switch (object.tableSourceType) { + default: + if (typeof object.tableSourceType === "number") { + message.tableSourceType = object.tableSourceType; + break; } + break; + case "TABLE_SOURCE_TYPE_UNSPECIFIED": + case 0: + message.tableSourceType = 0; + break; + case "BIGQUERY_VIEW": + case 2: + message.tableSourceType = 2; + break; + case "BIGQUERY_TABLE": + case 5: + message.tableSourceType = 5; + break; + case "BIGQUERY_MATERIALIZED_VIEW": + case 7: + message.tableSourceType = 7; + break; + } + if (object.viewSpec != null) { + if (typeof object.viewSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.BigQueryTableSpec.viewSpec: object expected"); + message.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.fromObject(object.viewSpec); + } + if (object.tableSpec != null) { + if (typeof object.tableSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1.BigQueryTableSpec.tableSpec: object expected"); + message.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.fromObject(object.tableSpec); } return message; }; /** - * Creates a plain object from a TagTemplate message. Also converts values to other types if specified. + * Creates a plain object from a BigQueryTableSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1.TagTemplate} message TagTemplate + * @param {google.cloud.datacatalog.v1.BigQueryTableSpec} message BigQueryTableSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagTemplate.toObject = function toObject(message, options) { + BigQueryTableSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.objects || options.defaults) - object.fields = {}; - if (options.defaults) { - object.name = ""; - object.displayName = ""; - object.isPubliclyReadable = false; + if (options.defaults) + object.tableSourceType = options.enums === String ? "TABLE_SOURCE_TYPE_UNSPECIFIED" : 0; + if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) + object.tableSourceType = options.enums === String ? $root.google.cloud.datacatalog.v1.TableSourceType[message.tableSourceType] === undefined ? message.tableSourceType : $root.google.cloud.datacatalog.v1.TableSourceType[message.tableSourceType] : message.tableSourceType; + if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { + object.viewSpec = $root.google.cloud.datacatalog.v1.ViewSpec.toObject(message.viewSpec, options); + if (options.oneofs) + object.typeSpec = "viewSpec"; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - var keys2; - if (message.fields && (keys2 = Object.keys(message.fields)).length) { - object.fields = {}; - for (var j = 0; j < keys2.length; ++j) - object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1.TagTemplateField.toObject(message.fields[keys2[j]], options); + if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { + object.tableSpec = $root.google.cloud.datacatalog.v1.TableSpec.toObject(message.tableSpec, options); + if (options.oneofs) + object.typeSpec = "tableSpec"; } - if (message.isPubliclyReadable != null && message.hasOwnProperty("isPubliclyReadable")) - object.isPubliclyReadable = message.isPubliclyReadable; return object; }; /** - * Converts this TagTemplate to JSON. + * Converts this BigQueryTableSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @instance * @returns {Object.} JSON object */ - TagTemplate.prototype.toJSON = function toJSON() { + BigQueryTableSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagTemplate + * Gets the default type url for BigQueryTableSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.TagTemplate + * @memberof google.cloud.datacatalog.v1.BigQueryTableSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagTemplate.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + BigQueryTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagTemplate"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.BigQueryTableSpec"; }; - return TagTemplate; + return BigQueryTableSpec; })(); - v1.TagTemplateField = (function() { + /** + * TableSourceType enum. + * @name google.cloud.datacatalog.v1.TableSourceType + * @enum {number} + * @property {number} TABLE_SOURCE_TYPE_UNSPECIFIED=0 TABLE_SOURCE_TYPE_UNSPECIFIED value + * @property {number} BIGQUERY_VIEW=2 BIGQUERY_VIEW value + * @property {number} BIGQUERY_TABLE=5 BIGQUERY_TABLE value + * @property {number} BIGQUERY_MATERIALIZED_VIEW=7 BIGQUERY_MATERIALIZED_VIEW value + */ + v1.TableSourceType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "TABLE_SOURCE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[2] = "BIGQUERY_VIEW"] = 2; + values[valuesById[5] = "BIGQUERY_TABLE"] = 5; + values[valuesById[7] = "BIGQUERY_MATERIALIZED_VIEW"] = 7; + return values; + })(); + + v1.ViewSpec = (function() { /** - * Properties of a TagTemplateField. + * Properties of a ViewSpec. * @memberof google.cloud.datacatalog.v1 - * @interface ITagTemplateField - * @property {string|null} [name] TagTemplateField name - * @property {string|null} [displayName] TagTemplateField displayName - * @property {google.cloud.datacatalog.v1.IFieldType|null} [type] TagTemplateField type - * @property {boolean|null} [isRequired] TagTemplateField isRequired - * @property {string|null} [description] TagTemplateField description - * @property {number|null} [order] TagTemplateField order + * @interface IViewSpec + * @property {string|null} [viewQuery] ViewSpec viewQuery */ /** - * Constructs a new TagTemplateField. + * Constructs a new ViewSpec. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a TagTemplateField. - * @implements ITagTemplateField + * @classdesc Represents a ViewSpec. + * @implements IViewSpec * @constructor - * @param {google.cloud.datacatalog.v1.ITagTemplateField=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IViewSpec=} [properties] Properties to set */ - function TagTemplateField(properties) { + function ViewSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -21873,145 +23193,75 @@ } /** - * TagTemplateField name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.name = ""; - - /** - * TagTemplateField displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.displayName = ""; - - /** - * TagTemplateField type. - * @member {google.cloud.datacatalog.v1.IFieldType|null|undefined} type - * @memberof google.cloud.datacatalog.v1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.type = null; - - /** - * TagTemplateField isRequired. - * @member {boolean} isRequired - * @memberof google.cloud.datacatalog.v1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.isRequired = false; - - /** - * TagTemplateField description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.description = ""; - - /** - * TagTemplateField order. - * @member {number} order - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * ViewSpec viewQuery. + * @member {string} viewQuery + * @memberof google.cloud.datacatalog.v1.ViewSpec * @instance */ - TagTemplateField.prototype.order = 0; + ViewSpec.prototype.viewQuery = ""; /** - * Creates a new TagTemplateField instance using the specified properties. + * Creates a new ViewSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplateField=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField instance + * @param {google.cloud.datacatalog.v1.IViewSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec instance */ - TagTemplateField.create = function create(properties) { - return new TagTemplateField(properties); + ViewSpec.create = function create(properties) { + return new ViewSpec(properties); }; /** - * Encodes the specified TagTemplateField message. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplateField.verify|verify} messages. + * Encodes the specified ViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.ViewSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplateField} message TagTemplateField message or plain object to encode + * @param {google.cloud.datacatalog.v1.IViewSpec} message ViewSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplateField.encode = function encode(message, writer) { + ViewSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - $root.google.cloud.datacatalog.v1.FieldType.encode(message.type, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.isRequired != null && Object.hasOwnProperty.call(message, "isRequired")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.isRequired); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.description); - if (message.order != null && Object.hasOwnProperty.call(message, "order")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.order); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.name); + if (message.viewQuery != null && Object.hasOwnProperty.call(message, "viewQuery")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.viewQuery); return writer; }; /** - * Encodes the specified TagTemplateField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplateField.verify|verify} messages. + * Encodes the specified ViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ViewSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1.ITagTemplateField} message TagTemplateField message or plain object to encode + * @param {google.cloud.datacatalog.v1.IViewSpec} message ViewSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplateField.encodeDelimited = function encodeDelimited(message, writer) { + ViewSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagTemplateField message from the specified reader or buffer. + * Decodes a ViewSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplateField.decode = function decode(reader, length) { + ViewSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagTemplateField(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ViewSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 6: { - message.name = reader.string(); - break; - } case 1: { - message.displayName = reader.string(); - break; - } - case 2: { - message.type = $root.google.cloud.datacatalog.v1.FieldType.decode(reader, reader.uint32()); - break; - } - case 3: { - message.isRequired = reader.bool(); - break; - } - case 4: { - message.description = reader.string(); - break; - } - case 5: { - message.order = reader.int32(); + message.viewQuery = reader.string(); break; } default: @@ -22023,169 +23273,122 @@ }; /** - * Decodes a TagTemplateField message from the specified reader or buffer, length delimited. + * Decodes a ViewSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplateField.decodeDelimited = function decodeDelimited(reader) { + ViewSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagTemplateField message. + * Verifies a ViewSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagTemplateField.verify = function verify(message) { + ViewSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.type != null && message.hasOwnProperty("type")) { - var error = $root.google.cloud.datacatalog.v1.FieldType.verify(message.type); - if (error) - return "type." + error; - } - if (message.isRequired != null && message.hasOwnProperty("isRequired")) - if (typeof message.isRequired !== "boolean") - return "isRequired: boolean expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.order != null && message.hasOwnProperty("order")) - if (!$util.isInteger(message.order)) - return "order: integer expected"; + if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) + if (!$util.isString(message.viewQuery)) + return "viewQuery: string expected"; return null; }; /** - * Creates a TagTemplateField message from a plain object. Also converts values to their respective internal types. + * Creates a ViewSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1.ViewSpec} ViewSpec */ - TagTemplateField.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.TagTemplateField) + ViewSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ViewSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.TagTemplateField(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.type != null) { - if (typeof object.type !== "object") - throw TypeError(".google.cloud.datacatalog.v1.TagTemplateField.type: object expected"); - message.type = $root.google.cloud.datacatalog.v1.FieldType.fromObject(object.type); - } - if (object.isRequired != null) - message.isRequired = Boolean(object.isRequired); - if (object.description != null) - message.description = String(object.description); - if (object.order != null) - message.order = object.order | 0; + var message = new $root.google.cloud.datacatalog.v1.ViewSpec(); + if (object.viewQuery != null) + message.viewQuery = String(object.viewQuery); return message; }; /** - * Creates a plain object from a TagTemplateField message. Also converts values to other types if specified. + * Creates a plain object from a ViewSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1.TagTemplateField} message TagTemplateField + * @param {google.cloud.datacatalog.v1.ViewSpec} message ViewSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagTemplateField.toObject = function toObject(message, options) { + ViewSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.displayName = ""; - object.type = null; - object.isRequired = false; - object.description = ""; - object.order = 0; - object.name = ""; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.type != null && message.hasOwnProperty("type")) - object.type = $root.google.cloud.datacatalog.v1.FieldType.toObject(message.type, options); - if (message.isRequired != null && message.hasOwnProperty("isRequired")) - object.isRequired = message.isRequired; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.order != null && message.hasOwnProperty("order")) - object.order = message.order; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (options.defaults) + object.viewQuery = ""; + if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) + object.viewQuery = message.viewQuery; return object; }; /** - * Converts this TagTemplateField to JSON. + * Converts this ViewSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @instance * @returns {Object.} JSON object */ - TagTemplateField.prototype.toJSON = function toJSON() { + ViewSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagTemplateField + * Gets the default type url for ViewSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @memberof google.cloud.datacatalog.v1.ViewSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagTemplateField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ViewSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagTemplateField"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ViewSpec"; }; - return TagTemplateField; + return ViewSpec; })(); - v1.FieldType = (function() { + v1.TableSpec = (function() { /** - * Properties of a FieldType. + * Properties of a TableSpec. * @memberof google.cloud.datacatalog.v1 - * @interface IFieldType - * @property {google.cloud.datacatalog.v1.FieldType.PrimitiveType|null} [primitiveType] FieldType primitiveType - * @property {google.cloud.datacatalog.v1.FieldType.IEnumType|null} [enumType] FieldType enumType + * @interface ITableSpec + * @property {string|null} [groupedEntry] TableSpec groupedEntry */ /** - * Constructs a new FieldType. + * Constructs a new TableSpec. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a FieldType. - * @implements IFieldType + * @classdesc Represents a TableSpec. + * @implements ITableSpec * @constructor - * @param {google.cloud.datacatalog.v1.IFieldType=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITableSpec=} [properties] Properties to set */ - function FieldType(properties) { + function TableSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -22193,103 +23396,75 @@ } /** - * FieldType primitiveType. - * @member {google.cloud.datacatalog.v1.FieldType.PrimitiveType|null|undefined} primitiveType - * @memberof google.cloud.datacatalog.v1.FieldType - * @instance - */ - FieldType.prototype.primitiveType = null; - - /** - * FieldType enumType. - * @member {google.cloud.datacatalog.v1.FieldType.IEnumType|null|undefined} enumType - * @memberof google.cloud.datacatalog.v1.FieldType - * @instance - */ - FieldType.prototype.enumType = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; - - /** - * FieldType typeDecl. - * @member {"primitiveType"|"enumType"|undefined} typeDecl - * @memberof google.cloud.datacatalog.v1.FieldType + * TableSpec groupedEntry. + * @member {string} groupedEntry + * @memberof google.cloud.datacatalog.v1.TableSpec * @instance */ - Object.defineProperty(FieldType.prototype, "typeDecl", { - get: $util.oneOfGetter($oneOfFields = ["primitiveType", "enumType"]), - set: $util.oneOfSetter($oneOfFields) - }); + TableSpec.prototype.groupedEntry = ""; /** - * Creates a new FieldType instance using the specified properties. + * Creates a new TableSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static - * @param {google.cloud.datacatalog.v1.IFieldType=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.FieldType} FieldType instance + * @param {google.cloud.datacatalog.v1.ITableSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec instance */ - FieldType.create = function create(properties) { - return new FieldType(properties); + TableSpec.create = function create(properties) { + return new TableSpec(properties); }; /** - * Encodes the specified FieldType message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.verify|verify} messages. + * Encodes the specified TableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.TableSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static - * @param {google.cloud.datacatalog.v1.IFieldType} message FieldType message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITableSpec} message TableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldType.encode = function encode(message, writer) { + TableSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.primitiveType != null && Object.hasOwnProperty.call(message, "primitiveType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.primitiveType); - if (message.enumType != null && Object.hasOwnProperty.call(message, "enumType")) - $root.google.cloud.datacatalog.v1.FieldType.EnumType.encode(message.enumType, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.groupedEntry != null && Object.hasOwnProperty.call(message, "groupedEntry")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.groupedEntry); return writer; }; /** - * Encodes the specified FieldType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.verify|verify} messages. + * Encodes the specified TableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TableSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static - * @param {google.cloud.datacatalog.v1.IFieldType} message FieldType message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITableSpec} message TableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldType.encodeDelimited = function encodeDelimited(message, writer) { + TableSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FieldType message from the specified reader or buffer. + * Decodes a TableSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldType.decode = function decode(reader, length) { + TableSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TableSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.primitiveType = reader.int32(); - break; - } - case 2: { - message.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.decode(reader, reader.uint32()); + message.groupedEntry = reader.string(); break; } default: @@ -22301,755 +23476,243 @@ }; /** - * Decodes a FieldType message from the specified reader or buffer, length delimited. + * Decodes a TableSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldType.decodeDelimited = function decodeDelimited(reader) { + TableSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FieldType message. + * Verifies a TableSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FieldType.verify = function verify(message) { + TableSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { - properties.typeDecl = 1; - switch (message.primitiveType) { - default: - return "primitiveType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - break; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (properties.typeDecl === 1) - return "typeDecl: multiple values"; - properties.typeDecl = 1; - { - var error = $root.google.cloud.datacatalog.v1.FieldType.EnumType.verify(message.enumType); - if (error) - return "enumType." + error; - } - } + if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) + if (!$util.isString(message.groupedEntry)) + return "groupedEntry: string expected"; return null; }; /** - * Creates a FieldType message from a plain object. Also converts values to their respective internal types. + * Creates a TableSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1.TableSpec} TableSpec */ - FieldType.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.FieldType) + TableSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TableSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.FieldType(); - switch (object.primitiveType) { - default: - if (typeof object.primitiveType === "number") { - message.primitiveType = object.primitiveType; - break; - } - break; - case "PRIMITIVE_TYPE_UNSPECIFIED": - case 0: - message.primitiveType = 0; - break; - case "DOUBLE": - case 1: - message.primitiveType = 1; - break; - case "STRING": - case 2: - message.primitiveType = 2; - break; - case "BOOL": - case 3: - message.primitiveType = 3; - break; - case "TIMESTAMP": - case 4: - message.primitiveType = 4; - break; - case "RICHTEXT": - case 5: - message.primitiveType = 5; - break; - } - if (object.enumType != null) { - if (typeof object.enumType !== "object") - throw TypeError(".google.cloud.datacatalog.v1.FieldType.enumType: object expected"); - message.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.fromObject(object.enumType); - } + var message = new $root.google.cloud.datacatalog.v1.TableSpec(); + if (object.groupedEntry != null) + message.groupedEntry = String(object.groupedEntry); return message; }; /** - * Creates a plain object from a FieldType message. Also converts values to other types if specified. + * Creates a plain object from a TableSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static - * @param {google.cloud.datacatalog.v1.FieldType} message FieldType + * @param {google.cloud.datacatalog.v1.TableSpec} message TableSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FieldType.toObject = function toObject(message, options) { + TableSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { - object.primitiveType = options.enums === String ? $root.google.cloud.datacatalog.v1.FieldType.PrimitiveType[message.primitiveType] === undefined ? message.primitiveType : $root.google.cloud.datacatalog.v1.FieldType.PrimitiveType[message.primitiveType] : message.primitiveType; - if (options.oneofs) - object.typeDecl = "primitiveType"; - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - object.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.toObject(message.enumType, options); - if (options.oneofs) - object.typeDecl = "enumType"; - } + if (options.defaults) + object.groupedEntry = ""; + if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) + object.groupedEntry = message.groupedEntry; return object; }; /** - * Converts this FieldType to JSON. + * Converts this TableSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @instance * @returns {Object.} JSON object */ - FieldType.prototype.toJSON = function toJSON() { + TableSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FieldType + * Gets the default type url for TableSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.FieldType + * @memberof google.cloud.datacatalog.v1.TableSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FieldType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TableSpec"; }; + return TableSpec; + })(); + + v1.BigQueryDateShardedSpec = (function() { + /** - * PrimitiveType enum. - * @name google.cloud.datacatalog.v1.FieldType.PrimitiveType - * @enum {number} - * @property {number} PRIMITIVE_TYPE_UNSPECIFIED=0 PRIMITIVE_TYPE_UNSPECIFIED value - * @property {number} DOUBLE=1 DOUBLE value - * @property {number} STRING=2 STRING value - * @property {number} BOOL=3 BOOL value - * @property {number} TIMESTAMP=4 TIMESTAMP value - * @property {number} RICHTEXT=5 RICHTEXT value + * Properties of a BigQueryDateShardedSpec. + * @memberof google.cloud.datacatalog.v1 + * @interface IBigQueryDateShardedSpec + * @property {string|null} [dataset] BigQueryDateShardedSpec dataset + * @property {string|null} [tablePrefix] BigQueryDateShardedSpec tablePrefix + * @property {number|Long|null} [shardCount] BigQueryDateShardedSpec shardCount + * @property {string|null} [latestShardResource] BigQueryDateShardedSpec latestShardResource */ - FieldType.PrimitiveType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "PRIMITIVE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "DOUBLE"] = 1; - values[valuesById[2] = "STRING"] = 2; - values[valuesById[3] = "BOOL"] = 3; - values[valuesById[4] = "TIMESTAMP"] = 4; - values[valuesById[5] = "RICHTEXT"] = 5; - return values; - })(); - FieldType.EnumType = (function() { + /** + * Constructs a new BigQueryDateShardedSpec. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a BigQueryDateShardedSpec. + * @implements IBigQueryDateShardedSpec + * @constructor + * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec=} [properties] Properties to set + */ + function BigQueryDateShardedSpec(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Properties of an EnumType. - * @memberof google.cloud.datacatalog.v1.FieldType - * @interface IEnumType - * @property {Array.|null} [allowedValues] EnumType allowedValues - */ + /** + * BigQueryDateShardedSpec dataset. + * @member {string} dataset + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @instance + */ + BigQueryDateShardedSpec.prototype.dataset = ""; - /** - * Constructs a new EnumType. - * @memberof google.cloud.datacatalog.v1.FieldType - * @classdesc Represents an EnumType. - * @implements IEnumType - * @constructor - * @param {google.cloud.datacatalog.v1.FieldType.IEnumType=} [properties] Properties to set - */ - function EnumType(properties) { - this.allowedValues = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * BigQueryDateShardedSpec tablePrefix. + * @member {string} tablePrefix + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @instance + */ + BigQueryDateShardedSpec.prototype.tablePrefix = ""; - /** - * EnumType allowedValues. - * @member {Array.} allowedValues - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @instance - */ - EnumType.prototype.allowedValues = $util.emptyArray; + /** + * BigQueryDateShardedSpec shardCount. + * @member {number|Long} shardCount + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @instance + */ + BigQueryDateShardedSpec.prototype.shardCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; - /** - * Creates a new EnumType instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1.FieldType.IEnumType=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType instance - */ - EnumType.create = function create(properties) { - return new EnumType(properties); - }; - - /** - * Encodes the specified EnumType message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1.FieldType.IEnumType} message EnumType message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumType.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.allowedValues != null && message.allowedValues.length) - for (var i = 0; i < message.allowedValues.length; ++i) - $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.encode(message.allowedValues[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - return writer; - }; - - /** - * Encodes the specified EnumType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1.FieldType.IEnumType} message EnumType message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumType.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumType message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumType.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.allowedValues && message.allowedValues.length)) - message.allowedValues = []; - message.allowedValues.push($root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumType message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumType.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumType message. - * @function verify - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumType.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.allowedValues != null && message.hasOwnProperty("allowedValues")) { - if (!Array.isArray(message.allowedValues)) - return "allowedValues: array expected"; - for (var i = 0; i < message.allowedValues.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify(message.allowedValues[i]); - if (error) - return "allowedValues." + error; - } - } - return null; - }; - - /** - * Creates an EnumType message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType - */ - EnumType.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.FieldType.EnumType) - return object; - var message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType(); - if (object.allowedValues) { - if (!Array.isArray(object.allowedValues)) - throw TypeError(".google.cloud.datacatalog.v1.FieldType.EnumType.allowedValues: array expected"); - message.allowedValues = []; - for (var i = 0; i < object.allowedValues.length; ++i) { - if (typeof object.allowedValues[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.FieldType.EnumType.allowedValues: object expected"); - message.allowedValues[i] = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.fromObject(object.allowedValues[i]); - } - } - return message; - }; - - /** - * Creates a plain object from an EnumType message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1.FieldType.EnumType} message EnumType - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumType.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.allowedValues = []; - if (message.allowedValues && message.allowedValues.length) { - object.allowedValues = []; - for (var j = 0; j < message.allowedValues.length; ++j) - object.allowedValues[j] = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.toObject(message.allowedValues[j], options); - } - return object; - }; - - /** - * Converts this EnumType to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @instance - * @returns {Object.} JSON object - */ - EnumType.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumType - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType.EnumType"; - }; - - EnumType.EnumValue = (function() { - - /** - * Properties of an EnumValue. - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @interface IEnumValue - * @property {string|null} [displayName] EnumValue displayName - */ - - /** - * Constructs a new EnumValue. - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType - * @classdesc Represents an EnumValue. - * @implements IEnumValue - * @constructor - * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue=} [properties] Properties to set - */ - function EnumValue(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * EnumValue displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @instance - */ - EnumValue.prototype.displayName = ""; - - /** - * Creates a new EnumValue instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue instance - */ - EnumValue.create = function create(properties) { - return new EnumValue(properties); - }; - - /** - * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - return writer; - }; - - /** - * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValue message. - * @function verify - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValue.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - return null; - }; - - /** - * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue - */ - EnumValue.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue) - return object; - var message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue(); - if (object.displayName != null) - message.displayName = String(object.displayName); - return message; - }; - - /** - * Creates a plain object from an EnumValue message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} message EnumValue - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValue.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.displayName = ""; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - return object; - }; - - /** - * Converts this EnumValue to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @instance - * @returns {Object.} JSON object - */ - EnumValue.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValue - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue"; - }; - - return EnumValue; - })(); - - return EnumType; - })(); - - return FieldType; - })(); - - v1.UsageStats = (function() { - - /** - * Properties of a UsageStats. - * @memberof google.cloud.datacatalog.v1 - * @interface IUsageStats - * @property {number|null} [totalCompletions] UsageStats totalCompletions - * @property {number|null} [totalFailures] UsageStats totalFailures - * @property {number|null} [totalCancellations] UsageStats totalCancellations - * @property {number|null} [totalExecutionTimeForCompletionsMillis] UsageStats totalExecutionTimeForCompletionsMillis - */ - - /** - * Constructs a new UsageStats. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a UsageStats. - * @implements IUsageStats - * @constructor - * @param {google.cloud.datacatalog.v1.IUsageStats=} [properties] Properties to set - */ - function UsageStats(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * UsageStats totalCompletions. - * @member {number} totalCompletions - * @memberof google.cloud.datacatalog.v1.UsageStats - * @instance - */ - UsageStats.prototype.totalCompletions = 0; - - /** - * UsageStats totalFailures. - * @member {number} totalFailures - * @memberof google.cloud.datacatalog.v1.UsageStats - * @instance - */ - UsageStats.prototype.totalFailures = 0; - - /** - * UsageStats totalCancellations. - * @member {number} totalCancellations - * @memberof google.cloud.datacatalog.v1.UsageStats - * @instance - */ - UsageStats.prototype.totalCancellations = 0; - - /** - * UsageStats totalExecutionTimeForCompletionsMillis. - * @member {number} totalExecutionTimeForCompletionsMillis - * @memberof google.cloud.datacatalog.v1.UsageStats - * @instance - */ - UsageStats.prototype.totalExecutionTimeForCompletionsMillis = 0; + /** + * BigQueryDateShardedSpec latestShardResource. + * @member {string} latestShardResource + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec + * @instance + */ + BigQueryDateShardedSpec.prototype.latestShardResource = ""; /** - * Creates a new UsageStats instance using the specified properties. + * Creates a new BigQueryDateShardedSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1.IUsageStats=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats instance + * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec instance */ - UsageStats.create = function create(properties) { - return new UsageStats(properties); + BigQueryDateShardedSpec.create = function create(properties) { + return new BigQueryDateShardedSpec(properties); }; /** - * Encodes the specified UsageStats message. Does not implicitly {@link google.cloud.datacatalog.v1.UsageStats.verify|verify} messages. + * Encodes the specified BigQueryDateShardedSpec message. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryDateShardedSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1.IUsageStats} message UsageStats message or plain object to encode + * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UsageStats.encode = function encode(message, writer) { + BigQueryDateShardedSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.totalCompletions != null && Object.hasOwnProperty.call(message, "totalCompletions")) - writer.uint32(/* id 1, wireType 5 =*/13).float(message.totalCompletions); - if (message.totalFailures != null && Object.hasOwnProperty.call(message, "totalFailures")) - writer.uint32(/* id 2, wireType 5 =*/21).float(message.totalFailures); - if (message.totalCancellations != null && Object.hasOwnProperty.call(message, "totalCancellations")) - writer.uint32(/* id 3, wireType 5 =*/29).float(message.totalCancellations); - if (message.totalExecutionTimeForCompletionsMillis != null && Object.hasOwnProperty.call(message, "totalExecutionTimeForCompletionsMillis")) - writer.uint32(/* id 4, wireType 5 =*/37).float(message.totalExecutionTimeForCompletionsMillis); + if (message.dataset != null && Object.hasOwnProperty.call(message, "dataset")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.dataset); + if (message.tablePrefix != null && Object.hasOwnProperty.call(message, "tablePrefix")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.tablePrefix); + if (message.shardCount != null && Object.hasOwnProperty.call(message, "shardCount")) + writer.uint32(/* id 3, wireType 0 =*/24).int64(message.shardCount); + if (message.latestShardResource != null && Object.hasOwnProperty.call(message, "latestShardResource")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.latestShardResource); return writer; }; /** - * Encodes the specified UsageStats message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UsageStats.verify|verify} messages. + * Encodes the specified BigQueryDateShardedSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.BigQueryDateShardedSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1.IUsageStats} message UsageStats message or plain object to encode + * @param {google.cloud.datacatalog.v1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UsageStats.encodeDelimited = function encodeDelimited(message, writer) { + BigQueryDateShardedSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a UsageStats message from the specified reader or buffer. + * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats + * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UsageStats.decode = function decode(reader, length) { + BigQueryDateShardedSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UsageStats(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.totalCompletions = reader.float(); + message.dataset = reader.string(); break; } case 2: { - message.totalFailures = reader.float(); + message.tablePrefix = reader.string(); break; } case 3: { - message.totalCancellations = reader.float(); + message.shardCount = reader.int64(); break; } case 4: { - message.totalExecutionTimeForCompletionsMillis = reader.float(); + message.latestShardResource = reader.string(); break; } default: @@ -23061,149 +23724,166 @@ }; /** - * Decodes a UsageStats message from the specified reader or buffer, length delimited. + * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats + * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UsageStats.decodeDelimited = function decodeDelimited(reader) { + BigQueryDateShardedSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a UsageStats message. + * Verifies a BigQueryDateShardedSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UsageStats.verify = function verify(message) { + BigQueryDateShardedSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.totalCompletions != null && message.hasOwnProperty("totalCompletions")) - if (typeof message.totalCompletions !== "number") - return "totalCompletions: number expected"; - if (message.totalFailures != null && message.hasOwnProperty("totalFailures")) - if (typeof message.totalFailures !== "number") - return "totalFailures: number expected"; - if (message.totalCancellations != null && message.hasOwnProperty("totalCancellations")) - if (typeof message.totalCancellations !== "number") - return "totalCancellations: number expected"; - if (message.totalExecutionTimeForCompletionsMillis != null && message.hasOwnProperty("totalExecutionTimeForCompletionsMillis")) - if (typeof message.totalExecutionTimeForCompletionsMillis !== "number") - return "totalExecutionTimeForCompletionsMillis: number expected"; + if (message.dataset != null && message.hasOwnProperty("dataset")) + if (!$util.isString(message.dataset)) + return "dataset: string expected"; + if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) + if (!$util.isString(message.tablePrefix)) + return "tablePrefix: string expected"; + if (message.shardCount != null && message.hasOwnProperty("shardCount")) + if (!$util.isInteger(message.shardCount) && !(message.shardCount && $util.isInteger(message.shardCount.low) && $util.isInteger(message.shardCount.high))) + return "shardCount: integer|Long expected"; + if (message.latestShardResource != null && message.hasOwnProperty("latestShardResource")) + if (!$util.isString(message.latestShardResource)) + return "latestShardResource: string expected"; return null; }; /** - * Creates a UsageStats message from a plain object. Also converts values to their respective internal types. + * Creates a BigQueryDateShardedSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats + * @returns {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} BigQueryDateShardedSpec */ - UsageStats.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UsageStats) + BigQueryDateShardedSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec) return object; - var message = new $root.google.cloud.datacatalog.v1.UsageStats(); - if (object.totalCompletions != null) - message.totalCompletions = Number(object.totalCompletions); - if (object.totalFailures != null) - message.totalFailures = Number(object.totalFailures); - if (object.totalCancellations != null) - message.totalCancellations = Number(object.totalCancellations); - if (object.totalExecutionTimeForCompletionsMillis != null) - message.totalExecutionTimeForCompletionsMillis = Number(object.totalExecutionTimeForCompletionsMillis); + var message = new $root.google.cloud.datacatalog.v1.BigQueryDateShardedSpec(); + if (object.dataset != null) + message.dataset = String(object.dataset); + if (object.tablePrefix != null) + message.tablePrefix = String(object.tablePrefix); + if (object.shardCount != null) + if ($util.Long) + (message.shardCount = $util.Long.fromValue(object.shardCount)).unsigned = false; + else if (typeof object.shardCount === "string") + message.shardCount = parseInt(object.shardCount, 10); + else if (typeof object.shardCount === "number") + message.shardCount = object.shardCount; + else if (typeof object.shardCount === "object") + message.shardCount = new $util.LongBits(object.shardCount.low >>> 0, object.shardCount.high >>> 0).toNumber(); + if (object.latestShardResource != null) + message.latestShardResource = String(object.latestShardResource); return message; }; /** - * Creates a plain object from a UsageStats message. Also converts values to other types if specified. + * Creates a plain object from a BigQueryDateShardedSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1.UsageStats} message UsageStats + * @param {google.cloud.datacatalog.v1.BigQueryDateShardedSpec} message BigQueryDateShardedSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UsageStats.toObject = function toObject(message, options) { + BigQueryDateShardedSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.totalCompletions = 0; - object.totalFailures = 0; - object.totalCancellations = 0; - object.totalExecutionTimeForCompletionsMillis = 0; + object.dataset = ""; + object.tablePrefix = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.shardCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.shardCount = options.longs === String ? "0" : 0; + object.latestShardResource = ""; } - if (message.totalCompletions != null && message.hasOwnProperty("totalCompletions")) - object.totalCompletions = options.json && !isFinite(message.totalCompletions) ? String(message.totalCompletions) : message.totalCompletions; - if (message.totalFailures != null && message.hasOwnProperty("totalFailures")) - object.totalFailures = options.json && !isFinite(message.totalFailures) ? String(message.totalFailures) : message.totalFailures; - if (message.totalCancellations != null && message.hasOwnProperty("totalCancellations")) - object.totalCancellations = options.json && !isFinite(message.totalCancellations) ? String(message.totalCancellations) : message.totalCancellations; - if (message.totalExecutionTimeForCompletionsMillis != null && message.hasOwnProperty("totalExecutionTimeForCompletionsMillis")) - object.totalExecutionTimeForCompletionsMillis = options.json && !isFinite(message.totalExecutionTimeForCompletionsMillis) ? String(message.totalExecutionTimeForCompletionsMillis) : message.totalExecutionTimeForCompletionsMillis; + if (message.dataset != null && message.hasOwnProperty("dataset")) + object.dataset = message.dataset; + if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) + object.tablePrefix = message.tablePrefix; + if (message.shardCount != null && message.hasOwnProperty("shardCount")) + if (typeof message.shardCount === "number") + object.shardCount = options.longs === String ? String(message.shardCount) : message.shardCount; + else + object.shardCount = options.longs === String ? $util.Long.prototype.toString.call(message.shardCount) : options.longs === Number ? new $util.LongBits(message.shardCount.low >>> 0, message.shardCount.high >>> 0).toNumber() : message.shardCount; + if (message.latestShardResource != null && message.hasOwnProperty("latestShardResource")) + object.latestShardResource = message.latestShardResource; return object; }; /** - * Converts this UsageStats to JSON. + * Converts this BigQueryDateShardedSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @instance * @returns {Object.} JSON object */ - UsageStats.prototype.toJSON = function toJSON() { + BigQueryDateShardedSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UsageStats + * Gets the default type url for BigQueryDateShardedSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UsageStats + * @memberof google.cloud.datacatalog.v1.BigQueryDateShardedSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UsageStats.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + BigQueryDateShardedSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UsageStats"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.BigQueryDateShardedSpec"; }; - return UsageStats; + return BigQueryDateShardedSpec; })(); - v1.UsageSignal = (function() { + v1.Tag = (function() { /** - * Properties of a UsageSignal. + * Properties of a Tag. * @memberof google.cloud.datacatalog.v1 - * @interface IUsageSignal - * @property {google.protobuf.ITimestamp|null} [updateTime] UsageSignal updateTime - * @property {Object.|null} [usageWithinTimeRange] UsageSignal usageWithinTimeRange + * @interface ITag + * @property {string|null} [name] Tag name + * @property {string|null} [template] Tag template + * @property {string|null} [templateDisplayName] Tag templateDisplayName + * @property {string|null} [column] Tag column + * @property {Object.|null} [fields] Tag fields */ /** - * Constructs a new UsageSignal. + * Constructs a new Tag. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a UsageSignal. - * @implements IUsageSignal + * @classdesc Represents a Tag. + * @implements ITag * @constructor - * @param {google.cloud.datacatalog.v1.IUsageSignal=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITag=} [properties] Properties to set */ - function UsageSignal(properties) { - this.usageWithinTimeRange = {}; + function Tag(properties) { + this.fields = {}; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -23211,93 +23891,149 @@ } /** - * UsageSignal updateTime. - * @member {google.protobuf.ITimestamp|null|undefined} updateTime - * @memberof google.cloud.datacatalog.v1.UsageSignal + * Tag name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.Tag * @instance */ - UsageSignal.prototype.updateTime = null; + Tag.prototype.name = ""; /** - * UsageSignal usageWithinTimeRange. - * @member {Object.} usageWithinTimeRange - * @memberof google.cloud.datacatalog.v1.UsageSignal + * Tag template. + * @member {string} template + * @memberof google.cloud.datacatalog.v1.Tag * @instance */ - UsageSignal.prototype.usageWithinTimeRange = $util.emptyObject; + Tag.prototype.template = ""; /** - * Creates a new UsageSignal instance using the specified properties. + * Tag templateDisplayName. + * @member {string} templateDisplayName + * @memberof google.cloud.datacatalog.v1.Tag + * @instance + */ + Tag.prototype.templateDisplayName = ""; + + /** + * Tag column. + * @member {string|null|undefined} column + * @memberof google.cloud.datacatalog.v1.Tag + * @instance + */ + Tag.prototype.column = null; + + /** + * Tag fields. + * @member {Object.} fields + * @memberof google.cloud.datacatalog.v1.Tag + * @instance + */ + Tag.prototype.fields = $util.emptyObject; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * Tag scope. + * @member {"column"|undefined} scope + * @memberof google.cloud.datacatalog.v1.Tag + * @instance + */ + Object.defineProperty(Tag.prototype, "scope", { + get: $util.oneOfGetter($oneOfFields = ["column"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new Tag instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static - * @param {google.cloud.datacatalog.v1.IUsageSignal=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal instance + * @param {google.cloud.datacatalog.v1.ITag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.Tag} Tag instance */ - UsageSignal.create = function create(properties) { - return new UsageSignal(properties); + Tag.create = function create(properties) { + return new Tag(properties); }; /** - * Encodes the specified UsageSignal message. Does not implicitly {@link google.cloud.datacatalog.v1.UsageSignal.verify|verify} messages. + * Encodes the specified Tag message. Does not implicitly {@link google.cloud.datacatalog.v1.Tag.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static - * @param {google.cloud.datacatalog.v1.IUsageSignal} message UsageSignal message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITag} message Tag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UsageSignal.encode = function encode(message, writer) { + Tag.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) - $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.usageWithinTimeRange != null && Object.hasOwnProperty.call(message, "usageWithinTimeRange")) - for (var keys = Object.keys(message.usageWithinTimeRange), i = 0; i < keys.length; ++i) { - writer.uint32(/* id 2, wireType 2 =*/18).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); - $root.google.cloud.datacatalog.v1.UsageStats.encode(message.usageWithinTimeRange[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.template != null && Object.hasOwnProperty.call(message, "template")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.template); + if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) + for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1.TagField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); } + if (message.column != null && Object.hasOwnProperty.call(message, "column")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.column); + if (message.templateDisplayName != null && Object.hasOwnProperty.call(message, "templateDisplayName")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.templateDisplayName); return writer; }; /** - * Encodes the specified UsageSignal message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UsageSignal.verify|verify} messages. + * Encodes the specified Tag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Tag.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static - * @param {google.cloud.datacatalog.v1.IUsageSignal} message UsageSignal message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITag} message Tag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UsageSignal.encodeDelimited = function encodeDelimited(message, writer) { + Tag.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a UsageSignal message from the specified reader or buffer. + * Decodes a Tag message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal + * @returns {google.cloud.datacatalog.v1.Tag} Tag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UsageSignal.decode = function decode(reader, length) { + Tag.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UsageSignal(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Tag(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.name = reader.string(); break; } case 2: { - if (message.usageWithinTimeRange === $util.emptyObject) - message.usageWithinTimeRange = {}; + message.template = reader.string(); + break; + } + case 5: { + message.templateDisplayName = reader.string(); + break; + } + case 4: { + message.column = reader.string(); + break; + } + case 3: { + if (message.fields === $util.emptyObject) + message.fields = {}; var end2 = reader.uint32() + reader.pos; key = ""; value = null; @@ -23308,14 +24044,14 @@ key = reader.string(); break; case 2: - value = $root.google.cloud.datacatalog.v1.UsageStats.decode(reader, reader.uint32()); + value = $root.google.cloud.datacatalog.v1.TagField.decode(reader, reader.uint32()); break; default: reader.skipType(tag2 & 7); break; } } - message.usageWithinTimeRange[key] = value; + message.fields[key] = value; break; } default: @@ -23327,625 +24063,813 @@ }; /** - * Decodes a UsageSignal message from the specified reader or buffer, length delimited. + * Decodes a Tag message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal + * @returns {google.cloud.datacatalog.v1.Tag} Tag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UsageSignal.decodeDelimited = function decodeDelimited(reader) { + Tag.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a UsageSignal message. + * Verifies a Tag message. * @function verify - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UsageSignal.verify = function verify(message) { + Tag.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.updateTime != null && message.hasOwnProperty("updateTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.updateTime); - if (error) - return "updateTime." + error; + var properties = {}; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.template != null && message.hasOwnProperty("template")) + if (!$util.isString(message.template)) + return "template: string expected"; + if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) + if (!$util.isString(message.templateDisplayName)) + return "templateDisplayName: string expected"; + if (message.column != null && message.hasOwnProperty("column")) { + properties.scope = 1; + if (!$util.isString(message.column)) + return "column: string expected"; } - if (message.usageWithinTimeRange != null && message.hasOwnProperty("usageWithinTimeRange")) { - if (!$util.isObject(message.usageWithinTimeRange)) - return "usageWithinTimeRange: object expected"; - var key = Object.keys(message.usageWithinTimeRange); + if (message.fields != null && message.hasOwnProperty("fields")) { + if (!$util.isObject(message.fields)) + return "fields: object expected"; + var key = Object.keys(message.fields); for (var i = 0; i < key.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.UsageStats.verify(message.usageWithinTimeRange[key[i]]); + var error = $root.google.cloud.datacatalog.v1.TagField.verify(message.fields[key[i]]); if (error) - return "usageWithinTimeRange." + error; + return "fields." + error; } } return null; }; /** - * Creates a UsageSignal message from a plain object. Also converts values to their respective internal types. + * Creates a Tag message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal + * @returns {google.cloud.datacatalog.v1.Tag} Tag */ - UsageSignal.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UsageSignal) + Tag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.Tag) return object; - var message = new $root.google.cloud.datacatalog.v1.UsageSignal(); - if (object.updateTime != null) { - if (typeof object.updateTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.updateTime: object expected"); - message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); - } - if (object.usageWithinTimeRange) { - if (typeof object.usageWithinTimeRange !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.usageWithinTimeRange: object expected"); - message.usageWithinTimeRange = {}; - for (var keys = Object.keys(object.usageWithinTimeRange), i = 0; i < keys.length; ++i) { - if (typeof object.usageWithinTimeRange[keys[i]] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.usageWithinTimeRange: object expected"); - message.usageWithinTimeRange[keys[i]] = $root.google.cloud.datacatalog.v1.UsageStats.fromObject(object.usageWithinTimeRange[keys[i]]); + var message = new $root.google.cloud.datacatalog.v1.Tag(); + if (object.name != null) + message.name = String(object.name); + if (object.template != null) + message.template = String(object.template); + if (object.templateDisplayName != null) + message.templateDisplayName = String(object.templateDisplayName); + if (object.column != null) + message.column = String(object.column); + if (object.fields) { + if (typeof object.fields !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Tag.fields: object expected"); + message.fields = {}; + for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { + if (typeof object.fields[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Tag.fields: object expected"); + message.fields[keys[i]] = $root.google.cloud.datacatalog.v1.TagField.fromObject(object.fields[keys[i]]); } } return message; }; /** - * Creates a plain object from a UsageSignal message. Also converts values to other types if specified. + * Creates a plain object from a Tag message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static - * @param {google.cloud.datacatalog.v1.UsageSignal} message UsageSignal + * @param {google.cloud.datacatalog.v1.Tag} message Tag * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UsageSignal.toObject = function toObject(message, options) { + Tag.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.objects || options.defaults) - object.usageWithinTimeRange = {}; - if (options.defaults) - object.updateTime = null; - if (message.updateTime != null && message.hasOwnProperty("updateTime")) - object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); + object.fields = {}; + if (options.defaults) { + object.name = ""; + object.template = ""; + object.templateDisplayName = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.template != null && message.hasOwnProperty("template")) + object.template = message.template; var keys2; - if (message.usageWithinTimeRange && (keys2 = Object.keys(message.usageWithinTimeRange)).length) { - object.usageWithinTimeRange = {}; + if (message.fields && (keys2 = Object.keys(message.fields)).length) { + object.fields = {}; for (var j = 0; j < keys2.length; ++j) - object.usageWithinTimeRange[keys2[j]] = $root.google.cloud.datacatalog.v1.UsageStats.toObject(message.usageWithinTimeRange[keys2[j]], options); + object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1.TagField.toObject(message.fields[keys2[j]], options); + } + if (message.column != null && message.hasOwnProperty("column")) { + object.column = message.column; + if (options.oneofs) + object.scope = "column"; } + if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) + object.templateDisplayName = message.templateDisplayName; return object; }; /** - * Converts this UsageSignal to JSON. + * Converts this Tag to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @instance * @returns {Object.} JSON object */ - UsageSignal.prototype.toJSON = function toJSON() { + Tag.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UsageSignal + * Gets the default type url for Tag * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UsageSignal + * @memberof google.cloud.datacatalog.v1.Tag * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UsageSignal.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Tag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UsageSignal"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.Tag"; }; - return UsageSignal; + return Tag; })(); - v1.PolicyTagManager = (function() { + v1.TagField = (function() { /** - * Constructs a new PolicyTagManager service. + * Properties of a TagField. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a PolicyTagManager - * @extends $protobuf.rpc.Service + * @interface ITagField + * @property {string|null} [displayName] TagField displayName + * @property {number|null} [doubleValue] TagField doubleValue + * @property {string|null} [stringValue] TagField stringValue + * @property {boolean|null} [boolValue] TagField boolValue + * @property {google.protobuf.ITimestamp|null} [timestampValue] TagField timestampValue + * @property {google.cloud.datacatalog.v1.TagField.IEnumValue|null} [enumValue] TagField enumValue + * @property {string|null} [richtextValue] TagField richtextValue + * @property {number|null} [order] TagField order + */ + + /** + * Constructs a new TagField. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a TagField. + * @implements ITagField * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @param {google.cloud.datacatalog.v1.ITagField=} [properties] Properties to set */ - function PolicyTagManager(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + function TagField(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - (PolicyTagManager.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManager; - /** - * Creates new PolicyTagManager service using the specified rpc implementation. - * @function create - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {PolicyTagManager} RPC service. Useful where requests and/or responses are streamed. + * TagField displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.TagField + * @instance */ - PolicyTagManager.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); - }; + TagField.prototype.displayName = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|createTaxonomy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef CreateTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy + * TagField doubleValue. + * @member {number|null|undefined} doubleValue + * @memberof google.cloud.datacatalog.v1.TagField + * @instance */ + TagField.prototype.doubleValue = null; /** - * Calls CreateTaxonomy. - * @function createTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField stringValue. + * @member {string|null|undefined} stringValue + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.CreateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManager.prototype.createTaxonomy = function createTaxonomy(request, callback) { - return this.rpcCall(createTaxonomy, $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); - }, "name", { value: "CreateTaxonomy" }); + TagField.prototype.stringValue = null; /** - * Calls CreateTaxonomy. - * @function createTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField boolValue. + * @member {boolean|null|undefined} boolValue + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + TagField.prototype.boolValue = null; /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|deleteTaxonomy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef DeleteTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * TagField timestampValue. + * @member {google.protobuf.ITimestamp|null|undefined} timestampValue + * @memberof google.cloud.datacatalog.v1.TagField + * @instance */ + TagField.prototype.timestampValue = null; /** - * Calls DeleteTaxonomy. - * @function deleteTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.DeleteTaxonomyCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.deleteTaxonomy = function deleteTaxonomy(request, callback) { - return this.rpcCall(deleteTaxonomy, $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteTaxonomy" }); - - /** - * Calls DeleteTaxonomy. - * @function deleteTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField enumValue. + * @member {google.cloud.datacatalog.v1.TagField.IEnumValue|null|undefined} enumValue + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|updateTaxonomy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef UpdateTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy */ + TagField.prototype.enumValue = null; /** - * Calls UpdateTaxonomy. - * @function updateTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField richtextValue. + * @member {string|null|undefined} richtextValue + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.UpdateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManager.prototype.updateTaxonomy = function updateTaxonomy(request, callback) { - return this.rpcCall(updateTaxonomy, $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); - }, "name", { value: "UpdateTaxonomy" }); + TagField.prototype.richtextValue = null; /** - * Calls UpdateTaxonomy. - * @function updateTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField order. + * @member {number} order + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + TagField.prototype.order = 0; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|listTaxonomies}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef ListTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.ListTaxonomiesResponse} [response] ListTaxonomiesResponse - */ + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Calls ListTaxonomies. - * @function listTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * TagField kind. + * @member {"doubleValue"|"stringValue"|"boolValue"|"timestampValue"|"enumValue"|"richtextValue"|undefined} kind + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.ListTaxonomiesCallback} callback Node-style callback called with the error, if any, and ListTaxonomiesResponse - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManager.prototype.listTaxonomies = function listTaxonomies(request, callback) { - return this.rpcCall(listTaxonomies, $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse, request, callback); - }, "name", { value: "ListTaxonomies" }); + Object.defineProperty(TagField.prototype, "kind", { + get: $util.oneOfGetter($oneOfFields = ["doubleValue", "stringValue", "boolValue", "timestampValue", "enumValue", "richtextValue"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Calls ListTaxonomies. - * @function listTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates a new TagField instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {google.cloud.datacatalog.v1.ITagField=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TagField} TagField instance */ + TagField.create = function create(properties) { + return new TagField(properties); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getTaxonomy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef GetTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy + * Encodes the specified TagField message. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {google.cloud.datacatalog.v1.ITagField} message TagField message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + TagField.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) + writer.uint32(/* id 2, wireType 1 =*/17).double(message.doubleValue); + if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.stringValue); + if (message.boolValue != null && Object.hasOwnProperty.call(message, "boolValue")) + writer.uint32(/* id 4, wireType 0 =*/32).bool(message.boolValue); + if (message.timestampValue != null && Object.hasOwnProperty.call(message, "timestampValue")) + $root.google.protobuf.Timestamp.encode(message.timestampValue, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.enumValue != null && Object.hasOwnProperty.call(message, "enumValue")) + $root.google.cloud.datacatalog.v1.TagField.EnumValue.encode(message.enumValue, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.order != null && Object.hasOwnProperty.call(message, "order")) + writer.uint32(/* id 7, wireType 0 =*/56).int32(message.order); + if (message.richtextValue != null && Object.hasOwnProperty.call(message, "richtextValue")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.richtextValue); + return writer; + }; /** - * Calls GetTaxonomy. - * @function getTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 + * Encodes the specified TagField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {google.cloud.datacatalog.v1.ITagField} message TagField message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(PolicyTagManager.prototype.getTaxonomy = function getTaxonomy(request, callback) { - return this.rpcCall(getTaxonomy, $root.google.cloud.datacatalog.v1.GetTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); - }, "name", { value: "GetTaxonomy" }); + TagField.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Calls GetTaxonomy. - * @function getTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Decodes a TagField message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.TagField} TagField + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + TagField.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagField(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + case 2: { + message.doubleValue = reader.double(); + break; + } + case 3: { + message.stringValue = reader.string(); + break; + } + case 4: { + message.boolValue = reader.bool(); + break; + } + case 5: { + message.timestampValue = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 6: { + message.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.decode(reader, reader.uint32()); + break; + } + case 8: { + message.richtextValue = reader.string(); + break; + } + case 7: { + message.order = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|createPolicyTag}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef CreatePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag + * Decodes a TagField message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.TagField} TagField + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + TagField.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls CreatePolicyTag. - * @function createPolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.CreatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 + * Verifies a TagField message. + * @function verify + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Object.defineProperty(PolicyTagManager.prototype.createPolicyTag = function createPolicyTag(request, callback) { - return this.rpcCall(createPolicyTag, $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); - }, "name", { value: "CreatePolicyTag" }); + TagField.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { + properties.kind = 1; + if (typeof message.doubleValue !== "number") + return "doubleValue: number expected"; + } + if (message.stringValue != null && message.hasOwnProperty("stringValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + if (!$util.isString(message.stringValue)) + return "stringValue: string expected"; + } + if (message.boolValue != null && message.hasOwnProperty("boolValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + if (typeof message.boolValue !== "boolean") + return "boolValue: boolean expected"; + } + if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + { + var error = $root.google.protobuf.Timestamp.verify(message.timestampValue); + if (error) + return "timestampValue." + error; + } + } + if (message.enumValue != null && message.hasOwnProperty("enumValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + { + var error = $root.google.cloud.datacatalog.v1.TagField.EnumValue.verify(message.enumValue); + if (error) + return "enumValue." + error; + } + } + if (message.richtextValue != null && message.hasOwnProperty("richtextValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + if (!$util.isString(message.richtextValue)) + return "richtextValue: string expected"; + } + if (message.order != null && message.hasOwnProperty("order")) + if (!$util.isInteger(message.order)) + return "order: integer expected"; + return null; + }; /** - * Calls CreatePolicyTag. - * @function createPolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates a TagField message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.TagField} TagField */ + TagField.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TagField) + return object; + var message = new $root.google.cloud.datacatalog.v1.TagField(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.doubleValue != null) + message.doubleValue = Number(object.doubleValue); + if (object.stringValue != null) + message.stringValue = String(object.stringValue); + if (object.boolValue != null) + message.boolValue = Boolean(object.boolValue); + if (object.timestampValue != null) { + if (typeof object.timestampValue !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TagField.timestampValue: object expected"); + message.timestampValue = $root.google.protobuf.Timestamp.fromObject(object.timestampValue); + } + if (object.enumValue != null) { + if (typeof object.enumValue !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TagField.enumValue: object expected"); + message.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.fromObject(object.enumValue); + } + if (object.richtextValue != null) + message.richtextValue = String(object.richtextValue); + if (object.order != null) + message.order = object.order | 0; + return message; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|deletePolicyTag}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef DeletePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Creates a plain object from a TagField message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {google.cloud.datacatalog.v1.TagField} message TagField + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ + TagField.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.displayName = ""; + object.order = 0; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { + object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; + if (options.oneofs) + object.kind = "doubleValue"; + } + if (message.stringValue != null && message.hasOwnProperty("stringValue")) { + object.stringValue = message.stringValue; + if (options.oneofs) + object.kind = "stringValue"; + } + if (message.boolValue != null && message.hasOwnProperty("boolValue")) { + object.boolValue = message.boolValue; + if (options.oneofs) + object.kind = "boolValue"; + } + if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { + object.timestampValue = $root.google.protobuf.Timestamp.toObject(message.timestampValue, options); + if (options.oneofs) + object.kind = "timestampValue"; + } + if (message.enumValue != null && message.hasOwnProperty("enumValue")) { + object.enumValue = $root.google.cloud.datacatalog.v1.TagField.EnumValue.toObject(message.enumValue, options); + if (options.oneofs) + object.kind = "enumValue"; + } + if (message.order != null && message.hasOwnProperty("order")) + object.order = message.order; + if (message.richtextValue != null && message.hasOwnProperty("richtextValue")) { + object.richtextValue = message.richtextValue; + if (options.oneofs) + object.kind = "richtextValue"; + } + return object; + }; /** - * Calls DeletePolicyTag. - * @function deletePolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * Converts this TagField to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.TagField * @instance - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.DeletePolicyTagCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * @returns {Object.} JSON object */ - Object.defineProperty(PolicyTagManager.prototype.deletePolicyTag = function deletePolicyTag(request, callback) { - return this.rpcCall(deletePolicyTag, $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeletePolicyTag" }); + TagField.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Calls DeletePolicyTag. - * @function deletePolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Gets the default type url for TagField + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.TagField + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + TagField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagField"; + }; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|updatePolicyTag}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef UpdatePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag - */ + TagField.EnumValue = (function() { - /** - * Calls UpdatePolicyTag. - * @function updatePolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.UpdatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.updatePolicyTag = function updatePolicyTag(request, callback) { - return this.rpcCall(updatePolicyTag, $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); - }, "name", { value: "UpdatePolicyTag" }); + /** + * Properties of an EnumValue. + * @memberof google.cloud.datacatalog.v1.TagField + * @interface IEnumValue + * @property {string|null} [displayName] EnumValue displayName + */ - /** - * Calls UpdatePolicyTag. - * @function updatePolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + /** + * Constructs a new EnumValue. + * @memberof google.cloud.datacatalog.v1.TagField + * @classdesc Represents an EnumValue. + * @implements IEnumValue + * @constructor + * @param {google.cloud.datacatalog.v1.TagField.IEnumValue=} [properties] Properties to set + */ + function EnumValue(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|listPolicyTags}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef ListPolicyTagsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.ListPolicyTagsResponse} [response] ListPolicyTagsResponse - */ + /** + * EnumValue displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @instance + */ + EnumValue.prototype.displayName = ""; - /** - * Calls ListPolicyTags. - * @function listPolicyTags - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.ListPolicyTagsCallback} callback Node-style callback called with the error, if any, and ListPolicyTagsResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.listPolicyTags = function listPolicyTags(request, callback) { - return this.rpcCall(listPolicyTags, $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest, $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse, request, callback); - }, "name", { value: "ListPolicyTags" }); - - /** - * Calls ListPolicyTags. - * @function listPolicyTags - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getPolicyTag}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef GetPolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag - */ - - /** - * Calls GetPolicyTag. - * @function getPolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetPolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.getPolicyTag = function getPolicyTag(request, callback) { - return this.rpcCall(getPolicyTag, $root.google.cloud.datacatalog.v1.GetPolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); - }, "name", { value: "GetPolicyTag" }); + /** + * Creates a new EnumValue instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.TagField.IEnumValue=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue instance + */ + EnumValue.create = function create(properties) { + return new EnumValue(properties); + }; - /** - * Calls GetPolicyTag. - * @function getPolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + /** + * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.EnumValue.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.TagField.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + return writer; + }; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getIamPolicy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef GetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy - */ + /** + * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagField.EnumValue.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.TagField.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.getIamPolicy = function getIamPolicy(request, callback) { - return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "GetIamPolicy" }); + /** + * Decodes an EnumValue message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagField.EnumValue(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + /** + * Decodes an EnumValue message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|setIamPolicy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef SetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy - */ + /** + * Verifies an EnumValue message. + * @function verify + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumValue.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + return null; + }; - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.setIamPolicy = function setIamPolicy(request, callback) { - return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "SetIamPolicy" }); + /** + * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.TagField.EnumValue} EnumValue + */ + EnumValue.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TagField.EnumValue) + return object; + var message = new $root.google.cloud.datacatalog.v1.TagField.EnumValue(); + if (object.displayName != null) + message.displayName = String(object.displayName); + return message; + }; - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + /** + * Creates a plain object from an EnumValue message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.TagField.EnumValue} message EnumValue + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumValue.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.displayName = ""; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + return object; + }; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|testIamPermissions}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @typedef TestIamPermissionsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse - */ + /** + * Converts this EnumValue to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @instance + * @returns {Object.} JSON object + */ + EnumValue.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManager.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.testIamPermissions = function testIamPermissions(request, callback) { - return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); - }, "name", { value: "TestIamPermissions" }); + /** + * Gets the default type url for EnumValue + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.TagField.EnumValue + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagField.EnumValue"; + }; - /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1.PolicyTagManager - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + return EnumValue; + })(); - return PolicyTagManager; + return TagField; })(); - v1.Taxonomy = (function() { + v1.TagTemplate = (function() { /** - * Properties of a Taxonomy. + * Properties of a TagTemplate. * @memberof google.cloud.datacatalog.v1 - * @interface ITaxonomy - * @property {string|null} [name] Taxonomy name - * @property {string|null} [displayName] Taxonomy displayName - * @property {string|null} [description] Taxonomy description - * @property {number|null} [policyTagCount] Taxonomy policyTagCount - * @property {google.cloud.datacatalog.v1.ISystemTimestamps|null} [taxonomyTimestamps] Taxonomy taxonomyTimestamps - * @property {Array.|null} [activatedPolicyTypes] Taxonomy activatedPolicyTypes + * @interface ITagTemplate + * @property {string|null} [name] TagTemplate name + * @property {string|null} [displayName] TagTemplate displayName + * @property {boolean|null} [isPubliclyReadable] TagTemplate isPubliclyReadable + * @property {Object.|null} [fields] TagTemplate fields */ /** - * Constructs a new Taxonomy. + * Constructs a new TagTemplate. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a Taxonomy. - * @implements ITaxonomy + * @classdesc Represents a TagTemplate. + * @implements ITagTemplate * @constructor - * @param {google.cloud.datacatalog.v1.ITaxonomy=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITagTemplate=} [properties] Properties to set */ - function Taxonomy(properties) { - this.activatedPolicyTypes = []; + function TagTemplate(properties) { + this.fields = {}; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -23953,124 +24877,103 @@ } /** - * Taxonomy name. + * TagTemplate name. * @member {string} name - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @instance */ - Taxonomy.prototype.name = ""; + TagTemplate.prototype.name = ""; /** - * Taxonomy displayName. + * TagTemplate displayName. * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.Taxonomy - * @instance - */ - Taxonomy.prototype.displayName = ""; - - /** - * Taxonomy description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.Taxonomy - * @instance - */ - Taxonomy.prototype.description = ""; - - /** - * Taxonomy policyTagCount. - * @member {number} policyTagCount - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @instance */ - Taxonomy.prototype.policyTagCount = 0; + TagTemplate.prototype.displayName = ""; /** - * Taxonomy taxonomyTimestamps. - * @member {google.cloud.datacatalog.v1.ISystemTimestamps|null|undefined} taxonomyTimestamps - * @memberof google.cloud.datacatalog.v1.Taxonomy + * TagTemplate isPubliclyReadable. + * @member {boolean} isPubliclyReadable + * @memberof google.cloud.datacatalog.v1.TagTemplate * @instance */ - Taxonomy.prototype.taxonomyTimestamps = null; + TagTemplate.prototype.isPubliclyReadable = false; /** - * Taxonomy activatedPolicyTypes. - * @member {Array.} activatedPolicyTypes - * @memberof google.cloud.datacatalog.v1.Taxonomy + * TagTemplate fields. + * @member {Object.} fields + * @memberof google.cloud.datacatalog.v1.TagTemplate * @instance */ - Taxonomy.prototype.activatedPolicyTypes = $util.emptyArray; + TagTemplate.prototype.fields = $util.emptyObject; /** - * Creates a new Taxonomy instance using the specified properties. + * Creates a new TagTemplate instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1.ITaxonomy=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy instance + * @param {google.cloud.datacatalog.v1.ITagTemplate=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate instance */ - Taxonomy.create = function create(properties) { - return new Taxonomy(properties); + TagTemplate.create = function create(properties) { + return new TagTemplate(properties); }; /** - * Encodes the specified Taxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.verify|verify} messages. + * Encodes the specified TagTemplate message. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplate.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1.ITaxonomy} message Taxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITagTemplate} message TagTemplate message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Taxonomy.encode = function encode(message, writer) { + TagTemplate.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.policyTagCount != null && Object.hasOwnProperty.call(message, "policyTagCount")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.policyTagCount); - if (message.taxonomyTimestamps != null && Object.hasOwnProperty.call(message, "taxonomyTimestamps")) - $root.google.cloud.datacatalog.v1.SystemTimestamps.encode(message.taxonomyTimestamps, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { - writer.uint32(/* id 6, wireType 2 =*/50).fork(); - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - writer.int32(message.activatedPolicyTypes[i]); - writer.ldelim(); - } + if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) + for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1.TagTemplateField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } + if (message.isPubliclyReadable != null && Object.hasOwnProperty.call(message, "isPubliclyReadable")) + writer.uint32(/* id 5, wireType 0 =*/40).bool(message.isPubliclyReadable); return writer; }; /** - * Encodes the specified Taxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.verify|verify} messages. + * Encodes the specified TagTemplate message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplate.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1.ITaxonomy} message Taxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITagTemplate} message TagTemplate message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Taxonomy.encodeDelimited = function encodeDelimited(message, writer) { + TagTemplate.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Taxonomy message from the specified reader or buffer. + * Decodes a TagTemplate message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Taxonomy.decode = function decode(reader, length) { + TagTemplate.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Taxonomy(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagTemplate(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -24082,27 +24985,31 @@ message.displayName = reader.string(); break; } - case 3: { - message.description = reader.string(); - break; - } - case 4: { - message.policyTagCount = reader.int32(); - break; - } case 5: { - message.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.decode(reader, reader.uint32()); + message.isPubliclyReadable = reader.bool(); break; } - case 6: { - if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) - message.activatedPolicyTypes = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.activatedPolicyTypes.push(reader.int32()); - } else - message.activatedPolicyTypes.push(reader.int32()); + case 3: { + if (message.fields === $util.emptyObject) + message.fields = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.cloud.datacatalog.v1.TagTemplateField.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.fields[key] = value; break; } default: @@ -24114,30 +25021,30 @@ }; /** - * Decodes a Taxonomy message from the specified reader or buffer, length delimited. + * Decodes a TagTemplate message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Taxonomy.decodeDelimited = function decodeDelimited(reader) { + TagTemplate.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Taxonomy message. + * Verifies a TagTemplate message. * @function verify - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Taxonomy.verify = function verify(message) { + TagTemplate.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) @@ -24146,187 +25053,140 @@ if (message.displayName != null && message.hasOwnProperty("displayName")) if (!$util.isString(message.displayName)) return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.policyTagCount != null && message.hasOwnProperty("policyTagCount")) - if (!$util.isInteger(message.policyTagCount)) - return "policyTagCount: integer expected"; - if (message.taxonomyTimestamps != null && message.hasOwnProperty("taxonomyTimestamps")) { - var error = $root.google.cloud.datacatalog.v1.SystemTimestamps.verify(message.taxonomyTimestamps); - if (error) - return "taxonomyTimestamps." + error; - } - if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { - if (!Array.isArray(message.activatedPolicyTypes)) - return "activatedPolicyTypes: array expected"; - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - switch (message.activatedPolicyTypes[i]) { - default: - return "activatedPolicyTypes: enum value[] expected"; - case 0: - case 1: - break; - } + if (message.isPubliclyReadable != null && message.hasOwnProperty("isPubliclyReadable")) + if (typeof message.isPubliclyReadable !== "boolean") + return "isPubliclyReadable: boolean expected"; + if (message.fields != null && message.hasOwnProperty("fields")) { + if (!$util.isObject(message.fields)) + return "fields: object expected"; + var key = Object.keys(message.fields); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.TagTemplateField.verify(message.fields[key[i]]); + if (error) + return "fields." + error; + } } return null; }; /** - * Creates a Taxonomy message from a plain object. Also converts values to their respective internal types. + * Creates a TagTemplate message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1.TagTemplate} TagTemplate */ - Taxonomy.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.Taxonomy) + TagTemplate.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TagTemplate) return object; - var message = new $root.google.cloud.datacatalog.v1.Taxonomy(); + var message = new $root.google.cloud.datacatalog.v1.TagTemplate(); if (object.name != null) message.name = String(object.name); if (object.displayName != null) message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.policyTagCount != null) - message.policyTagCount = object.policyTagCount | 0; - if (object.taxonomyTimestamps != null) { - if (typeof object.taxonomyTimestamps !== "object") - throw TypeError(".google.cloud.datacatalog.v1.Taxonomy.taxonomyTimestamps: object expected"); - message.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.fromObject(object.taxonomyTimestamps); - } - if (object.activatedPolicyTypes) { - if (!Array.isArray(object.activatedPolicyTypes)) - throw TypeError(".google.cloud.datacatalog.v1.Taxonomy.activatedPolicyTypes: array expected"); - message.activatedPolicyTypes = []; - for (var i = 0; i < object.activatedPolicyTypes.length; ++i) - switch (object.activatedPolicyTypes[i]) { - default: - if (typeof object.activatedPolicyTypes[i] === "number") { - message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; - break; - } - case "POLICY_TYPE_UNSPECIFIED": - case 0: - message.activatedPolicyTypes[i] = 0; - break; - case "FINE_GRAINED_ACCESS_CONTROL": - case 1: - message.activatedPolicyTypes[i] = 1; - break; - } + if (object.isPubliclyReadable != null) + message.isPubliclyReadable = Boolean(object.isPubliclyReadable); + if (object.fields) { + if (typeof object.fields !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TagTemplate.fields: object expected"); + message.fields = {}; + for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { + if (typeof object.fields[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TagTemplate.fields: object expected"); + message.fields[keys[i]] = $root.google.cloud.datacatalog.v1.TagTemplateField.fromObject(object.fields[keys[i]]); + } } return message; }; /** - * Creates a plain object from a Taxonomy message. Also converts values to other types if specified. + * Creates a plain object from a TagTemplate message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1.Taxonomy} message Taxonomy + * @param {google.cloud.datacatalog.v1.TagTemplate} message TagTemplate * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Taxonomy.toObject = function toObject(message, options) { + TagTemplate.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.activatedPolicyTypes = []; + if (options.objects || options.defaults) + object.fields = {}; if (options.defaults) { object.name = ""; object.displayName = ""; - object.description = ""; - object.policyTagCount = 0; - object.taxonomyTimestamps = null; + object.isPubliclyReadable = false; } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.policyTagCount != null && message.hasOwnProperty("policyTagCount")) - object.policyTagCount = message.policyTagCount; - if (message.taxonomyTimestamps != null && message.hasOwnProperty("taxonomyTimestamps")) - object.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.toObject(message.taxonomyTimestamps, options); - if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { - object.activatedPolicyTypes = []; - for (var j = 0; j < message.activatedPolicyTypes.length; ++j) - object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; + var keys2; + if (message.fields && (keys2 = Object.keys(message.fields)).length) { + object.fields = {}; + for (var j = 0; j < keys2.length; ++j) + object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1.TagTemplateField.toObject(message.fields[keys2[j]], options); } + if (message.isPubliclyReadable != null && message.hasOwnProperty("isPubliclyReadable")) + object.isPubliclyReadable = message.isPubliclyReadable; return object; }; /** - * Converts this Taxonomy to JSON. + * Converts this TagTemplate to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @instance * @returns {Object.} JSON object */ - Taxonomy.prototype.toJSON = function toJSON() { + TagTemplate.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Taxonomy + * Gets the default type url for TagTemplate * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.Taxonomy + * @memberof google.cloud.datacatalog.v1.TagTemplate * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Taxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TagTemplate.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.Taxonomy"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagTemplate"; }; - /** - * PolicyType enum. - * @name google.cloud.datacatalog.v1.Taxonomy.PolicyType - * @enum {number} - * @property {number} POLICY_TYPE_UNSPECIFIED=0 POLICY_TYPE_UNSPECIFIED value - * @property {number} FINE_GRAINED_ACCESS_CONTROL=1 FINE_GRAINED_ACCESS_CONTROL value - */ - Taxonomy.PolicyType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "POLICY_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "FINE_GRAINED_ACCESS_CONTROL"] = 1; - return values; - })(); - - return Taxonomy; + return TagTemplate; })(); - v1.PolicyTag = (function() { + v1.TagTemplateField = (function() { /** - * Properties of a PolicyTag. + * Properties of a TagTemplateField. * @memberof google.cloud.datacatalog.v1 - * @interface IPolicyTag - * @property {string|null} [name] PolicyTag name - * @property {string|null} [displayName] PolicyTag displayName - * @property {string|null} [description] PolicyTag description - * @property {string|null} [parentPolicyTag] PolicyTag parentPolicyTag - * @property {Array.|null} [childPolicyTags] PolicyTag childPolicyTags + * @interface ITagTemplateField + * @property {string|null} [name] TagTemplateField name + * @property {string|null} [displayName] TagTemplateField displayName + * @property {google.cloud.datacatalog.v1.IFieldType|null} [type] TagTemplateField type + * @property {boolean|null} [isRequired] TagTemplateField isRequired + * @property {string|null} [description] TagTemplateField description + * @property {number|null} [order] TagTemplateField order */ /** - * Constructs a new PolicyTag. + * Constructs a new TagTemplateField. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a PolicyTag. - * @implements IPolicyTag + * @classdesc Represents a TagTemplateField. + * @implements ITagTemplateField * @constructor - * @param {google.cloud.datacatalog.v1.IPolicyTag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITagTemplateField=} [properties] Properties to set */ - function PolicyTag(properties) { - this.childPolicyTags = []; + function TagTemplateField(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -24334,134 +25194,145 @@ } /** - * PolicyTag name. + * TagTemplateField name. * @member {string} name - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance */ - PolicyTag.prototype.name = ""; + TagTemplateField.prototype.name = ""; /** - * PolicyTag displayName. + * TagTemplateField displayName. * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance */ - PolicyTag.prototype.displayName = ""; + TagTemplateField.prototype.displayName = ""; /** - * PolicyTag description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.PolicyTag + * TagTemplateField type. + * @member {google.cloud.datacatalog.v1.IFieldType|null|undefined} type + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance */ - PolicyTag.prototype.description = ""; + TagTemplateField.prototype.type = null; /** - * PolicyTag parentPolicyTag. - * @member {string} parentPolicyTag - * @memberof google.cloud.datacatalog.v1.PolicyTag + * TagTemplateField isRequired. + * @member {boolean} isRequired + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance */ - PolicyTag.prototype.parentPolicyTag = ""; + TagTemplateField.prototype.isRequired = false; /** - * PolicyTag childPolicyTags. - * @member {Array.} childPolicyTags - * @memberof google.cloud.datacatalog.v1.PolicyTag + * TagTemplateField description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance */ - PolicyTag.prototype.childPolicyTags = $util.emptyArray; + TagTemplateField.prototype.description = ""; /** - * Creates a new PolicyTag instance using the specified properties. + * TagTemplateField order. + * @member {number} order + * @memberof google.cloud.datacatalog.v1.TagTemplateField + * @instance + */ + TagTemplateField.prototype.order = 0; + + /** + * Creates a new TagTemplateField instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1.IPolicyTag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag instance + * @param {google.cloud.datacatalog.v1.ITagTemplateField=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField instance */ - PolicyTag.create = function create(properties) { - return new PolicyTag(properties); + TagTemplateField.create = function create(properties) { + return new TagTemplateField(properties); }; /** - * Encodes the specified PolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1.PolicyTag.verify|verify} messages. + * Encodes the specified TagTemplateField message. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplateField.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1.IPolicyTag} message PolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITagTemplateField} message TagTemplateField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PolicyTag.encode = function encode(message, writer) { + TagTemplateField.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + $root.google.cloud.datacatalog.v1.FieldType.encode(message.type, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.isRequired != null && Object.hasOwnProperty.call(message, "isRequired")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.isRequired); if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.parentPolicyTag != null && Object.hasOwnProperty.call(message, "parentPolicyTag")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.parentPolicyTag); - if (message.childPolicyTags != null && message.childPolicyTags.length) - for (var i = 0; i < message.childPolicyTags.length; ++i) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.childPolicyTags[i]); + writer.uint32(/* id 4, wireType 2 =*/34).string(message.description); + if (message.order != null && Object.hasOwnProperty.call(message, "order")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.order); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.name); return writer; }; /** - * Encodes the specified PolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PolicyTag.verify|verify} messages. + * Encodes the specified TagTemplateField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TagTemplateField.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1.IPolicyTag} message PolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITagTemplateField} message TagTemplateField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PolicyTag.encodeDelimited = function encodeDelimited(message, writer) { + TagTemplateField.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a PolicyTag message from the specified reader or buffer. + * Decodes a TagTemplateField message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PolicyTag.decode = function decode(reader, length) { + TagTemplateField.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PolicyTag(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TagTemplateField(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { + case 6: { message.name = reader.string(); break; } - case 2: { + case 1: { message.displayName = reader.string(); break; } + case 2: { + message.type = $root.google.cloud.datacatalog.v1.FieldType.decode(reader, reader.uint32()); + break; + } case 3: { - message.description = reader.string(); + message.isRequired = reader.bool(); break; } case 4: { - message.parentPolicyTag = reader.string(); + message.description = reader.string(); break; } case 5: { - if (!(message.childPolicyTags && message.childPolicyTags.length)) - message.childPolicyTags = []; - message.childPolicyTags.push(reader.string()); + message.order = reader.int32(); break; } default: @@ -24473,30 +25344,30 @@ }; /** - * Decodes a PolicyTag message from the specified reader or buffer, length delimited. + * Decodes a TagTemplateField message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PolicyTag.decodeDelimited = function decodeDelimited(reader) { + TagTemplateField.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a PolicyTag message. + * Verifies a TagTemplateField message. * @function verify - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - PolicyTag.verify = function verify(message) { + TagTemplateField.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) @@ -24505,137 +25376,137 @@ if (message.displayName != null && message.hasOwnProperty("displayName")) if (!$util.isString(message.displayName)) return "displayName: string expected"; + if (message.type != null && message.hasOwnProperty("type")) { + var error = $root.google.cloud.datacatalog.v1.FieldType.verify(message.type); + if (error) + return "type." + error; + } + if (message.isRequired != null && message.hasOwnProperty("isRequired")) + if (typeof message.isRequired !== "boolean") + return "isRequired: boolean expected"; if (message.description != null && message.hasOwnProperty("description")) if (!$util.isString(message.description)) return "description: string expected"; - if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) - if (!$util.isString(message.parentPolicyTag)) - return "parentPolicyTag: string expected"; - if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { - if (!Array.isArray(message.childPolicyTags)) - return "childPolicyTags: array expected"; - for (var i = 0; i < message.childPolicyTags.length; ++i) - if (!$util.isString(message.childPolicyTags[i])) - return "childPolicyTags: string[] expected"; - } + if (message.order != null && message.hasOwnProperty("order")) + if (!$util.isInteger(message.order)) + return "order: integer expected"; return null; }; /** - * Creates a PolicyTag message from a plain object. Also converts values to their respective internal types. + * Creates a TagTemplateField message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1.TagTemplateField} TagTemplateField */ - PolicyTag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.PolicyTag) + TagTemplateField.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TagTemplateField) return object; - var message = new $root.google.cloud.datacatalog.v1.PolicyTag(); + var message = new $root.google.cloud.datacatalog.v1.TagTemplateField(); if (object.name != null) message.name = String(object.name); if (object.displayName != null) message.displayName = String(object.displayName); + if (object.type != null) { + if (typeof object.type !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TagTemplateField.type: object expected"); + message.type = $root.google.cloud.datacatalog.v1.FieldType.fromObject(object.type); + } + if (object.isRequired != null) + message.isRequired = Boolean(object.isRequired); if (object.description != null) message.description = String(object.description); - if (object.parentPolicyTag != null) - message.parentPolicyTag = String(object.parentPolicyTag); - if (object.childPolicyTags) { - if (!Array.isArray(object.childPolicyTags)) - throw TypeError(".google.cloud.datacatalog.v1.PolicyTag.childPolicyTags: array expected"); - message.childPolicyTags = []; - for (var i = 0; i < object.childPolicyTags.length; ++i) - message.childPolicyTags[i] = String(object.childPolicyTags[i]); - } + if (object.order != null) + message.order = object.order | 0; return message; }; /** - * Creates a plain object from a PolicyTag message. Also converts values to other types if specified. + * Creates a plain object from a TagTemplateField message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1.PolicyTag} message PolicyTag + * @param {google.cloud.datacatalog.v1.TagTemplateField} message TagTemplateField * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - PolicyTag.toObject = function toObject(message, options) { + TagTemplateField.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.childPolicyTags = []; if (options.defaults) { - object.name = ""; object.displayName = ""; + object.type = null; + object.isRequired = false; object.description = ""; - object.parentPolicyTag = ""; + object.order = 0; + object.name = ""; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; + if (message.type != null && message.hasOwnProperty("type")) + object.type = $root.google.cloud.datacatalog.v1.FieldType.toObject(message.type, options); + if (message.isRequired != null && message.hasOwnProperty("isRequired")) + object.isRequired = message.isRequired; if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; - if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) - object.parentPolicyTag = message.parentPolicyTag; - if (message.childPolicyTags && message.childPolicyTags.length) { - object.childPolicyTags = []; - for (var j = 0; j < message.childPolicyTags.length; ++j) - object.childPolicyTags[j] = message.childPolicyTags[j]; - } + if (message.order != null && message.hasOwnProperty("order")) + object.order = message.order; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this PolicyTag to JSON. + * Converts this TagTemplateField to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @instance * @returns {Object.} JSON object */ - PolicyTag.prototype.toJSON = function toJSON() { + TagTemplateField.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for PolicyTag + * Gets the default type url for TagTemplateField * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.PolicyTag + * @memberof google.cloud.datacatalog.v1.TagTemplateField * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - PolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TagTemplateField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.PolicyTag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TagTemplateField"; }; - return PolicyTag; + return TagTemplateField; })(); - v1.CreateTaxonomyRequest = (function() { + v1.FieldType = (function() { /** - * Properties of a CreateTaxonomyRequest. + * Properties of a FieldType. * @memberof google.cloud.datacatalog.v1 - * @interface ICreateTaxonomyRequest - * @property {string|null} [parent] CreateTaxonomyRequest parent - * @property {google.cloud.datacatalog.v1.ITaxonomy|null} [taxonomy] CreateTaxonomyRequest taxonomy + * @interface IFieldType + * @property {google.cloud.datacatalog.v1.FieldType.PrimitiveType|null} [primitiveType] FieldType primitiveType + * @property {google.cloud.datacatalog.v1.FieldType.IEnumType|null} [enumType] FieldType enumType */ /** - * Constructs a new CreateTaxonomyRequest. + * Constructs a new FieldType. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a CreateTaxonomyRequest. - * @implements ICreateTaxonomyRequest + * @classdesc Represents a FieldType. + * @implements IFieldType * @constructor - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IFieldType=} [properties] Properties to set */ - function CreateTaxonomyRequest(properties) { + function FieldType(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -24643,89 +25514,103 @@ } /** - * CreateTaxonomyRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * FieldType primitiveType. + * @member {google.cloud.datacatalog.v1.FieldType.PrimitiveType|null|undefined} primitiveType + * @memberof google.cloud.datacatalog.v1.FieldType * @instance */ - CreateTaxonomyRequest.prototype.parent = ""; + FieldType.prototype.primitiveType = null; /** - * CreateTaxonomyRequest taxonomy. - * @member {google.cloud.datacatalog.v1.ITaxonomy|null|undefined} taxonomy - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * FieldType enumType. + * @member {google.cloud.datacatalog.v1.FieldType.IEnumType|null|undefined} enumType + * @memberof google.cloud.datacatalog.v1.FieldType * @instance */ - CreateTaxonomyRequest.prototype.taxonomy = null; + FieldType.prototype.enumType = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Creates a new CreateTaxonomyRequest instance using the specified properties. + * FieldType typeDecl. + * @member {"primitiveType"|"enumType"|undefined} typeDecl + * @memberof google.cloud.datacatalog.v1.FieldType + * @instance + */ + Object.defineProperty(FieldType.prototype, "typeDecl", { + get: $util.oneOfGetter($oneOfFields = ["primitiveType", "enumType"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new FieldType instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1.IFieldType=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.FieldType} FieldType instance */ - CreateTaxonomyRequest.create = function create(properties) { - return new CreateTaxonomyRequest(properties); + FieldType.create = function create(properties) { + return new FieldType(properties); }; /** - * Encodes the specified CreateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.CreateTaxonomyRequest.verify|verify} messages. + * Encodes the specified FieldType message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IFieldType} message FieldType message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTaxonomyRequest.encode = function encode(message, writer) { + FieldType.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) - $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.primitiveType != null && Object.hasOwnProperty.call(message, "primitiveType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.primitiveType); + if (message.enumType != null && Object.hasOwnProperty.call(message, "enumType")) + $root.google.cloud.datacatalog.v1.FieldType.EnumType.encode(message.enumType, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified CreateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CreateTaxonomyRequest.verify|verify} messages. + * Encodes the specified FieldType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static - * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IFieldType} message FieldType message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + FieldType.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateTaxonomyRequest message from the specified reader or buffer. + * Decodes a FieldType message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.FieldType} FieldType * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTaxonomyRequest.decode = function decode(reader, length) { + FieldType.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.primitiveType = reader.int32(); break; } case 2: { - message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32()); + message.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.decode(reader, reader.uint32()); break; } default: @@ -24737,578 +25622,637 @@ }; /** - * Decodes a CreateTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a FieldType message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.FieldType} FieldType * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + FieldType.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateTaxonomyRequest message. + * Verifies a FieldType message. * @function verify - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateTaxonomyRequest.verify = function verify(message) { + FieldType.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { - var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomy); - if (error) - return "taxonomy." + error; - } - return null; - }; - - /** - * Creates a CreateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest - */ - CreateTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.taxonomy != null) { - if (typeof object.taxonomy !== "object") - throw TypeError(".google.cloud.datacatalog.v1.CreateTaxonomyRequest.taxonomy: object expected"); - message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomy); - } - return message; - }; - - /** - * Creates a plain object from a CreateTaxonomyRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.CreateTaxonomyRequest} message CreateTaxonomyRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - CreateTaxonomyRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.parent = ""; - object.taxonomy = null; - } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - object.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomy, options); - return object; - }; - - /** - * Converts this CreateTaxonomyRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest - * @instance - * @returns {Object.} JSON object - */ - CreateTaxonomyRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for CreateTaxonomyRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - CreateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.CreateTaxonomyRequest"; - }; - - return CreateTaxonomyRequest; - })(); - - v1.DeleteTaxonomyRequest = (function() { - - /** - * Properties of a DeleteTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1 - * @interface IDeleteTaxonomyRequest - * @property {string|null} [name] DeleteTaxonomyRequest name - */ - - /** - * Constructs a new DeleteTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DeleteTaxonomyRequest. - * @implements IDeleteTaxonomyRequest - * @constructor - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest=} [properties] Properties to set - */ - function DeleteTaxonomyRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * DeleteTaxonomyRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @instance - */ - DeleteTaxonomyRequest.prototype.name = ""; - - /** - * Creates a new DeleteTaxonomyRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest instance - */ - DeleteTaxonomyRequest.create = function create(properties) { - return new DeleteTaxonomyRequest(properties); - }; - - /** - * Encodes the specified DeleteTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.DeleteTaxonomyRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - DeleteTaxonomyRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - return writer; - }; - - /** - * Encodes the specified DeleteTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DeleteTaxonomyRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - DeleteTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - DeleteTaxonomyRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } + var properties = {}; + if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { + properties.typeDecl = 1; + switch (message.primitiveType) { default: - reader.skipType(tag & 7); + return "primitiveType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: break; } } - return message; - }; - - /** - * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - DeleteTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a DeleteTaxonomyRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - DeleteTaxonomyRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.enumType != null && message.hasOwnProperty("enumType")) { + if (properties.typeDecl === 1) + return "typeDecl: multiple values"; + properties.typeDecl = 1; + { + var error = $root.google.cloud.datacatalog.v1.FieldType.EnumType.verify(message.enumType); + if (error) + return "enumType." + error; + } + } return null; }; /** - * Creates a DeleteTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a FieldType message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.FieldType} FieldType */ - DeleteTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest) + FieldType.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.FieldType) return object; - var message = new $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.FieldType(); + switch (object.primitiveType) { + default: + if (typeof object.primitiveType === "number") { + message.primitiveType = object.primitiveType; + break; + } + break; + case "PRIMITIVE_TYPE_UNSPECIFIED": + case 0: + message.primitiveType = 0; + break; + case "DOUBLE": + case 1: + message.primitiveType = 1; + break; + case "STRING": + case 2: + message.primitiveType = 2; + break; + case "BOOL": + case 3: + message.primitiveType = 3; + break; + case "TIMESTAMP": + case 4: + message.primitiveType = 4; + break; + case "RICHTEXT": + case 5: + message.primitiveType = 5; + break; + } + if (object.enumType != null) { + if (typeof object.enumType !== "object") + throw TypeError(".google.cloud.datacatalog.v1.FieldType.enumType: object expected"); + message.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.fromObject(object.enumType); + } return message; }; /** - * Creates a plain object from a DeleteTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a FieldType message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static - * @param {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} message DeleteTaxonomyRequest + * @param {google.cloud.datacatalog.v1.FieldType} message FieldType * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteTaxonomyRequest.toObject = function toObject(message, options) { + FieldType.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { + object.primitiveType = options.enums === String ? $root.google.cloud.datacatalog.v1.FieldType.PrimitiveType[message.primitiveType] === undefined ? message.primitiveType : $root.google.cloud.datacatalog.v1.FieldType.PrimitiveType[message.primitiveType] : message.primitiveType; + if (options.oneofs) + object.typeDecl = "primitiveType"; + } + if (message.enumType != null && message.hasOwnProperty("enumType")) { + object.enumType = $root.google.cloud.datacatalog.v1.FieldType.EnumType.toObject(message.enumType, options); + if (options.oneofs) + object.typeDecl = "enumType"; + } return object; }; /** - * Converts this DeleteTaxonomyRequest to JSON. + * Converts this FieldType to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @instance * @returns {Object.} JSON object */ - DeleteTaxonomyRequest.prototype.toJSON = function toJSON() { + FieldType.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteTaxonomyRequest + * Gets the default type url for FieldType * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.FieldType * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FieldType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DeleteTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType"; }; - return DeleteTaxonomyRequest; - })(); - - v1.UpdateTaxonomyRequest = (function() { - /** - * Properties of an UpdateTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1 - * @interface IUpdateTaxonomyRequest - * @property {google.cloud.datacatalog.v1.ITaxonomy|null} [taxonomy] UpdateTaxonomyRequest taxonomy - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTaxonomyRequest updateMask + * PrimitiveType enum. + * @name google.cloud.datacatalog.v1.FieldType.PrimitiveType + * @enum {number} + * @property {number} PRIMITIVE_TYPE_UNSPECIFIED=0 PRIMITIVE_TYPE_UNSPECIFIED value + * @property {number} DOUBLE=1 DOUBLE value + * @property {number} STRING=2 STRING value + * @property {number} BOOL=3 BOOL value + * @property {number} TIMESTAMP=4 TIMESTAMP value + * @property {number} RICHTEXT=5 RICHTEXT value */ + FieldType.PrimitiveType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "PRIMITIVE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "DOUBLE"] = 1; + values[valuesById[2] = "STRING"] = 2; + values[valuesById[3] = "BOOL"] = 3; + values[valuesById[4] = "TIMESTAMP"] = 4; + values[valuesById[5] = "RICHTEXT"] = 5; + return values; + })(); - /** - * Constructs a new UpdateTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an UpdateTaxonomyRequest. - * @implements IUpdateTaxonomyRequest - * @constructor - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest=} [properties] Properties to set - */ - function UpdateTaxonomyRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + FieldType.EnumType = (function() { - /** - * UpdateTaxonomyRequest taxonomy. - * @member {google.cloud.datacatalog.v1.ITaxonomy|null|undefined} taxonomy - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @instance - */ - UpdateTaxonomyRequest.prototype.taxonomy = null; + /** + * Properties of an EnumType. + * @memberof google.cloud.datacatalog.v1.FieldType + * @interface IEnumType + * @property {Array.|null} [allowedValues] EnumType allowedValues + */ - /** - * UpdateTaxonomyRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @instance - */ - UpdateTaxonomyRequest.prototype.updateMask = null; + /** + * Constructs a new EnumType. + * @memberof google.cloud.datacatalog.v1.FieldType + * @classdesc Represents an EnumType. + * @implements IEnumType + * @constructor + * @param {google.cloud.datacatalog.v1.FieldType.IEnumType=} [properties] Properties to set + */ + function EnumType(properties) { + this.allowedValues = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new UpdateTaxonomyRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest instance - */ - UpdateTaxonomyRequest.create = function create(properties) { - return new UpdateTaxonomyRequest(properties); - }; + /** + * EnumType allowedValues. + * @member {Array.} allowedValues + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @instance + */ + EnumType.prototype.allowedValues = $util.emptyArray; - /** - * Encodes the specified UpdateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UpdateTaxonomyRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UpdateTaxonomyRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) - $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - return writer; - }; + /** + * Creates a new EnumType instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1.FieldType.IEnumType=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType instance + */ + EnumType.create = function create(properties) { + return new EnumType(properties); + }; - /** - * Encodes the specified UpdateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UpdateTaxonomyRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UpdateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified EnumType message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1.FieldType.IEnumType} message EnumType message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumType.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.allowedValues != null && message.allowedValues.length) + for (var i = 0; i < message.allowedValues.length; ++i) + $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.encode(message.allowedValues[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; - /** - * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UpdateTaxonomyRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32()); - break; - } - case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Encodes the specified EnumType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1.FieldType.IEnumType} message EnumType message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumType.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UpdateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes an EnumType message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumType.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.allowedValues && message.allowedValues.length)) + message.allowedValues = []; + message.allowedValues.push($root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Verifies an UpdateTaxonomyRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - UpdateTaxonomyRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { - var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomy); - if (error) - return "taxonomy." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } - return null; - }; + /** + * Decodes an EnumType message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumType.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates an UpdateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest - */ - UpdateTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest) + /** + * Verifies an EnumType message. + * @function verify + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumType.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.allowedValues != null && message.hasOwnProperty("allowedValues")) { + if (!Array.isArray(message.allowedValues)) + return "allowedValues: array expected"; + for (var i = 0; i < message.allowedValues.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify(message.allowedValues[i]); + if (error) + return "allowedValues." + error; + } + } + return null; + }; + + /** + * Creates an EnumType message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType} EnumType + */ + EnumType.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.FieldType.EnumType) + return object; + var message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType(); + if (object.allowedValues) { + if (!Array.isArray(object.allowedValues)) + throw TypeError(".google.cloud.datacatalog.v1.FieldType.EnumType.allowedValues: array expected"); + message.allowedValues = []; + for (var i = 0; i < object.allowedValues.length; ++i) { + if (typeof object.allowedValues[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.FieldType.EnumType.allowedValues: object expected"); + message.allowedValues[i] = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.fromObject(object.allowedValues[i]); + } + } + return message; + }; + + /** + * Creates a plain object from an EnumType message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1.FieldType.EnumType} message EnumType + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumType.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.allowedValues = []; + if (message.allowedValues && message.allowedValues.length) { + object.allowedValues = []; + for (var j = 0; j < message.allowedValues.length; ++j) + object.allowedValues[j] = $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.toObject(message.allowedValues[j], options); + } return object; - var message = new $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest(); - if (object.taxonomy != null) { - if (typeof object.taxonomy !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UpdateTaxonomyRequest.taxonomy: object expected"); - message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomy); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UpdateTaxonomyRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } - return message; - }; + }; - /** - * Creates a plain object from an UpdateTaxonomyRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} message UpdateTaxonomyRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - UpdateTaxonomyRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.taxonomy = null; - object.updateMask = null; - } - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - object.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomy, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); - return object; - }; + /** + * Converts this EnumType to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @instance + * @returns {Object.} JSON object + */ + EnumType.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Converts this UpdateTaxonomyRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @instance - * @returns {Object.} JSON object - */ - UpdateTaxonomyRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Gets the default type url for EnumType + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType.EnumType"; + }; - /** - * Gets the default type url for UpdateTaxonomyRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - UpdateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UpdateTaxonomyRequest"; - }; + EnumType.EnumValue = (function() { - return UpdateTaxonomyRequest; + /** + * Properties of an EnumValue. + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @interface IEnumValue + * @property {string|null} [displayName] EnumValue displayName + */ + + /** + * Constructs a new EnumValue. + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType + * @classdesc Represents an EnumValue. + * @implements IEnumValue + * @constructor + * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue=} [properties] Properties to set + */ + function EnumValue(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * EnumValue displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @instance + */ + EnumValue.prototype.displayName = ""; + + /** + * Creates a new EnumValue instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue instance + */ + EnumValue.create = function create(properties) { + return new EnumValue(properties); + }; + + /** + * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + return writer; + }; + + /** + * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EnumValue message. + * @function verify + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumValue.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + return null; + }; + + /** + * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} EnumValue + */ + EnumValue.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue) + return object; + var message = new $root.google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue(); + if (object.displayName != null) + message.displayName = String(object.displayName); + return message; + }; + + /** + * Creates a plain object from an EnumValue message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue} message EnumValue + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumValue.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.displayName = ""; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + return object; + }; + + /** + * Converts this EnumValue to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @instance + * @returns {Object.} JSON object + */ + EnumValue.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EnumValue + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.FieldType.EnumType.EnumValue"; + }; + + return EnumValue; + })(); + + return EnumType; + })(); + + return FieldType; })(); - v1.ListTaxonomiesRequest = (function() { + v1.UsageStats = (function() { /** - * Properties of a ListTaxonomiesRequest. + * Properties of a UsageStats. * @memberof google.cloud.datacatalog.v1 - * @interface IListTaxonomiesRequest - * @property {string|null} [parent] ListTaxonomiesRequest parent - * @property {number|null} [pageSize] ListTaxonomiesRequest pageSize - * @property {string|null} [pageToken] ListTaxonomiesRequest pageToken + * @interface IUsageStats + * @property {number|null} [totalCompletions] UsageStats totalCompletions + * @property {number|null} [totalFailures] UsageStats totalFailures + * @property {number|null} [totalCancellations] UsageStats totalCancellations + * @property {number|null} [totalExecutionTimeForCompletionsMillis] UsageStats totalExecutionTimeForCompletionsMillis */ /** - * Constructs a new ListTaxonomiesRequest. + * Constructs a new UsageStats. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListTaxonomiesRequest. - * @implements IListTaxonomiesRequest + * @classdesc Represents a UsageStats. + * @implements IUsageStats * @constructor - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUsageStats=} [properties] Properties to set */ - function ListTaxonomiesRequest(properties) { + function UsageStats(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -25316,103 +26260,117 @@ } /** - * ListTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * UsageStats totalCompletions. + * @member {number} totalCompletions + * @memberof google.cloud.datacatalog.v1.UsageStats * @instance */ - ListTaxonomiesRequest.prototype.parent = ""; + UsageStats.prototype.totalCompletions = 0; /** - * ListTaxonomiesRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * UsageStats totalFailures. + * @member {number} totalFailures + * @memberof google.cloud.datacatalog.v1.UsageStats * @instance */ - ListTaxonomiesRequest.prototype.pageSize = 0; + UsageStats.prototype.totalFailures = 0; /** - * ListTaxonomiesRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * UsageStats totalCancellations. + * @member {number} totalCancellations + * @memberof google.cloud.datacatalog.v1.UsageStats * @instance */ - ListTaxonomiesRequest.prototype.pageToken = ""; + UsageStats.prototype.totalCancellations = 0; /** - * Creates a new ListTaxonomiesRequest instance using the specified properties. + * UsageStats totalExecutionTimeForCompletionsMillis. + * @member {number} totalExecutionTimeForCompletionsMillis + * @memberof google.cloud.datacatalog.v1.UsageStats + * @instance + */ + UsageStats.prototype.totalExecutionTimeForCompletionsMillis = 0; + + /** + * Creates a new UsageStats instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest instance + * @param {google.cloud.datacatalog.v1.IUsageStats=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats instance */ - ListTaxonomiesRequest.create = function create(properties) { - return new ListTaxonomiesRequest(properties); + UsageStats.create = function create(properties) { + return new UsageStats(properties); }; /** - * Encodes the specified ListTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesRequest.verify|verify} messages. + * Encodes the specified UsageStats message. Does not implicitly {@link google.cloud.datacatalog.v1.UsageStats.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUsageStats} message UsageStats message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesRequest.encode = function encode(message, writer) { + UsageStats.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.totalCompletions != null && Object.hasOwnProperty.call(message, "totalCompletions")) + writer.uint32(/* id 1, wireType 5 =*/13).float(message.totalCompletions); + if (message.totalFailures != null && Object.hasOwnProperty.call(message, "totalFailures")) + writer.uint32(/* id 2, wireType 5 =*/21).float(message.totalFailures); + if (message.totalCancellations != null && Object.hasOwnProperty.call(message, "totalCancellations")) + writer.uint32(/* id 3, wireType 5 =*/29).float(message.totalCancellations); + if (message.totalExecutionTimeForCompletionsMillis != null && Object.hasOwnProperty.call(message, "totalExecutionTimeForCompletionsMillis")) + writer.uint32(/* id 4, wireType 5 =*/37).float(message.totalExecutionTimeForCompletionsMillis); return writer; }; /** - * Encodes the specified ListTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesRequest.verify|verify} messages. + * Encodes the specified UsageStats message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UsageStats.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUsageStats} message UsageStats message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + UsageStats.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTaxonomiesRequest message from the specified reader or buffer. + * Decodes a UsageStats message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesRequest.decode = function decode(reader, length) { + UsageStats.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UsageStats(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.totalCompletions = reader.float(); break; } case 2: { - message.pageSize = reader.int32(); + message.totalFailures = reader.float(); break; } case 3: { - message.pageToken = reader.string(); + message.totalCancellations = reader.float(); + break; + } + case 4: { + message.totalExecutionTimeForCompletionsMillis = reader.float(); break; } default: @@ -25424,141 +26382,147 @@ }; /** - * Decodes a ListTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes a UsageStats message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + UsageStats.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTaxonomiesRequest message. + * Verifies a UsageStats message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTaxonomiesRequest.verify = function verify(message) { + UsageStats.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; + if (message.totalCompletions != null && message.hasOwnProperty("totalCompletions")) + if (typeof message.totalCompletions !== "number") + return "totalCompletions: number expected"; + if (message.totalFailures != null && message.hasOwnProperty("totalFailures")) + if (typeof message.totalFailures !== "number") + return "totalFailures: number expected"; + if (message.totalCancellations != null && message.hasOwnProperty("totalCancellations")) + if (typeof message.totalCancellations !== "number") + return "totalCancellations: number expected"; + if (message.totalExecutionTimeForCompletionsMillis != null && message.hasOwnProperty("totalExecutionTimeForCompletionsMillis")) + if (typeof message.totalExecutionTimeForCompletionsMillis !== "number") + return "totalExecutionTimeForCompletionsMillis: number expected"; return null; }; /** - * Creates a ListTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a UsageStats message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UsageStats} UsageStats */ - ListTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest) + UsageStats.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UsageStats) return object; - var message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); + var message = new $root.google.cloud.datacatalog.v1.UsageStats(); + if (object.totalCompletions != null) + message.totalCompletions = Number(object.totalCompletions); + if (object.totalFailures != null) + message.totalFailures = Number(object.totalFailures); + if (object.totalCancellations != null) + message.totalCancellations = Number(object.totalCancellations); + if (object.totalExecutionTimeForCompletionsMillis != null) + message.totalExecutionTimeForCompletionsMillis = Number(object.totalExecutionTimeForCompletionsMillis); return message; }; /** - * Creates a plain object from a ListTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from a UsageStats message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static - * @param {google.cloud.datacatalog.v1.ListTaxonomiesRequest} message ListTaxonomiesRequest + * @param {google.cloud.datacatalog.v1.UsageStats} message UsageStats * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTaxonomiesRequest.toObject = function toObject(message, options) { + UsageStats.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; + object.totalCompletions = 0; + object.totalFailures = 0; + object.totalCancellations = 0; + object.totalExecutionTimeForCompletionsMillis = 0; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; + if (message.totalCompletions != null && message.hasOwnProperty("totalCompletions")) + object.totalCompletions = options.json && !isFinite(message.totalCompletions) ? String(message.totalCompletions) : message.totalCompletions; + if (message.totalFailures != null && message.hasOwnProperty("totalFailures")) + object.totalFailures = options.json && !isFinite(message.totalFailures) ? String(message.totalFailures) : message.totalFailures; + if (message.totalCancellations != null && message.hasOwnProperty("totalCancellations")) + object.totalCancellations = options.json && !isFinite(message.totalCancellations) ? String(message.totalCancellations) : message.totalCancellations; + if (message.totalExecutionTimeForCompletionsMillis != null && message.hasOwnProperty("totalExecutionTimeForCompletionsMillis")) + object.totalExecutionTimeForCompletionsMillis = options.json && !isFinite(message.totalExecutionTimeForCompletionsMillis) ? String(message.totalExecutionTimeForCompletionsMillis) : message.totalExecutionTimeForCompletionsMillis; return object; }; /** - * Converts this ListTaxonomiesRequest to JSON. + * Converts this UsageStats to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @instance * @returns {Object.} JSON object */ - ListTaxonomiesRequest.prototype.toJSON = function toJSON() { + UsageStats.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTaxonomiesRequest + * Gets the default type url for UsageStats * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UsageStats * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UsageStats.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UsageStats"; }; - return ListTaxonomiesRequest; + return UsageStats; })(); - v1.ListTaxonomiesResponse = (function() { + v1.CommonUsageStats = (function() { /** - * Properties of a ListTaxonomiesResponse. + * Properties of a CommonUsageStats. * @memberof google.cloud.datacatalog.v1 - * @interface IListTaxonomiesResponse - * @property {Array.|null} [taxonomies] ListTaxonomiesResponse taxonomies - * @property {string|null} [nextPageToken] ListTaxonomiesResponse nextPageToken + * @interface ICommonUsageStats + * @property {number|Long|null} [viewCount] CommonUsageStats viewCount */ /** - * Constructs a new ListTaxonomiesResponse. + * Constructs a new CommonUsageStats. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListTaxonomiesResponse. - * @implements IListTaxonomiesResponse + * @classdesc Represents a CommonUsageStats. + * @implements ICommonUsageStats * @constructor - * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ICommonUsageStats=} [properties] Properties to set */ - function ListTaxonomiesResponse(properties) { - this.taxonomies = []; + function CommonUsageStats(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -25566,92 +26530,89 @@ } /** - * ListTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * CommonUsageStats viewCount. + * @member {number|Long|null|undefined} viewCount + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @instance */ - ListTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + CommonUsageStats.prototype.viewCount = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * ListTaxonomiesResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * CommonUsageStats _viewCount. + * @member {"viewCount"|undefined} _viewCount + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @instance */ - ListTaxonomiesResponse.prototype.nextPageToken = ""; + Object.defineProperty(CommonUsageStats.prototype, "_viewCount", { + get: $util.oneOfGetter($oneOfFields = ["viewCount"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new ListTaxonomiesResponse instance using the specified properties. + * Creates a new CommonUsageStats instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1.ICommonUsageStats=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.CommonUsageStats} CommonUsageStats instance */ - ListTaxonomiesResponse.create = function create(properties) { - return new ListTaxonomiesResponse(properties); + CommonUsageStats.create = function create(properties) { + return new CommonUsageStats(properties); }; /** - * Encodes the specified ListTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesResponse.verify|verify} messages. + * Encodes the specified CommonUsageStats message. Does not implicitly {@link google.cloud.datacatalog.v1.CommonUsageStats.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICommonUsageStats} message CommonUsageStats message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesResponse.encode = function encode(message, writer) { + CommonUsageStats.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.viewCount != null && Object.hasOwnProperty.call(message, "viewCount")) + writer.uint32(/* id 1, wireType 0 =*/8).int64(message.viewCount); return writer; }; /** - * Encodes the specified ListTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesResponse.verify|verify} messages. + * Encodes the specified CommonUsageStats message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CommonUsageStats.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static - * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICommonUsageStats} message CommonUsageStats message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + CommonUsageStats.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTaxonomiesResponse message from the specified reader or buffer. + * Decodes a CommonUsageStats message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.CommonUsageStats} CommonUsageStats * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesResponse.decode = function decode(reader, length) { + CommonUsageStats.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CommonUsageStats(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32())); - break; - } - case 2: { - message.nextPageToken = reader.string(); + message.viewCount = reader.int64(); break; } default: @@ -25663,148 +26624,141 @@ }; /** - * Decodes a ListTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a CommonUsageStats message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.CommonUsageStats} CommonUsageStats * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + CommonUsageStats.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTaxonomiesResponse message. + * Verifies a CommonUsageStats message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTaxonomiesResponse.verify = function verify(message) { + CommonUsageStats.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } + var properties = {}; + if (message.viewCount != null && message.hasOwnProperty("viewCount")) { + properties._viewCount = 1; + if (!$util.isInteger(message.viewCount) && !(message.viewCount && $util.isInteger(message.viewCount.low) && $util.isInteger(message.viewCount.high))) + return "viewCount: integer|Long expected"; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; return null; }; /** - * Creates a ListTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a CommonUsageStats message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.CommonUsageStats} CommonUsageStats */ - ListTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse) + CommonUsageStats.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.CommonUsageStats) return object; - var message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1.ListTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ListTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomies[i]); - } - } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); + var message = new $root.google.cloud.datacatalog.v1.CommonUsageStats(); + if (object.viewCount != null) + if ($util.Long) + (message.viewCount = $util.Long.fromValue(object.viewCount)).unsigned = false; + else if (typeof object.viewCount === "string") + message.viewCount = parseInt(object.viewCount, 10); + else if (typeof object.viewCount === "number") + message.viewCount = object.viewCount; + else if (typeof object.viewCount === "object") + message.viewCount = new $util.LongBits(object.viewCount.low >>> 0, object.viewCount.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a ListTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a CommonUsageStats message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static - * @param {google.cloud.datacatalog.v1.ListTaxonomiesResponse} message ListTaxonomiesResponse + * @param {google.cloud.datacatalog.v1.CommonUsageStats} message CommonUsageStats * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTaxonomiesResponse.toObject = function toObject(message, options) { + CommonUsageStats.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomies[j], options); + if (message.viewCount != null && message.hasOwnProperty("viewCount")) { + if (typeof message.viewCount === "number") + object.viewCount = options.longs === String ? String(message.viewCount) : message.viewCount; + else + object.viewCount = options.longs === String ? $util.Long.prototype.toString.call(message.viewCount) : options.longs === Number ? new $util.LongBits(message.viewCount.low >>> 0, message.viewCount.high >>> 0).toNumber() : message.viewCount; + if (options.oneofs) + object._viewCount = "viewCount"; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this ListTaxonomiesResponse to JSON. + * Converts this CommonUsageStats to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @instance * @returns {Object.} JSON object */ - ListTaxonomiesResponse.prototype.toJSON = function toJSON() { + CommonUsageStats.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTaxonomiesResponse + * Gets the default type url for CommonUsageStats * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.CommonUsageStats * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CommonUsageStats.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.CommonUsageStats"; }; - return ListTaxonomiesResponse; + return CommonUsageStats; })(); - v1.GetTaxonomyRequest = (function() { + v1.UsageSignal = (function() { /** - * Properties of a GetTaxonomyRequest. + * Properties of a UsageSignal. * @memberof google.cloud.datacatalog.v1 - * @interface IGetTaxonomyRequest - * @property {string|null} [name] GetTaxonomyRequest name + * @interface IUsageSignal + * @property {google.protobuf.ITimestamp|null} [updateTime] UsageSignal updateTime + * @property {Object.|null} [usageWithinTimeRange] UsageSignal usageWithinTimeRange + * @property {Object.|null} [commonUsageWithinTimeRange] UsageSignal commonUsageWithinTimeRange + * @property {number|Long|null} [favoriteCount] UsageSignal favoriteCount */ /** - * Constructs a new GetTaxonomyRequest. + * Constructs a new UsageSignal. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a GetTaxonomyRequest. - * @implements IGetTaxonomyRequest + * @classdesc Represents a UsageSignal. + * @implements IUsageSignal * @constructor - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUsageSignal=} [properties] Properties to set */ - function GetTaxonomyRequest(properties) { + function UsageSignal(properties) { + this.usageWithinTimeRange = {}; + this.commonUsageWithinTimeRange = {}; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -25812,75 +26766,175 @@ } /** - * GetTaxonomyRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * UsageSignal updateTime. + * @member {google.protobuf.ITimestamp|null|undefined} updateTime + * @memberof google.cloud.datacatalog.v1.UsageSignal * @instance */ - GetTaxonomyRequest.prototype.name = ""; + UsageSignal.prototype.updateTime = null; /** - * Creates a new GetTaxonomyRequest instance using the specified properties. + * UsageSignal usageWithinTimeRange. + * @member {Object.} usageWithinTimeRange + * @memberof google.cloud.datacatalog.v1.UsageSignal + * @instance + */ + UsageSignal.prototype.usageWithinTimeRange = $util.emptyObject; + + /** + * UsageSignal commonUsageWithinTimeRange. + * @member {Object.} commonUsageWithinTimeRange + * @memberof google.cloud.datacatalog.v1.UsageSignal + * @instance + */ + UsageSignal.prototype.commonUsageWithinTimeRange = $util.emptyObject; + + /** + * UsageSignal favoriteCount. + * @member {number|Long|null|undefined} favoriteCount + * @memberof google.cloud.datacatalog.v1.UsageSignal + * @instance + */ + UsageSignal.prototype.favoriteCount = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * UsageSignal _favoriteCount. + * @member {"favoriteCount"|undefined} _favoriteCount + * @memberof google.cloud.datacatalog.v1.UsageSignal + * @instance + */ + Object.defineProperty(UsageSignal.prototype, "_favoriteCount", { + get: $util.oneOfGetter($oneOfFields = ["favoriteCount"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new UsageSignal instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1.IUsageSignal=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal instance */ - GetTaxonomyRequest.create = function create(properties) { - return new GetTaxonomyRequest(properties); + UsageSignal.create = function create(properties) { + return new UsageSignal(properties); }; /** - * Encodes the specified GetTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.GetTaxonomyRequest.verify|verify} messages. + * Encodes the specified UsageSignal message. Does not implicitly {@link google.cloud.datacatalog.v1.UsageSignal.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUsageSignal} message UsageSignal message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTaxonomyRequest.encode = function encode(message, writer) { + UsageSignal.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) + $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.usageWithinTimeRange != null && Object.hasOwnProperty.call(message, "usageWithinTimeRange")) + for (var keys = Object.keys(message.usageWithinTimeRange), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 2, wireType 2 =*/18).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1.UsageStats.encode(message.usageWithinTimeRange[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } + if (message.commonUsageWithinTimeRange != null && Object.hasOwnProperty.call(message, "commonUsageWithinTimeRange")) + for (var keys = Object.keys(message.commonUsageWithinTimeRange), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1.CommonUsageStats.encode(message.commonUsageWithinTimeRange[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } + if (message.favoriteCount != null && Object.hasOwnProperty.call(message, "favoriteCount")) + writer.uint32(/* id 4, wireType 0 =*/32).int64(message.favoriteCount); return writer; }; /** - * Encodes the specified GetTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GetTaxonomyRequest.verify|verify} messages. + * Encodes the specified UsageSignal message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UsageSignal.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static - * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUsageSignal} message UsageSignal message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + UsageSignal.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetTaxonomyRequest message from the specified reader or buffer. + * Decodes a UsageSignal message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTaxonomyRequest.decode = function decode(reader, length) { + UsageSignal.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GetTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UsageSignal(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 2: { + if (message.usageWithinTimeRange === $util.emptyObject) + message.usageWithinTimeRange = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.cloud.datacatalog.v1.UsageStats.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.usageWithinTimeRange[key] = value; + break; + } + case 3: { + if (message.commonUsageWithinTimeRange === $util.emptyObject) + message.commonUsageWithinTimeRange = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.cloud.datacatalog.v1.CommonUsageStats.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.commonUsageWithinTimeRange[key] = value; + break; + } + case 4: { + message.favoriteCount = reader.int64(); break; } default: @@ -25892,123 +26946,209 @@ }; /** - * Decodes a GetTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a UsageSignal message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + UsageSignal.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetTaxonomyRequest message. + * Verifies a UsageSignal message. * @function verify - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetTaxonomyRequest.verify = function verify(message) { + UsageSignal.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + var properties = {}; + if (message.updateTime != null && message.hasOwnProperty("updateTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.updateTime); + if (error) + return "updateTime." + error; + } + if (message.usageWithinTimeRange != null && message.hasOwnProperty("usageWithinTimeRange")) { + if (!$util.isObject(message.usageWithinTimeRange)) + return "usageWithinTimeRange: object expected"; + var key = Object.keys(message.usageWithinTimeRange); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.UsageStats.verify(message.usageWithinTimeRange[key[i]]); + if (error) + return "usageWithinTimeRange." + error; + } + } + if (message.commonUsageWithinTimeRange != null && message.hasOwnProperty("commonUsageWithinTimeRange")) { + if (!$util.isObject(message.commonUsageWithinTimeRange)) + return "commonUsageWithinTimeRange: object expected"; + var key = Object.keys(message.commonUsageWithinTimeRange); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.CommonUsageStats.verify(message.commonUsageWithinTimeRange[key[i]]); + if (error) + return "commonUsageWithinTimeRange." + error; + } + } + if (message.favoriteCount != null && message.hasOwnProperty("favoriteCount")) { + properties._favoriteCount = 1; + if (!$util.isInteger(message.favoriteCount) && !(message.favoriteCount && $util.isInteger(message.favoriteCount.low) && $util.isInteger(message.favoriteCount.high))) + return "favoriteCount: integer|Long expected"; + } return null; }; /** - * Creates a GetTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a UsageSignal message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.UsageSignal} UsageSignal */ - GetTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.GetTaxonomyRequest) + UsageSignal.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UsageSignal) return object; - var message = new $root.google.cloud.datacatalog.v1.GetTaxonomyRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.UsageSignal(); + if (object.updateTime != null) { + if (typeof object.updateTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.updateTime: object expected"); + message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); + } + if (object.usageWithinTimeRange) { + if (typeof object.usageWithinTimeRange !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.usageWithinTimeRange: object expected"); + message.usageWithinTimeRange = {}; + for (var keys = Object.keys(object.usageWithinTimeRange), i = 0; i < keys.length; ++i) { + if (typeof object.usageWithinTimeRange[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.usageWithinTimeRange: object expected"); + message.usageWithinTimeRange[keys[i]] = $root.google.cloud.datacatalog.v1.UsageStats.fromObject(object.usageWithinTimeRange[keys[i]]); + } + } + if (object.commonUsageWithinTimeRange) { + if (typeof object.commonUsageWithinTimeRange !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.commonUsageWithinTimeRange: object expected"); + message.commonUsageWithinTimeRange = {}; + for (var keys = Object.keys(object.commonUsageWithinTimeRange), i = 0; i < keys.length; ++i) { + if (typeof object.commonUsageWithinTimeRange[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UsageSignal.commonUsageWithinTimeRange: object expected"); + message.commonUsageWithinTimeRange[keys[i]] = $root.google.cloud.datacatalog.v1.CommonUsageStats.fromObject(object.commonUsageWithinTimeRange[keys[i]]); + } + } + if (object.favoriteCount != null) + if ($util.Long) + (message.favoriteCount = $util.Long.fromValue(object.favoriteCount)).unsigned = false; + else if (typeof object.favoriteCount === "string") + message.favoriteCount = parseInt(object.favoriteCount, 10); + else if (typeof object.favoriteCount === "number") + message.favoriteCount = object.favoriteCount; + else if (typeof object.favoriteCount === "object") + message.favoriteCount = new $util.LongBits(object.favoriteCount.low >>> 0, object.favoriteCount.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a GetTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a UsageSignal message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static - * @param {google.cloud.datacatalog.v1.GetTaxonomyRequest} message GetTaxonomyRequest + * @param {google.cloud.datacatalog.v1.UsageSignal} message UsageSignal * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetTaxonomyRequest.toObject = function toObject(message, options) { + UsageSignal.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.objects || options.defaults) { + object.usageWithinTimeRange = {}; + object.commonUsageWithinTimeRange = {}; + } if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.updateTime = null; + if (message.updateTime != null && message.hasOwnProperty("updateTime")) + object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); + var keys2; + if (message.usageWithinTimeRange && (keys2 = Object.keys(message.usageWithinTimeRange)).length) { + object.usageWithinTimeRange = {}; + for (var j = 0; j < keys2.length; ++j) + object.usageWithinTimeRange[keys2[j]] = $root.google.cloud.datacatalog.v1.UsageStats.toObject(message.usageWithinTimeRange[keys2[j]], options); + } + if (message.commonUsageWithinTimeRange && (keys2 = Object.keys(message.commonUsageWithinTimeRange)).length) { + object.commonUsageWithinTimeRange = {}; + for (var j = 0; j < keys2.length; ++j) + object.commonUsageWithinTimeRange[keys2[j]] = $root.google.cloud.datacatalog.v1.CommonUsageStats.toObject(message.commonUsageWithinTimeRange[keys2[j]], options); + } + if (message.favoriteCount != null && message.hasOwnProperty("favoriteCount")) { + if (typeof message.favoriteCount === "number") + object.favoriteCount = options.longs === String ? String(message.favoriteCount) : message.favoriteCount; + else + object.favoriteCount = options.longs === String ? $util.Long.prototype.toString.call(message.favoriteCount) : options.longs === Number ? new $util.LongBits(message.favoriteCount.low >>> 0, message.favoriteCount.high >>> 0).toNumber() : message.favoriteCount; + if (options.oneofs) + object._favoriteCount = "favoriteCount"; + } return object; }; /** - * Converts this GetTaxonomyRequest to JSON. + * Converts this UsageSignal to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @instance * @returns {Object.} JSON object */ - GetTaxonomyRequest.prototype.toJSON = function toJSON() { + UsageSignal.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetTaxonomyRequest + * Gets the default type url for UsageSignal * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.UsageSignal * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UsageSignal.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.GetTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UsageSignal"; }; - return GetTaxonomyRequest; + return UsageSignal; })(); - v1.CreatePolicyTagRequest = (function() { + v1.TaggedEntry = (function() { /** - * Properties of a CreatePolicyTagRequest. + * Properties of a TaggedEntry. * @memberof google.cloud.datacatalog.v1 - * @interface ICreatePolicyTagRequest - * @property {string|null} [parent] CreatePolicyTagRequest parent - * @property {google.cloud.datacatalog.v1.IPolicyTag|null} [policyTag] CreatePolicyTagRequest policyTag + * @interface ITaggedEntry + * @property {google.cloud.datacatalog.v1.IEntry|null} [v1Entry] TaggedEntry v1Entry + * @property {Array.|null} [presentTags] TaggedEntry presentTags + * @property {Array.|null} [absentTags] TaggedEntry absentTags */ /** - * Constructs a new CreatePolicyTagRequest. + * Constructs a new TaggedEntry. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a CreatePolicyTagRequest. - * @implements ICreatePolicyTagRequest + * @classdesc Represents a TaggedEntry. + * @implements ITaggedEntry * @constructor - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITaggedEntry=} [properties] Properties to set */ - function CreatePolicyTagRequest(properties) { + function TaggedEntry(properties) { + this.presentTags = []; + this.absentTags = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26016,89 +27156,123 @@ } /** - * CreatePolicyTagRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * TaggedEntry v1Entry. + * @member {google.cloud.datacatalog.v1.IEntry|null|undefined} v1Entry + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @instance */ - CreatePolicyTagRequest.prototype.parent = ""; + TaggedEntry.prototype.v1Entry = null; /** - * CreatePolicyTagRequest policyTag. - * @member {google.cloud.datacatalog.v1.IPolicyTag|null|undefined} policyTag - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * TaggedEntry presentTags. + * @member {Array.} presentTags + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @instance */ - CreatePolicyTagRequest.prototype.policyTag = null; + TaggedEntry.prototype.presentTags = $util.emptyArray; /** - * Creates a new CreatePolicyTagRequest instance using the specified properties. + * TaggedEntry absentTags. + * @member {Array.} absentTags + * @memberof google.cloud.datacatalog.v1.TaggedEntry + * @instance + */ + TaggedEntry.prototype.absentTags = $util.emptyArray; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * TaggedEntry entry. + * @member {"v1Entry"|undefined} entry + * @memberof google.cloud.datacatalog.v1.TaggedEntry + * @instance + */ + Object.defineProperty(TaggedEntry.prototype, "entry", { + get: $util.oneOfGetter($oneOfFields = ["v1Entry"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new TaggedEntry instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest instance + * @param {google.cloud.datacatalog.v1.ITaggedEntry=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.TaggedEntry} TaggedEntry instance */ - CreatePolicyTagRequest.create = function create(properties) { - return new CreatePolicyTagRequest(properties); + TaggedEntry.create = function create(properties) { + return new TaggedEntry(properties); }; /** - * Encodes the specified CreatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.CreatePolicyTagRequest.verify|verify} messages. + * Encodes the specified TaggedEntry message. Does not implicitly {@link google.cloud.datacatalog.v1.TaggedEntry.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITaggedEntry} message TaggedEntry message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreatePolicyTagRequest.encode = function encode(message, writer) { + TaggedEntry.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) - $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.v1Entry != null && Object.hasOwnProperty.call(message, "v1Entry")) + $root.google.cloud.datacatalog.v1.Entry.encode(message.v1Entry, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.presentTags != null && message.presentTags.length) + for (var i = 0; i < message.presentTags.length; ++i) + $root.google.cloud.datacatalog.v1.Tag.encode(message.presentTags[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.absentTags != null && message.absentTags.length) + for (var i = 0; i < message.absentTags.length; ++i) + $root.google.cloud.datacatalog.v1.Tag.encode(message.absentTags[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified CreatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CreatePolicyTagRequest.verify|verify} messages. + * Encodes the specified TaggedEntry message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.TaggedEntry.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static - * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITaggedEntry} message TaggedEntry message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + TaggedEntry.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreatePolicyTagRequest message from the specified reader or buffer. + * Decodes a TaggedEntry message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.TaggedEntry} TaggedEntry * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreatePolicyTagRequest.decode = function decode(reader, length) { + TaggedEntry.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.TaggedEntry(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.v1Entry = $root.google.cloud.datacatalog.v1.Entry.decode(reader, reader.uint32()); break; } case 2: { - message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32()); + if (!(message.presentTags && message.presentTags.length)) + message.presentTags = []; + message.presentTags.push($root.google.cloud.datacatalog.v1.Tag.decode(reader, reader.uint32())); + break; + } + case 3: { + if (!(message.absentTags && message.absentTags.length)) + message.absentTags = []; + message.absentTags.push($root.google.cloud.datacatalog.v1.Tag.decode(reader, reader.uint32())); break; } default: @@ -26110,136 +27284,184 @@ }; /** - * Decodes a CreatePolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a TaggedEntry message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.TaggedEntry} TaggedEntry * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + TaggedEntry.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreatePolicyTagRequest message. + * Verifies a TaggedEntry message. * @function verify - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreatePolicyTagRequest.verify = function verify(message) { + TaggedEntry.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) { - var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTag); - if (error) - return "policyTag." + error; + var properties = {}; + if (message.v1Entry != null && message.hasOwnProperty("v1Entry")) { + properties.entry = 1; + { + var error = $root.google.cloud.datacatalog.v1.Entry.verify(message.v1Entry); + if (error) + return "v1Entry." + error; + } + } + if (message.presentTags != null && message.hasOwnProperty("presentTags")) { + if (!Array.isArray(message.presentTags)) + return "presentTags: array expected"; + for (var i = 0; i < message.presentTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Tag.verify(message.presentTags[i]); + if (error) + return "presentTags." + error; + } + } + if (message.absentTags != null && message.hasOwnProperty("absentTags")) { + if (!Array.isArray(message.absentTags)) + return "absentTags: array expected"; + for (var i = 0; i < message.absentTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Tag.verify(message.absentTags[i]); + if (error) + return "absentTags." + error; + } } return null; }; /** - * Creates a CreatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a TaggedEntry message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.TaggedEntry} TaggedEntry */ - CreatePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest) + TaggedEntry.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.TaggedEntry) return object; - var message = new $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.policyTag != null) { - if (typeof object.policyTag !== "object") - throw TypeError(".google.cloud.datacatalog.v1.CreatePolicyTagRequest.policyTag: object expected"); - message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTag); + var message = new $root.google.cloud.datacatalog.v1.TaggedEntry(); + if (object.v1Entry != null) { + if (typeof object.v1Entry !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TaggedEntry.v1Entry: object expected"); + message.v1Entry = $root.google.cloud.datacatalog.v1.Entry.fromObject(object.v1Entry); + } + if (object.presentTags) { + if (!Array.isArray(object.presentTags)) + throw TypeError(".google.cloud.datacatalog.v1.TaggedEntry.presentTags: array expected"); + message.presentTags = []; + for (var i = 0; i < object.presentTags.length; ++i) { + if (typeof object.presentTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TaggedEntry.presentTags: object expected"); + message.presentTags[i] = $root.google.cloud.datacatalog.v1.Tag.fromObject(object.presentTags[i]); + } + } + if (object.absentTags) { + if (!Array.isArray(object.absentTags)) + throw TypeError(".google.cloud.datacatalog.v1.TaggedEntry.absentTags: array expected"); + message.absentTags = []; + for (var i = 0; i < object.absentTags.length; ++i) { + if (typeof object.absentTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.TaggedEntry.absentTags: object expected"); + message.absentTags[i] = $root.google.cloud.datacatalog.v1.Tag.fromObject(object.absentTags[i]); + } } return message; }; /** - * Creates a plain object from a CreatePolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a TaggedEntry message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static - * @param {google.cloud.datacatalog.v1.CreatePolicyTagRequest} message CreatePolicyTagRequest + * @param {google.cloud.datacatalog.v1.TaggedEntry} message TaggedEntry * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreatePolicyTagRequest.toObject = function toObject(message, options) { + TaggedEntry.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.parent = ""; - object.policyTag = null; + if (options.arrays || options.defaults) { + object.presentTags = []; + object.absentTags = []; + } + if (message.v1Entry != null && message.hasOwnProperty("v1Entry")) { + object.v1Entry = $root.google.cloud.datacatalog.v1.Entry.toObject(message.v1Entry, options); + if (options.oneofs) + object.entry = "v1Entry"; + } + if (message.presentTags && message.presentTags.length) { + object.presentTags = []; + for (var j = 0; j < message.presentTags.length; ++j) + object.presentTags[j] = $root.google.cloud.datacatalog.v1.Tag.toObject(message.presentTags[j], options); + } + if (message.absentTags && message.absentTags.length) { + object.absentTags = []; + for (var j = 0; j < message.absentTags.length; ++j) + object.absentTags[j] = $root.google.cloud.datacatalog.v1.Tag.toObject(message.absentTags[j], options); } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - object.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTag, options); return object; }; /** - * Converts this CreatePolicyTagRequest to JSON. + * Converts this TaggedEntry to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @instance * @returns {Object.} JSON object */ - CreatePolicyTagRequest.prototype.toJSON = function toJSON() { + TaggedEntry.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreatePolicyTagRequest + * Gets the default type url for TaggedEntry * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.TaggedEntry * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TaggedEntry.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.CreatePolicyTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.TaggedEntry"; }; - return CreatePolicyTagRequest; + return TaggedEntry; })(); - v1.DeletePolicyTagRequest = (function() { + v1.DumpItem = (function() { /** - * Properties of a DeletePolicyTagRequest. + * Properties of a DumpItem. * @memberof google.cloud.datacatalog.v1 - * @interface IDeletePolicyTagRequest - * @property {string|null} [name] DeletePolicyTagRequest name + * @interface IDumpItem + * @property {google.cloud.datacatalog.v1.ITaggedEntry|null} [taggedEntry] DumpItem taggedEntry */ /** - * Constructs a new DeletePolicyTagRequest. + * Constructs a new DumpItem. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a DeletePolicyTagRequest. - * @implements IDeletePolicyTagRequest + * @classdesc Represents a DumpItem. + * @implements IDumpItem * @constructor - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IDumpItem=} [properties] Properties to set */ - function DeletePolicyTagRequest(properties) { + function DumpItem(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26247,75 +27469,89 @@ } /** - * DeletePolicyTagRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * DumpItem taggedEntry. + * @member {google.cloud.datacatalog.v1.ITaggedEntry|null|undefined} taggedEntry + * @memberof google.cloud.datacatalog.v1.DumpItem * @instance */ - DeletePolicyTagRequest.prototype.name = ""; + DumpItem.prototype.taggedEntry = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Creates a new DeletePolicyTagRequest instance using the specified properties. + * DumpItem item. + * @member {"taggedEntry"|undefined} item + * @memberof google.cloud.datacatalog.v1.DumpItem + * @instance + */ + Object.defineProperty(DumpItem.prototype, "item", { + get: $util.oneOfGetter($oneOfFields = ["taggedEntry"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new DumpItem instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest instance + * @param {google.cloud.datacatalog.v1.IDumpItem=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DumpItem} DumpItem instance */ - DeletePolicyTagRequest.create = function create(properties) { - return new DeletePolicyTagRequest(properties); + DumpItem.create = function create(properties) { + return new DumpItem(properties); }; /** - * Encodes the specified DeletePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.DeletePolicyTagRequest.verify|verify} messages. + * Encodes the specified DumpItem message. Does not implicitly {@link google.cloud.datacatalog.v1.DumpItem.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDumpItem} message DumpItem message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeletePolicyTagRequest.encode = function encode(message, writer) { + DumpItem.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.taggedEntry != null && Object.hasOwnProperty.call(message, "taggedEntry")) + $root.google.cloud.datacatalog.v1.TaggedEntry.encode(message.taggedEntry, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified DeletePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DeletePolicyTagRequest.verify|verify} messages. + * Encodes the specified DumpItem message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DumpItem.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static - * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDumpItem} message DumpItem message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeletePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + DumpItem.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeletePolicyTagRequest message from the specified reader or buffer. + * Decodes a DumpItem message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.DumpItem} DumpItem * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeletePolicyTagRequest.decode = function decode(reader, length) { + DumpItem.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DumpItem(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.taggedEntry = $root.google.cloud.datacatalog.v1.TaggedEntry.decode(reader, reader.uint32()); break; } default: @@ -26327,361 +27563,603 @@ }; /** - * Decodes a DeletePolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a DumpItem message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.DumpItem} DumpItem * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeletePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + DumpItem.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeletePolicyTagRequest message. + * Verifies a DumpItem message. * @function verify - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeletePolicyTagRequest.verify = function verify(message) { + DumpItem.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + var properties = {}; + if (message.taggedEntry != null && message.hasOwnProperty("taggedEntry")) { + properties.item = 1; + { + var error = $root.google.cloud.datacatalog.v1.TaggedEntry.verify(message.taggedEntry); + if (error) + return "taggedEntry." + error; + } + } return null; }; /** - * Creates a DeletePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a DumpItem message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1.DumpItem} DumpItem */ - DeletePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest) + DumpItem.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DumpItem) return object; - var message = new $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.DumpItem(); + if (object.taggedEntry != null) { + if (typeof object.taggedEntry !== "object") + throw TypeError(".google.cloud.datacatalog.v1.DumpItem.taggedEntry: object expected"); + message.taggedEntry = $root.google.cloud.datacatalog.v1.TaggedEntry.fromObject(object.taggedEntry); + } return message; }; /** - * Creates a plain object from a DeletePolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a DumpItem message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static - * @param {google.cloud.datacatalog.v1.DeletePolicyTagRequest} message DeletePolicyTagRequest + * @param {google.cloud.datacatalog.v1.DumpItem} message DumpItem * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeletePolicyTagRequest.toObject = function toObject(message, options) { + DumpItem.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (message.taggedEntry != null && message.hasOwnProperty("taggedEntry")) { + object.taggedEntry = $root.google.cloud.datacatalog.v1.TaggedEntry.toObject(message.taggedEntry, options); + if (options.oneofs) + object.item = "taggedEntry"; + } return object; }; /** - * Converts this DeletePolicyTagRequest to JSON. + * Converts this DumpItem to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @instance * @returns {Object.} JSON object */ - DeletePolicyTagRequest.prototype.toJSON = function toJSON() { + DumpItem.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeletePolicyTagRequest + * Gets the default type url for DumpItem * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.DumpItem * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeletePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DumpItem.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.DeletePolicyTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DumpItem"; }; - return DeletePolicyTagRequest; + return DumpItem; })(); - v1.UpdatePolicyTagRequest = (function() { - - /** - * Properties of an UpdatePolicyTagRequest. - * @memberof google.cloud.datacatalog.v1 - * @interface IUpdatePolicyTagRequest - * @property {google.cloud.datacatalog.v1.IPolicyTag|null} [policyTag] UpdatePolicyTagRequest policyTag - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdatePolicyTagRequest updateMask - */ + v1.PolicyTagManager = (function() { /** - * Constructs a new UpdatePolicyTagRequest. + * Constructs a new PolicyTagManager service. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an UpdatePolicyTagRequest. - * @implements IUpdatePolicyTagRequest + * @classdesc Represents a PolicyTagManager + * @extends $protobuf.rpc.Service * @constructor - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest=} [properties] Properties to set + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited */ - function UpdatePolicyTagRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + function PolicyTagManager(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); } - /** - * UpdatePolicyTagRequest policyTag. - * @member {google.cloud.datacatalog.v1.IPolicyTag|null|undefined} policyTag - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @instance - */ - UpdatePolicyTagRequest.prototype.policyTag = null; - - /** - * UpdatePolicyTagRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @instance - */ - UpdatePolicyTagRequest.prototype.updateMask = null; + (PolicyTagManager.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManager; /** - * Creates a new UpdatePolicyTagRequest instance using the specified properties. + * Creates new PolicyTagManager service using the specified rpc implementation. * @function create - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1.PolicyTagManager * @static - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest instance + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {PolicyTagManager} RPC service. Useful where requests and/or responses are streamed. */ - UpdatePolicyTagRequest.create = function create(properties) { - return new UpdatePolicyTagRequest(properties); + PolicyTagManager.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); }; /** - * Encodes the specified UpdatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UpdatePolicyTagRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|createTaxonomy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef CreateTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy */ - UpdatePolicyTagRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) - $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - return writer; - }; /** - * Encodes the specified UpdatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UpdatePolicyTagRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls CreateTaxonomy. + * @function createTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.CreateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 */ - UpdatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Object.defineProperty(PolicyTagManager.prototype.createTaxonomy = function createTaxonomy(request, callback) { + return this.rpcCall(createTaxonomy, $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); + }, "name", { value: "CreateTaxonomy" }); /** - * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls CreateTaxonomy. + * @function createTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdatePolicyTagRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32()); - break; - } - case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|deleteTaxonomy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef DeleteTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - UpdatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies an UpdatePolicyTagRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls DeleteTaxonomy. + * @function deleteTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.DeleteTaxonomyCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ - UpdatePolicyTagRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) { - var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTag); - if (error) - return "policyTag." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } - return null; - }; + Object.defineProperty(PolicyTagManager.prototype.deleteTaxonomy = function deleteTaxonomy(request, callback) { + return this.rpcCall(deleteTaxonomy, $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteTaxonomy" }); /** - * Creates an UpdatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest + * Calls DeleteTaxonomy. + * @function deleteTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdatePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest(); - if (object.policyTag != null) { - if (typeof object.policyTag !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UpdatePolicyTagRequest.policyTag: object expected"); - message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTag); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1.UpdatePolicyTagRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } - return message; - }; /** - * Creates a plain object from an UpdatePolicyTagRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} message UpdatePolicyTagRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|updateTaxonomy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef UpdateTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy */ - UpdatePolicyTagRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.policyTag = null; - object.updateMask = null; - } - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - object.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTag, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); - return object; - }; /** - * Converts this UpdatePolicyTagRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest + * Calls UpdateTaxonomy. + * @function updateTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.UpdateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 */ - UpdatePolicyTagRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Object.defineProperty(PolicyTagManager.prototype.updateTaxonomy = function updateTaxonomy(request, callback) { + return this.rpcCall(updateTaxonomy, $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); + }, "name", { value: "UpdateTaxonomy" }); /** - * Gets the default type url for UpdatePolicyTagRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - UpdatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.UpdatePolicyTagRequest"; - }; + * Calls UpdateTaxonomy. + * @function updateTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - return UpdatePolicyTagRequest; + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|listTaxonomies}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef ListTaxonomiesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.ListTaxonomiesResponse} [response] ListTaxonomiesResponse + */ + + /** + * Calls ListTaxonomies. + * @function listTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.ListTaxonomiesCallback} callback Node-style callback called with the error, if any, and ListTaxonomiesResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.listTaxonomies = function listTaxonomies(request, callback) { + return this.rpcCall(listTaxonomies, $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse, request, callback); + }, "name", { value: "ListTaxonomies" }); + + /** + * Calls ListTaxonomies. + * @function listTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getTaxonomy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef GetTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy + */ + + /** + * Calls GetTaxonomy. + * @function getTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.getTaxonomy = function getTaxonomy(request, callback) { + return this.rpcCall(getTaxonomy, $root.google.cloud.datacatalog.v1.GetTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); + }, "name", { value: "GetTaxonomy" }); + + /** + * Calls GetTaxonomy. + * @function getTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|createPolicyTag}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef CreatePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag + */ + + /** + * Calls CreatePolicyTag. + * @function createPolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.CreatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.createPolicyTag = function createPolicyTag(request, callback) { + return this.rpcCall(createPolicyTag, $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); + }, "name", { value: "CreatePolicyTag" }); + + /** + * Calls CreatePolicyTag. + * @function createPolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|deletePolicyTag}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef DeletePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty + */ + + /** + * Calls DeletePolicyTag. + * @function deletePolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.DeletePolicyTagCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.deletePolicyTag = function deletePolicyTag(request, callback) { + return this.rpcCall(deletePolicyTag, $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeletePolicyTag" }); + + /** + * Calls DeletePolicyTag. + * @function deletePolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|updatePolicyTag}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef UpdatePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag + */ + + /** + * Calls UpdatePolicyTag. + * @function updatePolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.UpdatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.updatePolicyTag = function updatePolicyTag(request, callback) { + return this.rpcCall(updatePolicyTag, $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); + }, "name", { value: "UpdatePolicyTag" }); + + /** + * Calls UpdatePolicyTag. + * @function updatePolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|listPolicyTags}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef ListPolicyTagsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.ListPolicyTagsResponse} [response] ListPolicyTagsResponse + */ + + /** + * Calls ListPolicyTags. + * @function listPolicyTags + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.ListPolicyTagsCallback} callback Node-style callback called with the error, if any, and ListPolicyTagsResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.listPolicyTags = function listPolicyTags(request, callback) { + return this.rpcCall(listPolicyTags, $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest, $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse, request, callback); + }, "name", { value: "ListPolicyTags" }); + + /** + * Calls ListPolicyTags. + * @function listPolicyTags + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getPolicyTag}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef GetPolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1.PolicyTag} [response] PolicyTag + */ + + /** + * Calls GetPolicyTag. + * @function getPolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetPolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.getPolicyTag = function getPolicyTag(request, callback) { + return this.rpcCall(getPolicyTag, $root.google.cloud.datacatalog.v1.GetPolicyTagRequest, $root.google.cloud.datacatalog.v1.PolicyTag, request, callback); + }, "name", { value: "GetPolicyTag" }); + + /** + * Calls GetPolicyTag. + * @function getPolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|getIamPolicy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef GetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy + */ + + /** + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.getIamPolicy = function getIamPolicy(request, callback) { + return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "GetIamPolicy" }); + + /** + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|setIamPolicy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef SetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy + */ + + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.setIamPolicy = function setIamPolicy(request, callback) { + return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "SetIamPolicy" }); + + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManager|testIamPermissions}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @typedef TestIamPermissionsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse + */ + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManager.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.testIamPermissions = function testIamPermissions(request, callback) { + return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); + }, "name", { value: "TestIamPermissions" }); + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1.PolicyTagManager + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + return PolicyTagManager; })(); - v1.ListPolicyTagsRequest = (function() { + v1.Taxonomy = (function() { /** - * Properties of a ListPolicyTagsRequest. + * Properties of a Taxonomy. * @memberof google.cloud.datacatalog.v1 - * @interface IListPolicyTagsRequest - * @property {string|null} [parent] ListPolicyTagsRequest parent - * @property {number|null} [pageSize] ListPolicyTagsRequest pageSize - * @property {string|null} [pageToken] ListPolicyTagsRequest pageToken + * @interface ITaxonomy + * @property {string|null} [name] Taxonomy name + * @property {string|null} [displayName] Taxonomy displayName + * @property {string|null} [description] Taxonomy description + * @property {number|null} [policyTagCount] Taxonomy policyTagCount + * @property {google.cloud.datacatalog.v1.ISystemTimestamps|null} [taxonomyTimestamps] Taxonomy taxonomyTimestamps + * @property {Array.|null} [activatedPolicyTypes] Taxonomy activatedPolicyTypes + * @property {google.cloud.datacatalog.v1.Taxonomy.IService|null} [service] Taxonomy service */ /** - * Constructs a new ListPolicyTagsRequest. + * Constructs a new Taxonomy. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListPolicyTagsRequest. - * @implements IListPolicyTagsRequest + * @classdesc Represents a Taxonomy. + * @implements ITaxonomy * @constructor - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ITaxonomy=} [properties] Properties to set */ - function ListPolicyTagsRequest(properties) { + function Taxonomy(properties) { + this.activatedPolicyTypes = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26689,103 +28167,170 @@ } /** - * ListPolicyTagsRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * Taxonomy name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.Taxonomy * @instance */ - ListPolicyTagsRequest.prototype.parent = ""; + Taxonomy.prototype.name = ""; /** - * ListPolicyTagsRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * Taxonomy displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.Taxonomy * @instance */ - ListPolicyTagsRequest.prototype.pageSize = 0; + Taxonomy.prototype.displayName = ""; /** - * ListPolicyTagsRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * Taxonomy description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.Taxonomy * @instance */ - ListPolicyTagsRequest.prototype.pageToken = ""; + Taxonomy.prototype.description = ""; /** - * Creates a new ListPolicyTagsRequest instance using the specified properties. + * Taxonomy policyTagCount. + * @member {number} policyTagCount + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @instance + */ + Taxonomy.prototype.policyTagCount = 0; + + /** + * Taxonomy taxonomyTimestamps. + * @member {google.cloud.datacatalog.v1.ISystemTimestamps|null|undefined} taxonomyTimestamps + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @instance + */ + Taxonomy.prototype.taxonomyTimestamps = null; + + /** + * Taxonomy activatedPolicyTypes. + * @member {Array.} activatedPolicyTypes + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @instance + */ + Taxonomy.prototype.activatedPolicyTypes = $util.emptyArray; + + /** + * Taxonomy service. + * @member {google.cloud.datacatalog.v1.Taxonomy.IService|null|undefined} service + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @instance + */ + Taxonomy.prototype.service = null; + + /** + * Creates a new Taxonomy instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest instance + * @param {google.cloud.datacatalog.v1.ITaxonomy=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy instance */ - ListPolicyTagsRequest.create = function create(properties) { - return new ListPolicyTagsRequest(properties); + Taxonomy.create = function create(properties) { + return new Taxonomy(properties); }; /** - * Encodes the specified ListPolicyTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsRequest.verify|verify} messages. + * Encodes the specified Taxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITaxonomy} message Taxonomy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListPolicyTagsRequest.encode = function encode(message, writer) { + Taxonomy.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.policyTagCount != null && Object.hasOwnProperty.call(message, "policyTagCount")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.policyTagCount); + if (message.taxonomyTimestamps != null && Object.hasOwnProperty.call(message, "taxonomyTimestamps")) + $root.google.cloud.datacatalog.v1.SystemTimestamps.encode(message.taxonomyTimestamps, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { + writer.uint32(/* id 6, wireType 2 =*/50).fork(); + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + writer.int32(message.activatedPolicyTypes[i]); + writer.ldelim(); + } + if (message.service != null && Object.hasOwnProperty.call(message, "service")) + $root.google.cloud.datacatalog.v1.Taxonomy.Service.encode(message.service, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); return writer; }; /** - * Encodes the specified ListPolicyTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsRequest.verify|verify} messages. + * Encodes the specified Taxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ITaxonomy} message Taxonomy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListPolicyTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { + Taxonomy.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListPolicyTagsRequest message from the specified reader or buffer. + * Decodes a Taxonomy message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest + * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListPolicyTagsRequest.decode = function decode(reader, length) { + Taxonomy.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Taxonomy(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.name = reader.string(); break; } case 2: { - message.pageSize = reader.int32(); + message.displayName = reader.string(); break; } case 3: { - message.pageToken = reader.string(); + message.description = reader.string(); + break; + } + case 4: { + message.policyTagCount = reader.int32(); + break; + } + case 5: { + message.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.decode(reader, reader.uint32()); + break; + } + case 6: { + if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) + message.activatedPolicyTypes = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.activatedPolicyTypes.push(reader.int32()); + } else + message.activatedPolicyTypes.push(reader.int32()); + break; + } + case 7: { + message.service = $root.google.cloud.datacatalog.v1.Taxonomy.Service.decode(reader, reader.uint32()); break; } default: @@ -26797,141 +28342,483 @@ }; /** - * Decodes a ListPolicyTagsRequest message from the specified reader or buffer, length delimited. + * Decodes a Taxonomy message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest + * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListPolicyTagsRequest.decodeDelimited = function decodeDelimited(reader) { + Taxonomy.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListPolicyTagsRequest message. + * Verifies a Taxonomy message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListPolicyTagsRequest.verify = function verify(message) { + Taxonomy.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.policyTagCount != null && message.hasOwnProperty("policyTagCount")) + if (!$util.isInteger(message.policyTagCount)) + return "policyTagCount: integer expected"; + if (message.taxonomyTimestamps != null && message.hasOwnProperty("taxonomyTimestamps")) { + var error = $root.google.cloud.datacatalog.v1.SystemTimestamps.verify(message.taxonomyTimestamps); + if (error) + return "taxonomyTimestamps." + error; + } + if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { + if (!Array.isArray(message.activatedPolicyTypes)) + return "activatedPolicyTypes: array expected"; + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + switch (message.activatedPolicyTypes[i]) { + default: + return "activatedPolicyTypes: enum value[] expected"; + case 0: + case 1: + break; + } + } + if (message.service != null && message.hasOwnProperty("service")) { + var error = $root.google.cloud.datacatalog.v1.Taxonomy.Service.verify(message.service); + if (error) + return "service." + error; + } return null; }; /** - * Creates a ListPolicyTagsRequest message from a plain object. Also converts values to their respective internal types. + * Creates a Taxonomy message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest + * @returns {google.cloud.datacatalog.v1.Taxonomy} Taxonomy */ - ListPolicyTagsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest) + Taxonomy.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.Taxonomy) return object; - var message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); + var message = new $root.google.cloud.datacatalog.v1.Taxonomy(); + if (object.name != null) + message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.policyTagCount != null) + message.policyTagCount = object.policyTagCount | 0; + if (object.taxonomyTimestamps != null) { + if (typeof object.taxonomyTimestamps !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Taxonomy.taxonomyTimestamps: object expected"); + message.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.fromObject(object.taxonomyTimestamps); + } + if (object.activatedPolicyTypes) { + if (!Array.isArray(object.activatedPolicyTypes)) + throw TypeError(".google.cloud.datacatalog.v1.Taxonomy.activatedPolicyTypes: array expected"); + message.activatedPolicyTypes = []; + for (var i = 0; i < object.activatedPolicyTypes.length; ++i) + switch (object.activatedPolicyTypes[i]) { + default: + if (typeof object.activatedPolicyTypes[i] === "number") { + message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; + break; + } + case "POLICY_TYPE_UNSPECIFIED": + case 0: + message.activatedPolicyTypes[i] = 0; + break; + case "FINE_GRAINED_ACCESS_CONTROL": + case 1: + message.activatedPolicyTypes[i] = 1; + break; + } + } + if (object.service != null) { + if (typeof object.service !== "object") + throw TypeError(".google.cloud.datacatalog.v1.Taxonomy.service: object expected"); + message.service = $root.google.cloud.datacatalog.v1.Taxonomy.Service.fromObject(object.service); + } return message; }; /** - * Creates a plain object from a ListPolicyTagsRequest message. Also converts values to other types if specified. + * Creates a plain object from a Taxonomy message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1.ListPolicyTagsRequest} message ListPolicyTagsRequest + * @param {google.cloud.datacatalog.v1.Taxonomy} message Taxonomy * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListPolicyTagsRequest.toObject = function toObject(message, options) { + Taxonomy.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.activatedPolicyTypes = []; if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; + object.name = ""; + object.displayName = ""; + object.description = ""; + object.policyTagCount = 0; + object.taxonomyTimestamps = null; + object.service = null; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.policyTagCount != null && message.hasOwnProperty("policyTagCount")) + object.policyTagCount = message.policyTagCount; + if (message.taxonomyTimestamps != null && message.hasOwnProperty("taxonomyTimestamps")) + object.taxonomyTimestamps = $root.google.cloud.datacatalog.v1.SystemTimestamps.toObject(message.taxonomyTimestamps, options); + if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { + object.activatedPolicyTypes = []; + for (var j = 0; j < message.activatedPolicyTypes.length; ++j) + object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; + } + if (message.service != null && message.hasOwnProperty("service")) + object.service = $root.google.cloud.datacatalog.v1.Taxonomy.Service.toObject(message.service, options); return object; }; /** - * Converts this ListPolicyTagsRequest to JSON. + * Converts this Taxonomy to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @instance * @returns {Object.} JSON object */ - ListPolicyTagsRequest.prototype.toJSON = function toJSON() { + Taxonomy.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListPolicyTagsRequest + * Gets the default type url for Taxonomy * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @memberof google.cloud.datacatalog.v1.Taxonomy * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListPolicyTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Taxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListPolicyTagsRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.Taxonomy"; }; - return ListPolicyTagsRequest; + /** + * PolicyType enum. + * @name google.cloud.datacatalog.v1.Taxonomy.PolicyType + * @enum {number} + * @property {number} POLICY_TYPE_UNSPECIFIED=0 POLICY_TYPE_UNSPECIFIED value + * @property {number} FINE_GRAINED_ACCESS_CONTROL=1 FINE_GRAINED_ACCESS_CONTROL value + */ + Taxonomy.PolicyType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "POLICY_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "FINE_GRAINED_ACCESS_CONTROL"] = 1; + return values; + })(); + + Taxonomy.Service = (function() { + + /** + * Properties of a Service. + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @interface IService + * @property {google.cloud.datacatalog.v1.ManagingSystem|null} [name] Service name + * @property {string|null} [identity] Service identity + */ + + /** + * Constructs a new Service. + * @memberof google.cloud.datacatalog.v1.Taxonomy + * @classdesc Represents a Service. + * @implements IService + * @constructor + * @param {google.cloud.datacatalog.v1.Taxonomy.IService=} [properties] Properties to set + */ + function Service(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Service name. + * @member {google.cloud.datacatalog.v1.ManagingSystem} name + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @instance + */ + Service.prototype.name = 0; + + /** + * Service identity. + * @member {string} identity + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @instance + */ + Service.prototype.identity = ""; + + /** + * Creates a new Service instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {google.cloud.datacatalog.v1.Taxonomy.IService=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.Taxonomy.Service} Service instance + */ + Service.create = function create(properties) { + return new Service(properties); + }; + + /** + * Encodes the specified Service message. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.Service.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {google.cloud.datacatalog.v1.Taxonomy.IService} message Service message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Service.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.name); + if (message.identity != null && Object.hasOwnProperty.call(message, "identity")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.identity); + return writer; + }; + + /** + * Encodes the specified Service message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.Taxonomy.Service.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {google.cloud.datacatalog.v1.Taxonomy.IService} message Service message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Service.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Service message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.Taxonomy.Service} Service + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Service.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.Taxonomy.Service(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.int32(); + break; + } + case 2: { + message.identity = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a Service message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.Taxonomy.Service} Service + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Service.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Service message. + * @function verify + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Service.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + switch (message.name) { + default: + return "name: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.identity != null && message.hasOwnProperty("identity")) + if (!$util.isString(message.identity)) + return "identity: string expected"; + return null; + }; + + /** + * Creates a Service message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.Taxonomy.Service} Service + */ + Service.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.Taxonomy.Service) + return object; + var message = new $root.google.cloud.datacatalog.v1.Taxonomy.Service(); + switch (object.name) { + default: + if (typeof object.name === "number") { + message.name = object.name; + break; + } + break; + case "MANAGING_SYSTEM_UNSPECIFIED": + case 0: + message.name = 0; + break; + case "MANAGING_SYSTEM_DATAPLEX": + case 1: + message.name = 1; + break; + case "MANAGING_SYSTEM_OTHER": + case 2: + message.name = 2; + break; + } + if (object.identity != null) + message.identity = String(object.identity); + return message; + }; + + /** + * Creates a plain object from a Service message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {google.cloud.datacatalog.v1.Taxonomy.Service} message Service + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Service.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.name = options.enums === String ? "MANAGING_SYSTEM_UNSPECIFIED" : 0; + object.identity = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = options.enums === String ? $root.google.cloud.datacatalog.v1.ManagingSystem[message.name] === undefined ? message.name : $root.google.cloud.datacatalog.v1.ManagingSystem[message.name] : message.name; + if (message.identity != null && message.hasOwnProperty("identity")) + object.identity = message.identity; + return object; + }; + + /** + * Converts this Service to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @instance + * @returns {Object.} JSON object + */ + Service.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Service + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.Taxonomy.Service + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Service.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.Taxonomy.Service"; + }; + + return Service; + })(); + + return Taxonomy; })(); - v1.ListPolicyTagsResponse = (function() { + v1.PolicyTag = (function() { /** - * Properties of a ListPolicyTagsResponse. + * Properties of a PolicyTag. * @memberof google.cloud.datacatalog.v1 - * @interface IListPolicyTagsResponse - * @property {Array.|null} [policyTags] ListPolicyTagsResponse policyTags - * @property {string|null} [nextPageToken] ListPolicyTagsResponse nextPageToken + * @interface IPolicyTag + * @property {string|null} [name] PolicyTag name + * @property {string|null} [displayName] PolicyTag displayName + * @property {string|null} [description] PolicyTag description + * @property {string|null} [parentPolicyTag] PolicyTag parentPolicyTag + * @property {Array.|null} [childPolicyTags] PolicyTag childPolicyTags */ /** - * Constructs a new ListPolicyTagsResponse. + * Constructs a new PolicyTag. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ListPolicyTagsResponse. - * @implements IListPolicyTagsResponse + * @classdesc Represents a PolicyTag. + * @implements IPolicyTag * @constructor - * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IPolicyTag=} [properties] Properties to set */ - function ListPolicyTagsResponse(properties) { - this.policyTags = []; + function PolicyTag(properties) { + this.childPolicyTags = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -26939,92 +28826,134 @@ } /** - * ListPolicyTagsResponse policyTags. - * @member {Array.} policyTags - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * PolicyTag name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.PolicyTag * @instance */ - ListPolicyTagsResponse.prototype.policyTags = $util.emptyArray; + PolicyTag.prototype.name = ""; /** - * ListPolicyTagsResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * PolicyTag displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.PolicyTag * @instance */ - ListPolicyTagsResponse.prototype.nextPageToken = ""; + PolicyTag.prototype.displayName = ""; /** - * Creates a new ListPolicyTagsResponse instance using the specified properties. + * PolicyTag description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.PolicyTag + * @instance + */ + PolicyTag.prototype.description = ""; + + /** + * PolicyTag parentPolicyTag. + * @member {string} parentPolicyTag + * @memberof google.cloud.datacatalog.v1.PolicyTag + * @instance + */ + PolicyTag.prototype.parentPolicyTag = ""; + + /** + * PolicyTag childPolicyTags. + * @member {Array.} childPolicyTags + * @memberof google.cloud.datacatalog.v1.PolicyTag + * @instance + */ + PolicyTag.prototype.childPolicyTags = $util.emptyArray; + + /** + * Creates a new PolicyTag instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse instance + * @param {google.cloud.datacatalog.v1.IPolicyTag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag instance */ - ListPolicyTagsResponse.create = function create(properties) { - return new ListPolicyTagsResponse(properties); + PolicyTag.create = function create(properties) { + return new PolicyTag(properties); }; /** - * Encodes the specified ListPolicyTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsResponse.verify|verify} messages. + * Encodes the specified PolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1.PolicyTag.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IPolicyTag} message PolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListPolicyTagsResponse.encode = function encode(message, writer) { + PolicyTag.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.policyTags != null && message.policyTags.length) - for (var i = 0; i < message.policyTags.length; ++i) - $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.parentPolicyTag != null && Object.hasOwnProperty.call(message, "parentPolicyTag")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.parentPolicyTag); + if (message.childPolicyTags != null && message.childPolicyTags.length) + for (var i = 0; i < message.childPolicyTags.length; ++i) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.childPolicyTags[i]); return writer; }; /** - * Encodes the specified ListPolicyTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsResponse.verify|verify} messages. + * Encodes the specified PolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.PolicyTag.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IPolicyTag} message PolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListPolicyTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { + PolicyTag.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListPolicyTagsResponse message from the specified reader or buffer. + * Decodes a PolicyTag message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListPolicyTagsResponse.decode = function decode(reader, length) { + PolicyTag.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.PolicyTag(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.policyTags && message.policyTags.length)) - message.policyTags = []; - message.policyTags.push($root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32())); + message.name = reader.string(); break; } case 2: { - message.nextPageToken = reader.string(); + message.displayName = reader.string(); + break; + } + case 3: { + message.description = reader.string(); + break; + } + case 4: { + message.parentPolicyTag = reader.string(); + break; + } + case 5: { + if (!(message.childPolicyTags && message.childPolicyTags.length)) + message.childPolicyTags = []; + message.childPolicyTags.push(reader.string()); break; } default: @@ -27036,148 +28965,169 @@ }; /** - * Decodes a ListPolicyTagsResponse message from the specified reader or buffer, length delimited. + * Decodes a PolicyTag message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListPolicyTagsResponse.decodeDelimited = function decodeDelimited(reader) { + PolicyTag.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListPolicyTagsResponse message. + * Verifies a PolicyTag message. * @function verify - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListPolicyTagsResponse.verify = function verify(message) { + PolicyTag.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.policyTags != null && message.hasOwnProperty("policyTags")) { - if (!Array.isArray(message.policyTags)) - return "policyTags: array expected"; - for (var i = 0; i < message.policyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTags[i]); - if (error) - return "policyTags." + error; - } - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; - return null; - }; - - /** - * Creates a ListPolicyTagsResponse message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) + if (!$util.isString(message.parentPolicyTag)) + return "parentPolicyTag: string expected"; + if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { + if (!Array.isArray(message.childPolicyTags)) + return "childPolicyTags: array expected"; + for (var i = 0; i < message.childPolicyTags.length; ++i) + if (!$util.isString(message.childPolicyTags[i])) + return "childPolicyTags: string[] expected"; + } + return null; + }; + + /** + * Creates a PolicyTag message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.PolicyTag + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.PolicyTag} PolicyTag */ - ListPolicyTagsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse) + PolicyTag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.PolicyTag) return object; - var message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse(); - if (object.policyTags) { - if (!Array.isArray(object.policyTags)) - throw TypeError(".google.cloud.datacatalog.v1.ListPolicyTagsResponse.policyTags: array expected"); - message.policyTags = []; - for (var i = 0; i < object.policyTags.length; ++i) { - if (typeof object.policyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ListPolicyTagsResponse.policyTags: object expected"); - message.policyTags[i] = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTags[i]); - } + var message = new $root.google.cloud.datacatalog.v1.PolicyTag(); + if (object.name != null) + message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.parentPolicyTag != null) + message.parentPolicyTag = String(object.parentPolicyTag); + if (object.childPolicyTags) { + if (!Array.isArray(object.childPolicyTags)) + throw TypeError(".google.cloud.datacatalog.v1.PolicyTag.childPolicyTags: array expected"); + message.childPolicyTags = []; + for (var i = 0; i < object.childPolicyTags.length; ++i) + message.childPolicyTags[i] = String(object.childPolicyTags[i]); } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a ListPolicyTagsResponse message. Also converts values to other types if specified. + * Creates a plain object from a PolicyTag message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1.ListPolicyTagsResponse} message ListPolicyTagsResponse + * @param {google.cloud.datacatalog.v1.PolicyTag} message PolicyTag * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListPolicyTagsResponse.toObject = function toObject(message, options) { + PolicyTag.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.policyTags = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.policyTags && message.policyTags.length) { - object.policyTags = []; - for (var j = 0; j < message.policyTags.length; ++j) - object.policyTags[j] = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTags[j], options); + object.childPolicyTags = []; + if (options.defaults) { + object.name = ""; + object.displayName = ""; + object.description = ""; + object.parentPolicyTag = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) + object.parentPolicyTag = message.parentPolicyTag; + if (message.childPolicyTags && message.childPolicyTags.length) { + object.childPolicyTags = []; + for (var j = 0; j < message.childPolicyTags.length; ++j) + object.childPolicyTags[j] = message.childPolicyTags[j]; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this ListPolicyTagsResponse to JSON. + * Converts this PolicyTag to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @instance * @returns {Object.} JSON object */ - ListPolicyTagsResponse.prototype.toJSON = function toJSON() { + PolicyTag.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListPolicyTagsResponse + * Gets the default type url for PolicyTag * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @memberof google.cloud.datacatalog.v1.PolicyTag * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListPolicyTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + PolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListPolicyTagsResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.PolicyTag"; }; - return ListPolicyTagsResponse; + return PolicyTag; })(); - v1.GetPolicyTagRequest = (function() { + v1.CreateTaxonomyRequest = (function() { /** - * Properties of a GetPolicyTagRequest. + * Properties of a CreateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IGetPolicyTagRequest - * @property {string|null} [name] GetPolicyTagRequest name + * @interface ICreateTaxonomyRequest + * @property {string|null} [parent] CreateTaxonomyRequest parent + * @property {google.cloud.datacatalog.v1.ITaxonomy|null} [taxonomy] CreateTaxonomyRequest taxonomy */ /** - * Constructs a new GetPolicyTagRequest. + * Constructs a new CreateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a GetPolicyTagRequest. - * @implements IGetPolicyTagRequest + * @classdesc Represents a CreateTaxonomyRequest. + * @implements ICreateTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest=} [properties] Properties to set */ - function GetPolicyTagRequest(properties) { + function CreateTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27185,75 +29135,89 @@ } /** - * GetPolicyTagRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * CreateTaxonomyRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @instance */ - GetPolicyTagRequest.prototype.name = ""; + CreateTaxonomyRequest.prototype.parent = ""; /** - * Creates a new GetPolicyTagRequest instance using the specified properties. + * CreateTaxonomyRequest taxonomy. + * @member {google.cloud.datacatalog.v1.ITaxonomy|null|undefined} taxonomy + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest + * @instance + */ + CreateTaxonomyRequest.prototype.taxonomy = null; + + /** + * Creates a new CreateTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest instance + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest instance */ - GetPolicyTagRequest.create = function create(properties) { - return new GetPolicyTagRequest(properties); + CreateTaxonomyRequest.create = function create(properties) { + return new CreateTaxonomyRequest(properties); }; /** - * Encodes the specified GetPolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.GetPolicyTagRequest.verify|verify} messages. + * Encodes the specified CreateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.CreateTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetPolicyTagRequest.encode = function encode(message, writer) { + CreateTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) + $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified GetPolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GetPolicyTagRequest.verify|verify} messages. + * Encodes the specified CreateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CreateTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetPolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + CreateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetPolicyTagRequest message from the specified reader or buffer. + * Decodes a CreateTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetPolicyTagRequest.decode = function decode(reader, length) { + CreateTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GetPolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.parent = reader.string(); + break; + } + case 2: { + message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32()); break; } default: @@ -27265,261 +29229,136 @@ }; /** - * Decodes a GetPolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a CreateTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetPolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + CreateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetPolicyTagRequest message. + * Verifies a CreateTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetPolicyTagRequest.verify = function verify(message) { + CreateTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { + var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomy); + if (error) + return "taxonomy." + error; + } return null; }; /** - * Creates a GetPolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a CreateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1.CreateTaxonomyRequest} CreateTaxonomyRequest */ - GetPolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.GetPolicyTagRequest) + CreateTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.GetPolicyTagRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1.CreateTaxonomyRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.taxonomy != null) { + if (typeof object.taxonomy !== "object") + throw TypeError(".google.cloud.datacatalog.v1.CreateTaxonomyRequest.taxonomy: object expected"); + message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomy); + } return message; }; /** - * Creates a plain object from a GetPolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a CreateTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.GetPolicyTagRequest} message GetPolicyTagRequest + * @param {google.cloud.datacatalog.v1.CreateTaxonomyRequest} message CreateTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetPolicyTagRequest.toObject = function toObject(message, options) { + CreateTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (options.defaults) { + object.parent = ""; + object.taxonomy = null; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + object.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomy, options); return object; }; /** - * Converts this GetPolicyTagRequest to JSON. + * Converts this CreateTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @instance * @returns {Object.} JSON object */ - GetPolicyTagRequest.prototype.toJSON = function toJSON() { + CreateTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetPolicyTagRequest + * Gets the default type url for CreateTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1.CreateTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetPolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.GetPolicyTagRequest"; - }; - - return GetPolicyTagRequest; - })(); - - v1.PolicyTagManagerSerialization = (function() { - - /** - * Constructs a new PolicyTagManagerSerialization service. - * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a PolicyTagManagerSerialization - * @extends $protobuf.rpc.Service - * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - */ - function PolicyTagManagerSerialization(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); - } - - (PolicyTagManagerSerialization.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManagerSerialization; - - /** - * Creates new PolicyTagManagerSerialization service using the specified rpc implementation. - * @function create - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {PolicyTagManagerSerialization} RPC service. Useful where requests and/or responses are streamed. - */ - PolicyTagManagerSerialization.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); + return typeUrlPrefix + "/google.cloud.datacatalog.v1.CreateTaxonomyRequest"; }; - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|replaceTaxonomy}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @typedef ReplaceTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy - */ - - /** - * Calls ReplaceTaxonomy. - * @function replaceTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} request ReplaceTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ReplaceTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManagerSerialization.prototype.replaceTaxonomy = function replaceTaxonomy(request, callback) { - return this.rpcCall(replaceTaxonomy, $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); - }, "name", { value: "ReplaceTaxonomy" }); - - /** - * Calls ReplaceTaxonomy. - * @function replaceTaxonomy - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} request ReplaceTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|importTaxonomies}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @typedef ImportTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} [response] ImportTaxonomiesResponse - */ - - /** - * Calls ImportTaxonomies. - * @function importTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ImportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ImportTaxonomiesResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManagerSerialization.prototype.importTaxonomies = function importTaxonomies(request, callback) { - return this.rpcCall(importTaxonomies, $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse, request, callback); - }, "name", { value: "ImportTaxonomies" }); - - /** - * Calls ImportTaxonomies. - * @function importTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|exportTaxonomies}. - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @typedef ExportTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} [response] ExportTaxonomiesResponse - */ - - /** - * Calls ExportTaxonomies. - * @function exportTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ExportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ExportTaxonomiesResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManagerSerialization.prototype.exportTaxonomies = function exportTaxonomies(request, callback) { - return this.rpcCall(exportTaxonomies, $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse, request, callback); - }, "name", { value: "ExportTaxonomies" }); - - /** - * Calls ExportTaxonomies. - * @function exportTaxonomies - * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - return PolicyTagManagerSerialization; + return CreateTaxonomyRequest; })(); - v1.SerializedTaxonomy = (function() { + v1.DeleteTaxonomyRequest = (function() { /** - * Properties of a SerializedTaxonomy. + * Properties of a DeleteTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @interface ISerializedTaxonomy - * @property {string|null} [displayName] SerializedTaxonomy displayName - * @property {string|null} [description] SerializedTaxonomy description - * @property {Array.|null} [policyTags] SerializedTaxonomy policyTags - * @property {Array.|null} [activatedPolicyTypes] SerializedTaxonomy activatedPolicyTypes + * @interface IDeleteTaxonomyRequest + * @property {string|null} [name] DeleteTaxonomyRequest name */ /** - * Constructs a new SerializedTaxonomy. + * Constructs a new DeleteTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a SerializedTaxonomy. - * @implements ISerializedTaxonomy + * @classdesc Represents a DeleteTaxonomyRequest. + * @implements IDeleteTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest=} [properties] Properties to set */ - function SerializedTaxonomy(properties) { - this.policyTags = []; - this.activatedPolicyTypes = []; + function DeleteTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27527,131 +29366,75 @@ } /** - * SerializedTaxonomy displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy - * @instance - */ - SerializedTaxonomy.prototype.displayName = ""; - - /** - * SerializedTaxonomy description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy - * @instance - */ - SerializedTaxonomy.prototype.description = ""; - - /** - * SerializedTaxonomy policyTags. - * @member {Array.} policyTags - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy - * @instance - */ - SerializedTaxonomy.prototype.policyTags = $util.emptyArray; - - /** - * SerializedTaxonomy activatedPolicyTypes. - * @member {Array.} activatedPolicyTypes - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * DeleteTaxonomyRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @instance */ - SerializedTaxonomy.prototype.activatedPolicyTypes = $util.emptyArray; + DeleteTaxonomyRequest.prototype.name = ""; /** - * Creates a new SerializedTaxonomy instance using the specified properties. + * Creates a new DeleteTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy instance + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest instance */ - SerializedTaxonomy.create = function create(properties) { - return new SerializedTaxonomy(properties); + DeleteTaxonomyRequest.create = function create(properties) { + return new DeleteTaxonomyRequest(properties); }; /** - * Encodes the specified SerializedTaxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedTaxonomy.verify|verify} messages. + * Encodes the specified DeleteTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.DeleteTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedTaxonomy.encode = function encode(message, writer) { + DeleteTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); - if (message.policyTags != null && message.policyTags.length) - for (var i = 0; i < message.policyTags.length; ++i) - $root.google.cloud.datacatalog.v1.SerializedPolicyTag.encode(message.policyTags[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { - writer.uint32(/* id 4, wireType 2 =*/34).fork(); - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - writer.int32(message.activatedPolicyTypes[i]); - writer.ldelim(); - } + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified SerializedTaxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedTaxonomy.verify|verify} messages. + * Encodes the specified DeleteTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DeleteTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedTaxonomy.encodeDelimited = function encodeDelimited(message, writer) { + DeleteTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SerializedTaxonomy message from the specified reader or buffer. + * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedTaxonomy.decode = function decode(reader, length) { + DeleteTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SerializedTaxonomy(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); - break; - } - case 2: { - message.description = reader.string(); - break; - } - case 3: { - if (!(message.policyTags && message.policyTags.length)) - message.policyTags = []; - message.policyTags.push($root.google.cloud.datacatalog.v1.SerializedPolicyTag.decode(reader, reader.uint32())); - break; - } - case 4: { - if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) - message.activatedPolicyTypes = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.activatedPolicyTypes.push(reader.int32()); - } else - message.activatedPolicyTypes.push(reader.int32()); + message.name = reader.string(); break; } default: @@ -27663,201 +29446,123 @@ }; /** - * Decodes a SerializedTaxonomy message from the specified reader or buffer, length delimited. + * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedTaxonomy.decodeDelimited = function decodeDelimited(reader) { + DeleteTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SerializedTaxonomy message. + * Verifies a DeleteTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SerializedTaxonomy.verify = function verify(message) { + DeleteTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.policyTags != null && message.hasOwnProperty("policyTags")) { - if (!Array.isArray(message.policyTags)) - return "policyTags: array expected"; - for (var i = 0; i < message.policyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.verify(message.policyTags[i]); - if (error) - return "policyTags." + error; - } - } - if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { - if (!Array.isArray(message.activatedPolicyTypes)) - return "activatedPolicyTypes: array expected"; - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - switch (message.activatedPolicyTypes[i]) { - default: - return "activatedPolicyTypes: enum value[] expected"; - case 0: - case 1: - break; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates a SerializedTaxonomy message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} DeleteTaxonomyRequest */ - SerializedTaxonomy.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.SerializedTaxonomy) + DeleteTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.SerializedTaxonomy(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.policyTags) { - if (!Array.isArray(object.policyTags)) - throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.policyTags: array expected"); - message.policyTags = []; - for (var i = 0; i < object.policyTags.length; ++i) { - if (typeof object.policyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.policyTags: object expected"); - message.policyTags[i] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.fromObject(object.policyTags[i]); - } - } - if (object.activatedPolicyTypes) { - if (!Array.isArray(object.activatedPolicyTypes)) - throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.activatedPolicyTypes: array expected"); - message.activatedPolicyTypes = []; - for (var i = 0; i < object.activatedPolicyTypes.length; ++i) - switch (object.activatedPolicyTypes[i]) { - default: - if (typeof object.activatedPolicyTypes[i] === "number") { - message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; - break; - } - case "POLICY_TYPE_UNSPECIFIED": - case 0: - message.activatedPolicyTypes[i] = 0; - break; - case "FINE_GRAINED_ACCESS_CONTROL": - case 1: - message.activatedPolicyTypes[i] = 1; - break; - } - } + var message = new $root.google.cloud.datacatalog.v1.DeleteTaxonomyRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from a SerializedTaxonomy message. Also converts values to other types if specified. + * Creates a plain object from a DeleteTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.SerializedTaxonomy} message SerializedTaxonomy + * @param {google.cloud.datacatalog.v1.DeleteTaxonomyRequest} message DeleteTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SerializedTaxonomy.toObject = function toObject(message, options) { + DeleteTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.policyTags = []; - object.activatedPolicyTypes = []; - } - if (options.defaults) { - object.displayName = ""; - object.description = ""; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.policyTags && message.policyTags.length) { - object.policyTags = []; - for (var j = 0; j < message.policyTags.length; ++j) - object.policyTags[j] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.toObject(message.policyTags[j], options); - } - if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { - object.activatedPolicyTypes = []; - for (var j = 0; j < message.activatedPolicyTypes.length; ++j) - object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; - } + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this SerializedTaxonomy to JSON. + * Converts this DeleteTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @instance * @returns {Object.} JSON object */ - SerializedTaxonomy.prototype.toJSON = function toJSON() { + DeleteTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SerializedTaxonomy + * Gets the default type url for DeleteTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1.DeleteTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SerializedTaxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.SerializedTaxonomy"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DeleteTaxonomyRequest"; }; - return SerializedTaxonomy; + return DeleteTaxonomyRequest; })(); - v1.SerializedPolicyTag = (function() { + v1.UpdateTaxonomyRequest = (function() { /** - * Properties of a SerializedPolicyTag. + * Properties of an UpdateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @interface ISerializedPolicyTag - * @property {string|null} [policyTag] SerializedPolicyTag policyTag - * @property {string|null} [displayName] SerializedPolicyTag displayName - * @property {string|null} [description] SerializedPolicyTag description - * @property {Array.|null} [childPolicyTags] SerializedPolicyTag childPolicyTags + * @interface IUpdateTaxonomyRequest + * @property {google.cloud.datacatalog.v1.ITaxonomy|null} [taxonomy] UpdateTaxonomyRequest taxonomy + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTaxonomyRequest updateMask */ /** - * Constructs a new SerializedPolicyTag. + * Constructs a new UpdateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a SerializedPolicyTag. - * @implements ISerializedPolicyTag + * @classdesc Represents an UpdateTaxonomyRequest. + * @implements IUpdateTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest=} [properties] Properties to set */ - function SerializedPolicyTag(properties) { - this.childPolicyTags = []; + function UpdateTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -27865,120 +29570,89 @@ } /** - * SerializedPolicyTag policyTag. - * @member {string} policyTag - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag - * @instance - */ - SerializedPolicyTag.prototype.policyTag = ""; - - /** - * SerializedPolicyTag displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag - * @instance - */ - SerializedPolicyTag.prototype.displayName = ""; - - /** - * SerializedPolicyTag description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * UpdateTaxonomyRequest taxonomy. + * @member {google.cloud.datacatalog.v1.ITaxonomy|null|undefined} taxonomy + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @instance */ - SerializedPolicyTag.prototype.description = ""; + UpdateTaxonomyRequest.prototype.taxonomy = null; /** - * SerializedPolicyTag childPolicyTags. - * @member {Array.} childPolicyTags - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * UpdateTaxonomyRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @instance */ - SerializedPolicyTag.prototype.childPolicyTags = $util.emptyArray; + UpdateTaxonomyRequest.prototype.updateMask = null; /** - * Creates a new SerializedPolicyTag instance using the specified properties. + * Creates a new UpdateTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag instance + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest instance */ - SerializedPolicyTag.create = function create(properties) { - return new SerializedPolicyTag(properties); + UpdateTaxonomyRequest.create = function create(properties) { + return new UpdateTaxonomyRequest(properties); }; /** - * Encodes the specified SerializedPolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedPolicyTag.verify|verify} messages. + * Encodes the specified UpdateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UpdateTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedPolicyTag.encode = function encode(message, writer) { + UpdateTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.policyTag); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.childPolicyTags != null && message.childPolicyTags.length) - for (var i = 0; i < message.childPolicyTags.length; ++i) - $root.google.cloud.datacatalog.v1.SerializedPolicyTag.encode(message.childPolicyTags[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) + $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified SerializedPolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedPolicyTag.verify|verify} messages. + * Encodes the specified UpdateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UpdateTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedPolicyTag.encodeDelimited = function encodeDelimited(message, writer) { + UpdateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SerializedPolicyTag message from the specified reader or buffer. + * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedPolicyTag.decode = function decode(reader, length) { + UpdateTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SerializedPolicyTag(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.policyTag = reader.string(); + message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32()); break; } case 2: { - message.displayName = reader.string(); - break; - } - case 3: { - message.description = reader.string(); - break; - } - case 4: { - if (!(message.childPolicyTags && message.childPolicyTags.length)) - message.childPolicyTags = []; - message.childPolicyTags.push($root.google.cloud.datacatalog.v1.SerializedPolicyTag.decode(reader, reader.uint32())); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -27990,166 +29664,144 @@ }; /** - * Decodes a SerializedPolicyTag message from the specified reader or buffer, length delimited. + * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedPolicyTag.decodeDelimited = function decodeDelimited(reader) { + UpdateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SerializedPolicyTag message. + * Verifies an UpdateTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SerializedPolicyTag.verify = function verify(message) { + UpdateTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - if (!$util.isString(message.policyTag)) - return "policyTag: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { - if (!Array.isArray(message.childPolicyTags)) - return "childPolicyTags: array expected"; - for (var i = 0; i < message.childPolicyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.verify(message.childPolicyTags[i]); - if (error) - return "childPolicyTags." + error; - } + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { + var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomy); + if (error) + return "taxonomy." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates a SerializedPolicyTag message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} UpdateTaxonomyRequest */ - SerializedPolicyTag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.SerializedPolicyTag) + UpdateTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.SerializedPolicyTag(); - if (object.policyTag != null) - message.policyTag = String(object.policyTag); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.childPolicyTags) { - if (!Array.isArray(object.childPolicyTags)) - throw TypeError(".google.cloud.datacatalog.v1.SerializedPolicyTag.childPolicyTags: array expected"); - message.childPolicyTags = []; - for (var i = 0; i < object.childPolicyTags.length; ++i) { - if (typeof object.childPolicyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.SerializedPolicyTag.childPolicyTags: object expected"); - message.childPolicyTags[i] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.fromObject(object.childPolicyTags[i]); - } + var message = new $root.google.cloud.datacatalog.v1.UpdateTaxonomyRequest(); + if (object.taxonomy != null) { + if (typeof object.taxonomy !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UpdateTaxonomyRequest.taxonomy: object expected"); + message.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomy); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UpdateTaxonomyRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from a SerializedPolicyTag message. Also converts values to other types if specified. + * Creates a plain object from an UpdateTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.SerializedPolicyTag} message SerializedPolicyTag + * @param {google.cloud.datacatalog.v1.UpdateTaxonomyRequest} message UpdateTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SerializedPolicyTag.toObject = function toObject(message, options) { + UpdateTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.childPolicyTags = []; if (options.defaults) { - object.policyTag = ""; - object.displayName = ""; - object.description = ""; - } - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - object.policyTag = message.policyTag; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.childPolicyTags && message.childPolicyTags.length) { - object.childPolicyTags = []; - for (var j = 0; j < message.childPolicyTags.length; ++j) - object.childPolicyTags[j] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.toObject(message.childPolicyTags[j], options); + object.taxonomy = null; + object.updateMask = null; } + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + object.taxonomy = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomy, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this SerializedPolicyTag to JSON. + * Converts this UpdateTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @instance * @returns {Object.} JSON object */ - SerializedPolicyTag.prototype.toJSON = function toJSON() { + UpdateTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SerializedPolicyTag + * Gets the default type url for UpdateTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1.UpdateTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SerializedPolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.SerializedPolicyTag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UpdateTaxonomyRequest"; }; - return SerializedPolicyTag; + return UpdateTaxonomyRequest; })(); - v1.ReplaceTaxonomyRequest = (function() { + v1.ListTaxonomiesRequest = (function() { /** - * Properties of a ReplaceTaxonomyRequest. + * Properties of a ListTaxonomiesRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IReplaceTaxonomyRequest - * @property {string|null} [name] ReplaceTaxonomyRequest name - * @property {google.cloud.datacatalog.v1.ISerializedTaxonomy|null} [serializedTaxonomy] ReplaceTaxonomyRequest serializedTaxonomy + * @interface IListTaxonomiesRequest + * @property {string|null} [parent] ListTaxonomiesRequest parent + * @property {number|null} [pageSize] ListTaxonomiesRequest pageSize + * @property {string|null} [pageToken] ListTaxonomiesRequest pageToken + * @property {string|null} [filter] ListTaxonomiesRequest filter */ /** - * Constructs a new ReplaceTaxonomyRequest. + * Constructs a new ListTaxonomiesRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a ReplaceTaxonomyRequest. - * @implements IReplaceTaxonomyRequest + * @classdesc Represents a ListTaxonomiesRequest. + * @implements IListTaxonomiesRequest * @constructor - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest=} [properties] Properties to set */ - function ReplaceTaxonomyRequest(properties) { + function ListTaxonomiesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -28157,89 +29809,117 @@ } /** - * ReplaceTaxonomyRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * ListTaxonomiesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @instance */ - ReplaceTaxonomyRequest.prototype.name = ""; + ListTaxonomiesRequest.prototype.parent = ""; /** - * ReplaceTaxonomyRequest serializedTaxonomy. - * @member {google.cloud.datacatalog.v1.ISerializedTaxonomy|null|undefined} serializedTaxonomy - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * ListTaxonomiesRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @instance */ - ReplaceTaxonomyRequest.prototype.serializedTaxonomy = null; + ListTaxonomiesRequest.prototype.pageSize = 0; /** - * Creates a new ReplaceTaxonomyRequest instance using the specified properties. + * ListTaxonomiesRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @instance + */ + ListTaxonomiesRequest.prototype.pageToken = ""; + + /** + * ListTaxonomiesRequest filter. + * @member {string} filter + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest + * @instance + */ + ListTaxonomiesRequest.prototype.filter = ""; + + /** + * Creates a new ListTaxonomiesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest instance */ - ReplaceTaxonomyRequest.create = function create(properties) { - return new ReplaceTaxonomyRequest(properties); + ListTaxonomiesRequest.create = function create(properties) { + return new ListTaxonomiesRequest(properties); }; /** - * Encodes the specified ReplaceTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} message ReplaceTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ReplaceTaxonomyRequest.encode = function encode(message, writer) { + ListTaxonomiesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.serializedTaxonomy != null && Object.hasOwnProperty.call(message, "serializedTaxonomy")) - $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.serializedTaxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.filter != null && Object.hasOwnProperty.call(message, "filter")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.filter); return writer; }; /** - * Encodes the specified ReplaceTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} message ReplaceTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ReplaceTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ReplaceTaxonomyRequest message from the specified reader or buffer. + * Decodes a ListTaxonomiesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ReplaceTaxonomyRequest.decode = function decode(reader, length) { + ListTaxonomiesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.parent = reader.string(); break; } case 2: { - message.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32()); + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); + break; + } + case 4: { + message.filter = reader.string(); break; } default: @@ -28251,138 +29931,149 @@ }; /** - * Decodes a ReplaceTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a ListTaxonomiesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ReplaceTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + ListTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ReplaceTaxonomyRequest message. + * Verifies a ListTaxonomiesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ReplaceTaxonomyRequest.verify = function verify(message) { + ListTaxonomiesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.serializedTaxonomy != null && message.hasOwnProperty("serializedTaxonomy")) { - var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.serializedTaxonomy); - if (error) - return "serializedTaxonomy." + error; - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + if (message.filter != null && message.hasOwnProperty("filter")) + if (!$util.isString(message.filter)) + return "filter: string expected"; return null; }; /** - * Creates a ReplaceTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesRequest} ListTaxonomiesRequest */ - ReplaceTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest) + ListTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest(); - if (object.name != null) - message.name = String(object.name); - if (object.serializedTaxonomy != null) { - if (typeof object.serializedTaxonomy !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.serializedTaxonomy: object expected"); - message.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.serializedTaxonomy); - } + var message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + if (object.filter != null) + message.filter = String(object.filter); return message; }; /** - * Creates a plain object from a ReplaceTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListTaxonomiesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} message ReplaceTaxonomyRequest + * @param {google.cloud.datacatalog.v1.ListTaxonomiesRequest} message ListTaxonomiesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ReplaceTaxonomyRequest.toObject = function toObject(message, options) { + ListTaxonomiesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.name = ""; - object.serializedTaxonomy = null; + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; + object.filter = ""; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.serializedTaxonomy != null && message.hasOwnProperty("serializedTaxonomy")) - object.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.serializedTaxonomy, options); + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.filter != null && message.hasOwnProperty("filter")) + object.filter = message.filter; return object; }; /** - * Converts this ReplaceTaxonomyRequest to JSON. + * Converts this ListTaxonomiesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @instance * @returns {Object.} JSON object */ - ReplaceTaxonomyRequest.prototype.toJSON = function toJSON() { + ListTaxonomiesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ReplaceTaxonomyRequest + * Gets the default type url for ListTaxonomiesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ReplaceTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ReplaceTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListTaxonomiesRequest"; }; - return ReplaceTaxonomyRequest; + return ListTaxonomiesRequest; })(); - v1.ImportTaxonomiesRequest = (function() { + v1.ListTaxonomiesResponse = (function() { /** - * Properties of an ImportTaxonomiesRequest. + * Properties of a ListTaxonomiesResponse. * @memberof google.cloud.datacatalog.v1 - * @interface IImportTaxonomiesRequest - * @property {string|null} [parent] ImportTaxonomiesRequest parent - * @property {google.cloud.datacatalog.v1.IInlineSource|null} [inlineSource] ImportTaxonomiesRequest inlineSource - * @property {google.cloud.datacatalog.v1.ICrossRegionalSource|null} [crossRegionalSource] ImportTaxonomiesRequest crossRegionalSource + * @interface IListTaxonomiesResponse + * @property {Array.|null} [taxonomies] ListTaxonomiesResponse taxonomies + * @property {string|null} [nextPageToken] ListTaxonomiesResponse nextPageToken */ /** - * Constructs a new ImportTaxonomiesRequest. + * Constructs a new ListTaxonomiesResponse. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an ImportTaxonomiesRequest. - * @implements IImportTaxonomiesRequest + * @classdesc Represents a ListTaxonomiesResponse. + * @implements IListTaxonomiesResponse * @constructor - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse=} [properties] Properties to set */ - function ImportTaxonomiesRequest(properties) { + function ListTaxonomiesResponse(properties) { + this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -28390,117 +30081,92 @@ } /** - * ImportTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest - * @instance - */ - ImportTaxonomiesRequest.prototype.parent = ""; - - /** - * ImportTaxonomiesRequest inlineSource. - * @member {google.cloud.datacatalog.v1.IInlineSource|null|undefined} inlineSource - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest - * @instance - */ - ImportTaxonomiesRequest.prototype.inlineSource = null; - - /** - * ImportTaxonomiesRequest crossRegionalSource. - * @member {google.cloud.datacatalog.v1.ICrossRegionalSource|null|undefined} crossRegionalSource - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * ListTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @instance */ - ImportTaxonomiesRequest.prototype.crossRegionalSource = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + ListTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; /** - * ImportTaxonomiesRequest source. - * @member {"inlineSource"|"crossRegionalSource"|undefined} source - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * ListTaxonomiesResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @instance */ - Object.defineProperty(ImportTaxonomiesRequest.prototype, "source", { - get: $util.oneOfGetter($oneOfFields = ["inlineSource", "crossRegionalSource"]), - set: $util.oneOfSetter($oneOfFields) - }); + ListTaxonomiesResponse.prototype.nextPageToken = ""; /** - * Creates a new ImportTaxonomiesRequest instance using the specified properties. + * Creates a new ListTaxonomiesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest instance + * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse instance */ - ImportTaxonomiesRequest.create = function create(properties) { - return new ImportTaxonomiesRequest(properties); + ListTaxonomiesResponse.create = function create(properties) { + return new ListTaxonomiesResponse(properties); }; /** - * Encodes the specified ImportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesRequest.encode = function encode(message, writer) { + ListTaxonomiesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.inlineSource != null && Object.hasOwnProperty.call(message, "inlineSource")) - $root.google.cloud.datacatalog.v1.InlineSource.encode(message.inlineSource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.crossRegionalSource != null && Object.hasOwnProperty.call(message, "crossRegionalSource")) - $root.google.cloud.datacatalog.v1.CrossRegionalSource.encode(message.crossRegionalSource, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); return writer; }; /** - * Encodes the specified ImportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListTaxonomiesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer. + * Decodes a ListTaxonomiesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesRequest.decode = function decode(reader, length) { + ListTaxonomiesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32())); break; } case 2: { - message.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.decode(reader, reader.uint32()); - break; - } - case 3: { - message.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.decode(reader, reader.uint32()); + message.nextPageToken = reader.string(); break; } default: @@ -28512,162 +30178,148 @@ }; /** - * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes a ListTaxonomiesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + ListTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ImportTaxonomiesRequest message. + * Verifies a ListTaxonomiesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ImportTaxonomiesRequest.verify = function verify(message) { + ListTaxonomiesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { - properties.source = 1; - { - var error = $root.google.cloud.datacatalog.v1.InlineSource.verify(message.inlineSource); - if (error) - return "inlineSource." + error; - } - } - if (message.crossRegionalSource != null && message.hasOwnProperty("crossRegionalSource")) { - if (properties.source === 1) - return "source: multiple values"; - properties.source = 1; - { - var error = $root.google.cloud.datacatalog.v1.CrossRegionalSource.verify(message.crossRegionalSource); + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomies[i]); if (error) - return "crossRegionalSource." + error; + return "taxonomies." + error; } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates an ImportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.ListTaxonomiesResponse} ListTaxonomiesResponse */ - ImportTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest) + ListTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.inlineSource != null) { - if (typeof object.inlineSource !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesRequest.inlineSource: object expected"); - message.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.fromObject(object.inlineSource); - } - if (object.crossRegionalSource != null) { - if (typeof object.crossRegionalSource !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesRequest.crossRegionalSource: object expected"); - message.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.fromObject(object.crossRegionalSource); + var message = new $root.google.cloud.datacatalog.v1.ListTaxonomiesResponse(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1.ListTaxonomiesResponse.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ListTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomies[i]); + } } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from an ImportTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListTaxonomiesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} message ImportTaxonomiesRequest + * @param {google.cloud.datacatalog.v1.ListTaxonomiesResponse} message ListTaxonomiesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ImportTaxonomiesRequest.toObject = function toObject(message, options) { + ListTaxonomiesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.taxonomies = []; if (options.defaults) - object.parent = ""; - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { - object.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.toObject(message.inlineSource, options); - if (options.oneofs) - object.source = "inlineSource"; - } - if (message.crossRegionalSource != null && message.hasOwnProperty("crossRegionalSource")) { - object.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.toObject(message.crossRegionalSource, options); - if (options.oneofs) - object.source = "crossRegionalSource"; + object.nextPageToken = ""; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomies[j], options); } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this ImportTaxonomiesRequest to JSON. + * Converts this ListTaxonomiesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @instance * @returns {Object.} JSON object */ - ImportTaxonomiesRequest.prototype.toJSON = function toJSON() { + ListTaxonomiesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ImportTaxonomiesRequest + * Gets the default type url for ListTaxonomiesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.ListTaxonomiesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ImportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListTaxonomiesResponse"; }; - return ImportTaxonomiesRequest; + return ListTaxonomiesResponse; })(); - v1.InlineSource = (function() { + v1.GetTaxonomyRequest = (function() { /** - * Properties of an InlineSource. + * Properties of a GetTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IInlineSource - * @property {Array.|null} [taxonomies] InlineSource taxonomies + * @interface IGetTaxonomyRequest + * @property {string|null} [name] GetTaxonomyRequest name */ /** - * Constructs a new InlineSource. + * Constructs a new GetTaxonomyRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an InlineSource. - * @implements IInlineSource + * @classdesc Represents a GetTaxonomyRequest. + * @implements IGetTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1.IInlineSource=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest=} [properties] Properties to set */ - function InlineSource(properties) { - this.taxonomies = []; + function GetTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -28675,78 +30327,75 @@ } /** - * InlineSource taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1.InlineSource + * GetTaxonomyRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @instance */ - InlineSource.prototype.taxonomies = $util.emptyArray; + GetTaxonomyRequest.prototype.name = ""; /** - * Creates a new InlineSource instance using the specified properties. + * Creates a new GetTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IInlineSource=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource instance + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest instance */ - InlineSource.create = function create(properties) { - return new InlineSource(properties); + GetTaxonomyRequest.create = function create(properties) { + return new GetTaxonomyRequest(properties); }; /** - * Encodes the specified InlineSource message. Does not implicitly {@link google.cloud.datacatalog.v1.InlineSource.verify|verify} messages. + * Encodes the specified GetTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.GetTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IInlineSource} message InlineSource message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - InlineSource.encode = function encode(message, writer) { + GetTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified InlineSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.InlineSource.verify|verify} messages. + * Encodes the specified GetTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GetTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.IInlineSource} message InlineSource message or plain object to encode + * @param {google.cloud.datacatalog.v1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - InlineSource.encodeDelimited = function encodeDelimited(message, writer) { + GetTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an InlineSource message from the specified reader or buffer. + * Decodes a GetTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - InlineSource.decode = function decode(reader, length) { + GetTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.InlineSource(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GetTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32())); + message.name = reader.string(); break; } default: @@ -28758,139 +30407,123 @@ }; /** - * Decodes an InlineSource message from the specified reader or buffer, length delimited. + * Decodes a GetTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - InlineSource.decodeDelimited = function decodeDelimited(reader) { + GetTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an InlineSource message. + * Verifies a GetTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - InlineSource.verify = function verify(message) { + GetTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates an InlineSource message from a plain object. Also converts values to their respective internal types. + * Creates a GetTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1.GetTaxonomyRequest} GetTaxonomyRequest */ - InlineSource.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.InlineSource) + GetTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.GetTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.InlineSource(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1.InlineSource.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.InlineSource.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.taxonomies[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1.GetTaxonomyRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from an InlineSource message. Also converts values to other types if specified. + * Creates a plain object from a GetTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1.InlineSource} message InlineSource + * @param {google.cloud.datacatalog.v1.GetTaxonomyRequest} message GetTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - InlineSource.toObject = function toObject(message, options) { + GetTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.taxonomies[j], options); - } + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this InlineSource to JSON. + * Converts this GetTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @instance * @returns {Object.} JSON object */ - InlineSource.prototype.toJSON = function toJSON() { + GetTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for InlineSource + * Gets the default type url for GetTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.InlineSource + * @memberof google.cloud.datacatalog.v1.GetTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - InlineSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.InlineSource"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.GetTaxonomyRequest"; }; - return InlineSource; + return GetTaxonomyRequest; })(); - v1.CrossRegionalSource = (function() { + v1.CreatePolicyTagRequest = (function() { /** - * Properties of a CrossRegionalSource. + * Properties of a CreatePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @interface ICrossRegionalSource - * @property {string|null} [taxonomy] CrossRegionalSource taxonomy + * @interface ICreatePolicyTagRequest + * @property {string|null} [parent] CreatePolicyTagRequest parent + * @property {google.cloud.datacatalog.v1.IPolicyTag|null} [policyTag] CreatePolicyTagRequest policyTag */ /** - * Constructs a new CrossRegionalSource. + * Constructs a new CreatePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents a CrossRegionalSource. - * @implements ICrossRegionalSource + * @classdesc Represents a CreatePolicyTagRequest. + * @implements ICreatePolicyTagRequest * @constructor - * @param {google.cloud.datacatalog.v1.ICrossRegionalSource=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest=} [properties] Properties to set */ - function CrossRegionalSource(properties) { + function CreatePolicyTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -28898,75 +30531,89 @@ } /** - * CrossRegionalSource taxonomy. - * @member {string} taxonomy - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * CreatePolicyTagRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @instance */ - CrossRegionalSource.prototype.taxonomy = ""; + CreatePolicyTagRequest.prototype.parent = ""; /** - * Creates a new CrossRegionalSource instance using the specified properties. + * CreatePolicyTagRequest policyTag. + * @member {google.cloud.datacatalog.v1.IPolicyTag|null|undefined} policyTag + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest + * @instance + */ + CreatePolicyTagRequest.prototype.policyTag = null; + + /** + * Creates a new CreatePolicyTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.ICrossRegionalSource=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource instance + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest instance */ - CrossRegionalSource.create = function create(properties) { - return new CrossRegionalSource(properties); + CreatePolicyTagRequest.create = function create(properties) { + return new CreatePolicyTagRequest(properties); }; /** - * Encodes the specified CrossRegionalSource message. Does not implicitly {@link google.cloud.datacatalog.v1.CrossRegionalSource.verify|verify} messages. + * Encodes the specified CreatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.CreatePolicyTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.ICrossRegionalSource} message CrossRegionalSource message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CrossRegionalSource.encode = function encode(message, writer) { + CreatePolicyTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.taxonomy); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) + $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified CrossRegionalSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CrossRegionalSource.verify|verify} messages. + * Encodes the specified CreatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CreatePolicyTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.ICrossRegionalSource} message CrossRegionalSource message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CrossRegionalSource.encodeDelimited = function encodeDelimited(message, writer) { + CreatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CrossRegionalSource message from the specified reader or buffer. + * Decodes a CreatePolicyTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource + * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CrossRegionalSource.decode = function decode(reader, length) { + CreatePolicyTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CrossRegionalSource(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.taxonomy = reader.string(); + message.parent = reader.string(); + break; + } + case 2: { + message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32()); break; } default: @@ -28978,123 +30625,136 @@ }; /** - * Decodes a CrossRegionalSource message from the specified reader or buffer, length delimited. + * Decodes a CreatePolicyTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource + * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CrossRegionalSource.decodeDelimited = function decodeDelimited(reader) { + CreatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CrossRegionalSource message. + * Verifies a CreatePolicyTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CrossRegionalSource.verify = function verify(message) { + CreatePolicyTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - if (!$util.isString(message.taxonomy)) - return "taxonomy: string expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) { + var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTag); + if (error) + return "policyTag." + error; + } return null; }; /** - * Creates a CrossRegionalSource message from a plain object. Also converts values to their respective internal types. + * Creates a CreatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource + * @returns {google.cloud.datacatalog.v1.CreatePolicyTagRequest} CreatePolicyTagRequest */ - CrossRegionalSource.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.CrossRegionalSource) + CreatePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.CrossRegionalSource(); - if (object.taxonomy != null) - message.taxonomy = String(object.taxonomy); + var message = new $root.google.cloud.datacatalog.v1.CreatePolicyTagRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.policyTag != null) { + if (typeof object.policyTag !== "object") + throw TypeError(".google.cloud.datacatalog.v1.CreatePolicyTagRequest.policyTag: object expected"); + message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTag); + } return message; }; /** - * Creates a plain object from a CrossRegionalSource message. Also converts values to other types if specified. + * Creates a plain object from a CreatePolicyTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.CrossRegionalSource} message CrossRegionalSource + * @param {google.cloud.datacatalog.v1.CreatePolicyTagRequest} message CreatePolicyTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CrossRegionalSource.toObject = function toObject(message, options) { + CreatePolicyTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.taxonomy = ""; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - object.taxonomy = message.taxonomy; + if (options.defaults) { + object.parent = ""; + object.policyTag = null; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + object.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTag, options); return object; }; /** - * Converts this CrossRegionalSource to JSON. + * Converts this CreatePolicyTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @instance * @returns {Object.} JSON object */ - CrossRegionalSource.prototype.toJSON = function toJSON() { + CreatePolicyTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CrossRegionalSource + * Gets the default type url for CreatePolicyTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.CrossRegionalSource + * @memberof google.cloud.datacatalog.v1.CreatePolicyTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CrossRegionalSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.CrossRegionalSource"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.CreatePolicyTagRequest"; }; - return CrossRegionalSource; + return CreatePolicyTagRequest; })(); - v1.ImportTaxonomiesResponse = (function() { + v1.DeletePolicyTagRequest = (function() { /** - * Properties of an ImportTaxonomiesResponse. + * Properties of a DeletePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IImportTaxonomiesResponse - * @property {Array.|null} [taxonomies] ImportTaxonomiesResponse taxonomies + * @interface IDeletePolicyTagRequest + * @property {string|null} [name] DeletePolicyTagRequest name */ /** - * Constructs a new ImportTaxonomiesResponse. + * Constructs a new DeletePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an ImportTaxonomiesResponse. - * @implements IImportTaxonomiesResponse + * @classdesc Represents a DeletePolicyTagRequest. + * @implements IDeletePolicyTagRequest * @constructor - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest=} [properties] Properties to set */ - function ImportTaxonomiesResponse(properties) { - this.taxonomies = []; + function DeletePolicyTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -29102,78 +30762,75 @@ } /** - * ImportTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * DeletePolicyTagRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @instance */ - ImportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + DeletePolicyTagRequest.prototype.name = ""; /** - * Creates a new ImportTaxonomiesResponse instance using the specified properties. + * Creates a new DeletePolicyTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest instance */ - ImportTaxonomiesResponse.create = function create(properties) { - return new ImportTaxonomiesResponse(properties); + DeletePolicyTagRequest.create = function create(properties) { + return new DeletePolicyTagRequest(properties); }; /** - * Encodes the specified ImportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified DeletePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.DeletePolicyTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesResponse.encode = function encode(message, writer) { + DeletePolicyTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified ImportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified DeletePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.DeletePolicyTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + DeletePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer. + * Decodes a DeletePolicyTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesResponse.decode = function decode(reader, length) { + DeletePolicyTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32())); + message.name = reader.string(); break; } default: @@ -29185,142 +30842,123 @@ }; /** - * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a DeletePolicyTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + DeletePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ImportTaxonomiesResponse message. + * Verifies a DeletePolicyTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ImportTaxonomiesResponse.verify = function verify(message) { + DeletePolicyTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates an ImportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a DeletePolicyTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.DeletePolicyTagRequest} DeletePolicyTagRequest */ - ImportTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse) + DeletePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomies[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1.DeletePolicyTagRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from an ImportTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a DeletePolicyTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} message ImportTaxonomiesResponse + * @param {google.cloud.datacatalog.v1.DeletePolicyTagRequest} message DeletePolicyTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ImportTaxonomiesResponse.toObject = function toObject(message, options) { + DeletePolicyTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomies[j], options); - } + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this ImportTaxonomiesResponse to JSON. + * Converts this DeletePolicyTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @instance * @returns {Object.} JSON object */ - ImportTaxonomiesResponse.prototype.toJSON = function toJSON() { + DeletePolicyTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ImportTaxonomiesResponse + * Gets the default type url for DeletePolicyTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.DeletePolicyTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ImportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeletePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.DeletePolicyTagRequest"; }; - return ImportTaxonomiesResponse; + return DeletePolicyTagRequest; })(); - v1.ExportTaxonomiesRequest = (function() { + v1.UpdatePolicyTagRequest = (function() { /** - * Properties of an ExportTaxonomiesRequest. + * Properties of an UpdatePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IExportTaxonomiesRequest - * @property {string|null} [parent] ExportTaxonomiesRequest parent - * @property {Array.|null} [taxonomies] ExportTaxonomiesRequest taxonomies - * @property {boolean|null} [serializedTaxonomies] ExportTaxonomiesRequest serializedTaxonomies + * @interface IUpdatePolicyTagRequest + * @property {google.cloud.datacatalog.v1.IPolicyTag|null} [policyTag] UpdatePolicyTagRequest policyTag + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdatePolicyTagRequest updateMask */ /** - * Constructs a new ExportTaxonomiesRequest. + * Constructs a new UpdatePolicyTagRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an ExportTaxonomiesRequest. - * @implements IExportTaxonomiesRequest + * @classdesc Represents an UpdatePolicyTagRequest. + * @implements IUpdatePolicyTagRequest * @constructor - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest=} [properties] Properties to set */ - function ExportTaxonomiesRequest(properties) { - this.taxonomies = []; + function UpdatePolicyTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -29328,120 +30966,89 @@ } /** - * ExportTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest - * @instance - */ - ExportTaxonomiesRequest.prototype.parent = ""; - - /** - * ExportTaxonomiesRequest taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest - * @instance - */ - ExportTaxonomiesRequest.prototype.taxonomies = $util.emptyArray; - - /** - * ExportTaxonomiesRequest serializedTaxonomies. - * @member {boolean|null|undefined} serializedTaxonomies - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * UpdatePolicyTagRequest policyTag. + * @member {google.cloud.datacatalog.v1.IPolicyTag|null|undefined} policyTag + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @instance */ - ExportTaxonomiesRequest.prototype.serializedTaxonomies = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + UpdatePolicyTagRequest.prototype.policyTag = null; /** - * ExportTaxonomiesRequest destination. - * @member {"serializedTaxonomies"|undefined} destination - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * UpdatePolicyTagRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @instance */ - Object.defineProperty(ExportTaxonomiesRequest.prototype, "destination", { - get: $util.oneOfGetter($oneOfFields = ["serializedTaxonomies"]), - set: $util.oneOfSetter($oneOfFields) - }); + UpdatePolicyTagRequest.prototype.updateMask = null; /** - * Creates a new ExportTaxonomiesRequest instance using the specified properties. + * Creates a new UpdatePolicyTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest instance + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest instance */ - ExportTaxonomiesRequest.create = function create(properties) { - return new ExportTaxonomiesRequest(properties); + UpdatePolicyTagRequest.create = function create(properties) { + return new UpdatePolicyTagRequest(properties); }; /** - * Encodes the specified ExportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified UpdatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.UpdatePolicyTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesRequest.encode = function encode(message, writer) { + UpdatePolicyTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.taxonomies[i]); - if (message.serializedTaxonomies != null && Object.hasOwnProperty.call(message, "serializedTaxonomies")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.serializedTaxonomies); + if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) + $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified ExportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified UpdatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.UpdatePolicyTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + UpdatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer. + * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesRequest.decode = function decode(reader, length) { + UpdatePolicyTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32()); break; } case 2: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push(reader.string()); - break; - } - case 3: { - message.serializedTaxonomies = reader.bool(); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -29453,157 +31060,143 @@ }; /** - * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + UpdatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ExportTaxonomiesRequest message. + * Verifies an UpdatePolicyTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ExportTaxonomiesRequest.verify = function verify(message) { + UpdatePolicyTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) - if (!$util.isString(message.taxonomies[i])) - return "taxonomies: string[] expected"; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) { + var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTag); + if (error) + return "policyTag." + error; } - if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { - properties.destination = 1; - if (typeof message.serializedTaxonomies !== "boolean") - return "serializedTaxonomies: boolean expected"; + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates an ExportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates an UpdatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} UpdatePolicyTagRequest */ - ExportTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest) + UpdatePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesRequest.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) - message.taxonomies[i] = String(object.taxonomies[i]); + var message = new $root.google.cloud.datacatalog.v1.UpdatePolicyTagRequest(); + if (object.policyTag != null) { + if (typeof object.policyTag !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UpdatePolicyTagRequest.policyTag: object expected"); + message.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTag); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1.UpdatePolicyTagRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } - if (object.serializedTaxonomies != null) - message.serializedTaxonomies = Boolean(object.serializedTaxonomies); return message; }; /** - * Creates a plain object from an ExportTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from an UpdatePolicyTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static - * @param {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} message ExportTaxonomiesRequest + * @param {google.cloud.datacatalog.v1.UpdatePolicyTagRequest} message UpdatePolicyTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ExportTaxonomiesRequest.toObject = function toObject(message, options) { + UpdatePolicyTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (options.defaults) - object.parent = ""; - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = message.taxonomies[j]; - } - if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { - object.serializedTaxonomies = message.serializedTaxonomies; - if (options.oneofs) - object.destination = "serializedTaxonomies"; + if (options.defaults) { + object.policyTag = null; + object.updateMask = null; } + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + object.policyTag = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTag, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this ExportTaxonomiesRequest to JSON. + * Converts this UpdatePolicyTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @instance * @returns {Object.} JSON object */ - ExportTaxonomiesRequest.prototype.toJSON = function toJSON() { + UpdatePolicyTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ExportTaxonomiesRequest + * Gets the default type url for UpdatePolicyTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1.UpdatePolicyTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ExportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ExportTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.UpdatePolicyTagRequest"; }; - return ExportTaxonomiesRequest; + return UpdatePolicyTagRequest; })(); - v1.ExportTaxonomiesResponse = (function() { + v1.ListPolicyTagsRequest = (function() { /** - * Properties of an ExportTaxonomiesResponse. + * Properties of a ListPolicyTagsRequest. * @memberof google.cloud.datacatalog.v1 - * @interface IExportTaxonomiesResponse - * @property {Array.|null} [taxonomies] ExportTaxonomiesResponse taxonomies + * @interface IListPolicyTagsRequest + * @property {string|null} [parent] ListPolicyTagsRequest parent + * @property {number|null} [pageSize] ListPolicyTagsRequest pageSize + * @property {string|null} [pageToken] ListPolicyTagsRequest pageToken */ /** - * Constructs a new ExportTaxonomiesResponse. + * Constructs a new ListPolicyTagsRequest. * @memberof google.cloud.datacatalog.v1 - * @classdesc Represents an ExportTaxonomiesResponse. - * @implements IExportTaxonomiesResponse + * @classdesc Represents a ListPolicyTagsRequest. + * @implements IListPolicyTagsRequest * @constructor - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest=} [properties] Properties to set */ - function ExportTaxonomiesResponse(properties) { - this.taxonomies = []; + function ListPolicyTagsRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -29611,78 +31204,103 @@ } /** - * ExportTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * ListPolicyTagsRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @instance */ - ExportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + ListPolicyTagsRequest.prototype.parent = ""; /** - * Creates a new ExportTaxonomiesResponse instance using the specified properties. + * ListPolicyTagsRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @instance + */ + ListPolicyTagsRequest.prototype.pageSize = 0; + + /** + * ListPolicyTagsRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest + * @instance + */ + ListPolicyTagsRequest.prototype.pageToken = ""; + + /** + * Creates a new ListPolicyTagsRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest instance */ - ExportTaxonomiesResponse.create = function create(properties) { - return new ExportTaxonomiesResponse(properties); + ListPolicyTagsRequest.create = function create(properties) { + return new ListPolicyTagsRequest(properties); }; /** - * Encodes the specified ExportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified ListPolicyTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesResponse.encode = function encode(message, writer) { + ListPolicyTagsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); return writer; }; /** - * Encodes the specified ExportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified ListPolicyTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static - * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + ListPolicyTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer. + * Decodes a ListPolicyTagsRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesResponse.decode = function decode(reader, length) { + ListPolicyTagsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32())); + message.parent = reader.string(); + break; + } + case 2: { + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); break; } default: @@ -29694,1229 +31312,1188 @@ }; /** - * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a ListPolicyTagsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + ListPolicyTagsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ExportTaxonomiesResponse message. + * Verifies a ListPolicyTagsRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ExportTaxonomiesResponse.verify = function verify(message) { + ListPolicyTagsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; return null; }; /** - * Creates an ExportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a ListPolicyTagsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsRequest} ListPolicyTagsRequest */ - ExportTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse) + ListPolicyTagsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest) return object; - var message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.taxonomies[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); return message; }; /** - * Creates a plain object from an ExportTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a ListPolicyTagsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static - * @param {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} message ExportTaxonomiesResponse + * @param {google.cloud.datacatalog.v1.ListPolicyTagsRequest} message ListPolicyTagsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ExportTaxonomiesResponse.toObject = function toObject(message, options) { + ListPolicyTagsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.taxonomies[j], options); + if (options.defaults) { + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; return object; }; /** - * Converts this ExportTaxonomiesResponse to JSON. + * Converts this ListPolicyTagsRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @instance * @returns {Object.} JSON object */ - ExportTaxonomiesResponse.prototype.toJSON = function toJSON() { + ListPolicyTagsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ExportTaxonomiesResponse + * Gets the default type url for ListPolicyTagsRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ExportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListPolicyTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1.ExportTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListPolicyTagsRequest"; }; - return ExportTaxonomiesResponse; - })(); - - return v1; - })(); - - datacatalog.v1beta1 = (function() { - - /** - * Namespace v1beta1. - * @memberof google.cloud.datacatalog - * @namespace - */ - var v1beta1 = {}; - - /** - * IntegratedSystem enum. - * @name google.cloud.datacatalog.v1beta1.IntegratedSystem - * @enum {number} - * @property {number} INTEGRATED_SYSTEM_UNSPECIFIED=0 INTEGRATED_SYSTEM_UNSPECIFIED value - * @property {number} BIGQUERY=1 BIGQUERY value - * @property {number} CLOUD_PUBSUB=2 CLOUD_PUBSUB value - */ - v1beta1.IntegratedSystem = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "INTEGRATED_SYSTEM_UNSPECIFIED"] = 0; - values[valuesById[1] = "BIGQUERY"] = 1; - values[valuesById[2] = "CLOUD_PUBSUB"] = 2; - return values; + return ListPolicyTagsRequest; })(); - v1beta1.DataCatalog = (function() { - - /** - * Constructs a new DataCatalog service. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DataCatalog - * @extends $protobuf.rpc.Service - * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - */ - function DataCatalog(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); - } - - (DataCatalog.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = DataCatalog; + v1.ListPolicyTagsResponse = (function() { /** - * Creates new DataCatalog service using the specified rpc implementation. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {DataCatalog} RPC service. Useful where requests and/or responses are streamed. + * Properties of a ListPolicyTagsResponse. + * @memberof google.cloud.datacatalog.v1 + * @interface IListPolicyTagsResponse + * @property {Array.|null} [policyTags] ListPolicyTagsResponse policyTags + * @property {string|null} [nextPageToken] ListPolicyTagsResponse nextPageToken */ - DataCatalog.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); - }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|searchCatalog}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef SearchCatalogCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} [response] SearchCatalogResponse + * Constructs a new ListPolicyTagsResponse. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a ListPolicyTagsResponse. + * @implements IListPolicyTagsResponse + * @constructor + * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse=} [properties] Properties to set */ + function ListPolicyTagsResponse(properties) { + this.policyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Calls SearchCatalog. - * @function searchCatalog - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * ListPolicyTagsResponse policyTags. + * @member {Array.} policyTags + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse * @instance - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} request SearchCatalogRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalogCallback} callback Node-style callback called with the error, if any, and SearchCatalogResponse - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.searchCatalog = function searchCatalog(request, callback) { - return this.rpcCall(searchCatalog, $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest, $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse, request, callback); - }, "name", { value: "SearchCatalog" }); + ListPolicyTagsResponse.prototype.policyTags = $util.emptyArray; /** - * Calls SearchCatalog. - * @function searchCatalog - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * ListPolicyTagsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse * @instance - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} request SearchCatalogRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + ListPolicyTagsResponse.prototype.nextPageToken = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createEntryGroup}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef CreateEntryGroupCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup + * Creates a new ListPolicyTagsResponse instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse instance */ + ListPolicyTagsResponse.create = function create(properties) { + return new ListPolicyTagsResponse(properties); + }; /** - * Calls CreateEntryGroup. - * @function createEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} request CreateEntryGroupRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup - * @returns {undefined} - * @variation 1 + * Encodes the specified ListPolicyTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(DataCatalog.prototype.createEntryGroup = function createEntryGroup(request, callback) { - return this.rpcCall(createEntryGroup, $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); - }, "name", { value: "CreateEntryGroup" }); + ListPolicyTagsResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.policyTags != null && message.policyTags.length) + for (var i = 0; i < message.policyTags.length; ++i) + $root.google.cloud.datacatalog.v1.PolicyTag.encode(message.policyTags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + return writer; + }; /** - * Calls CreateEntryGroup. - * @function createEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} request CreateEntryGroupRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Encodes the specified ListPolicyTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ListPolicyTagsResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + ListPolicyTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateEntryGroup}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef UpdateEntryGroupCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup + * Decodes a ListPolicyTagsResponse message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + ListPolicyTagsResponse.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.policyTags && message.policyTags.length)) + message.policyTags = []; + message.policyTags.push($root.google.cloud.datacatalog.v1.PolicyTag.decode(reader, reader.uint32())); + break; + } + case 2: { + message.nextPageToken = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Calls UpdateEntryGroup. - * @function updateEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} request UpdateEntryGroupRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup - * @returns {undefined} - * @variation 1 + * Decodes a ListPolicyTagsResponse message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Object.defineProperty(DataCatalog.prototype.updateEntryGroup = function updateEntryGroup(request, callback) { - return this.rpcCall(updateEntryGroup, $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); - }, "name", { value: "UpdateEntryGroup" }); + ListPolicyTagsResponse.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls UpdateEntryGroup. - * @function updateEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} request UpdateEntryGroupRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Verifies a ListPolicyTagsResponse message. + * @function verify + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ + ListPolicyTagsResponse.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.policyTags != null && message.hasOwnProperty("policyTags")) { + if (!Array.isArray(message.policyTags)) + return "policyTags: array expected"; + for (var i = 0; i < message.policyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.PolicyTag.verify(message.policyTags[i]); + if (error) + return "policyTags." + error; + } + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; + return null; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getEntryGroup}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef GetEntryGroupCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup - */ + * Creates a ListPolicyTagsResponse message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.ListPolicyTagsResponse} ListPolicyTagsResponse + */ + ListPolicyTagsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse) + return object; + var message = new $root.google.cloud.datacatalog.v1.ListPolicyTagsResponse(); + if (object.policyTags) { + if (!Array.isArray(object.policyTags)) + throw TypeError(".google.cloud.datacatalog.v1.ListPolicyTagsResponse.policyTags: array expected"); + message.policyTags = []; + for (var i = 0; i < object.policyTags.length; ++i) { + if (typeof object.policyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ListPolicyTagsResponse.policyTags: object expected"); + message.policyTags[i] = $root.google.cloud.datacatalog.v1.PolicyTag.fromObject(object.policyTags[i]); + } + } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); + return message; + }; /** - * Calls GetEntryGroup. - * @function getEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} request GetEntryGroupRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup - * @returns {undefined} - * @variation 1 + * Creates a plain object from a ListPolicyTagsResponse message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1.ListPolicyTagsResponse} message ListPolicyTagsResponse + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - Object.defineProperty(DataCatalog.prototype.getEntryGroup = function getEntryGroup(request, callback) { - return this.rpcCall(getEntryGroup, $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); - }, "name", { value: "GetEntryGroup" }); + ListPolicyTagsResponse.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.policyTags = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.policyTags && message.policyTags.length) { + object.policyTags = []; + for (var j = 0; j < message.policyTags.length; ++j) + object.policyTags[j] = $root.google.cloud.datacatalog.v1.PolicyTag.toObject(message.policyTags[j], options); + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; + return object; + }; /** - * Calls GetEntryGroup. - * @function getEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Converts this ListPolicyTagsResponse to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} request GetEntryGroupRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * @returns {Object.} JSON object */ + ListPolicyTagsResponse.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteEntryGroup}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef DeleteEntryGroupCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Gets the default type url for ListPolicyTagsResponse + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.ListPolicyTagsResponse + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + ListPolicyTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ListPolicyTagsResponse"; + }; + + return ListPolicyTagsResponse; + })(); + + v1.GetPolicyTagRequest = (function() { /** - * Calls DeleteEntryGroup. - * @function deleteEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} request DeleteEntryGroupRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteEntryGroupCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * Properties of a GetPolicyTagRequest. + * @memberof google.cloud.datacatalog.v1 + * @interface IGetPolicyTagRequest + * @property {string|null} [name] GetPolicyTagRequest name */ - Object.defineProperty(DataCatalog.prototype.deleteEntryGroup = function deleteEntryGroup(request, callback) { - return this.rpcCall(deleteEntryGroup, $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteEntryGroup" }); /** - * Calls DeleteEntryGroup. - * @function deleteEntryGroup - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Constructs a new GetPolicyTagRequest. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a GetPolicyTagRequest. + * @implements IGetPolicyTagRequest + * @constructor + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest=} [properties] Properties to set + */ + function GetPolicyTagRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * GetPolicyTagRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} request DeleteEntryGroupRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + GetPolicyTagRequest.prototype.name = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listEntryGroups}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef ListEntryGroupsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} [response] ListEntryGroupsResponse + * Creates a new GetPolicyTagRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest instance */ + GetPolicyTagRequest.create = function create(properties) { + return new GetPolicyTagRequest(properties); + }; /** - * Calls ListEntryGroups. - * @function listEntryGroups - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} request ListEntryGroupsRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListEntryGroupsCallback} callback Node-style callback called with the error, if any, and ListEntryGroupsResponse - * @returns {undefined} - * @variation 1 + * Encodes the specified GetPolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.GetPolicyTagRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(DataCatalog.prototype.listEntryGroups = function listEntryGroups(request, callback) { - return this.rpcCall(listEntryGroups, $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest, $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse, request, callback); - }, "name", { value: "ListEntryGroups" }); + GetPolicyTagRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; /** - * Calls ListEntryGroups. - * @function listEntryGroups - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} request ListEntryGroupsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Encodes the specified GetPolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.GetPolicyTagRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + GetPolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createEntry}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef CreateEntryCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry + * Decodes a GetPolicyTagRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + GetPolicyTagRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.GetPolicyTagRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Calls CreateEntry. - * @function createEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} request CreateEntryRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateEntryCallback} callback Node-style callback called with the error, if any, and Entry - * @returns {undefined} - * @variation 1 + * Decodes a GetPolicyTagRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Object.defineProperty(DataCatalog.prototype.createEntry = function createEntry(request, callback) { - return this.rpcCall(createEntry, $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); - }, "name", { value: "CreateEntry" }); + GetPolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls CreateEntry. - * @function createEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} request CreateEntryRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Verifies a GetPolicyTagRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ + GetPolicyTagRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateEntry}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef UpdateEntryCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry + * Creates a GetPolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.GetPolicyTagRequest} GetPolicyTagRequest */ + GetPolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.GetPolicyTagRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1.GetPolicyTagRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; /** - * Calls UpdateEntry. - * @function updateEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} request UpdateEntryRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateEntryCallback} callback Node-style callback called with the error, if any, and Entry - * @returns {undefined} - * @variation 1 + * Creates a plain object from a GetPolicyTagRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1.GetPolicyTagRequest} message GetPolicyTagRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - Object.defineProperty(DataCatalog.prototype.updateEntry = function updateEntry(request, callback) { - return this.rpcCall(updateEntry, $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); - }, "name", { value: "UpdateEntry" }); + GetPolicyTagRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; /** - * Calls UpdateEntry. - * @function updateEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Converts this GetPolicyTagRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} request UpdateEntryRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * @returns {Object.} JSON object */ + GetPolicyTagRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteEntry}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef DeleteEntryCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Gets the default type url for GetPolicyTagRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.GetPolicyTagRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + GetPolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.GetPolicyTagRequest"; + }; + + return GetPolicyTagRequest; + })(); + + v1.PolicyTagManagerSerialization = (function() { /** - * Calls DeleteEntry. - * @function deleteEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} request DeleteEntryRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteEntryCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * Constructs a new PolicyTagManagerSerialization service. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a PolicyTagManagerSerialization + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited */ - Object.defineProperty(DataCatalog.prototype.deleteEntry = function deleteEntry(request, callback) { - return this.rpcCall(deleteEntry, $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteEntry" }); + function PolicyTagManagerSerialization(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } + + (PolicyTagManagerSerialization.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManagerSerialization; /** - * Calls DeleteEntry. - * @function deleteEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} request DeleteEntryRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates new PolicyTagManagerSerialization service using the specified rpc implementation. + * @function create + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization + * @static + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {PolicyTagManagerSerialization} RPC service. Useful where requests and/or responses are streamed. */ + PolicyTagManagerSerialization.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getEntry}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef GetEntryCallback + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|replaceTaxonomy}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization + * @typedef ReplaceTaxonomyCallback * @type {function} * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry + * @param {google.cloud.datacatalog.v1.Taxonomy} [response] Taxonomy */ /** - * Calls GetEntry. - * @function getEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ReplaceTaxonomy. + * @function replaceTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} request GetEntryRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} request ReplaceTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ReplaceTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy * @returns {undefined} * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.getEntry = function getEntry(request, callback) { - return this.rpcCall(getEntry, $root.google.cloud.datacatalog.v1beta1.GetEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); - }, "name", { value: "GetEntry" }); + Object.defineProperty(PolicyTagManagerSerialization.prototype.replaceTaxonomy = function replaceTaxonomy(request, callback) { + return this.rpcCall(replaceTaxonomy, $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest, $root.google.cloud.datacatalog.v1.Taxonomy, request, callback); + }, "name", { value: "ReplaceTaxonomy" }); /** - * Calls GetEntry. - * @function getEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ReplaceTaxonomy. + * @function replaceTaxonomy + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} request GetEntryRequest message or plain object - * @returns {Promise} Promise + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} request ReplaceTaxonomyRequest message or plain object + * @returns {Promise} Promise * @variation 2 */ /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|lookupEntry}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef LookupEntryCallback + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|importTaxonomies}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization + * @typedef ImportTaxonomiesCallback * @type {function} * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry + * @param {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} [response] ImportTaxonomiesResponse */ /** - * Calls LookupEntry. - * @function lookupEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ImportTaxonomies. + * @function importTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} request LookupEntryRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.LookupEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ImportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ImportTaxonomiesResponse * @returns {undefined} * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.lookupEntry = function lookupEntry(request, callback) { - return this.rpcCall(lookupEntry, $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); - }, "name", { value: "LookupEntry" }); + Object.defineProperty(PolicyTagManagerSerialization.prototype.importTaxonomies = function importTaxonomies(request, callback) { + return this.rpcCall(importTaxonomies, $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse, request, callback); + }, "name", { value: "ImportTaxonomies" }); /** - * Calls LookupEntry. - * @function lookupEntry - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ImportTaxonomies. + * @function importTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} request LookupEntryRequest message or plain object - * @returns {Promise} Promise + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object + * @returns {Promise} Promise * @variation 2 */ /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listEntries}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef ListEntriesCallback + * Callback as used by {@link google.cloud.datacatalog.v1.PolicyTagManagerSerialization|exportTaxonomies}. + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization + * @typedef ExportTaxonomiesCallback * @type {function} * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ListEntriesResponse} [response] ListEntriesResponse + * @param {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} [response] ExportTaxonomiesResponse */ /** - * Calls ListEntries. - * @function listEntries - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ExportTaxonomies. + * @function exportTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} request ListEntriesRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListEntriesCallback} callback Node-style callback called with the error, if any, and ListEntriesResponse + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1.PolicyTagManagerSerialization.ExportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ExportTaxonomiesResponse * @returns {undefined} * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.listEntries = function listEntries(request, callback) { - return this.rpcCall(listEntries, $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest, $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse, request, callback); - }, "name", { value: "ListEntries" }); + Object.defineProperty(PolicyTagManagerSerialization.prototype.exportTaxonomies = function exportTaxonomies(request, callback) { + return this.rpcCall(exportTaxonomies, $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest, $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse, request, callback); + }, "name", { value: "ExportTaxonomies" }); /** - * Calls ListEntries. - * @function listEntries - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Calls ExportTaxonomies. + * @function exportTaxonomies + * @memberof google.cloud.datacatalog.v1.PolicyTagManagerSerialization * @instance - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} request ListEntriesRequest message or plain object - * @returns {Promise} Promise + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object + * @returns {Promise} Promise * @variation 2 */ - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTagTemplate}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef CreateTagTemplateCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate - */ + return PolicyTagManagerSerialization; + })(); + + v1.SerializedTaxonomy = (function() { /** - * Calls CreateTagTemplate. - * @function createTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} request CreateTagTemplateRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.createTagTemplate = function createTagTemplate(request, callback) { - return this.rpcCall(createTagTemplate, $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); - }, "name", { value: "CreateTagTemplate" }); - - /** - * Calls CreateTagTemplate. - * @function createTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} request CreateTagTemplateRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Properties of a SerializedTaxonomy. + * @memberof google.cloud.datacatalog.v1 + * @interface ISerializedTaxonomy + * @property {string|null} [displayName] SerializedTaxonomy displayName + * @property {string|null} [description] SerializedTaxonomy description + * @property {Array.|null} [policyTags] SerializedTaxonomy policyTags + * @property {Array.|null} [activatedPolicyTypes] SerializedTaxonomy activatedPolicyTypes */ /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getTagTemplate}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef GetTagTemplateCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate + * Constructs a new SerializedTaxonomy. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a SerializedTaxonomy. + * @implements ISerializedTaxonomy + * @constructor + * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy=} [properties] Properties to set */ + function SerializedTaxonomy(properties) { + this.policyTags = []; + this.activatedPolicyTypes = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Calls GetTagTemplate. - * @function getTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedTaxonomy displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} request GetTagTemplateRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.getTagTemplate = function getTagTemplate(request, callback) { - return this.rpcCall(getTagTemplate, $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); - }, "name", { value: "GetTagTemplate" }); + SerializedTaxonomy.prototype.displayName = ""; /** - * Calls GetTagTemplate. - * @function getTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedTaxonomy description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} request GetTagTemplateRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + SerializedTaxonomy.prototype.description = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTagTemplate}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef UpdateTagTemplateCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate + * SerializedTaxonomy policyTags. + * @member {Array.} policyTags + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @instance */ + SerializedTaxonomy.prototype.policyTags = $util.emptyArray; /** - * Calls UpdateTagTemplate. - * @function updateTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedTaxonomy activatedPolicyTypes. + * @member {Array.} activatedPolicyTypes + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} request UpdateTagTemplateRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.updateTagTemplate = function updateTagTemplate(request, callback) { - return this.rpcCall(updateTagTemplate, $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); - }, "name", { value: "UpdateTagTemplate" }); + SerializedTaxonomy.prototype.activatedPolicyTypes = $util.emptyArray; /** - * Calls UpdateTagTemplate. - * @function updateTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} request UpdateTagTemplateRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates a new SerializedTaxonomy instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy instance */ + SerializedTaxonomy.create = function create(properties) { + return new SerializedTaxonomy(properties); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTagTemplate}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef DeleteTagTemplateCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Encodes the specified SerializedTaxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedTaxonomy.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + SerializedTaxonomy.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); + if (message.policyTags != null && message.policyTags.length) + for (var i = 0; i < message.policyTags.length; ++i) + $root.google.cloud.datacatalog.v1.SerializedPolicyTag.encode(message.policyTags[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { + writer.uint32(/* id 4, wireType 2 =*/34).fork(); + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + writer.int32(message.activatedPolicyTypes[i]); + writer.ldelim(); + } + return writer; + }; /** - * Calls DeleteTagTemplate. - * @function deleteTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} request DeleteTagTemplateRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplateCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * Encodes the specified SerializedTaxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedTaxonomy.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(DataCatalog.prototype.deleteTagTemplate = function deleteTagTemplate(request, callback) { - return this.rpcCall(deleteTagTemplate, $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteTagTemplate" }); + SerializedTaxonomy.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Calls DeleteTagTemplate. - * @function deleteTagTemplate - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} request DeleteTagTemplateRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Decodes a SerializedTaxonomy message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + SerializedTaxonomy.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SerializedTaxonomy(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + case 2: { + message.description = reader.string(); + break; + } + case 3: { + if (!(message.policyTags && message.policyTags.length)) + message.policyTags = []; + message.policyTags.push($root.google.cloud.datacatalog.v1.SerializedPolicyTag.decode(reader, reader.uint32())); + break; + } + case 4: { + if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) + message.activatedPolicyTypes = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.activatedPolicyTypes.push(reader.int32()); + } else + message.activatedPolicyTypes.push(reader.int32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTagTemplateField}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef CreateTagTemplateFieldCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField + * Decodes a SerializedTaxonomy message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + SerializedTaxonomy.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls CreateTagTemplateField. - * @function createTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} request CreateTagTemplateFieldRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField - * @returns {undefined} - * @variation 1 + * Verifies a SerializedTaxonomy message. + * @function verify + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Object.defineProperty(DataCatalog.prototype.createTagTemplateField = function createTagTemplateField(request, callback) { - return this.rpcCall(createTagTemplateField, $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); - }, "name", { value: "CreateTagTemplateField" }); + SerializedTaxonomy.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.policyTags != null && message.hasOwnProperty("policyTags")) { + if (!Array.isArray(message.policyTags)) + return "policyTags: array expected"; + for (var i = 0; i < message.policyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.verify(message.policyTags[i]); + if (error) + return "policyTags." + error; + } + } + if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { + if (!Array.isArray(message.activatedPolicyTypes)) + return "activatedPolicyTypes: array expected"; + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + switch (message.activatedPolicyTypes[i]) { + default: + return "activatedPolicyTypes: enum value[] expected"; + case 0: + case 1: + break; + } + } + return null; + }; /** - * Calls CreateTagTemplateField. - * @function createTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} request CreateTagTemplateFieldRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates a SerializedTaxonomy message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1.SerializedTaxonomy} SerializedTaxonomy */ + SerializedTaxonomy.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.SerializedTaxonomy) + return object; + var message = new $root.google.cloud.datacatalog.v1.SerializedTaxonomy(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.policyTags) { + if (!Array.isArray(object.policyTags)) + throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.policyTags: array expected"); + message.policyTags = []; + for (var i = 0; i < object.policyTags.length; ++i) { + if (typeof object.policyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.policyTags: object expected"); + message.policyTags[i] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.fromObject(object.policyTags[i]); + } + } + if (object.activatedPolicyTypes) { + if (!Array.isArray(object.activatedPolicyTypes)) + throw TypeError(".google.cloud.datacatalog.v1.SerializedTaxonomy.activatedPolicyTypes: array expected"); + message.activatedPolicyTypes = []; + for (var i = 0; i < object.activatedPolicyTypes.length; ++i) + switch (object.activatedPolicyTypes[i]) { + default: + if (typeof object.activatedPolicyTypes[i] === "number") { + message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; + break; + } + case "POLICY_TYPE_UNSPECIFIED": + case 0: + message.activatedPolicyTypes[i] = 0; + break; + case "FINE_GRAINED_ACCESS_CONTROL": + case 1: + message.activatedPolicyTypes[i] = 1; + break; + } + } + return message; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTagTemplateField}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef UpdateTagTemplateFieldCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField + * Creates a plain object from a SerializedTaxonomy message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1.SerializedTaxonomy} message SerializedTaxonomy + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ + SerializedTaxonomy.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.policyTags = []; + object.activatedPolicyTypes = []; + } + if (options.defaults) { + object.displayName = ""; + object.description = ""; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.policyTags && message.policyTags.length) { + object.policyTags = []; + for (var j = 0; j < message.policyTags.length; ++j) + object.policyTags[j] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.toObject(message.policyTags[j], options); + } + if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { + object.activatedPolicyTypes = []; + for (var j = 0; j < message.activatedPolicyTypes.length; ++j) + object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; + } + return object; + }; /** - * Calls UpdateTagTemplateField. - * @function updateTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * Converts this SerializedTaxonomy to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} request UpdateTagTemplateFieldRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField - * @returns {undefined} - * @variation 1 + * @returns {Object.} JSON object */ - Object.defineProperty(DataCatalog.prototype.updateTagTemplateField = function updateTagTemplateField(request, callback) { - return this.rpcCall(updateTagTemplateField, $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); - }, "name", { value: "UpdateTagTemplateField" }); + SerializedTaxonomy.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Calls UpdateTagTemplateField. - * @function updateTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} request UpdateTagTemplateFieldRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Gets the default type url for SerializedTaxonomy + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1.SerializedTaxonomy + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + SerializedTaxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1.SerializedTaxonomy"; + }; + + return SerializedTaxonomy; + })(); + + v1.SerializedPolicyTag = (function() { /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|renameTagTemplateField}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef RenameTagTemplateFieldCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField + * Properties of a SerializedPolicyTag. + * @memberof google.cloud.datacatalog.v1 + * @interface ISerializedPolicyTag + * @property {string|null} [policyTag] SerializedPolicyTag policyTag + * @property {string|null} [displayName] SerializedPolicyTag displayName + * @property {string|null} [description] SerializedPolicyTag description + * @property {Array.|null} [childPolicyTags] SerializedPolicyTag childPolicyTags */ /** - * Calls RenameTagTemplateField. - * @function renameTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} request RenameTagTemplateFieldRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.RenameTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField - * @returns {undefined} - * @variation 1 + * Constructs a new SerializedPolicyTag. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a SerializedPolicyTag. + * @implements ISerializedPolicyTag + * @constructor + * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag=} [properties] Properties to set */ - Object.defineProperty(DataCatalog.prototype.renameTagTemplateField = function renameTagTemplateField(request, callback) { - return this.rpcCall(renameTagTemplateField, $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); - }, "name", { value: "RenameTagTemplateField" }); + function SerializedPolicyTag(properties) { + this.childPolicyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Calls RenameTagTemplateField. - * @function renameTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedPolicyTag policyTag. + * @member {string} policyTag + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @instance - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} request RenameTagTemplateFieldRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + SerializedPolicyTag.prototype.policyTag = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTagTemplateField}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef DeleteTagTemplateFieldCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * SerializedPolicyTag displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag + * @instance */ + SerializedPolicyTag.prototype.displayName = ""; /** - * Calls DeleteTagTemplateField. - * @function deleteTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedPolicyTag description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} request DeleteTagTemplateFieldRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(DataCatalog.prototype.deleteTagTemplateField = function deleteTagTemplateField(request, callback) { - return this.rpcCall(deleteTagTemplateField, $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteTagTemplateField" }); + SerializedPolicyTag.prototype.description = ""; /** - * Calls DeleteTagTemplateField. - * @function deleteTagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * SerializedPolicyTag childPolicyTags. + * @member {Array.} childPolicyTags + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} request DeleteTagTemplateFieldRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + SerializedPolicyTag.prototype.childPolicyTags = $util.emptyArray; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTag}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef CreateTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Tag} [response] Tag - */ - - /** - * Calls CreateTag. - * @function createTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} request CreateTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagCallback} callback Node-style callback called with the error, if any, and Tag - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.createTag = function createTag(request, callback) { - return this.rpcCall(createTag, $root.google.cloud.datacatalog.v1beta1.CreateTagRequest, $root.google.cloud.datacatalog.v1beta1.Tag, request, callback); - }, "name", { value: "CreateTag" }); - - /** - * Calls CreateTag. - * @function createTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} request CreateTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTag}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef UpdateTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Tag} [response] Tag - */ - - /** - * Calls UpdateTag. - * @function updateTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} request UpdateTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagCallback} callback Node-style callback called with the error, if any, and Tag - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.updateTag = function updateTag(request, callback) { - return this.rpcCall(updateTag, $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest, $root.google.cloud.datacatalog.v1beta1.Tag, request, callback); - }, "name", { value: "UpdateTag" }); - - /** - * Calls UpdateTag. - * @function updateTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} request UpdateTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTag}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef DeleteTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty - */ - - /** - * Calls DeleteTag. - * @function deleteTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} request DeleteTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.deleteTag = function deleteTag(request, callback) { - return this.rpcCall(deleteTag, $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteTag" }); - - /** - * Calls DeleteTag. - * @function deleteTag - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} request DeleteTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listTags}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef ListTagsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ListTagsResponse} [response] ListTagsResponse - */ - - /** - * Calls ListTags. - * @function listTags - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} request ListTagsRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListTagsCallback} callback Node-style callback called with the error, if any, and ListTagsResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.listTags = function listTags(request, callback) { - return this.rpcCall(listTags, $root.google.cloud.datacatalog.v1beta1.ListTagsRequest, $root.google.cloud.datacatalog.v1beta1.ListTagsResponse, request, callback); - }, "name", { value: "ListTags" }); - - /** - * Calls ListTags. - * @function listTags - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} request ListTagsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|setIamPolicy}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef SetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy - */ - - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.setIamPolicy = function setIamPolicy(request, callback) { - return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "SetIamPolicy" }); - - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getIamPolicy}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef GetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy - */ - - /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.getIamPolicy = function getIamPolicy(request, callback) { - return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "GetIamPolicy" }); - - /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|testIamPermissions}. - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @typedef TestIamPermissionsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse - */ - - /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.DataCatalog.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(DataCatalog.prototype.testIamPermissions = function testIamPermissions(request, callback) { - return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); - }, "name", { value: "TestIamPermissions" }); - - /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1beta1.DataCatalog - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - return DataCatalog; - })(); - - v1beta1.SearchCatalogRequest = (function() { - - /** - * Properties of a SearchCatalogRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISearchCatalogRequest - * @property {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope|null} [scope] SearchCatalogRequest scope - * @property {string|null} [query] SearchCatalogRequest query - * @property {number|null} [pageSize] SearchCatalogRequest pageSize - * @property {string|null} [pageToken] SearchCatalogRequest pageToken - * @property {string|null} [orderBy] SearchCatalogRequest orderBy - */ - - /** - * Constructs a new SearchCatalogRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SearchCatalogRequest. - * @implements ISearchCatalogRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest=} [properties] Properties to set - */ - function SearchCatalogRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * SearchCatalogRequest scope. - * @member {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope|null|undefined} scope - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @instance - */ - SearchCatalogRequest.prototype.scope = null; - - /** - * SearchCatalogRequest query. - * @member {string} query - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @instance - */ - SearchCatalogRequest.prototype.query = ""; - - /** - * SearchCatalogRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @instance - */ - SearchCatalogRequest.prototype.pageSize = 0; - - /** - * SearchCatalogRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @instance - */ - SearchCatalogRequest.prototype.pageToken = ""; - - /** - * SearchCatalogRequest orderBy. - * @member {string} orderBy - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @instance - */ - SearchCatalogRequest.prototype.orderBy = ""; - - /** - * Creates a new SearchCatalogRequest instance using the specified properties. + * Creates a new SerializedPolicyTag instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest instance + * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag instance */ - SearchCatalogRequest.create = function create(properties) { - return new SearchCatalogRequest(properties); + SerializedPolicyTag.create = function create(properties) { + return new SerializedPolicyTag(properties); }; /** - * Encodes the specified SearchCatalogRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.verify|verify} messages. + * Encodes the specified SerializedPolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedPolicyTag.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} message SearchCatalogRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogRequest.encode = function encode(message, writer) { + SerializedPolicyTag.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.query != null && Object.hasOwnProperty.call(message, "query")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.query); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); - if (message.orderBy != null && Object.hasOwnProperty.call(message, "orderBy")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.orderBy); - if (message.scope != null && Object.hasOwnProperty.call(message, "scope")) - $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.encode(message.scope, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.policyTag); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.childPolicyTags != null && message.childPolicyTags.length) + for (var i = 0; i < message.childPolicyTags.length; ++i) + $root.google.cloud.datacatalog.v1.SerializedPolicyTag.encode(message.childPolicyTags[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified SearchCatalogRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.verify|verify} messages. + * Encodes the specified SerializedPolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.SerializedPolicyTag.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} message SearchCatalogRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogRequest.encodeDelimited = function encodeDelimited(message, writer) { + SerializedPolicyTag.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SearchCatalogRequest message from the specified reader or buffer. + * Decodes a SerializedPolicyTag message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest + * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogRequest.decode = function decode(reader, length) { + SerializedPolicyTag.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.SerializedPolicyTag(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 6: { - message.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.decode(reader, reader.uint32()); - break; - } case 1: { - message.query = reader.string(); + message.policyTag = reader.string(); break; } case 2: { - message.pageSize = reader.int32(); + message.displayName = reader.string(); break; } case 3: { - message.pageToken = reader.string(); + message.description = reader.string(); break; } - case 5: { - message.orderBy = reader.string(); + case 4: { + if (!(message.childPolicyTags && message.childPolicyTags.length)) + message.childPolicyTags = []; + message.childPolicyTags.push($root.google.cloud.datacatalog.v1.SerializedPolicyTag.decode(reader, reader.uint32())); break; } default: @@ -30928,445 +32505,166 @@ }; /** - * Decodes a SearchCatalogRequest message from the specified reader or buffer, length delimited. + * Decodes a SerializedPolicyTag message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest + * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogRequest.decodeDelimited = function decodeDelimited(reader) { + SerializedPolicyTag.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SearchCatalogRequest message. + * Verifies a SerializedPolicyTag message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SearchCatalogRequest.verify = function verify(message) { + SerializedPolicyTag.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.scope != null && message.hasOwnProperty("scope")) { - var error = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify(message.scope); - if (error) - return "scope." + error; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + if (!$util.isString(message.policyTag)) + return "policyTag: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { + if (!Array.isArray(message.childPolicyTags)) + return "childPolicyTags: array expected"; + for (var i = 0; i < message.childPolicyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.verify(message.childPolicyTags[i]); + if (error) + return "childPolicyTags." + error; + } } - if (message.query != null && message.hasOwnProperty("query")) - if (!$util.isString(message.query)) - return "query: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; - if (message.orderBy != null && message.hasOwnProperty("orderBy")) - if (!$util.isString(message.orderBy)) - return "orderBy: string expected"; return null; }; /** - * Creates a SearchCatalogRequest message from a plain object. Also converts values to their respective internal types. + * Creates a SerializedPolicyTag message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest + * @returns {google.cloud.datacatalog.v1.SerializedPolicyTag} SerializedPolicyTag */ - SearchCatalogRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest) + SerializedPolicyTag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.SerializedPolicyTag) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest(); - if (object.scope != null) { - if (typeof object.scope !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.scope: object expected"); - message.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.fromObject(object.scope); + var message = new $root.google.cloud.datacatalog.v1.SerializedPolicyTag(); + if (object.policyTag != null) + message.policyTag = String(object.policyTag); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.childPolicyTags) { + if (!Array.isArray(object.childPolicyTags)) + throw TypeError(".google.cloud.datacatalog.v1.SerializedPolicyTag.childPolicyTags: array expected"); + message.childPolicyTags = []; + for (var i = 0; i < object.childPolicyTags.length; ++i) { + if (typeof object.childPolicyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.SerializedPolicyTag.childPolicyTags: object expected"); + message.childPolicyTags[i] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.fromObject(object.childPolicyTags[i]); + } } - if (object.query != null) - message.query = String(object.query); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); - if (object.orderBy != null) - message.orderBy = String(object.orderBy); return message; }; /** - * Creates a plain object from a SearchCatalogRequest message. Also converts values to other types if specified. + * Creates a plain object from a SerializedPolicyTag message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} message SearchCatalogRequest + * @param {google.cloud.datacatalog.v1.SerializedPolicyTag} message SerializedPolicyTag * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SearchCatalogRequest.toObject = function toObject(message, options) { + SerializedPolicyTag.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.childPolicyTags = []; if (options.defaults) { - object.query = ""; - object.pageSize = 0; - object.pageToken = ""; - object.orderBy = ""; - object.scope = null; + object.policyTag = ""; + object.displayName = ""; + object.description = ""; + } + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + object.policyTag = message.policyTag; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.childPolicyTags && message.childPolicyTags.length) { + object.childPolicyTags = []; + for (var j = 0; j < message.childPolicyTags.length; ++j) + object.childPolicyTags[j] = $root.google.cloud.datacatalog.v1.SerializedPolicyTag.toObject(message.childPolicyTags[j], options); } - if (message.query != null && message.hasOwnProperty("query")) - object.query = message.query; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; - if (message.orderBy != null && message.hasOwnProperty("orderBy")) - object.orderBy = message.orderBy; - if (message.scope != null && message.hasOwnProperty("scope")) - object.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.toObject(message.scope, options); return object; }; /** - * Converts this SearchCatalogRequest to JSON. + * Converts this SerializedPolicyTag to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @instance * @returns {Object.} JSON object */ - SearchCatalogRequest.prototype.toJSON = function toJSON() { + SerializedPolicyTag.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SearchCatalogRequest + * Gets the default type url for SerializedPolicyTag * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @memberof google.cloud.datacatalog.v1.SerializedPolicyTag * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SearchCatalogRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SerializedPolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.SerializedPolicyTag"; }; - SearchCatalogRequest.Scope = (function() { + return SerializedPolicyTag; + })(); - /** - * Properties of a Scope. - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @interface IScope - * @property {Array.|null} [includeOrgIds] Scope includeOrgIds - * @property {Array.|null} [includeProjectIds] Scope includeProjectIds - * @property {boolean|null} [includeGcpPublicDatasets] Scope includeGcpPublicDatasets - */ - - /** - * Constructs a new Scope. - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest - * @classdesc Represents a Scope. - * @implements IScope - * @constructor - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope=} [properties] Properties to set - */ - function Scope(properties) { - this.includeOrgIds = []; - this.includeProjectIds = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * Scope includeOrgIds. - * @member {Array.} includeOrgIds - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @instance - */ - Scope.prototype.includeOrgIds = $util.emptyArray; - - /** - * Scope includeProjectIds. - * @member {Array.} includeProjectIds - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @instance - */ - Scope.prototype.includeProjectIds = $util.emptyArray; - - /** - * Scope includeGcpPublicDatasets. - * @member {boolean} includeGcpPublicDatasets - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @instance - */ - Scope.prototype.includeGcpPublicDatasets = false; - - /** - * Creates a new Scope instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope instance - */ - Scope.create = function create(properties) { - return new Scope(properties); - }; - - /** - * Encodes the specified Scope message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope} message Scope message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Scope.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.includeOrgIds != null && message.includeOrgIds.length) - for (var i = 0; i < message.includeOrgIds.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.includeOrgIds[i]); - if (message.includeProjectIds != null && message.includeProjectIds.length) - for (var i = 0; i < message.includeProjectIds.length; ++i) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.includeProjectIds[i]); - if (message.includeGcpPublicDatasets != null && Object.hasOwnProperty.call(message, "includeGcpPublicDatasets")) - writer.uint32(/* id 7, wireType 0 =*/56).bool(message.includeGcpPublicDatasets); - return writer; - }; - - /** - * Encodes the specified Scope message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope} message Scope message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Scope.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a Scope message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Scope.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 2: { - if (!(message.includeOrgIds && message.includeOrgIds.length)) - message.includeOrgIds = []; - message.includeOrgIds.push(reader.string()); - break; - } - case 3: { - if (!(message.includeProjectIds && message.includeProjectIds.length)) - message.includeProjectIds = []; - message.includeProjectIds.push(reader.string()); - break; - } - case 7: { - message.includeGcpPublicDatasets = reader.bool(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a Scope message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Scope.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a Scope message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Scope.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.includeOrgIds != null && message.hasOwnProperty("includeOrgIds")) { - if (!Array.isArray(message.includeOrgIds)) - return "includeOrgIds: array expected"; - for (var i = 0; i < message.includeOrgIds.length; ++i) - if (!$util.isString(message.includeOrgIds[i])) - return "includeOrgIds: string[] expected"; - } - if (message.includeProjectIds != null && message.hasOwnProperty("includeProjectIds")) { - if (!Array.isArray(message.includeProjectIds)) - return "includeProjectIds: array expected"; - for (var i = 0; i < message.includeProjectIds.length; ++i) - if (!$util.isString(message.includeProjectIds[i])) - return "includeProjectIds: string[] expected"; - } - if (message.includeGcpPublicDatasets != null && message.hasOwnProperty("includeGcpPublicDatasets")) - if (typeof message.includeGcpPublicDatasets !== "boolean") - return "includeGcpPublicDatasets: boolean expected"; - return null; - }; - - /** - * Creates a Scope message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope - */ - Scope.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope(); - if (object.includeOrgIds) { - if (!Array.isArray(object.includeOrgIds)) - throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.includeOrgIds: array expected"); - message.includeOrgIds = []; - for (var i = 0; i < object.includeOrgIds.length; ++i) - message.includeOrgIds[i] = String(object.includeOrgIds[i]); - } - if (object.includeProjectIds) { - if (!Array.isArray(object.includeProjectIds)) - throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.includeProjectIds: array expected"); - message.includeProjectIds = []; - for (var i = 0; i < object.includeProjectIds.length; ++i) - message.includeProjectIds[i] = String(object.includeProjectIds[i]); - } - if (object.includeGcpPublicDatasets != null) - message.includeGcpPublicDatasets = Boolean(object.includeGcpPublicDatasets); - return message; - }; - - /** - * Creates a plain object from a Scope message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} message Scope - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Scope.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.includeOrgIds = []; - object.includeProjectIds = []; - } - if (options.defaults) - object.includeGcpPublicDatasets = false; - if (message.includeOrgIds && message.includeOrgIds.length) { - object.includeOrgIds = []; - for (var j = 0; j < message.includeOrgIds.length; ++j) - object.includeOrgIds[j] = message.includeOrgIds[j]; - } - if (message.includeProjectIds && message.includeProjectIds.length) { - object.includeProjectIds = []; - for (var j = 0; j < message.includeProjectIds.length; ++j) - object.includeProjectIds[j] = message.includeProjectIds[j]; - } - if (message.includeGcpPublicDatasets != null && message.hasOwnProperty("includeGcpPublicDatasets")) - object.includeGcpPublicDatasets = message.includeGcpPublicDatasets; - return object; - }; - - /** - * Converts this Scope to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @instance - * @returns {Object.} JSON object - */ - Scope.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for Scope - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Scope.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope"; - }; - - return Scope; - })(); - - return SearchCatalogRequest; - })(); - - v1beta1.SearchCatalogResponse = (function() { + v1.ReplaceTaxonomyRequest = (function() { /** - * Properties of a SearchCatalogResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISearchCatalogResponse - * @property {Array.|null} [results] SearchCatalogResponse results - * @property {string|null} [nextPageToken] SearchCatalogResponse nextPageToken + * Properties of a ReplaceTaxonomyRequest. + * @memberof google.cloud.datacatalog.v1 + * @interface IReplaceTaxonomyRequest + * @property {string|null} [name] ReplaceTaxonomyRequest name + * @property {google.cloud.datacatalog.v1.ISerializedTaxonomy|null} [serializedTaxonomy] ReplaceTaxonomyRequest serializedTaxonomy */ /** - * Constructs a new SearchCatalogResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SearchCatalogResponse. - * @implements ISearchCatalogResponse + * Constructs a new ReplaceTaxonomyRequest. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a ReplaceTaxonomyRequest. + * @implements IReplaceTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest=} [properties] Properties to set */ - function SearchCatalogResponse(properties) { - this.results = []; + function ReplaceTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -31374,92 +32672,89 @@ } /** - * SearchCatalogResponse results. - * @member {Array.} results - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * ReplaceTaxonomyRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @instance */ - SearchCatalogResponse.prototype.results = $util.emptyArray; + ReplaceTaxonomyRequest.prototype.name = ""; /** - * SearchCatalogResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * ReplaceTaxonomyRequest serializedTaxonomy. + * @member {google.cloud.datacatalog.v1.ISerializedTaxonomy|null|undefined} serializedTaxonomy + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @instance */ - SearchCatalogResponse.prototype.nextPageToken = ""; + ReplaceTaxonomyRequest.prototype.serializedTaxonomy = null; /** - * Creates a new SearchCatalogResponse instance using the specified properties. + * Creates a new ReplaceTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse instance + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest instance */ - SearchCatalogResponse.create = function create(properties) { - return new SearchCatalogResponse(properties); + ReplaceTaxonomyRequest.create = function create(properties) { + return new ReplaceTaxonomyRequest(properties); }; /** - * Encodes the specified SearchCatalogResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResponse.verify|verify} messages. + * Encodes the specified ReplaceTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse} message SearchCatalogResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} message ReplaceTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogResponse.encode = function encode(message, writer) { + ReplaceTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.results != null && message.results.length) - for (var i = 0; i < message.results.length; ++i) - $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.encode(message.results[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.nextPageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.serializedTaxonomy != null && Object.hasOwnProperty.call(message, "serializedTaxonomy")) + $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.serializedTaxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified SearchCatalogResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResponse.verify|verify} messages. + * Encodes the specified ReplaceTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse} message SearchCatalogResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IReplaceTaxonomyRequest} message ReplaceTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogResponse.encodeDelimited = function encodeDelimited(message, writer) { + ReplaceTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SearchCatalogResponse message from the specified reader or buffer. + * Decodes a ReplaceTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse + * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogResponse.decode = function decode(reader, length) { + ReplaceTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.results && message.results.length)) - message.results = []; - message.results.push($root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.decode(reader, reader.uint32())); + message.name = reader.string(); break; } - case 3: { - message.nextPageToken = reader.string(); + case 2: { + message.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32()); break; } default: @@ -31471,150 +32766,138 @@ }; /** - * Decodes a SearchCatalogResponse message from the specified reader or buffer, length delimited. + * Decodes a ReplaceTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse + * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogResponse.decodeDelimited = function decodeDelimited(reader) { + ReplaceTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SearchCatalogResponse message. + * Verifies a ReplaceTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SearchCatalogResponse.verify = function verify(message) { + ReplaceTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.results != null && message.hasOwnProperty("results")) { - if (!Array.isArray(message.results)) - return "results: array expected"; - for (var i = 0; i < message.results.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify(message.results[i]); - if (error) - return "results." + error; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.serializedTaxonomy != null && message.hasOwnProperty("serializedTaxonomy")) { + var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.serializedTaxonomy); + if (error) + return "serializedTaxonomy." + error; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; return null; }; /** - * Creates a SearchCatalogResponse message from a plain object. Also converts values to their respective internal types. + * Creates a ReplaceTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse + * @returns {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} ReplaceTaxonomyRequest */ - SearchCatalogResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse) + ReplaceTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse(); - if (object.results) { - if (!Array.isArray(object.results)) - throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogResponse.results: array expected"); - message.results = []; - for (var i = 0; i < object.results.length; ++i) { - if (typeof object.results[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogResponse.results: object expected"); - message.results[i] = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.fromObject(object.results[i]); - } + var message = new $root.google.cloud.datacatalog.v1.ReplaceTaxonomyRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.serializedTaxonomy != null) { + if (typeof object.serializedTaxonomy !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ReplaceTaxonomyRequest.serializedTaxonomy: object expected"); + message.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.serializedTaxonomy); } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a SearchCatalogResponse message. Also converts values to other types if specified. + * Creates a plain object from a ReplaceTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} message SearchCatalogResponse + * @param {google.cloud.datacatalog.v1.ReplaceTaxonomyRequest} message ReplaceTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SearchCatalogResponse.toObject = function toObject(message, options) { + ReplaceTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.results = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.results && message.results.length) { - object.results = []; - for (var j = 0; j < message.results.length; ++j) - object.results[j] = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.toObject(message.results[j], options); + if (options.defaults) { + object.name = ""; + object.serializedTaxonomy = null; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.serializedTaxonomy != null && message.hasOwnProperty("serializedTaxonomy")) + object.serializedTaxonomy = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.serializedTaxonomy, options); return object; }; /** - * Converts this SearchCatalogResponse to JSON. + * Converts this ReplaceTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @instance * @returns {Object.} JSON object */ - SearchCatalogResponse.prototype.toJSON = function toJSON() { + ReplaceTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SearchCatalogResponse + * Gets the default type url for ReplaceTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @memberof google.cloud.datacatalog.v1.ReplaceTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SearchCatalogResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ReplaceTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ReplaceTaxonomyRequest"; }; - return SearchCatalogResponse; + return ReplaceTaxonomyRequest; })(); - v1beta1.CreateEntryGroupRequest = (function() { + v1.ImportTaxonomiesRequest = (function() { /** - * Properties of a CreateEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateEntryGroupRequest - * @property {string|null} [parent] CreateEntryGroupRequest parent - * @property {string|null} [entryGroupId] CreateEntryGroupRequest entryGroupId - * @property {google.cloud.datacatalog.v1beta1.IEntryGroup|null} [entryGroup] CreateEntryGroupRequest entryGroup + * Properties of an ImportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1 + * @interface IImportTaxonomiesRequest + * @property {string|null} [parent] ImportTaxonomiesRequest parent + * @property {google.cloud.datacatalog.v1.IInlineSource|null} [inlineSource] ImportTaxonomiesRequest inlineSource + * @property {google.cloud.datacatalog.v1.ICrossRegionalSource|null} [crossRegionalSource] ImportTaxonomiesRequest crossRegionalSource */ /** - * Constructs a new CreateEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateEntryGroupRequest. - * @implements ICreateEntryGroupRequest + * Constructs a new ImportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents an ImportTaxonomiesRequest. + * @implements IImportTaxonomiesRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest=} [properties] Properties to set */ - function CreateEntryGroupRequest(properties) { + function ImportTaxonomiesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -31622,90 +32905,104 @@ } /** - * CreateEntryGroupRequest parent. + * ImportTaxonomiesRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @instance */ - CreateEntryGroupRequest.prototype.parent = ""; + ImportTaxonomiesRequest.prototype.parent = ""; /** - * CreateEntryGroupRequest entryGroupId. - * @member {string} entryGroupId - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * ImportTaxonomiesRequest inlineSource. + * @member {google.cloud.datacatalog.v1.IInlineSource|null|undefined} inlineSource + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @instance */ - CreateEntryGroupRequest.prototype.entryGroupId = ""; + ImportTaxonomiesRequest.prototype.inlineSource = null; /** - * CreateEntryGroupRequest entryGroup. - * @member {google.cloud.datacatalog.v1beta1.IEntryGroup|null|undefined} entryGroup - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * ImportTaxonomiesRequest crossRegionalSource. + * @member {google.cloud.datacatalog.v1.ICrossRegionalSource|null|undefined} crossRegionalSource + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @instance */ - CreateEntryGroupRequest.prototype.entryGroup = null; + ImportTaxonomiesRequest.prototype.crossRegionalSource = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Creates a new CreateEntryGroupRequest instance using the specified properties. + * ImportTaxonomiesRequest source. + * @member {"inlineSource"|"crossRegionalSource"|undefined} source + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest + * @instance + */ + Object.defineProperty(ImportTaxonomiesRequest.prototype, "source", { + get: $util.oneOfGetter($oneOfFields = ["inlineSource", "crossRegionalSource"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ImportTaxonomiesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest instance + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest instance */ - CreateEntryGroupRequest.create = function create(properties) { - return new CreateEntryGroupRequest(properties); + ImportTaxonomiesRequest.create = function create(properties) { + return new ImportTaxonomiesRequest(properties); }; /** - * Encodes the specified CreateEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.verify|verify} messages. + * Encodes the specified ImportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} message CreateEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateEntryGroupRequest.encode = function encode(message, writer) { + ImportTaxonomiesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.entryGroup != null && Object.hasOwnProperty.call(message, "entryGroup")) - $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroup, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.entryGroupId != null && Object.hasOwnProperty.call(message, "entryGroupId")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.entryGroupId); + if (message.inlineSource != null && Object.hasOwnProperty.call(message, "inlineSource")) + $root.google.cloud.datacatalog.v1.InlineSource.encode(message.inlineSource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.crossRegionalSource != null && Object.hasOwnProperty.call(message, "crossRegionalSource")) + $root.google.cloud.datacatalog.v1.CrossRegionalSource.encode(message.crossRegionalSource, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified CreateEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.verify|verify} messages. + * Encodes the specified ImportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} message CreateEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { + ImportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateEntryGroupRequest message from the specified reader or buffer. + * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateEntryGroupRequest.decode = function decode(reader, length) { + ImportTaxonomiesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -31713,12 +33010,12 @@ message.parent = reader.string(); break; } - case 3: { - message.entryGroupId = reader.string(); + case 2: { + message.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.decode(reader, reader.uint32()); break; } - case 2: { - message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32()); + case 3: { + message.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.decode(reader, reader.uint32()); break; } default: @@ -31730,145 +33027,162 @@ }; /** - * Decodes a CreateEntryGroupRequest message from the specified reader or buffer, length delimited. + * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { + ImportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateEntryGroupRequest message. + * Verifies an ImportTaxonomiesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateEntryGroupRequest.verify = function verify(message) { + ImportTaxonomiesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + var properties = {}; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.entryGroupId != null && message.hasOwnProperty("entryGroupId")) - if (!$util.isString(message.entryGroupId)) - return "entryGroupId: string expected"; - if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) { - var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroup); - if (error) - return "entryGroup." + error; + if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { + properties.source = 1; + { + var error = $root.google.cloud.datacatalog.v1.InlineSource.verify(message.inlineSource); + if (error) + return "inlineSource." + error; + } + } + if (message.crossRegionalSource != null && message.hasOwnProperty("crossRegionalSource")) { + if (properties.source === 1) + return "source: multiple values"; + properties.source = 1; + { + var error = $root.google.cloud.datacatalog.v1.CrossRegionalSource.verify(message.crossRegionalSource); + if (error) + return "crossRegionalSource." + error; + } } return null; }; /** - * Creates a CreateEntryGroupRequest message from a plain object. Also converts values to their respective internal types. + * Creates an ImportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} ImportTaxonomiesRequest */ - CreateEntryGroupRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest) + ImportTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest(); + var message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.entryGroupId != null) - message.entryGroupId = String(object.entryGroupId); - if (object.entryGroup != null) { - if (typeof object.entryGroup !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.entryGroup: object expected"); - message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroup); + if (object.inlineSource != null) { + if (typeof object.inlineSource !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesRequest.inlineSource: object expected"); + message.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.fromObject(object.inlineSource); + } + if (object.crossRegionalSource != null) { + if (typeof object.crossRegionalSource !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesRequest.crossRegionalSource: object expected"); + message.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.fromObject(object.crossRegionalSource); } return message; }; /** - * Creates a plain object from a CreateEntryGroupRequest message. Also converts values to other types if specified. + * Creates a plain object from an ImportTaxonomiesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} message CreateEntryGroupRequest + * @param {google.cloud.datacatalog.v1.ImportTaxonomiesRequest} message ImportTaxonomiesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreateEntryGroupRequest.toObject = function toObject(message, options) { + ImportTaxonomiesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { + if (options.defaults) object.parent = ""; - object.entryGroup = null; - object.entryGroupId = ""; - } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) - object.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroup, options); - if (message.entryGroupId != null && message.hasOwnProperty("entryGroupId")) - object.entryGroupId = message.entryGroupId; + if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { + object.inlineSource = $root.google.cloud.datacatalog.v1.InlineSource.toObject(message.inlineSource, options); + if (options.oneofs) + object.source = "inlineSource"; + } + if (message.crossRegionalSource != null && message.hasOwnProperty("crossRegionalSource")) { + object.crossRegionalSource = $root.google.cloud.datacatalog.v1.CrossRegionalSource.toObject(message.crossRegionalSource, options); + if (options.oneofs) + object.source = "crossRegionalSource"; + } return object; }; /** - * Converts this CreateEntryGroupRequest to JSON. + * Converts this ImportTaxonomiesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @instance * @returns {Object.} JSON object */ - CreateEntryGroupRequest.prototype.toJSON = function toJSON() { + ImportTaxonomiesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreateEntryGroupRequest + * Gets the default type url for ImportTaxonomiesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreateEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ImportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportTaxonomiesRequest"; }; - return CreateEntryGroupRequest; + return ImportTaxonomiesRequest; })(); - v1beta1.UpdateEntryGroupRequest = (function() { + v1.InlineSource = (function() { /** - * Properties of an UpdateEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateEntryGroupRequest - * @property {google.cloud.datacatalog.v1beta1.IEntryGroup|null} [entryGroup] UpdateEntryGroupRequest entryGroup - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateEntryGroupRequest updateMask + * Properties of an InlineSource. + * @memberof google.cloud.datacatalog.v1 + * @interface IInlineSource + * @property {Array.|null} [taxonomies] InlineSource taxonomies */ /** - * Constructs a new UpdateEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateEntryGroupRequest. - * @implements IUpdateEntryGroupRequest + * Constructs a new InlineSource. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents an InlineSource. + * @implements IInlineSource * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IInlineSource=} [properties] Properties to set */ - function UpdateEntryGroupRequest(properties) { + function InlineSource(properties) { + this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -31876,89 +33190,78 @@ } /** - * UpdateEntryGroupRequest entryGroup. - * @member {google.cloud.datacatalog.v1beta1.IEntryGroup|null|undefined} entryGroup - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest - * @instance - */ - UpdateEntryGroupRequest.prototype.entryGroup = null; - - /** - * UpdateEntryGroupRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * InlineSource taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1.InlineSource * @instance */ - UpdateEntryGroupRequest.prototype.updateMask = null; + InlineSource.prototype.taxonomies = $util.emptyArray; /** - * Creates a new UpdateEntryGroupRequest instance using the specified properties. + * Creates a new InlineSource instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest instance + * @param {google.cloud.datacatalog.v1.IInlineSource=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource instance */ - UpdateEntryGroupRequest.create = function create(properties) { - return new UpdateEntryGroupRequest(properties); + InlineSource.create = function create(properties) { + return new InlineSource(properties); }; /** - * Encodes the specified UpdateEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.verify|verify} messages. + * Encodes the specified InlineSource message. Does not implicitly {@link google.cloud.datacatalog.v1.InlineSource.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} message UpdateEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IInlineSource} message InlineSource message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateEntryGroupRequest.encode = function encode(message, writer) { + InlineSource.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.entryGroup != null && Object.hasOwnProperty.call(message, "entryGroup")) - $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroup, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified UpdateEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.verify|verify} messages. + * Encodes the specified InlineSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.InlineSource.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} message UpdateEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IInlineSource} message InlineSource message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { + InlineSource.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateEntryGroupRequest message from the specified reader or buffer. + * Decodes an InlineSource message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateEntryGroupRequest.decode = function decode(reader, length) { + InlineSource.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.InlineSource(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32()); - break; - } - case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32())); break; } default: @@ -31970,142 +33273,139 @@ }; /** - * Decodes an UpdateEntryGroupRequest message from the specified reader or buffer, length delimited. + * Decodes an InlineSource message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { + InlineSource.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateEntryGroupRequest message. + * Verifies an InlineSource message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateEntryGroupRequest.verify = function verify(message) { + InlineSource.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) { - var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroup); - if (error) - return "entryGroup." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } } return null; }; /** - * Creates an UpdateEntryGroupRequest message from a plain object. Also converts values to their respective internal types. + * Creates an InlineSource message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.InlineSource} InlineSource */ - UpdateEntryGroupRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest) + InlineSource.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.InlineSource) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest(); - if (object.entryGroup != null) { - if (typeof object.entryGroup !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.entryGroup: object expected"); - message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroup); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + var message = new $root.google.cloud.datacatalog.v1.InlineSource(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1.InlineSource.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.InlineSource.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.taxonomies[i]); + } } return message; }; /** - * Creates a plain object from an UpdateEntryGroupRequest message. Also converts values to other types if specified. + * Creates a plain object from an InlineSource message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} message UpdateEntryGroupRequest + * @param {google.cloud.datacatalog.v1.InlineSource} message InlineSource * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateEntryGroupRequest.toObject = function toObject(message, options) { + InlineSource.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.entryGroup = null; - object.updateMask = null; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.taxonomies[j], options); } - if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) - object.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroup, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this UpdateEntryGroupRequest to JSON. + * Converts this InlineSource to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @instance * @returns {Object.} JSON object */ - UpdateEntryGroupRequest.prototype.toJSON = function toJSON() { + InlineSource.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateEntryGroupRequest + * Gets the default type url for InlineSource * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.InlineSource * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + InlineSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.InlineSource"; }; - return UpdateEntryGroupRequest; + return InlineSource; })(); - v1beta1.GetEntryGroupRequest = (function() { + v1.CrossRegionalSource = (function() { /** - * Properties of a GetEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGetEntryGroupRequest - * @property {string|null} [name] GetEntryGroupRequest name - * @property {google.protobuf.IFieldMask|null} [readMask] GetEntryGroupRequest readMask + * Properties of a CrossRegionalSource. + * @memberof google.cloud.datacatalog.v1 + * @interface ICrossRegionalSource + * @property {string|null} [taxonomy] CrossRegionalSource taxonomy */ /** - * Constructs a new GetEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GetEntryGroupRequest. - * @implements IGetEntryGroupRequest + * Constructs a new CrossRegionalSource. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents a CrossRegionalSource. + * @implements ICrossRegionalSource * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.ICrossRegionalSource=} [properties] Properties to set */ - function GetEntryGroupRequest(properties) { + function CrossRegionalSource(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -32113,89 +33413,75 @@ } /** - * GetEntryGroupRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest - * @instance - */ - GetEntryGroupRequest.prototype.name = ""; - - /** - * GetEntryGroupRequest readMask. - * @member {google.protobuf.IFieldMask|null|undefined} readMask - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * CrossRegionalSource taxonomy. + * @member {string} taxonomy + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @instance */ - GetEntryGroupRequest.prototype.readMask = null; + CrossRegionalSource.prototype.taxonomy = ""; /** - * Creates a new GetEntryGroupRequest instance using the specified properties. + * Creates a new CrossRegionalSource instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest instance + * @param {google.cloud.datacatalog.v1.ICrossRegionalSource=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource instance */ - GetEntryGroupRequest.create = function create(properties) { - return new GetEntryGroupRequest(properties); + CrossRegionalSource.create = function create(properties) { + return new CrossRegionalSource(properties); }; /** - * Encodes the specified GetEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.verify|verify} messages. + * Encodes the specified CrossRegionalSource message. Does not implicitly {@link google.cloud.datacatalog.v1.CrossRegionalSource.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} message GetEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICrossRegionalSource} message CrossRegionalSource message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetEntryGroupRequest.encode = function encode(message, writer) { + CrossRegionalSource.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) - $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.taxonomy); return writer; }; /** - * Encodes the specified GetEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.verify|verify} messages. + * Encodes the specified CrossRegionalSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.CrossRegionalSource.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} message GetEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.ICrossRegionalSource} message CrossRegionalSource message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { + CrossRegionalSource.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetEntryGroupRequest message from the specified reader or buffer. + * Decodes a CrossRegionalSource message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetEntryGroupRequest.decode = function decode(reader, length) { + CrossRegionalSource.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.CrossRegionalSource(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + message.taxonomy = reader.string(); break; } default: @@ -32207,137 +33493,123 @@ }; /** - * Decodes a GetEntryGroupRequest message from the specified reader or buffer, length delimited. + * Decodes a CrossRegionalSource message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { + CrossRegionalSource.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetEntryGroupRequest message. + * Verifies a CrossRegionalSource message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetEntryGroupRequest.verify = function verify(message) { + CrossRegionalSource.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.readMask != null && message.hasOwnProperty("readMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.readMask); - if (error) - return "readMask." + error; - } + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + if (!$util.isString(message.taxonomy)) + return "taxonomy: string expected"; return null; }; /** - * Creates a GetEntryGroupRequest message from a plain object. Also converts values to their respective internal types. + * Creates a CrossRegionalSource message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.CrossRegionalSource} CrossRegionalSource */ - GetEntryGroupRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest) + CrossRegionalSource.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.CrossRegionalSource) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest(); - if (object.name != null) - message.name = String(object.name); - if (object.readMask != null) { - if (typeof object.readMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.readMask: object expected"); - message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); - } + var message = new $root.google.cloud.datacatalog.v1.CrossRegionalSource(); + if (object.taxonomy != null) + message.taxonomy = String(object.taxonomy); return message; }; /** - * Creates a plain object from a GetEntryGroupRequest message. Also converts values to other types if specified. + * Creates a plain object from a CrossRegionalSource message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static - * @param {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} message GetEntryGroupRequest + * @param {google.cloud.datacatalog.v1.CrossRegionalSource} message CrossRegionalSource * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetEntryGroupRequest.toObject = function toObject(message, options) { + CrossRegionalSource.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.readMask = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.readMask != null && message.hasOwnProperty("readMask")) - object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); + if (options.defaults) + object.taxonomy = ""; + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + object.taxonomy = message.taxonomy; return object; }; /** - * Converts this GetEntryGroupRequest to JSON. + * Converts this CrossRegionalSource to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @instance * @returns {Object.} JSON object */ - GetEntryGroupRequest.prototype.toJSON = function toJSON() { + CrossRegionalSource.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetEntryGroupRequest + * Gets the default type url for CrossRegionalSource * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.CrossRegionalSource * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CrossRegionalSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetEntryGroupRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.CrossRegionalSource"; }; - return GetEntryGroupRequest; + return CrossRegionalSource; })(); - v1beta1.DeleteEntryGroupRequest = (function() { + v1.ImportTaxonomiesResponse = (function() { /** - * Properties of a DeleteEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteEntryGroupRequest - * @property {string|null} [name] DeleteEntryGroupRequest name - * @property {boolean|null} [force] DeleteEntryGroupRequest force + * Properties of an ImportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1 + * @interface IImportTaxonomiesResponse + * @property {Array.|null} [taxonomies] ImportTaxonomiesResponse taxonomies */ /** - * Constructs a new DeleteEntryGroupRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteEntryGroupRequest. - * @implements IDeleteEntryGroupRequest + * Constructs a new ImportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents an ImportTaxonomiesResponse. + * @implements IImportTaxonomiesResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse=} [properties] Properties to set */ - function DeleteEntryGroupRequest(properties) { + function ImportTaxonomiesResponse(properties) { + this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -32345,89 +33617,78 @@ } /** - * DeleteEntryGroupRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest - * @instance - */ - DeleteEntryGroupRequest.prototype.name = ""; - - /** - * DeleteEntryGroupRequest force. - * @member {boolean} force - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * ImportTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @instance */ - DeleteEntryGroupRequest.prototype.force = false; + ImportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; /** - * Creates a new DeleteEntryGroupRequest instance using the specified properties. + * Creates a new ImportTaxonomiesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest instance + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse instance */ - DeleteEntryGroupRequest.create = function create(properties) { - return new DeleteEntryGroupRequest(properties); + ImportTaxonomiesResponse.create = function create(properties) { + return new ImportTaxonomiesResponse(properties); }; /** - * Encodes the specified DeleteEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest.verify|verify} messages. + * Encodes the specified ImportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} message DeleteEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteEntryGroupRequest.encode = function encode(message, writer) { + ImportTaxonomiesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.force != null && Object.hasOwnProperty.call(message, "force")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.force); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified DeleteEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest.verify|verify} messages. + * Encodes the specified ImportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ImportTaxonomiesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} message DeleteEntryGroupRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { + ImportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteEntryGroupRequest message from the specified reader or buffer. + * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteEntryGroupRequest.decode = function decode(reader, length) { + ImportTaxonomiesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.force = reader.bool(); + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1.Taxonomy.decode(reader, reader.uint32())); break; } default: @@ -32439,133 +33700,142 @@ }; /** - * Decodes a DeleteEntryGroupRequest message from the specified reader or buffer, length delimited. + * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { + ImportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteEntryGroupRequest message. + * Verifies an ImportTaxonomiesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteEntryGroupRequest.verify = function verify(message) { + ImportTaxonomiesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.force != null && message.hasOwnProperty("force")) - if (typeof message.force !== "boolean") - return "force: boolean expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.Taxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } + } return null; }; /** - * Creates a DeleteEntryGroupRequest message from a plain object. Also converts values to their respective internal types. + * Creates an ImportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest + * @returns {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} ImportTaxonomiesResponse */ - DeleteEntryGroupRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest) + ImportTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest(); - if (object.name != null) - message.name = String(object.name); - if (object.force != null) - message.force = Boolean(object.force); + var message = new $root.google.cloud.datacatalog.v1.ImportTaxonomiesResponse(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesResponse.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ImportTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1.Taxonomy.fromObject(object.taxonomies[i]); + } + } return message; }; /** - * Creates a plain object from a DeleteEntryGroupRequest message. Also converts values to other types if specified. + * Creates a plain object from an ImportTaxonomiesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} message DeleteEntryGroupRequest + * @param {google.cloud.datacatalog.v1.ImportTaxonomiesResponse} message ImportTaxonomiesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteEntryGroupRequest.toObject = function toObject(message, options) { + ImportTaxonomiesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.force = false; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1.Taxonomy.toObject(message.taxonomies[j], options); } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.force != null && message.hasOwnProperty("force")) - object.force = message.force; return object; }; /** - * Converts this DeleteEntryGroupRequest to JSON. + * Converts this ImportTaxonomiesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @instance * @returns {Object.} JSON object */ - DeleteEntryGroupRequest.prototype.toJSON = function toJSON() { + ImportTaxonomiesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteEntryGroupRequest + * Gets the default type url for ImportTaxonomiesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest + * @memberof google.cloud.datacatalog.v1.ImportTaxonomiesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ImportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ImportTaxonomiesResponse"; }; - return DeleteEntryGroupRequest; + return ImportTaxonomiesResponse; })(); - v1beta1.ListEntryGroupsRequest = (function() { + v1.ExportTaxonomiesRequest = (function() { /** - * Properties of a ListEntryGroupsRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListEntryGroupsRequest - * @property {string|null} [parent] ListEntryGroupsRequest parent - * @property {number|null} [pageSize] ListEntryGroupsRequest pageSize - * @property {string|null} [pageToken] ListEntryGroupsRequest pageToken + * Properties of an ExportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1 + * @interface IExportTaxonomiesRequest + * @property {string|null} [parent] ExportTaxonomiesRequest parent + * @property {Array.|null} [taxonomies] ExportTaxonomiesRequest taxonomies + * @property {boolean|null} [serializedTaxonomies] ExportTaxonomiesRequest serializedTaxonomies */ /** - * Constructs a new ListEntryGroupsRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListEntryGroupsRequest. - * @implements IListEntryGroupsRequest + * Constructs a new ExportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents an ExportTaxonomiesRequest. + * @implements IExportTaxonomiesRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest=} [properties] Properties to set */ - function ListEntryGroupsRequest(properties) { + function ExportTaxonomiesRequest(properties) { + this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -32573,90 +33843,105 @@ } /** - * ListEntryGroupsRequest parent. + * ExportTaxonomiesRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @instance */ - ListEntryGroupsRequest.prototype.parent = ""; + ExportTaxonomiesRequest.prototype.parent = ""; /** - * ListEntryGroupsRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * ExportTaxonomiesRequest taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @instance */ - ListEntryGroupsRequest.prototype.pageSize = 0; + ExportTaxonomiesRequest.prototype.taxonomies = $util.emptyArray; /** - * ListEntryGroupsRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * ExportTaxonomiesRequest serializedTaxonomies. + * @member {boolean|null|undefined} serializedTaxonomies + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @instance */ - ListEntryGroupsRequest.prototype.pageToken = ""; + ExportTaxonomiesRequest.prototype.serializedTaxonomies = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Creates a new ListEntryGroupsRequest instance using the specified properties. + * ExportTaxonomiesRequest destination. + * @member {"serializedTaxonomies"|undefined} destination + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest + * @instance + */ + Object.defineProperty(ExportTaxonomiesRequest.prototype, "destination", { + get: $util.oneOfGetter($oneOfFields = ["serializedTaxonomies"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ExportTaxonomiesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest instance + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest instance */ - ListEntryGroupsRequest.create = function create(properties) { - return new ListEntryGroupsRequest(properties); + ExportTaxonomiesRequest.create = function create(properties) { + return new ExportTaxonomiesRequest(properties); }; /** - * Encodes the specified ListEntryGroupsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest.verify|verify} messages. + * Encodes the specified ExportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} message ListEntryGroupsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntryGroupsRequest.encode = function encode(message, writer) { + ExportTaxonomiesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.taxonomies[i]); + if (message.serializedTaxonomies != null && Object.hasOwnProperty.call(message, "serializedTaxonomies")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.serializedTaxonomies); return writer; }; /** - * Encodes the specified ListEntryGroupsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest.verify|verify} messages. + * Encodes the specified ExportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} message ListEntryGroupsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntryGroupsRequest.encodeDelimited = function encodeDelimited(message, writer) { + ExportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntryGroupsRequest message from the specified reader or buffer. + * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntryGroupsRequest.decode = function decode(reader, length) { + ExportTaxonomiesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -32665,11 +33950,13 @@ break; } case 2: { - message.pageSize = reader.int32(); + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push(reader.string()); break; } case 3: { - message.pageToken = reader.string(); + message.serializedTaxonomies = reader.bool(); break; } default: @@ -32681,141 +33968,157 @@ }; /** - * Decodes a ListEntryGroupsRequest message from the specified reader or buffer, length delimited. + * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntryGroupsRequest.decodeDelimited = function decodeDelimited(reader) { + ExportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntryGroupsRequest message. + * Verifies an ExportTaxonomiesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntryGroupsRequest.verify = function verify(message) { + ExportTaxonomiesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + var properties = {}; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) + if (!$util.isString(message.taxonomies[i])) + return "taxonomies: string[] expected"; + } + if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { + properties.destination = 1; + if (typeof message.serializedTaxonomies !== "boolean") + return "serializedTaxonomies: boolean expected"; + } return null; }; /** - * Creates a ListEntryGroupsRequest message from a plain object. Also converts values to their respective internal types. + * Creates an ExportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} ExportTaxonomiesRequest */ - ListEntryGroupsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest) + ExportTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest(); + var message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesRequest.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) + message.taxonomies[i] = String(object.taxonomies[i]); + } + if (object.serializedTaxonomies != null) + message.serializedTaxonomies = Boolean(object.serializedTaxonomies); return message; }; /** - * Creates a plain object from a ListEntryGroupsRequest message. Also converts values to other types if specified. + * Creates a plain object from an ExportTaxonomiesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} message ListEntryGroupsRequest + * @param {google.cloud.datacatalog.v1.ExportTaxonomiesRequest} message ExportTaxonomiesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntryGroupsRequest.toObject = function toObject(message, options) { + ExportTaxonomiesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { + if (options.arrays || options.defaults) + object.taxonomies = []; + if (options.defaults) object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; - } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = message.taxonomies[j]; + } + if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { + object.serializedTaxonomies = message.serializedTaxonomies; + if (options.oneofs) + object.destination = "serializedTaxonomies"; + } return object; }; /** - * Converts this ListEntryGroupsRequest to JSON. + * Converts this ExportTaxonomiesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @instance * @returns {Object.} JSON object */ - ListEntryGroupsRequest.prototype.toJSON = function toJSON() { + ExportTaxonomiesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntryGroupsRequest + * Gets the default type url for ExportTaxonomiesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntryGroupsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ExportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ExportTaxonomiesRequest"; }; - return ListEntryGroupsRequest; + return ExportTaxonomiesRequest; })(); - v1beta1.ListEntryGroupsResponse = (function() { + v1.ExportTaxonomiesResponse = (function() { /** - * Properties of a ListEntryGroupsResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListEntryGroupsResponse - * @property {Array.|null} [entryGroups] ListEntryGroupsResponse entryGroups - * @property {string|null} [nextPageToken] ListEntryGroupsResponse nextPageToken + * Properties of an ExportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1 + * @interface IExportTaxonomiesResponse + * @property {Array.|null} [taxonomies] ExportTaxonomiesResponse taxonomies */ /** - * Constructs a new ListEntryGroupsResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListEntryGroupsResponse. - * @implements IListEntryGroupsResponse + * Constructs a new ExportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1 + * @classdesc Represents an ExportTaxonomiesResponse. + * @implements IExportTaxonomiesResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse=} [properties] Properties to set */ - function ListEntryGroupsResponse(properties) { - this.entryGroups = []; + function ExportTaxonomiesResponse(properties) { + this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -32823,92 +34126,78 @@ } /** - * ListEntryGroupsResponse entryGroups. - * @member {Array.} entryGroups - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse - * @instance - */ - ListEntryGroupsResponse.prototype.entryGroups = $util.emptyArray; - - /** - * ListEntryGroupsResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * ExportTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @instance */ - ListEntryGroupsResponse.prototype.nextPageToken = ""; + ExportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; /** - * Creates a new ListEntryGroupsResponse instance using the specified properties. + * Creates a new ExportTaxonomiesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse instance + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse instance */ - ListEntryGroupsResponse.create = function create(properties) { - return new ListEntryGroupsResponse(properties); + ExportTaxonomiesResponse.create = function create(properties) { + return new ExportTaxonomiesResponse(properties); }; /** - * Encodes the specified ListEntryGroupsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.verify|verify} messages. + * Encodes the specified ExportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse} message ListEntryGroupsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntryGroupsResponse.encode = function encode(message, writer) { + ExportTaxonomiesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.entryGroups != null && message.entryGroups.length) - for (var i = 0; i < message.entryGroups.length; ++i) - $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroups[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified ListEntryGroupsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.verify|verify} messages. + * Encodes the specified ExportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1.ExportTaxonomiesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse} message ListEntryGroupsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntryGroupsResponse.encodeDelimited = function encodeDelimited(message, writer) { + ExportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntryGroupsResponse message from the specified reader or buffer. + * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntryGroupsResponse.decode = function decode(reader, length) { + ExportTaxonomiesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.entryGroups && message.entryGroups.length)) - message.entryGroups = []; - message.entryGroups.push($root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32())); - break; - } - case 2: { - message.nextPageToken = reader.string(); + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1.SerializedTaxonomy.decode(reader, reader.uint32())); break; } default: @@ -32920,1588 +34209,1229 @@ }; /** - * Decodes a ListEntryGroupsResponse message from the specified reader or buffer, length delimited. + * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntryGroupsResponse.decodeDelimited = function decodeDelimited(reader) { + ExportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntryGroupsResponse message. + * Verifies an ExportTaxonomiesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntryGroupsResponse.verify = function verify(message) { + ExportTaxonomiesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.entryGroups != null && message.hasOwnProperty("entryGroups")) { - if (!Array.isArray(message.entryGroups)) - return "entryGroups: array expected"; - for (var i = 0; i < message.entryGroups.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroups[i]); + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.verify(message.taxonomies[i]); if (error) - return "entryGroups." + error; + return "taxonomies." + error; } } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; return null; }; /** - * Creates a ListEntryGroupsResponse message from a plain object. Also converts values to their respective internal types. + * Creates an ExportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse + * @returns {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} ExportTaxonomiesResponse */ - ListEntryGroupsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse) + ExportTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse(); - if (object.entryGroups) { - if (!Array.isArray(object.entryGroups)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.entryGroups: array expected"); - message.entryGroups = []; - for (var i = 0; i < object.entryGroups.length; ++i) { - if (typeof object.entryGroups[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.entryGroups: object expected"); - message.entryGroups[i] = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroups[i]); + var message = new $root.google.cloud.datacatalog.v1.ExportTaxonomiesResponse(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesResponse.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1.ExportTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.fromObject(object.taxonomies[i]); } } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a ListEntryGroupsResponse message. Also converts values to other types if specified. + * Creates a plain object from an ExportTaxonomiesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} message ListEntryGroupsResponse + * @param {google.cloud.datacatalog.v1.ExportTaxonomiesResponse} message ExportTaxonomiesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntryGroupsResponse.toObject = function toObject(message, options) { + ExportTaxonomiesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.entryGroups = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.entryGroups && message.entryGroups.length) { - object.entryGroups = []; - for (var j = 0; j < message.entryGroups.length; ++j) - object.entryGroups[j] = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroups[j], options); + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1.SerializedTaxonomy.toObject(message.taxonomies[j], options); } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this ListEntryGroupsResponse to JSON. + * Converts this ExportTaxonomiesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @instance * @returns {Object.} JSON object */ - ListEntryGroupsResponse.prototype.toJSON = function toJSON() { + ExportTaxonomiesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntryGroupsResponse + * Gets the default type url for ExportTaxonomiesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse + * @memberof google.cloud.datacatalog.v1.ExportTaxonomiesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntryGroupsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ExportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1.ExportTaxonomiesResponse"; }; - return ListEntryGroupsResponse; + return ExportTaxonomiesResponse; })(); - v1beta1.CreateEntryRequest = (function() { + return v1; + })(); - /** - * Properties of a CreateEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateEntryRequest - * @property {string|null} [parent] CreateEntryRequest parent - * @property {string|null} [entryId] CreateEntryRequest entryId - * @property {google.cloud.datacatalog.v1beta1.IEntry|null} [entry] CreateEntryRequest entry - */ + datacatalog.v1beta1 = (function() { + + /** + * Namespace v1beta1. + * @memberof google.cloud.datacatalog + * @namespace + */ + var v1beta1 = {}; + + /** + * IntegratedSystem enum. + * @name google.cloud.datacatalog.v1beta1.IntegratedSystem + * @enum {number} + * @property {number} INTEGRATED_SYSTEM_UNSPECIFIED=0 INTEGRATED_SYSTEM_UNSPECIFIED value + * @property {number} BIGQUERY=1 BIGQUERY value + * @property {number} CLOUD_PUBSUB=2 CLOUD_PUBSUB value + */ + v1beta1.IntegratedSystem = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "INTEGRATED_SYSTEM_UNSPECIFIED"] = 0; + values[valuesById[1] = "BIGQUERY"] = 1; + values[valuesById[2] = "CLOUD_PUBSUB"] = 2; + return values; + })(); + + v1beta1.DataCatalog = (function() { /** - * Constructs a new CreateEntryRequest. + * Constructs a new DataCatalog service. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateEntryRequest. - * @implements ICreateEntryRequest + * @classdesc Represents a DataCatalog + * @extends $protobuf.rpc.Service * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest=} [properties] Properties to set + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited */ - function CreateEntryRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + function DataCatalog(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); } - /** - * CreateEntryRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @instance - */ - CreateEntryRequest.prototype.parent = ""; - - /** - * CreateEntryRequest entryId. - * @member {string} entryId - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @instance - */ - CreateEntryRequest.prototype.entryId = ""; - - /** - * CreateEntryRequest entry. - * @member {google.cloud.datacatalog.v1beta1.IEntry|null|undefined} entry - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @instance - */ - CreateEntryRequest.prototype.entry = null; + (DataCatalog.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = DataCatalog; /** - * Creates a new CreateEntryRequest instance using the specified properties. + * Creates new DataCatalog service using the specified rpc implementation. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest instance + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {DataCatalog} RPC service. Useful where requests and/or responses are streamed. */ - CreateEntryRequest.create = function create(properties) { - return new CreateEntryRequest(properties); + DataCatalog.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); }; /** - * Encodes the specified CreateEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} message CreateEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|searchCatalog}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef SearchCatalogCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} [response] SearchCatalogResponse */ - CreateEntryRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.entry != null && Object.hasOwnProperty.call(message, "entry")) - $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entry, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.entryId != null && Object.hasOwnProperty.call(message, "entryId")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.entryId); - return writer; - }; /** - * Encodes the specified CreateEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} message CreateEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls SearchCatalog. + * @function searchCatalog + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} request SearchCatalogRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.SearchCatalogCallback} callback Node-style callback called with the error, if any, and SearchCatalogResponse + * @returns {undefined} + * @variation 1 */ - CreateEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Object.defineProperty(DataCatalog.prototype.searchCatalog = function searchCatalog(request, callback) { + return this.rpcCall(searchCatalog, $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest, $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse, request, callback); + }, "name", { value: "SearchCatalog" }); /** - * Decodes a CreateEntryRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls SearchCatalog. + * @function searchCatalog + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} request SearchCatalogRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateEntryRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.parent = reader.string(); - break; - } - case 3: { - message.entryId = reader.string(); - break; - } - case 2: { - message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a CreateEntryRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createEntryGroup}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef CreateEntryGroupCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup */ - CreateEntryRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies a CreateEntryRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls CreateEntryGroup. + * @function createEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} request CreateEntryGroupRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup + * @returns {undefined} + * @variation 1 */ - CreateEntryRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.entryId != null && message.hasOwnProperty("entryId")) - if (!$util.isString(message.entryId)) - return "entryId: string expected"; - if (message.entry != null && message.hasOwnProperty("entry")) { - var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entry); - if (error) - return "entry." + error; - } - return null; - }; + Object.defineProperty(DataCatalog.prototype.createEntryGroup = function createEntryGroup(request, callback) { + return this.rpcCall(createEntryGroup, $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); + }, "name", { value: "CreateEntryGroup" }); /** - * Creates a CreateEntryRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest + * Calls CreateEntryGroup. + * @function createEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} request CreateEntryGroupRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - CreateEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.entryId != null) - message.entryId = String(object.entryId); - if (object.entry != null) { - if (typeof object.entry !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateEntryRequest.entry: object expected"); - message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entry); - } - return message; - }; /** - * Creates a plain object from a CreateEntryRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.CreateEntryRequest} message CreateEntryRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateEntryGroup}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef UpdateEntryGroupCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup */ - CreateEntryRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.parent = ""; - object.entry = null; - object.entryId = ""; - } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.entry != null && message.hasOwnProperty("entry")) - object.entry = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entry, options); - if (message.entryId != null && message.hasOwnProperty("entryId")) - object.entryId = message.entryId; - return object; - }; /** - * Converts this CreateEntryRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest + * Calls UpdateEntryGroup. + * @function updateEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance - * @returns {Object.} JSON object - */ - CreateEntryRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for CreateEntryRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} request UpdateEntryGroupRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup + * @returns {undefined} + * @variation 1 */ - CreateEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateEntryRequest"; - }; - - return CreateEntryRequest; - })(); - - v1beta1.UpdateEntryRequest = (function() { + Object.defineProperty(DataCatalog.prototype.updateEntryGroup = function updateEntryGroup(request, callback) { + return this.rpcCall(updateEntryGroup, $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); + }, "name", { value: "UpdateEntryGroup" }); /** - * Properties of an UpdateEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateEntryRequest - * @property {google.cloud.datacatalog.v1beta1.IEntry|null} [entry] UpdateEntryRequest entry - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateEntryRequest updateMask + * Calls UpdateEntryGroup. + * @function updateEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} request UpdateEntryGroupRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ /** - * Constructs a new UpdateEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateEntryRequest. - * @implements IUpdateEntryRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest=} [properties] Properties to set + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getEntryGroup}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef GetEntryGroupCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.EntryGroup} [response] EntryGroup */ - function UpdateEntryRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * UpdateEntryRequest entry. - * @member {google.cloud.datacatalog.v1beta1.IEntry|null|undefined} entry - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest + * Calls GetEntryGroup. + * @function getEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} request GetEntryGroupRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetEntryGroupCallback} callback Node-style callback called with the error, if any, and EntryGroup + * @returns {undefined} + * @variation 1 */ - UpdateEntryRequest.prototype.entry = null; + Object.defineProperty(DataCatalog.prototype.getEntryGroup = function getEntryGroup(request, callback) { + return this.rpcCall(getEntryGroup, $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest, $root.google.cloud.datacatalog.v1beta1.EntryGroup, request, callback); + }, "name", { value: "GetEntryGroup" }); /** - * UpdateEntryRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest + * Calls GetEntryGroup. + * @function getEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} request GetEntryGroupRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdateEntryRequest.prototype.updateMask = null; /** - * Creates a new UpdateEntryRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteEntryGroup}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef DeleteEntryGroupCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - UpdateEntryRequest.create = function create(properties) { - return new UpdateEntryRequest(properties); - }; /** - * Encodes the specified UpdateEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} message UpdateEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls DeleteEntryGroup. + * @function deleteEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} request DeleteEntryGroupRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteEntryGroupCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ - UpdateEntryRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.entry != null && Object.hasOwnProperty.call(message, "entry")) - $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entry, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - return writer; - }; + Object.defineProperty(DataCatalog.prototype.deleteEntryGroup = function deleteEntryGroup(request, callback) { + return this.rpcCall(deleteEntryGroup, $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteEntryGroup" }); /** - * Encodes the specified UpdateEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} message UpdateEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls DeleteEntryGroup. + * @function deleteEntryGroup + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} request DeleteEntryGroupRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdateEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; /** - * Decodes an UpdateEntryRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listEntryGroups}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef ListEntryGroupsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} [response] ListEntryGroupsResponse */ - UpdateEntryRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32()); - break; - } - case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes an UpdateEntryRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls ListEntryGroups. + * @function listEntryGroups + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} request ListEntryGroupsRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListEntryGroupsCallback} callback Node-style callback called with the error, if any, and ListEntryGroupsResponse + * @returns {undefined} + * @variation 1 */ - UpdateEntryRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + Object.defineProperty(DataCatalog.prototype.listEntryGroups = function listEntryGroups(request, callback) { + return this.rpcCall(listEntryGroups, $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest, $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse, request, callback); + }, "name", { value: "ListEntryGroups" }); /** - * Verifies an UpdateEntryRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls ListEntryGroups. + * @function listEntryGroups + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} request ListEntryGroupsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdateEntryRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.entry != null && message.hasOwnProperty("entry")) { - var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entry); - if (error) - return "entry." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } - return null; - }; /** - * Creates an UpdateEntryRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createEntry}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef CreateEntryCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry */ - UpdateEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest(); - if (object.entry != null) { - if (typeof object.entry !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryRequest.entry: object expected"); - message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entry); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } - return message; - }; /** - * Creates a plain object from an UpdateEntryRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} message UpdateEntryRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Calls CreateEntry. + * @function createEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} request CreateEntryRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @returns {undefined} + * @variation 1 */ - UpdateEntryRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.entry = null; - object.updateMask = null; - } - if (message.entry != null && message.hasOwnProperty("entry")) - object.entry = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entry, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); - return object; - }; + Object.defineProperty(DataCatalog.prototype.createEntry = function createEntry(request, callback) { + return this.rpcCall(createEntry, $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); + }, "name", { value: "CreateEntry" }); /** - * Converts this UpdateEntryRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest + * Calls CreateEntry. + * @function createEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} request CreateEntryRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdateEntryRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; /** - * Gets the default type url for UpdateEntryRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateEntry}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef UpdateEntryCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry */ - UpdateEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateEntryRequest"; - }; - return UpdateEntryRequest; - })(); - - v1beta1.DeleteEntryRequest = (function() { + /** + * Calls UpdateEntry. + * @function updateEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} request UpdateEntryRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(DataCatalog.prototype.updateEntry = function updateEntry(request, callback) { + return this.rpcCall(updateEntry, $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); + }, "name", { value: "UpdateEntry" }); /** - * Properties of a DeleteEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteEntryRequest - * @property {string|null} [name] DeleteEntryRequest name + * Calls UpdateEntry. + * @function updateEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} request UpdateEntryRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ /** - * Constructs a new DeleteEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteEntryRequest. - * @implements IDeleteEntryRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest=} [properties] Properties to set + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteEntry}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef DeleteEntryCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - function DeleteEntryRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * DeleteEntryRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest + * Calls DeleteEntry. + * @function deleteEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} request DeleteEntryRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteEntryCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ - DeleteEntryRequest.prototype.name = ""; + Object.defineProperty(DataCatalog.prototype.deleteEntry = function deleteEntry(request, callback) { + return this.rpcCall(deleteEntry, $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteEntry" }); /** - * Creates a new DeleteEntryRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest instance + * Calls DeleteEntry. + * @function deleteEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} request DeleteEntryRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - DeleteEntryRequest.create = function create(properties) { - return new DeleteEntryRequest(properties); - }; /** - * Encodes the specified DeleteEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} message DeleteEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getEntry}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef GetEntryCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry */ - DeleteEntryRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - return writer; - }; /** - * Encodes the specified DeleteEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} message DeleteEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls GetEntry. + * @function getEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} request GetEntryRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @returns {undefined} + * @variation 1 */ - DeleteEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Object.defineProperty(DataCatalog.prototype.getEntry = function getEntry(request, callback) { + return this.rpcCall(getEntry, $root.google.cloud.datacatalog.v1beta1.GetEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); + }, "name", { value: "GetEntry" }); /** - * Decodes a DeleteEntryRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls GetEntry. + * @function getEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} request GetEntryRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - DeleteEntryRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a DeleteEntryRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|lookupEntry}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef LookupEntryCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Entry} [response] Entry */ - DeleteEntryRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies a DeleteEntryRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls LookupEntry. + * @function lookupEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} request LookupEntryRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.LookupEntryCallback} callback Node-style callback called with the error, if any, and Entry + * @returns {undefined} + * @variation 1 */ - DeleteEntryRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - return null; - }; + Object.defineProperty(DataCatalog.prototype.lookupEntry = function lookupEntry(request, callback) { + return this.rpcCall(lookupEntry, $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest, $root.google.cloud.datacatalog.v1beta1.Entry, request, callback); + }, "name", { value: "LookupEntry" }); /** - * Creates a DeleteEntryRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest + * Calls LookupEntry. + * @function lookupEntry + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} request LookupEntryRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - DeleteEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest(); - if (object.name != null) - message.name = String(object.name); - return message; - }; /** - * Creates a plain object from a DeleteEntryRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} message DeleteEntryRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listEntries}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef ListEntriesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ListEntriesResponse} [response] ListEntriesResponse */ - DeleteEntryRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - return object; - }; /** - * Converts this DeleteEntryRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest + * Calls ListEntries. + * @function listEntries + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} request ListEntriesRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListEntriesCallback} callback Node-style callback called with the error, if any, and ListEntriesResponse + * @returns {undefined} + * @variation 1 */ - DeleteEntryRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Object.defineProperty(DataCatalog.prototype.listEntries = function listEntries(request, callback) { + return this.rpcCall(listEntries, $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest, $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse, request, callback); + }, "name", { value: "ListEntries" }); /** - * Gets the default type url for DeleteEntryRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Calls ListEntries. + * @function listEntries + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} request ListEntriesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - DeleteEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteEntryRequest"; - }; - - return DeleteEntryRequest; - })(); - - v1beta1.GetEntryRequest = (function() { /** - * Properties of a GetEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGetEntryRequest - * @property {string|null} [name] GetEntryRequest name + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTagTemplate}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef CreateTagTemplateCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate */ /** - * Constructs a new GetEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GetEntryRequest. - * @implements IGetEntryRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest=} [properties] Properties to set + * Calls CreateTagTemplate. + * @function createTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} request CreateTagTemplateRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate + * @returns {undefined} + * @variation 1 */ - function GetEntryRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + Object.defineProperty(DataCatalog.prototype.createTagTemplate = function createTagTemplate(request, callback) { + return this.rpcCall(createTagTemplate, $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); + }, "name", { value: "CreateTagTemplate" }); /** - * GetEntryRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest + * Calls CreateTagTemplate. + * @function createTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} request CreateTagTemplateRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - GetEntryRequest.prototype.name = ""; /** - * Creates a new GetEntryRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getTagTemplate}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef GetTagTemplateCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate */ - GetEntryRequest.create = function create(properties) { - return new GetEntryRequest(properties); - }; /** - * Encodes the specified GetEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} message GetEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls GetTagTemplate. + * @function getTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} request GetTagTemplateRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate + * @returns {undefined} + * @variation 1 */ - GetEntryRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - return writer; - }; + Object.defineProperty(DataCatalog.prototype.getTagTemplate = function getTagTemplate(request, callback) { + return this.rpcCall(getTagTemplate, $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); + }, "name", { value: "GetTagTemplate" }); /** - * Encodes the specified GetEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} message GetEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls GetTagTemplate. + * @function getTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} request GetTagTemplateRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - GetEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; /** - * Decodes a GetEntryRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTagTemplate}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef UpdateTagTemplateCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplate} [response] TagTemplate */ - GetEntryRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetEntryRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a GetEntryRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls UpdateTagTemplate. + * @function updateTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} request UpdateTagTemplateRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplateCallback} callback Node-style callback called with the error, if any, and TagTemplate + * @returns {undefined} + * @variation 1 */ - GetEntryRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + Object.defineProperty(DataCatalog.prototype.updateTagTemplate = function updateTagTemplate(request, callback) { + return this.rpcCall(updateTagTemplate, $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplate, request, callback); + }, "name", { value: "UpdateTagTemplate" }); /** - * Verifies a GetEntryRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls UpdateTagTemplate. + * @function updateTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} request UpdateTagTemplateRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - GetEntryRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - return null; - }; /** - * Creates a GetEntryRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTagTemplate}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef DeleteTagTemplateCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - GetEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetEntryRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GetEntryRequest(); - if (object.name != null) - message.name = String(object.name); - return message; - }; /** - * Creates a plain object from a GetEntryRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.GetEntryRequest} message GetEntryRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Calls DeleteTagTemplate. + * @function deleteTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} request DeleteTagTemplateRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplateCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ - GetEntryRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - return object; - }; + Object.defineProperty(DataCatalog.prototype.deleteTagTemplate = function deleteTagTemplate(request, callback) { + return this.rpcCall(deleteTagTemplate, $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteTagTemplate" }); /** - * Converts this GetEntryRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest + * Calls DeleteTagTemplate. + * @function deleteTagTemplate + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} request DeleteTagTemplateRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - GetEntryRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; /** - * Gets the default type url for GetEntryRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTagTemplateField}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef CreateTagTemplateFieldCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField */ - GetEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetEntryRequest"; - }; - - return GetEntryRequest; - })(); - v1beta1.LookupEntryRequest = (function() { + /** + * Calls CreateTagTemplateField. + * @function createTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} request CreateTagTemplateFieldRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(DataCatalog.prototype.createTagTemplateField = function createTagTemplateField(request, callback) { + return this.rpcCall(createTagTemplateField, $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); + }, "name", { value: "CreateTagTemplateField" }); /** - * Properties of a LookupEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ILookupEntryRequest - * @property {string|null} [linkedResource] LookupEntryRequest linkedResource - * @property {string|null} [sqlResource] LookupEntryRequest sqlResource + * Calls CreateTagTemplateField. + * @function createTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} request CreateTagTemplateFieldRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ /** - * Constructs a new LookupEntryRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a LookupEntryRequest. - * @implements ILookupEntryRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest=} [properties] Properties to set + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTagTemplateField}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef UpdateTagTemplateFieldCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField */ - function LookupEntryRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * LookupEntryRequest linkedResource. - * @member {string|null|undefined} linkedResource - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest + * Calls UpdateTagTemplateField. + * @function updateTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} request UpdateTagTemplateFieldRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField + * @returns {undefined} + * @variation 1 */ - LookupEntryRequest.prototype.linkedResource = null; + Object.defineProperty(DataCatalog.prototype.updateTagTemplateField = function updateTagTemplateField(request, callback) { + return this.rpcCall(updateTagTemplateField, $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); + }, "name", { value: "UpdateTagTemplateField" }); /** - * LookupEntryRequest sqlResource. - * @member {string|null|undefined} sqlResource - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest + * Calls UpdateTagTemplateField. + * @function updateTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} request UpdateTagTemplateFieldRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - LookupEntryRequest.prototype.sqlResource = null; - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|renameTagTemplateField}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef RenameTagTemplateFieldCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} [response] TagTemplateField + */ /** - * LookupEntryRequest targetName. - * @member {"linkedResource"|"sqlResource"|undefined} targetName - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest + * Calls RenameTagTemplateField. + * @function renameTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} request RenameTagTemplateFieldRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.RenameTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and TagTemplateField + * @returns {undefined} + * @variation 1 */ - Object.defineProperty(LookupEntryRequest.prototype, "targetName", { - get: $util.oneOfGetter($oneOfFields = ["linkedResource", "sqlResource"]), - set: $util.oneOfSetter($oneOfFields) - }); + Object.defineProperty(DataCatalog.prototype.renameTagTemplateField = function renameTagTemplateField(request, callback) { + return this.rpcCall(renameTagTemplateField, $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest, $root.google.cloud.datacatalog.v1beta1.TagTemplateField, request, callback); + }, "name", { value: "RenameTagTemplateField" }); /** - * Creates a new LookupEntryRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest instance + * Calls RenameTagTemplateField. + * @function renameTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} request RenameTagTemplateFieldRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - LookupEntryRequest.create = function create(properties) { - return new LookupEntryRequest(properties); - }; /** - * Encodes the specified LookupEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.LookupEntryRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} message LookupEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTagTemplateField}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef DeleteTagTemplateFieldCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - LookupEntryRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.linkedResource); - if (message.sqlResource != null && Object.hasOwnProperty.call(message, "sqlResource")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.sqlResource); - return writer; - }; /** - * Encodes the specified LookupEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.LookupEntryRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} message LookupEntryRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls DeleteTagTemplateField. + * @function deleteTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} request DeleteTagTemplateFieldRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagTemplateFieldCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ - LookupEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + Object.defineProperty(DataCatalog.prototype.deleteTagTemplateField = function deleteTagTemplateField(request, callback) { + return this.rpcCall(deleteTagTemplateField, $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteTagTemplateField" }); /** - * Decodes a LookupEntryRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls DeleteTagTemplateField. + * @function deleteTagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} request DeleteTagTemplateFieldRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - LookupEntryRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.linkedResource = reader.string(); - break; - } - case 3: { - message.sqlResource = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a LookupEntryRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|createTag}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef CreateTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Tag} [response] Tag */ - LookupEntryRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; /** - * Verifies a LookupEntryRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls CreateTag. + * @function createTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} request CreateTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.CreateTagCallback} callback Node-style callback called with the error, if any, and Tag + * @returns {undefined} + * @variation 1 */ - LookupEntryRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) { - properties.targetName = 1; - if (!$util.isString(message.linkedResource)) - return "linkedResource: string expected"; - } - if (message.sqlResource != null && message.hasOwnProperty("sqlResource")) { - if (properties.targetName === 1) - return "targetName: multiple values"; - properties.targetName = 1; - if (!$util.isString(message.sqlResource)) - return "sqlResource: string expected"; - } - return null; - }; + Object.defineProperty(DataCatalog.prototype.createTag = function createTag(request, callback) { + return this.rpcCall(createTag, $root.google.cloud.datacatalog.v1beta1.CreateTagRequest, $root.google.cloud.datacatalog.v1beta1.Tag, request, callback); + }, "name", { value: "CreateTag" }); /** - * Creates a LookupEntryRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest + * Calls CreateTag. + * @function createTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} request CreateTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - LookupEntryRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest(); - if (object.linkedResource != null) - message.linkedResource = String(object.linkedResource); - if (object.sqlResource != null) - message.sqlResource = String(object.sqlResource); - return message; - }; /** - * Creates a plain object from a LookupEntryRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.LookupEntryRequest} message LookupEntryRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|updateTag}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef UpdateTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Tag} [response] Tag */ - LookupEntryRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) { - object.linkedResource = message.linkedResource; - if (options.oneofs) - object.targetName = "linkedResource"; - } - if (message.sqlResource != null && message.hasOwnProperty("sqlResource")) { - object.sqlResource = message.sqlResource; - if (options.oneofs) - object.targetName = "sqlResource"; - } - return object; - }; /** - * Converts this LookupEntryRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest + * Calls UpdateTag. + * @function updateTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} request UpdateTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.UpdateTagCallback} callback Node-style callback called with the error, if any, and Tag + * @returns {undefined} + * @variation 1 */ - LookupEntryRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Object.defineProperty(DataCatalog.prototype.updateTag = function updateTag(request, callback) { + return this.rpcCall(updateTag, $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest, $root.google.cloud.datacatalog.v1beta1.Tag, request, callback); + }, "name", { value: "UpdateTag" }); /** - * Gets the default type url for LookupEntryRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Calls UpdateTag. + * @function updateTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} request UpdateTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - LookupEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.LookupEntryRequest"; - }; - return LookupEntryRequest; - })(); + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|deleteTag}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef DeleteTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty + */ - v1beta1.Entry = (function() { + /** + * Calls DeleteTag. + * @function deleteTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} request DeleteTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.DeleteTagCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(DataCatalog.prototype.deleteTag = function deleteTag(request, callback) { + return this.rpcCall(deleteTag, $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteTag" }); /** - * Properties of an Entry. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IEntry - * @property {string|null} [name] Entry name - * @property {string|null} [linkedResource] Entry linkedResource - * @property {google.cloud.datacatalog.v1beta1.EntryType|null} [type] Entry type - * @property {string|null} [userSpecifiedType] Entry userSpecifiedType - * @property {google.cloud.datacatalog.v1beta1.IntegratedSystem|null} [integratedSystem] Entry integratedSystem - * @property {string|null} [userSpecifiedSystem] Entry userSpecifiedSystem - * @property {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec|null} [gcsFilesetSpec] Entry gcsFilesetSpec - * @property {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec|null} [bigqueryTableSpec] Entry bigqueryTableSpec - * @property {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec|null} [bigqueryDateShardedSpec] Entry bigqueryDateShardedSpec - * @property {string|null} [displayName] Entry displayName - * @property {string|null} [description] Entry description - * @property {google.cloud.datacatalog.v1beta1.ISchema|null} [schema] Entry schema - * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [sourceSystemTimestamps] Entry sourceSystemTimestamps + * Calls DeleteTag. + * @function deleteTag + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} request DeleteTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ /** - * Constructs a new Entry. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an Entry. - * @implements IEntry - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IEntry=} [properties] Properties to set + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|listTags}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef ListTagsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ListTagsResponse} [response] ListTagsResponse */ - function Entry(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * Entry name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls ListTags. + * @function listTags + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} request ListTagsRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.ListTagsCallback} callback Node-style callback called with the error, if any, and ListTagsResponse + * @returns {undefined} + * @variation 1 */ - Entry.prototype.name = ""; + Object.defineProperty(DataCatalog.prototype.listTags = function listTags(request, callback) { + return this.rpcCall(listTags, $root.google.cloud.datacatalog.v1beta1.ListTagsRequest, $root.google.cloud.datacatalog.v1beta1.ListTagsResponse, request, callback); + }, "name", { value: "ListTags" }); /** - * Entry linkedResource. - * @member {string} linkedResource - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls ListTags. + * @function listTags + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} request ListTagsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - Entry.prototype.linkedResource = ""; /** - * Entry type. - * @member {google.cloud.datacatalog.v1beta1.EntryType|null|undefined} type - * @memberof google.cloud.datacatalog.v1beta1.Entry - * @instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|setIamPolicy}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef SetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy */ - Entry.prototype.type = null; /** - * Entry userSpecifiedType. - * @member {string|null|undefined} userSpecifiedType - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 */ - Entry.prototype.userSpecifiedType = null; + Object.defineProperty(DataCatalog.prototype.setIamPolicy = function setIamPolicy(request, callback) { + return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "SetIamPolicy" }); /** - * Entry integratedSystem. - * @member {google.cloud.datacatalog.v1beta1.IntegratedSystem|null|undefined} integratedSystem - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - Entry.prototype.integratedSystem = null; /** - * Entry userSpecifiedSystem. - * @member {string|null|undefined} userSpecifiedSystem - * @memberof google.cloud.datacatalog.v1beta1.Entry - * @instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|getIamPolicy}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef GetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy */ - Entry.prototype.userSpecifiedSystem = null; /** - * Entry gcsFilesetSpec. - * @member {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec|null|undefined} gcsFilesetSpec - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 */ - Entry.prototype.gcsFilesetSpec = null; + Object.defineProperty(DataCatalog.prototype.getIamPolicy = function getIamPolicy(request, callback) { + return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "GetIamPolicy" }); /** - * Entry bigqueryTableSpec. - * @member {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec|null|undefined} bigqueryTableSpec - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - Entry.prototype.bigqueryTableSpec = null; /** - * Entry bigqueryDateShardedSpec. - * @member {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec|null|undefined} bigqueryDateShardedSpec - * @memberof google.cloud.datacatalog.v1beta1.Entry - * @instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.DataCatalog|testIamPermissions}. + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog + * @typedef TestIamPermissionsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse */ - Entry.prototype.bigqueryDateShardedSpec = null; /** - * Entry displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.DataCatalog.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse + * @returns {undefined} + * @variation 1 */ - Entry.prototype.displayName = ""; + Object.defineProperty(DataCatalog.prototype.testIamPermissions = function testIamPermissions(request, callback) { + return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); + }, "name", { value: "TestIamPermissions" }); /** - * Entry description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1beta1.DataCatalog * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - Entry.prototype.description = ""; + + return DataCatalog; + })(); + + v1beta1.SearchCatalogRequest = (function() { /** - * Entry schema. - * @member {google.cloud.datacatalog.v1beta1.ISchema|null|undefined} schema - * @memberof google.cloud.datacatalog.v1beta1.Entry - * @instance + * Properties of a SearchCatalogRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISearchCatalogRequest + * @property {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope|null} [scope] SearchCatalogRequest scope + * @property {string|null} [query] SearchCatalogRequest query + * @property {number|null} [pageSize] SearchCatalogRequest pageSize + * @property {string|null} [pageToken] SearchCatalogRequest pageToken + * @property {string|null} [orderBy] SearchCatalogRequest orderBy */ - Entry.prototype.schema = null; /** - * Entry sourceSystemTimestamps. - * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} sourceSystemTimestamps - * @memberof google.cloud.datacatalog.v1beta1.Entry + * Constructs a new SearchCatalogRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a SearchCatalogRequest. + * @implements ISearchCatalogRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest=} [properties] Properties to set + */ + function SearchCatalogRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * SearchCatalogRequest scope. + * @member {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope|null|undefined} scope + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @instance */ - Entry.prototype.sourceSystemTimestamps = null; + SearchCatalogRequest.prototype.scope = null; - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * SearchCatalogRequest query. + * @member {string} query + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @instance + */ + SearchCatalogRequest.prototype.query = ""; /** - * Entry entryType. - * @member {"type"|"userSpecifiedType"|undefined} entryType - * @memberof google.cloud.datacatalog.v1beta1.Entry + * SearchCatalogRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @instance */ - Object.defineProperty(Entry.prototype, "entryType", { - get: $util.oneOfGetter($oneOfFields = ["type", "userSpecifiedType"]), - set: $util.oneOfSetter($oneOfFields) - }); + SearchCatalogRequest.prototype.pageSize = 0; /** - * Entry system. - * @member {"integratedSystem"|"userSpecifiedSystem"|undefined} system - * @memberof google.cloud.datacatalog.v1beta1.Entry + * SearchCatalogRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @instance */ - Object.defineProperty(Entry.prototype, "system", { - get: $util.oneOfGetter($oneOfFields = ["integratedSystem", "userSpecifiedSystem"]), - set: $util.oneOfSetter($oneOfFields) - }); + SearchCatalogRequest.prototype.pageToken = ""; /** - * Entry typeSpec. - * @member {"gcsFilesetSpec"|"bigqueryTableSpec"|"bigqueryDateShardedSpec"|undefined} typeSpec - * @memberof google.cloud.datacatalog.v1beta1.Entry + * SearchCatalogRequest orderBy. + * @member {string} orderBy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @instance */ - Object.defineProperty(Entry.prototype, "typeSpec", { - get: $util.oneOfGetter($oneOfFields = ["gcsFilesetSpec", "bigqueryTableSpec", "bigqueryDateShardedSpec"]), - set: $util.oneOfSetter($oneOfFields) - }); + SearchCatalogRequest.prototype.orderBy = ""; /** - * Creates a new Entry instance using the specified properties. + * Creates a new SearchCatalogRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IEntry=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry instance + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest instance */ - Entry.create = function create(properties) { - return new Entry(properties); + SearchCatalogRequest.create = function create(properties) { + return new SearchCatalogRequest(properties); }; /** - * Encodes the specified Entry message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Entry.verify|verify} messages. + * Encodes the specified SearchCatalogRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IEntry} message Entry message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} message SearchCatalogRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Entry.encode = function encode(message, writer) { + SearchCatalogRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.type); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.description); - if (message.schema != null && Object.hasOwnProperty.call(message, "schema")) - $root.google.cloud.datacatalog.v1beta1.Schema.encode(message.schema, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.gcsFilesetSpec != null && Object.hasOwnProperty.call(message, "gcsFilesetSpec")) - $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.encode(message.gcsFilesetSpec, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - if (message.sourceSystemTimestamps != null && Object.hasOwnProperty.call(message, "sourceSystemTimestamps")) - $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.sourceSystemTimestamps, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) - writer.uint32(/* id 9, wireType 2 =*/74).string(message.linkedResource); - if (message.bigqueryTableSpec != null && Object.hasOwnProperty.call(message, "bigqueryTableSpec")) - $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.encode(message.bigqueryTableSpec, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); - if (message.bigqueryDateShardedSpec != null && Object.hasOwnProperty.call(message, "bigqueryDateShardedSpec")) - $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.encode(message.bigqueryDateShardedSpec, writer.uint32(/* id 15, wireType 2 =*/122).fork()).ldelim(); - if (message.userSpecifiedType != null && Object.hasOwnProperty.call(message, "userSpecifiedType")) - writer.uint32(/* id 16, wireType 2 =*/130).string(message.userSpecifiedType); - if (message.integratedSystem != null && Object.hasOwnProperty.call(message, "integratedSystem")) - writer.uint32(/* id 17, wireType 0 =*/136).int32(message.integratedSystem); - if (message.userSpecifiedSystem != null && Object.hasOwnProperty.call(message, "userSpecifiedSystem")) - writer.uint32(/* id 18, wireType 2 =*/146).string(message.userSpecifiedSystem); + if (message.query != null && Object.hasOwnProperty.call(message, "query")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.query); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.orderBy != null && Object.hasOwnProperty.call(message, "orderBy")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.orderBy); + if (message.scope != null && Object.hasOwnProperty.call(message, "scope")) + $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.encode(message.scope, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); return writer; }; /** - * Encodes the specified Entry message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Entry.verify|verify} messages. + * Encodes the specified SearchCatalogRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IEntry} message Entry message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogRequest} message SearchCatalogRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Entry.encodeDelimited = function encodeDelimited(message, writer) { + SearchCatalogRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an Entry message from the specified reader or buffer. + * Decodes a SearchCatalogRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Entry.decode = function decode(reader, length) { + SearchCatalogRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Entry(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 9: { - message.linkedResource = reader.string(); - break; - } - case 2: { - message.type = reader.int32(); - break; - } - case 16: { - message.userSpecifiedType = reader.string(); - break; - } - case 17: { - message.integratedSystem = reader.int32(); - break; - } - case 18: { - message.userSpecifiedSystem = reader.string(); - break; - } case 6: { - message.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.decode(reader, reader.uint32()); + message.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.decode(reader, reader.uint32()); break; } - case 12: { - message.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.decode(reader, reader.uint32()); + case 1: { + message.query = reader.string(); break; } - case 15: { - message.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.decode(reader, reader.uint32()); + case 2: { + message.pageSize = reader.int32(); break; } case 3: { - message.displayName = reader.string(); - break; - } - case 4: { - message.description = reader.string(); + message.pageToken = reader.string(); break; } case 5: { - message.schema = $root.google.cloud.datacatalog.v1beta1.Schema.decode(reader, reader.uint32()); - break; - } - case 7: { - message.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); + message.orderBy = reader.string(); break; } default: @@ -34513,463 +35443,538 @@ }; /** - * Decodes an Entry message from the specified reader or buffer, length delimited. + * Decodes a SearchCatalogRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Entry.decodeDelimited = function decodeDelimited(reader) { + SearchCatalogRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an Entry message. + * Verifies a SearchCatalogRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Entry.verify = function verify(message) { + SearchCatalogRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - if (!$util.isString(message.linkedResource)) - return "linkedResource: string expected"; - if (message.type != null && message.hasOwnProperty("type")) { - properties.entryType = 1; - switch (message.type) { - default: - return "type: enum value expected"; - case 0: - case 2: - case 5: - case 3: - case 4: - break; - } - } - if (message.userSpecifiedType != null && message.hasOwnProperty("userSpecifiedType")) { - if (properties.entryType === 1) - return "entryType: multiple values"; - properties.entryType = 1; - if (!$util.isString(message.userSpecifiedType)) - return "userSpecifiedType: string expected"; - } - if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { - properties.system = 1; - switch (message.integratedSystem) { - default: - return "integratedSystem: enum value expected"; - case 0: - case 1: - case 2: - break; - } - } - if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { - if (properties.system === 1) - return "system: multiple values"; - properties.system = 1; - if (!$util.isString(message.userSpecifiedSystem)) - return "userSpecifiedSystem: string expected"; - } - if (message.gcsFilesetSpec != null && message.hasOwnProperty("gcsFilesetSpec")) { - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify(message.gcsFilesetSpec); - if (error) - return "gcsFilesetSpec." + error; - } - } - if (message.bigqueryTableSpec != null && message.hasOwnProperty("bigqueryTableSpec")) { - if (properties.typeSpec === 1) - return "typeSpec: multiple values"; - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify(message.bigqueryTableSpec); - if (error) - return "bigqueryTableSpec." + error; - } - } - if (message.bigqueryDateShardedSpec != null && message.hasOwnProperty("bigqueryDateShardedSpec")) { - if (properties.typeSpec === 1) - return "typeSpec: multiple values"; - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify(message.bigqueryDateShardedSpec); - if (error) - return "bigqueryDateShardedSpec." + error; - } - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.schema != null && message.hasOwnProperty("schema")) { - var error = $root.google.cloud.datacatalog.v1beta1.Schema.verify(message.schema); - if (error) - return "schema." + error; - } - if (message.sourceSystemTimestamps != null && message.hasOwnProperty("sourceSystemTimestamps")) { - var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.sourceSystemTimestamps); + if (message.scope != null && message.hasOwnProperty("scope")) { + var error = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify(message.scope); if (error) - return "sourceSystemTimestamps." + error; + return "scope." + error; } + if (message.query != null && message.hasOwnProperty("query")) + if (!$util.isString(message.query)) + return "query: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + if (message.orderBy != null && message.hasOwnProperty("orderBy")) + if (!$util.isString(message.orderBy)) + return "orderBy: string expected"; return null; }; /** - * Creates an Entry message from a plain object. Also converts values to their respective internal types. + * Creates a SearchCatalogRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} SearchCatalogRequest */ - Entry.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.Entry) + SearchCatalogRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.Entry(); - if (object.name != null) - message.name = String(object.name); - if (object.linkedResource != null) - message.linkedResource = String(object.linkedResource); - switch (object.type) { - default: - if (typeof object.type === "number") { - message.type = object.type; - break; - } - break; - case "ENTRY_TYPE_UNSPECIFIED": - case 0: - message.type = 0; - break; - case "TABLE": - case 2: - message.type = 2; - break; - case "MODEL": - case 5: - message.type = 5; - break; - case "DATA_STREAM": - case 3: - message.type = 3; - break; - case "FILESET": - case 4: - message.type = 4; - break; - } - if (object.userSpecifiedType != null) - message.userSpecifiedType = String(object.userSpecifiedType); - switch (object.integratedSystem) { - default: - if (typeof object.integratedSystem === "number") { - message.integratedSystem = object.integratedSystem; - break; - } - break; - case "INTEGRATED_SYSTEM_UNSPECIFIED": - case 0: - message.integratedSystem = 0; - break; - case "BIGQUERY": - case 1: - message.integratedSystem = 1; - break; - case "CLOUD_PUBSUB": - case 2: - message.integratedSystem = 2; - break; - } - if (object.userSpecifiedSystem != null) - message.userSpecifiedSystem = String(object.userSpecifiedSystem); - if (object.gcsFilesetSpec != null) { - if (typeof object.gcsFilesetSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.gcsFilesetSpec: object expected"); - message.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.fromObject(object.gcsFilesetSpec); - } - if (object.bigqueryTableSpec != null) { - if (typeof object.bigqueryTableSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.bigqueryTableSpec: object expected"); - message.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.fromObject(object.bigqueryTableSpec); - } - if (object.bigqueryDateShardedSpec != null) { - if (typeof object.bigqueryDateShardedSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.bigqueryDateShardedSpec: object expected"); - message.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.fromObject(object.bigqueryDateShardedSpec); - } - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.schema != null) { - if (typeof object.schema !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.schema: object expected"); - message.schema = $root.google.cloud.datacatalog.v1beta1.Schema.fromObject(object.schema); - } - if (object.sourceSystemTimestamps != null) { - if (typeof object.sourceSystemTimestamps !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.sourceSystemTimestamps: object expected"); - message.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.sourceSystemTimestamps); + var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest(); + if (object.scope != null) { + if (typeof object.scope !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.scope: object expected"); + message.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.fromObject(object.scope); } + if (object.query != null) + message.query = String(object.query); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + if (object.orderBy != null) + message.orderBy = String(object.orderBy); return message; }; /** - * Creates a plain object from an Entry message. Also converts values to other types if specified. + * Creates a plain object from a SearchCatalogRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static - * @param {google.cloud.datacatalog.v1beta1.Entry} message Entry + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest} message SearchCatalogRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Entry.toObject = function toObject(message, options) { + SearchCatalogRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.name = ""; - object.displayName = ""; - object.description = ""; - object.schema = null; - object.sourceSystemTimestamps = null; - object.linkedResource = ""; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.type != null && message.hasOwnProperty("type")) { - object.type = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.EntryType[message.type] === undefined ? message.type : $root.google.cloud.datacatalog.v1beta1.EntryType[message.type] : message.type; - if (options.oneofs) - object.entryType = "type"; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.schema != null && message.hasOwnProperty("schema")) - object.schema = $root.google.cloud.datacatalog.v1beta1.Schema.toObject(message.schema, options); - if (message.gcsFilesetSpec != null && message.hasOwnProperty("gcsFilesetSpec")) { - object.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.toObject(message.gcsFilesetSpec, options); - if (options.oneofs) - object.typeSpec = "gcsFilesetSpec"; - } - if (message.sourceSystemTimestamps != null && message.hasOwnProperty("sourceSystemTimestamps")) - object.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.sourceSystemTimestamps, options); - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - object.linkedResource = message.linkedResource; - if (message.bigqueryTableSpec != null && message.hasOwnProperty("bigqueryTableSpec")) { - object.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.toObject(message.bigqueryTableSpec, options); - if (options.oneofs) - object.typeSpec = "bigqueryTableSpec"; - } - if (message.bigqueryDateShardedSpec != null && message.hasOwnProperty("bigqueryDateShardedSpec")) { - object.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.toObject(message.bigqueryDateShardedSpec, options); - if (options.oneofs) - object.typeSpec = "bigqueryDateShardedSpec"; - } - if (message.userSpecifiedType != null && message.hasOwnProperty("userSpecifiedType")) { - object.userSpecifiedType = message.userSpecifiedType; - if (options.oneofs) - object.entryType = "userSpecifiedType"; - } - if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { - object.integratedSystem = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.IntegratedSystem[message.integratedSystem] === undefined ? message.integratedSystem : $root.google.cloud.datacatalog.v1beta1.IntegratedSystem[message.integratedSystem] : message.integratedSystem; - if (options.oneofs) - object.system = "integratedSystem"; - } - if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { - object.userSpecifiedSystem = message.userSpecifiedSystem; - if (options.oneofs) - object.system = "userSpecifiedSystem"; + object.query = ""; + object.pageSize = 0; + object.pageToken = ""; + object.orderBy = ""; + object.scope = null; } + if (message.query != null && message.hasOwnProperty("query")) + object.query = message.query; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.orderBy != null && message.hasOwnProperty("orderBy")) + object.orderBy = message.orderBy; + if (message.scope != null && message.hasOwnProperty("scope")) + object.scope = $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.toObject(message.scope, options); return object; }; /** - * Converts this Entry to JSON. + * Converts this SearchCatalogRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @instance * @returns {Object.} JSON object */ - Entry.prototype.toJSON = function toJSON() { + SearchCatalogRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Entry + * Gets the default type url for SearchCatalogRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.Entry + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Entry.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SearchCatalogRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Entry"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogRequest"; }; - return Entry; - })(); + SearchCatalogRequest.Scope = (function() { - v1beta1.EntryGroup = (function() { + /** + * Properties of a Scope. + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @interface IScope + * @property {Array.|null} [includeOrgIds] Scope includeOrgIds + * @property {Array.|null} [includeProjectIds] Scope includeProjectIds + * @property {boolean|null} [includeGcpPublicDatasets] Scope includeGcpPublicDatasets + */ - /** - * Properties of an EntryGroup. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IEntryGroup - * @property {string|null} [name] EntryGroup name - * @property {string|null} [displayName] EntryGroup displayName - * @property {string|null} [description] EntryGroup description - * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [dataCatalogTimestamps] EntryGroup dataCatalogTimestamps - */ + /** + * Constructs a new Scope. + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest + * @classdesc Represents a Scope. + * @implements IScope + * @constructor + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope=} [properties] Properties to set + */ + function Scope(properties) { + this.includeOrgIds = []; + this.includeProjectIds = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Constructs a new EntryGroup. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an EntryGroup. - * @implements IEntryGroup - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IEntryGroup=} [properties] Properties to set - */ - function EntryGroup(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Scope includeOrgIds. + * @member {Array.} includeOrgIds + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @instance + */ + Scope.prototype.includeOrgIds = $util.emptyArray; - /** - * EntryGroup name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @instance - */ - EntryGroup.prototype.name = ""; + /** + * Scope includeProjectIds. + * @member {Array.} includeProjectIds + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @instance + */ + Scope.prototype.includeProjectIds = $util.emptyArray; - /** - * EntryGroup displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @instance - */ - EntryGroup.prototype.displayName = ""; + /** + * Scope includeGcpPublicDatasets. + * @member {boolean} includeGcpPublicDatasets + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @instance + */ + Scope.prototype.includeGcpPublicDatasets = false; - /** - * EntryGroup description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @instance - */ - EntryGroup.prototype.description = ""; + /** + * Creates a new Scope instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope instance + */ + Scope.create = function create(properties) { + return new Scope(properties); + }; - /** - * EntryGroup dataCatalogTimestamps. - * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} dataCatalogTimestamps - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @instance - */ - EntryGroup.prototype.dataCatalogTimestamps = null; + /** + * Encodes the specified Scope message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope} message Scope message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Scope.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.includeOrgIds != null && message.includeOrgIds.length) + for (var i = 0; i < message.includeOrgIds.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.includeOrgIds[i]); + if (message.includeProjectIds != null && message.includeProjectIds.length) + for (var i = 0; i < message.includeProjectIds.length; ++i) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.includeProjectIds[i]); + if (message.includeGcpPublicDatasets != null && Object.hasOwnProperty.call(message, "includeGcpPublicDatasets")) + writer.uint32(/* id 7, wireType 0 =*/56).bool(message.includeGcpPublicDatasets); + return writer; + }; - /** - * Creates a new EntryGroup instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @static - * @param {google.cloud.datacatalog.v1beta1.IEntryGroup=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup instance - */ - EntryGroup.create = function create(properties) { - return new EntryGroup(properties); - }; + /** + * Encodes the specified Scope message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.IScope} message Scope message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Scope.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Encodes the specified EntryGroup message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.EntryGroup.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @static - * @param {google.cloud.datacatalog.v1beta1.IEntryGroup} message EntryGroup message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EntryGroup.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.dataCatalogTimestamps != null && Object.hasOwnProperty.call(message, "dataCatalogTimestamps")) - $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.dataCatalogTimestamps, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - return writer; - }; + /** + * Decodes a Scope message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Scope.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 2: { + if (!(message.includeOrgIds && message.includeOrgIds.length)) + message.includeOrgIds = []; + message.includeOrgIds.push(reader.string()); + break; + } + case 3: { + if (!(message.includeProjectIds && message.includeProjectIds.length)) + message.includeProjectIds = []; + message.includeProjectIds.push(reader.string()); + break; + } + case 7: { + message.includeGcpPublicDatasets = reader.bool(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Encodes the specified EntryGroup message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.EntryGroup.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup - * @static - * @param {google.cloud.datacatalog.v1beta1.IEntryGroup} message EntryGroup message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + /** + * Decodes a Scope message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Scope.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Scope message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Scope.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.includeOrgIds != null && message.hasOwnProperty("includeOrgIds")) { + if (!Array.isArray(message.includeOrgIds)) + return "includeOrgIds: array expected"; + for (var i = 0; i < message.includeOrgIds.length; ++i) + if (!$util.isString(message.includeOrgIds[i])) + return "includeOrgIds: string[] expected"; + } + if (message.includeProjectIds != null && message.hasOwnProperty("includeProjectIds")) { + if (!Array.isArray(message.includeProjectIds)) + return "includeProjectIds: array expected"; + for (var i = 0; i < message.includeProjectIds.length; ++i) + if (!$util.isString(message.includeProjectIds[i])) + return "includeProjectIds: string[] expected"; + } + if (message.includeGcpPublicDatasets != null && message.hasOwnProperty("includeGcpPublicDatasets")) + if (typeof message.includeGcpPublicDatasets !== "boolean") + return "includeGcpPublicDatasets: boolean expected"; + return null; + }; + + /** + * Creates a Scope message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} Scope + */ + Scope.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope(); + if (object.includeOrgIds) { + if (!Array.isArray(object.includeOrgIds)) + throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.includeOrgIds: array expected"); + message.includeOrgIds = []; + for (var i = 0; i < object.includeOrgIds.length; ++i) + message.includeOrgIds[i] = String(object.includeOrgIds[i]); + } + if (object.includeProjectIds) { + if (!Array.isArray(object.includeProjectIds)) + throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope.includeProjectIds: array expected"); + message.includeProjectIds = []; + for (var i = 0; i < object.includeProjectIds.length; ++i) + message.includeProjectIds[i] = String(object.includeProjectIds[i]); + } + if (object.includeGcpPublicDatasets != null) + message.includeGcpPublicDatasets = Boolean(object.includeGcpPublicDatasets); + return message; + }; + + /** + * Creates a plain object from a Scope message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope} message Scope + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Scope.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.includeOrgIds = []; + object.includeProjectIds = []; + } + if (options.defaults) + object.includeGcpPublicDatasets = false; + if (message.includeOrgIds && message.includeOrgIds.length) { + object.includeOrgIds = []; + for (var j = 0; j < message.includeOrgIds.length; ++j) + object.includeOrgIds[j] = message.includeOrgIds[j]; + } + if (message.includeProjectIds && message.includeProjectIds.length) { + object.includeProjectIds = []; + for (var j = 0; j < message.includeProjectIds.length; ++j) + object.includeProjectIds[j] = message.includeProjectIds[j]; + } + if (message.includeGcpPublicDatasets != null && message.hasOwnProperty("includeGcpPublicDatasets")) + object.includeGcpPublicDatasets = message.includeGcpPublicDatasets; + return object; + }; + + /** + * Converts this Scope to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @instance + * @returns {Object.} JSON object + */ + Scope.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Scope + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Scope.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogRequest.Scope"; + }; + + return Scope; + })(); + + return SearchCatalogRequest; + })(); + + v1beta1.SearchCatalogResponse = (function() { + + /** + * Properties of a SearchCatalogResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISearchCatalogResponse + * @property {Array.|null} [results] SearchCatalogResponse results + * @property {string|null} [nextPageToken] SearchCatalogResponse nextPageToken */ - EntryGroup.encodeDelimited = function encodeDelimited(message, writer) { + + /** + * Constructs a new SearchCatalogResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a SearchCatalogResponse. + * @implements ISearchCatalogResponse + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse=} [properties] Properties to set + */ + function SearchCatalogResponse(properties) { + this.results = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * SearchCatalogResponse results. + * @member {Array.} results + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @instance + */ + SearchCatalogResponse.prototype.results = $util.emptyArray; + + /** + * SearchCatalogResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @instance + */ + SearchCatalogResponse.prototype.nextPageToken = ""; + + /** + * Creates a new SearchCatalogResponse instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse instance + */ + SearchCatalogResponse.create = function create(properties) { + return new SearchCatalogResponse(properties); + }; + + /** + * Encodes the specified SearchCatalogResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse} message SearchCatalogResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SearchCatalogResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.results != null && message.results.length) + for (var i = 0; i < message.results.length; ++i) + $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.encode(message.results[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.nextPageToken); + return writer; + }; + + /** + * Encodes the specified SearchCatalogResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResponse} message SearchCatalogResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SearchCatalogResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EntryGroup message from the specified reader or buffer. + * Decodes a SearchCatalogResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EntryGroup.decode = function decode(reader, length) { + SearchCatalogResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.EntryGroup(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.displayName = reader.string(); + if (!(message.results && message.results.length)) + message.results = []; + message.results.push($root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.decode(reader, reader.uint32())); break; } case 3: { - message.description = reader.string(); - break; - } - case 4: { - message.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); + message.nextPageToken = reader.string(); break; } default: @@ -34981,154 +35986,150 @@ }; /** - * Decodes an EntryGroup message from the specified reader or buffer, length delimited. + * Decodes a SearchCatalogResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EntryGroup.decodeDelimited = function decodeDelimited(reader) { + SearchCatalogResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EntryGroup message. + * Verifies a SearchCatalogResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EntryGroup.verify = function verify(message) { + SearchCatalogResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.dataCatalogTimestamps != null && message.hasOwnProperty("dataCatalogTimestamps")) { - var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.dataCatalogTimestamps); - if (error) - return "dataCatalogTimestamps." + error; + if (message.results != null && message.hasOwnProperty("results")) { + if (!Array.isArray(message.results)) + return "results: array expected"; + for (var i = 0; i < message.results.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify(message.results[i]); + if (error) + return "results." + error; + } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates an EntryGroup message from a plain object. Also converts values to their respective internal types. + * Creates a SearchCatalogResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} SearchCatalogResponse */ - EntryGroup.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.EntryGroup) + SearchCatalogResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.EntryGroup(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.dataCatalogTimestamps != null) { - if (typeof object.dataCatalogTimestamps !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.EntryGroup.dataCatalogTimestamps: object expected"); - message.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.dataCatalogTimestamps); + var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResponse(); + if (object.results) { + if (!Array.isArray(object.results)) + throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogResponse.results: array expected"); + message.results = []; + for (var i = 0; i < object.results.length; ++i) { + if (typeof object.results[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SearchCatalogResponse.results: object expected"); + message.results[i] = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.fromObject(object.results[i]); + } } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from an EntryGroup message. Also converts values to other types if specified. + * Creates a plain object from a SearchCatalogResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static - * @param {google.cloud.datacatalog.v1beta1.EntryGroup} message EntryGroup + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResponse} message SearchCatalogResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EntryGroup.toObject = function toObject(message, options) { + SearchCatalogResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.displayName = ""; - object.description = ""; - object.dataCatalogTimestamps = null; + if (options.arrays || options.defaults) + object.results = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.results && message.results.length) { + object.results = []; + for (var j = 0; j < message.results.length; ++j) + object.results[j] = $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult.toObject(message.results[j], options); } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.dataCatalogTimestamps != null && message.hasOwnProperty("dataCatalogTimestamps")) - object.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.dataCatalogTimestamps, options); + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this EntryGroup to JSON. + * Converts this SearchCatalogResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @instance * @returns {Object.} JSON object */ - EntryGroup.prototype.toJSON = function toJSON() { + SearchCatalogResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EntryGroup + * Gets the default type url for SearchCatalogResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EntryGroup.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SearchCatalogResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.EntryGroup"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogResponse"; }; - return EntryGroup; + return SearchCatalogResponse; })(); - v1beta1.CreateTagTemplateRequest = (function() { + v1beta1.CreateEntryGroupRequest = (function() { /** - * Properties of a CreateTagTemplateRequest. + * Properties of a CreateEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateTagTemplateRequest - * @property {string|null} [parent] CreateTagTemplateRequest parent - * @property {string|null} [tagTemplateId] CreateTagTemplateRequest tagTemplateId - * @property {google.cloud.datacatalog.v1beta1.ITagTemplate|null} [tagTemplate] CreateTagTemplateRequest tagTemplate + * @interface ICreateEntryGroupRequest + * @property {string|null} [parent] CreateEntryGroupRequest parent + * @property {string|null} [entryGroupId] CreateEntryGroupRequest entryGroupId + * @property {google.cloud.datacatalog.v1beta1.IEntryGroup|null} [entryGroup] CreateEntryGroupRequest entryGroup */ /** - * Constructs a new CreateTagTemplateRequest. + * Constructs a new CreateEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateTagTemplateRequest. - * @implements ICreateTagTemplateRequest + * @classdesc Represents a CreateEntryGroupRequest. + * @implements ICreateEntryGroupRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest=} [properties] Properties to set */ - function CreateTagTemplateRequest(properties) { + function CreateEntryGroupRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -35136,90 +36137,90 @@ } /** - * CreateTagTemplateRequest parent. + * CreateEntryGroupRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @instance */ - CreateTagTemplateRequest.prototype.parent = ""; + CreateEntryGroupRequest.prototype.parent = ""; /** - * CreateTagTemplateRequest tagTemplateId. - * @member {string} tagTemplateId - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * CreateEntryGroupRequest entryGroupId. + * @member {string} entryGroupId + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @instance */ - CreateTagTemplateRequest.prototype.tagTemplateId = ""; + CreateEntryGroupRequest.prototype.entryGroupId = ""; /** - * CreateTagTemplateRequest tagTemplate. - * @member {google.cloud.datacatalog.v1beta1.ITagTemplate|null|undefined} tagTemplate - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * CreateEntryGroupRequest entryGroup. + * @member {google.cloud.datacatalog.v1beta1.IEntryGroup|null|undefined} entryGroup + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @instance */ - CreateTagTemplateRequest.prototype.tagTemplate = null; + CreateEntryGroupRequest.prototype.entryGroup = null; /** - * Creates a new CreateTagTemplateRequest instance using the specified properties. + * Creates a new CreateEntryGroupRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest instance + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest instance */ - CreateTagTemplateRequest.create = function create(properties) { - return new CreateTagTemplateRequest(properties); + CreateEntryGroupRequest.create = function create(properties) { + return new CreateEntryGroupRequest(properties); }; /** - * Encodes the specified CreateTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.verify|verify} messages. + * Encodes the specified CreateEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} message CreateTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} message CreateEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagTemplateRequest.encode = function encode(message, writer) { + CreateEntryGroupRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.tagTemplate != null && Object.hasOwnProperty.call(message, "tagTemplate")) - $root.google.cloud.datacatalog.v1beta1.TagTemplate.encode(message.tagTemplate, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.tagTemplateId != null && Object.hasOwnProperty.call(message, "tagTemplateId")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.tagTemplateId); + if (message.entryGroup != null && Object.hasOwnProperty.call(message, "entryGroup")) + $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroup, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.entryGroupId != null && Object.hasOwnProperty.call(message, "entryGroupId")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.entryGroupId); return writer; }; /** - * Encodes the specified CreateTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.verify|verify} messages. + * Encodes the specified CreateEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} message CreateTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryGroupRequest} message CreateEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { + CreateEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateTagTemplateRequest message from the specified reader or buffer. + * Decodes a CreateEntryGroupRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagTemplateRequest.decode = function decode(reader, length) { + CreateEntryGroupRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -35228,11 +36229,11 @@ break; } case 3: { - message.tagTemplateId = reader.string(); + message.entryGroupId = reader.string(); break; } case 2: { - message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.decode(reader, reader.uint32()); + message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32()); break; } default: @@ -35244,144 +36245,145 @@ }; /** - * Decodes a CreateTagTemplateRequest message from the specified reader or buffer, length delimited. + * Decodes a CreateEntryGroupRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { + CreateEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateTagTemplateRequest message. + * Verifies a CreateEntryGroupRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateTagTemplateRequest.verify = function verify(message) { + CreateEntryGroupRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.tagTemplateId != null && message.hasOwnProperty("tagTemplateId")) - if (!$util.isString(message.tagTemplateId)) - return "tagTemplateId: string expected"; - if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) { - var error = $root.google.cloud.datacatalog.v1beta1.TagTemplate.verify(message.tagTemplate); + if (message.entryGroupId != null && message.hasOwnProperty("entryGroupId")) + if (!$util.isString(message.entryGroupId)) + return "entryGroupId: string expected"; + if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) { + var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroup); if (error) - return "tagTemplate." + error; + return "entryGroup." + error; } return null; }; /** - * Creates a CreateTagTemplateRequest message from a plain object. Also converts values to their respective internal types. + * Creates a CreateEntryGroupRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} CreateEntryGroupRequest */ - CreateTagTemplateRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest) + CreateEntryGroupRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.tagTemplateId != null) - message.tagTemplateId = String(object.tagTemplateId); - if (object.tagTemplate != null) { - if (typeof object.tagTemplate !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.tagTemplate: object expected"); - message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.fromObject(object.tagTemplate); - } - return message; - }; - + if (object.entryGroupId != null) + message.entryGroupId = String(object.entryGroupId); + if (object.entryGroup != null) { + if (typeof object.entryGroup !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest.entryGroup: object expected"); + message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroup); + } + return message; + }; + /** - * Creates a plain object from a CreateTagTemplateRequest message. Also converts values to other types if specified. + * Creates a plain object from a CreateEntryGroupRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} message CreateTagTemplateRequest + * @param {google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest} message CreateEntryGroupRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreateTagTemplateRequest.toObject = function toObject(message, options) { + CreateEntryGroupRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.parent = ""; - object.tagTemplate = null; - object.tagTemplateId = ""; + object.entryGroup = null; + object.entryGroupId = ""; } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) - object.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.toObject(message.tagTemplate, options); - if (message.tagTemplateId != null && message.hasOwnProperty("tagTemplateId")) - object.tagTemplateId = message.tagTemplateId; + if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) + object.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroup, options); + if (message.entryGroupId != null && message.hasOwnProperty("entryGroupId")) + object.entryGroupId = message.entryGroupId; return object; }; /** - * Converts this CreateTagTemplateRequest to JSON. + * Converts this CreateEntryGroupRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @instance * @returns {Object.} JSON object */ - CreateTagTemplateRequest.prototype.toJSON = function toJSON() { + CreateEntryGroupRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreateTagTemplateRequest + * Gets the default type url for CreateEntryGroupRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreateTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateEntryGroupRequest"; }; - return CreateTagTemplateRequest; + return CreateEntryGroupRequest; })(); - v1beta1.GetTagTemplateRequest = (function() { + v1beta1.UpdateEntryGroupRequest = (function() { /** - * Properties of a GetTagTemplateRequest. + * Properties of an UpdateEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGetTagTemplateRequest - * @property {string|null} [name] GetTagTemplateRequest name + * @interface IUpdateEntryGroupRequest + * @property {google.cloud.datacatalog.v1beta1.IEntryGroup|null} [entryGroup] UpdateEntryGroupRequest entryGroup + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateEntryGroupRequest updateMask */ /** - * Constructs a new GetTagTemplateRequest. + * Constructs a new UpdateEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GetTagTemplateRequest. - * @implements IGetTagTemplateRequest + * @classdesc Represents an UpdateEntryGroupRequest. + * @implements IUpdateEntryGroupRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest=} [properties] Properties to set */ - function GetTagTemplateRequest(properties) { + function UpdateEntryGroupRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -35389,75 +36391,89 @@ } /** - * GetTagTemplateRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * UpdateEntryGroupRequest entryGroup. + * @member {google.cloud.datacatalog.v1beta1.IEntryGroup|null|undefined} entryGroup + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @instance */ - GetTagTemplateRequest.prototype.name = ""; + UpdateEntryGroupRequest.prototype.entryGroup = null; /** - * Creates a new GetTagTemplateRequest instance using the specified properties. + * UpdateEntryGroupRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest + * @instance + */ + UpdateEntryGroupRequest.prototype.updateMask = null; + + /** + * Creates a new UpdateEntryGroupRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest instance */ - GetTagTemplateRequest.create = function create(properties) { - return new GetTagTemplateRequest(properties); + UpdateEntryGroupRequest.create = function create(properties) { + return new UpdateEntryGroupRequest(properties); }; /** - * Encodes the specified GetTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTagTemplateRequest.verify|verify} messages. + * Encodes the specified UpdateEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} message GetTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} message UpdateEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTagTemplateRequest.encode = function encode(message, writer) { + UpdateEntryGroupRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.entryGroup != null && Object.hasOwnProperty.call(message, "entryGroup")) + $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroup, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified GetTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTagTemplateRequest.verify|verify} messages. + * Encodes the specified UpdateEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} message GetTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryGroupRequest} message UpdateEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { + UpdateEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetTagTemplateRequest message from the specified reader or buffer. + * Decodes an UpdateEntryGroupRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTagTemplateRequest.decode = function decode(reader, length) { + UpdateEntryGroupRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32()); + break; + } + case 2: { + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -35469,123 +36485,142 @@ }; /** - * Decodes a GetTagTemplateRequest message from the specified reader or buffer, length delimited. + * Decodes an UpdateEntryGroupRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { + UpdateEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetTagTemplateRequest message. + * Verifies an UpdateEntryGroupRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetTagTemplateRequest.verify = function verify(message) { + UpdateEntryGroupRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) { + var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroup); + if (error) + return "entryGroup." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; + } return null; }; /** - * Creates a GetTagTemplateRequest message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateEntryGroupRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} UpdateEntryGroupRequest */ - GetTagTemplateRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest) + UpdateEntryGroupRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest(); + if (object.entryGroup != null) { + if (typeof object.entryGroup !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.entryGroup: object expected"); + message.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroup); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + } return message; }; /** - * Creates a plain object from a GetTagTemplateRequest message. Also converts values to other types if specified. + * Creates a plain object from an UpdateEntryGroupRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} message GetTagTemplateRequest + * @param {google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest} message UpdateEntryGroupRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetTagTemplateRequest.toObject = function toObject(message, options) { + UpdateEntryGroupRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (options.defaults) { + object.entryGroup = null; + object.updateMask = null; + } + if (message.entryGroup != null && message.hasOwnProperty("entryGroup")) + object.entryGroup = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroup, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this GetTagTemplateRequest to JSON. + * Converts this UpdateEntryGroupRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @instance * @returns {Object.} JSON object */ - GetTagTemplateRequest.prototype.toJSON = function toJSON() { + UpdateEntryGroupRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetTagTemplateRequest + * Gets the default type url for UpdateEntryGroupRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetTagTemplateRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateEntryGroupRequest"; }; - return GetTagTemplateRequest; + return UpdateEntryGroupRequest; })(); - v1beta1.UpdateTagTemplateRequest = (function() { + v1beta1.GetEntryGroupRequest = (function() { /** - * Properties of an UpdateTagTemplateRequest. + * Properties of a GetEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateTagTemplateRequest - * @property {google.cloud.datacatalog.v1beta1.ITagTemplate|null} [tagTemplate] UpdateTagTemplateRequest tagTemplate - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagTemplateRequest updateMask + * @interface IGetEntryGroupRequest + * @property {string|null} [name] GetEntryGroupRequest name + * @property {google.protobuf.IFieldMask|null} [readMask] GetEntryGroupRequest readMask */ /** - * Constructs a new UpdateTagTemplateRequest. + * Constructs a new GetEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateTagTemplateRequest. - * @implements IUpdateTagTemplateRequest + * @classdesc Represents a GetEntryGroupRequest. + * @implements IGetEntryGroupRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest=} [properties] Properties to set */ - function UpdateTagTemplateRequest(properties) { + function GetEntryGroupRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -35593,89 +36628,89 @@ } /** - * UpdateTagTemplateRequest tagTemplate. - * @member {google.cloud.datacatalog.v1beta1.ITagTemplate|null|undefined} tagTemplate - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * GetEntryGroupRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @instance */ - UpdateTagTemplateRequest.prototype.tagTemplate = null; + GetEntryGroupRequest.prototype.name = ""; /** - * UpdateTagTemplateRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * GetEntryGroupRequest readMask. + * @member {google.protobuf.IFieldMask|null|undefined} readMask + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @instance */ - UpdateTagTemplateRequest.prototype.updateMask = null; + GetEntryGroupRequest.prototype.readMask = null; /** - * Creates a new UpdateTagTemplateRequest instance using the specified properties. + * Creates a new GetEntryGroupRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest instance */ - UpdateTagTemplateRequest.create = function create(properties) { - return new UpdateTagTemplateRequest(properties); + GetEntryGroupRequest.create = function create(properties) { + return new GetEntryGroupRequest(properties); }; /** - * Encodes the specified UpdateTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.verify|verify} messages. + * Encodes the specified GetEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} message UpdateTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} message GetEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagTemplateRequest.encode = function encode(message, writer) { + GetEntryGroupRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.tagTemplate != null && Object.hasOwnProperty.call(message, "tagTemplate")) - $root.google.cloud.datacatalog.v1beta1.TagTemplate.encode(message.tagTemplate, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) + $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified UpdateTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.verify|verify} messages. + * Encodes the specified GetEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} message UpdateTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetEntryGroupRequest} message GetEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { + GetEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateTagTemplateRequest message from the specified reader or buffer. + * Decodes a GetEntryGroupRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagTemplateRequest.decode = function decode(reader, length) { + GetEntryGroupRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.decode(reader, reader.uint32()); + message.name = reader.string(); break; } case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -35687,142 +36722,137 @@ }; /** - * Decodes an UpdateTagTemplateRequest message from the specified reader or buffer, length delimited. + * Decodes a GetEntryGroupRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { + GetEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateTagTemplateRequest message. + * Verifies a GetEntryGroupRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateTagTemplateRequest.verify = function verify(message) { + GetEntryGroupRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) { - var error = $root.google.cloud.datacatalog.v1beta1.TagTemplate.verify(message.tagTemplate); - if (error) - return "tagTemplate." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.readMask != null && message.hasOwnProperty("readMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.readMask); if (error) - return "updateMask." + error; + return "readMask." + error; } return null; }; /** - * Creates an UpdateTagTemplateRequest message from a plain object. Also converts values to their respective internal types. + * Creates a GetEntryGroupRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} GetEntryGroupRequest */ - UpdateTagTemplateRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest) + GetEntryGroupRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest(); - if (object.tagTemplate != null) { - if (typeof object.tagTemplate !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.tagTemplate: object expected"); - message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.fromObject(object.tagTemplate); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + var message = new $root.google.cloud.datacatalog.v1beta1.GetEntryGroupRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.readMask != null) { + if (typeof object.readMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.GetEntryGroupRequest.readMask: object expected"); + message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); } return message; }; /** - * Creates a plain object from an UpdateTagTemplateRequest message. Also converts values to other types if specified. + * Creates a plain object from a GetEntryGroupRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} message UpdateTagTemplateRequest + * @param {google.cloud.datacatalog.v1beta1.GetEntryGroupRequest} message GetEntryGroupRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateTagTemplateRequest.toObject = function toObject(message, options) { + GetEntryGroupRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.tagTemplate = null; - object.updateMask = null; + object.name = ""; + object.readMask = null; } - if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) - object.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.toObject(message.tagTemplate, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.readMask != null && message.hasOwnProperty("readMask")) + object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); return object; }; /** - * Converts this UpdateTagTemplateRequest to JSON. + * Converts this GetEntryGroupRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @instance * @returns {Object.} JSON object */ - UpdateTagTemplateRequest.prototype.toJSON = function toJSON() { + GetEntryGroupRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateTagTemplateRequest + * Gets the default type url for GetEntryGroupRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryGroupRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetEntryGroupRequest"; }; - return UpdateTagTemplateRequest; + return GetEntryGroupRequest; })(); - v1beta1.DeleteTagTemplateRequest = (function() { + v1beta1.DeleteEntryGroupRequest = (function() { /** - * Properties of a DeleteTagTemplateRequest. + * Properties of a DeleteEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteTagTemplateRequest - * @property {string|null} [name] DeleteTagTemplateRequest name - * @property {boolean|null} [force] DeleteTagTemplateRequest force + * @interface IDeleteEntryGroupRequest + * @property {string|null} [name] DeleteEntryGroupRequest name + * @property {boolean|null} [force] DeleteEntryGroupRequest force */ /** - * Constructs a new DeleteTagTemplateRequest. + * Constructs a new DeleteEntryGroupRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteTagTemplateRequest. - * @implements IDeleteTagTemplateRequest + * @classdesc Represents a DeleteEntryGroupRequest. + * @implements IDeleteEntryGroupRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest=} [properties] Properties to set */ - function DeleteTagTemplateRequest(properties) { + function DeleteEntryGroupRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -35830,43 +36860,43 @@ } /** - * DeleteTagTemplateRequest name. + * DeleteEntryGroupRequest name. * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @instance */ - DeleteTagTemplateRequest.prototype.name = ""; + DeleteEntryGroupRequest.prototype.name = ""; /** - * DeleteTagTemplateRequest force. + * DeleteEntryGroupRequest force. * @member {boolean} force - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @instance */ - DeleteTagTemplateRequest.prototype.force = false; + DeleteEntryGroupRequest.prototype.force = false; /** - * Creates a new DeleteTagTemplateRequest instance using the specified properties. + * Creates a new DeleteEntryGroupRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest instance */ - DeleteTagTemplateRequest.create = function create(properties) { - return new DeleteTagTemplateRequest(properties); + DeleteEntryGroupRequest.create = function create(properties) { + return new DeleteEntryGroupRequest(properties); }; /** - * Encodes the specified DeleteTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest.verify|verify} messages. + * Encodes the specified DeleteEntryGroupRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} message DeleteTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} message DeleteEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagTemplateRequest.encode = function encode(message, writer) { + DeleteEntryGroupRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) @@ -35877,33 +36907,33 @@ }; /** - * Encodes the specified DeleteTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest.verify|verify} messages. + * Encodes the specified DeleteEntryGroupRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} message DeleteTagTemplateRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryGroupRequest} message DeleteEntryGroupRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { + DeleteEntryGroupRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteTagTemplateRequest message from the specified reader or buffer. + * Decodes a DeleteEntryGroupRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagTemplateRequest.decode = function decode(reader, length) { + DeleteEntryGroupRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -35924,30 +36954,30 @@ }; /** - * Decodes a DeleteTagTemplateRequest message from the specified reader or buffer, length delimited. + * Decodes a DeleteEntryGroupRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { + DeleteEntryGroupRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteTagTemplateRequest message. + * Verifies a DeleteEntryGroupRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteTagTemplateRequest.verify = function verify(message) { + DeleteEntryGroupRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) @@ -35960,17 +36990,17 @@ }; /** - * Creates a DeleteTagTemplateRequest message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteEntryGroupRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} DeleteEntryGroupRequest */ - DeleteTagTemplateRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest) + DeleteEntryGroupRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest(); if (object.name != null) message.name = String(object.name); if (object.force != null) @@ -35979,15 +37009,15 @@ }; /** - * Creates a plain object from a DeleteTagTemplateRequest message. Also converts values to other types if specified. + * Creates a plain object from a DeleteEntryGroupRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} message DeleteTagTemplateRequest + * @param {google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest} message DeleteEntryGroupRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteTagTemplateRequest.toObject = function toObject(message, options) { + DeleteEntryGroupRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -36003,53 +37033,54 @@ }; /** - * Converts this DeleteTagTemplateRequest to JSON. + * Converts this DeleteEntryGroupRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @instance * @returns {Object.} JSON object */ - DeleteTagTemplateRequest.prototype.toJSON = function toJSON() { + DeleteEntryGroupRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteTagTemplateRequest + * Gets the default type url for DeleteEntryGroupRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteEntryGroupRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteEntryGroupRequest"; }; - return DeleteTagTemplateRequest; + return DeleteEntryGroupRequest; })(); - v1beta1.CreateTagRequest = (function() { + v1beta1.ListEntryGroupsRequest = (function() { /** - * Properties of a CreateTagRequest. + * Properties of a ListEntryGroupsRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateTagRequest - * @property {string|null} [parent] CreateTagRequest parent - * @property {google.cloud.datacatalog.v1beta1.ITag|null} [tag] CreateTagRequest tag + * @interface IListEntryGroupsRequest + * @property {string|null} [parent] ListEntryGroupsRequest parent + * @property {number|null} [pageSize] ListEntryGroupsRequest pageSize + * @property {string|null} [pageToken] ListEntryGroupsRequest pageToken */ /** - * Constructs a new CreateTagRequest. + * Constructs a new ListEntryGroupsRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateTagRequest. - * @implements ICreateTagRequest + * @classdesc Represents a ListEntryGroupsRequest. + * @implements IListEntryGroupsRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest=} [properties] Properties to set */ - function CreateTagRequest(properties) { + function ListEntryGroupsRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -36057,80 +37088,90 @@ } /** - * CreateTagRequest parent. + * ListEntryGroupsRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @instance */ - CreateTagRequest.prototype.parent = ""; + ListEntryGroupsRequest.prototype.parent = ""; /** - * CreateTagRequest tag. - * @member {google.cloud.datacatalog.v1beta1.ITag|null|undefined} tag - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * ListEntryGroupsRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @instance */ - CreateTagRequest.prototype.tag = null; + ListEntryGroupsRequest.prototype.pageSize = 0; /** - * Creates a new CreateTagRequest instance using the specified properties. + * ListEntryGroupsRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest + * @instance + */ + ListEntryGroupsRequest.prototype.pageToken = ""; + + /** + * Creates a new ListEntryGroupsRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest instance */ - CreateTagRequest.create = function create(properties) { - return new CreateTagRequest(properties); + ListEntryGroupsRequest.create = function create(properties) { + return new ListEntryGroupsRequest(properties); }; /** - * Encodes the specified CreateTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagRequest.verify|verify} messages. + * Encodes the specified ListEntryGroupsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} message CreateTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} message ListEntryGroupsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagRequest.encode = function encode(message, writer) { + ListEntryGroupsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.tag != null && Object.hasOwnProperty.call(message, "tag")) - $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); return writer; }; /** - * Encodes the specified CreateTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagRequest.verify|verify} messages. + * Encodes the specified ListEntryGroupsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} message CreateTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsRequest} message ListEntryGroupsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListEntryGroupsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateTagRequest message from the specified reader or buffer. + * Decodes a ListEntryGroupsRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagRequest.decode = function decode(reader, length) { + ListEntryGroupsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -36139,7 +37180,11 @@ break; } case 2: { - message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32()); + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); break; } default: @@ -36151,137 +37196,141 @@ }; /** - * Decodes a CreateTagRequest message from the specified reader or buffer, length delimited. + * Decodes a ListEntryGroupsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagRequest.decodeDelimited = function decodeDelimited(reader) { + ListEntryGroupsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateTagRequest message. + * Verifies a ListEntryGroupsRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateTagRequest.verify = function verify(message) { + ListEntryGroupsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.tag != null && message.hasOwnProperty("tag")) { - var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tag); - if (error) - return "tag." + error; - } + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; return null; }; /** - * Creates a CreateTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntryGroupsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} ListEntryGroupsRequest */ - CreateTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagRequest) + ListEntryGroupsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.tag != null) { - if (typeof object.tag !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagRequest.tag: object expected"); - message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tag); - } + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); return message; }; /** - * Creates a plain object from a CreateTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListEntryGroupsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.CreateTagRequest} message CreateTagRequest + * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest} message ListEntryGroupsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreateTagRequest.toObject = function toObject(message, options) { + ListEntryGroupsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.parent = ""; - object.tag = null; + object.pageSize = 0; + object.pageToken = ""; } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.tag != null && message.hasOwnProperty("tag")) - object.tag = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tag, options); + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; return object; }; /** - * Converts this CreateTagRequest to JSON. + * Converts this ListEntryGroupsRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @instance * @returns {Object.} JSON object */ - CreateTagRequest.prototype.toJSON = function toJSON() { + ListEntryGroupsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreateTagRequest + * Gets the default type url for ListEntryGroupsRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreateTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntryGroupsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntryGroupsRequest"; }; - return CreateTagRequest; + return ListEntryGroupsRequest; })(); - v1beta1.UpdateTagRequest = (function() { + v1beta1.ListEntryGroupsResponse = (function() { /** - * Properties of an UpdateTagRequest. + * Properties of a ListEntryGroupsResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateTagRequest - * @property {google.cloud.datacatalog.v1beta1.ITag|null} [tag] UpdateTagRequest tag - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagRequest updateMask + * @interface IListEntryGroupsResponse + * @property {Array.|null} [entryGroups] ListEntryGroupsResponse entryGroups + * @property {string|null} [nextPageToken] ListEntryGroupsResponse nextPageToken */ /** - * Constructs a new UpdateTagRequest. + * Constructs a new ListEntryGroupsResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateTagRequest. - * @implements IUpdateTagRequest + * @classdesc Represents a ListEntryGroupsResponse. + * @implements IListEntryGroupsResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse=} [properties] Properties to set */ - function UpdateTagRequest(properties) { + function ListEntryGroupsResponse(properties) { + this.entryGroups = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -36289,89 +37338,92 @@ } /** - * UpdateTagRequest tag. - * @member {google.cloud.datacatalog.v1beta1.ITag|null|undefined} tag - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * ListEntryGroupsResponse entryGroups. + * @member {Array.} entryGroups + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @instance */ - UpdateTagRequest.prototype.tag = null; + ListEntryGroupsResponse.prototype.entryGroups = $util.emptyArray; /** - * UpdateTagRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * ListEntryGroupsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @instance */ - UpdateTagRequest.prototype.updateMask = null; + ListEntryGroupsResponse.prototype.nextPageToken = ""; /** - * Creates a new UpdateTagRequest instance using the specified properties. + * Creates a new ListEntryGroupsResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse instance */ - UpdateTagRequest.create = function create(properties) { - return new UpdateTagRequest(properties); + ListEntryGroupsResponse.create = function create(properties) { + return new ListEntryGroupsResponse(properties); }; /** - * Encodes the specified UpdateTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagRequest.verify|verify} messages. + * Encodes the specified ListEntryGroupsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} message UpdateTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse} message ListEntryGroupsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagRequest.encode = function encode(message, writer) { + ListEntryGroupsResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.tag != null && Object.hasOwnProperty.call(message, "tag")) - $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.entryGroups != null && message.entryGroups.length) + for (var i = 0; i < message.entryGroups.length; ++i) + $root.google.cloud.datacatalog.v1beta1.EntryGroup.encode(message.entryGroups[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); return writer; }; /** - * Encodes the specified UpdateTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagRequest.verify|verify} messages. + * Encodes the specified ListEntryGroupsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} message UpdateTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntryGroupsResponse} message ListEntryGroupsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListEntryGroupsResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateTagRequest message from the specified reader or buffer. + * Decodes a ListEntryGroupsResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagRequest.decode = function decode(reader, length) { + ListEntryGroupsResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32()); + if (!(message.entryGroups && message.entryGroups.length)) + message.entryGroups = []; + message.entryGroups.push($root.google.cloud.datacatalog.v1beta1.EntryGroup.decode(reader, reader.uint32())); break; } case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + message.nextPageToken = reader.string(); break; } default: @@ -36383,141 +37435,150 @@ }; /** - * Decodes an UpdateTagRequest message from the specified reader or buffer, length delimited. + * Decodes a ListEntryGroupsResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagRequest.decodeDelimited = function decodeDelimited(reader) { + ListEntryGroupsResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateTagRequest message. + * Verifies a ListEntryGroupsResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateTagRequest.verify = function verify(message) { + ListEntryGroupsResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.tag != null && message.hasOwnProperty("tag")) { - var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tag); - if (error) - return "tag." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; + if (message.entryGroups != null && message.hasOwnProperty("entryGroups")) { + if (!Array.isArray(message.entryGroups)) + return "entryGroups: array expected"; + for (var i = 0; i < message.entryGroups.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.EntryGroup.verify(message.entryGroups[i]); + if (error) + return "entryGroups." + error; + } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates an UpdateTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntryGroupsResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest + * @returns {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} ListEntryGroupsResponse */ - UpdateTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest) + ListEntryGroupsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest(); - if (object.tag != null) { - if (typeof object.tag !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagRequest.tag: object expected"); - message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tag); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + var message = new $root.google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse(); + if (object.entryGroups) { + if (!Array.isArray(object.entryGroups)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.entryGroups: array expected"); + message.entryGroups = []; + for (var i = 0; i < object.entryGroups.length; ++i) { + if (typeof object.entryGroups[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse.entryGroups: object expected"); + message.entryGroups[i] = $root.google.cloud.datacatalog.v1beta1.EntryGroup.fromObject(object.entryGroups[i]); + } } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from an UpdateTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListEntryGroupsResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateTagRequest} message UpdateTagRequest + * @param {google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse} message ListEntryGroupsResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateTagRequest.toObject = function toObject(message, options) { + ListEntryGroupsResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.tag = null; - object.updateMask = null; + if (options.arrays || options.defaults) + object.entryGroups = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.entryGroups && message.entryGroups.length) { + object.entryGroups = []; + for (var j = 0; j < message.entryGroups.length; ++j) + object.entryGroups[j] = $root.google.cloud.datacatalog.v1beta1.EntryGroup.toObject(message.entryGroups[j], options); } - if (message.tag != null && message.hasOwnProperty("tag")) - object.tag = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tag, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this UpdateTagRequest to JSON. + * Converts this ListEntryGroupsResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @instance * @returns {Object.} JSON object */ - UpdateTagRequest.prototype.toJSON = function toJSON() { + ListEntryGroupsResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateTagRequest + * Gets the default type url for ListEntryGroupsResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @memberof google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntryGroupsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntryGroupsResponse"; }; - return UpdateTagRequest; + return ListEntryGroupsResponse; })(); - v1beta1.DeleteTagRequest = (function() { + v1beta1.CreateEntryRequest = (function() { /** - * Properties of a DeleteTagRequest. + * Properties of a CreateEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteTagRequest - * @property {string|null} [name] DeleteTagRequest name + * @interface ICreateEntryRequest + * @property {string|null} [parent] CreateEntryRequest parent + * @property {string|null} [entryId] CreateEntryRequest entryId + * @property {google.cloud.datacatalog.v1beta1.IEntry|null} [entry] CreateEntryRequest entry */ /** - * Constructs a new DeleteTagRequest. + * Constructs a new CreateEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteTagRequest. - * @implements IDeleteTagRequest + * @classdesc Represents a CreateEntryRequest. + * @implements ICreateEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest=} [properties] Properties to set */ - function DeleteTagRequest(properties) { + function CreateEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -36525,75 +37586,103 @@ } /** - * DeleteTagRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * CreateEntryRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @instance */ - DeleteTagRequest.prototype.name = ""; + CreateEntryRequest.prototype.parent = ""; /** - * Creates a new DeleteTagRequest instance using the specified properties. + * CreateEntryRequest entryId. + * @member {string} entryId + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest + * @instance + */ + CreateEntryRequest.prototype.entryId = ""; + + /** + * CreateEntryRequest entry. + * @member {google.cloud.datacatalog.v1beta1.IEntry|null|undefined} entry + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest + * @instance + */ + CreateEntryRequest.prototype.entry = null; + + /** + * Creates a new CreateEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest instance */ - DeleteTagRequest.create = function create(properties) { - return new DeleteTagRequest(properties); + CreateEntryRequest.create = function create(properties) { + return new CreateEntryRequest(properties); }; /** - * Encodes the specified DeleteTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagRequest.verify|verify} messages. + * Encodes the specified CreateEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} message DeleteTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} message CreateEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagRequest.encode = function encode(message, writer) { + CreateEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.entry != null && Object.hasOwnProperty.call(message, "entry")) + $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entry, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.entryId != null && Object.hasOwnProperty.call(message, "entryId")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.entryId); return writer; }; /** - * Encodes the specified DeleteTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagRequest.verify|verify} messages. + * Encodes the specified CreateEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} message DeleteTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateEntryRequest} message CreateEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + CreateEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteTagRequest message from the specified reader or buffer. + * Decodes a CreateEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagRequest.decode = function decode(reader, length) { + CreateEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.parent = reader.string(); + break; + } + case 3: { + message.entryId = reader.string(); + break; + } + case 2: { + message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32()); break; } default: @@ -36605,124 +37694,145 @@ }; /** - * Decodes a DeleteTagRequest message from the specified reader or buffer, length delimited. + * Decodes a CreateEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagRequest.decodeDelimited = function decodeDelimited(reader) { + CreateEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteTagRequest message. + * Verifies a CreateEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteTagRequest.verify = function verify(message) { + CreateEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.entryId != null && message.hasOwnProperty("entryId")) + if (!$util.isString(message.entryId)) + return "entryId: string expected"; + if (message.entry != null && message.hasOwnProperty("entry")) { + var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entry); + if (error) + return "entry." + error; + } return null; }; /** - * Creates a DeleteTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a CreateEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateEntryRequest} CreateEntryRequest */ - DeleteTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest) + CreateEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1beta1.CreateEntryRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.entryId != null) + message.entryId = String(object.entryId); + if (object.entry != null) { + if (typeof object.entry !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateEntryRequest.entry: object expected"); + message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entry); + } return message; }; /** - * Creates a plain object from a DeleteTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a CreateEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteTagRequest} message DeleteTagRequest + * @param {google.cloud.datacatalog.v1beta1.CreateEntryRequest} message CreateEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteTagRequest.toObject = function toObject(message, options) { + CreateEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (options.defaults) { + object.parent = ""; + object.entry = null; + object.entryId = ""; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.entry != null && message.hasOwnProperty("entry")) + object.entry = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entry, options); + if (message.entryId != null && message.hasOwnProperty("entryId")) + object.entryId = message.entryId; return object; }; /** - * Converts this DeleteTagRequest to JSON. + * Converts this CreateEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @instance * @returns {Object.} JSON object */ - DeleteTagRequest.prototype.toJSON = function toJSON() { + CreateEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteTagRequest + * Gets the default type url for CreateEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateEntryRequest"; }; - return DeleteTagRequest; + return CreateEntryRequest; })(); - v1beta1.CreateTagTemplateFieldRequest = (function() { + v1beta1.UpdateEntryRequest = (function() { /** - * Properties of a CreateTagTemplateFieldRequest. + * Properties of an UpdateEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateTagTemplateFieldRequest - * @property {string|null} [parent] CreateTagTemplateFieldRequest parent - * @property {string|null} [tagTemplateFieldId] CreateTagTemplateFieldRequest tagTemplateFieldId - * @property {google.cloud.datacatalog.v1beta1.ITagTemplateField|null} [tagTemplateField] CreateTagTemplateFieldRequest tagTemplateField + * @interface IUpdateEntryRequest + * @property {google.cloud.datacatalog.v1beta1.IEntry|null} [entry] UpdateEntryRequest entry + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateEntryRequest updateMask */ /** - * Constructs a new CreateTagTemplateFieldRequest. + * Constructs a new UpdateEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateTagTemplateFieldRequest. - * @implements ICreateTagTemplateFieldRequest + * @classdesc Represents an UpdateEntryRequest. + * @implements IUpdateEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest=} [properties] Properties to set */ - function CreateTagTemplateFieldRequest(properties) { + function UpdateEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -36730,103 +37840,89 @@ } /** - * CreateTagTemplateFieldRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest - * @instance - */ - CreateTagTemplateFieldRequest.prototype.parent = ""; - - /** - * CreateTagTemplateFieldRequest tagTemplateFieldId. - * @member {string} tagTemplateFieldId - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * UpdateEntryRequest entry. + * @member {google.cloud.datacatalog.v1beta1.IEntry|null|undefined} entry + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @instance */ - CreateTagTemplateFieldRequest.prototype.tagTemplateFieldId = ""; + UpdateEntryRequest.prototype.entry = null; /** - * CreateTagTemplateFieldRequest tagTemplateField. - * @member {google.cloud.datacatalog.v1beta1.ITagTemplateField|null|undefined} tagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * UpdateEntryRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @instance */ - CreateTagTemplateFieldRequest.prototype.tagTemplateField = null; + UpdateEntryRequest.prototype.updateMask = null; /** - * Creates a new CreateTagTemplateFieldRequest instance using the specified properties. + * Creates a new UpdateEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest instance */ - CreateTagTemplateFieldRequest.create = function create(properties) { - return new CreateTagTemplateFieldRequest(properties); + UpdateEntryRequest.create = function create(properties) { + return new UpdateEntryRequest(properties); }; /** - * Encodes the specified CreateTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified UpdateEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} message UpdateEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagTemplateFieldRequest.encode = function encode(message, writer) { + UpdateEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.tagTemplateFieldId != null && Object.hasOwnProperty.call(message, "tagTemplateFieldId")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.tagTemplateFieldId); - if (message.tagTemplateField != null && Object.hasOwnProperty.call(message, "tagTemplateField")) - $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.tagTemplateField, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.entry != null && Object.hasOwnProperty.call(message, "entry")) + $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entry, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified CreateTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified UpdateEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateEntryRequest} message UpdateEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { + UpdateEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateTagTemplateFieldRequest message from the specified reader or buffer. + * Decodes an UpdateEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagTemplateFieldRequest.decode = function decode(reader, length) { + UpdateEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32()); break; } case 2: { - message.tagTemplateFieldId = reader.string(); - break; - } - case 3: { - message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -36838,146 +37934,141 @@ }; /** - * Decodes a CreateTagTemplateFieldRequest message from the specified reader or buffer, length delimited. + * Decodes an UpdateEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { + UpdateEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateTagTemplateFieldRequest message. + * Verifies an UpdateEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateTagTemplateFieldRequest.verify = function verify(message) { + UpdateEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.tagTemplateFieldId != null && message.hasOwnProperty("tagTemplateFieldId")) - if (!$util.isString(message.tagTemplateFieldId)) - return "tagTemplateFieldId: string expected"; - if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) { - var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.tagTemplateField); + if (message.entry != null && message.hasOwnProperty("entry")) { + var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entry); if (error) - return "tagTemplateField." + error; + return "entry." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates a CreateTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} UpdateEntryRequest */ - CreateTagTemplateFieldRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest) + UpdateEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.tagTemplateFieldId != null) - message.tagTemplateFieldId = String(object.tagTemplateFieldId); - if (object.tagTemplateField != null) { - if (typeof object.tagTemplateField !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.tagTemplateField: object expected"); - message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.tagTemplateField); + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateEntryRequest(); + if (object.entry != null) { + if (typeof object.entry !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryRequest.entry: object expected"); + message.entry = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entry); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateEntryRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from a CreateTagTemplateFieldRequest message. Also converts values to other types if specified. + * Creates a plain object from an UpdateEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest + * @param {google.cloud.datacatalog.v1beta1.UpdateEntryRequest} message UpdateEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreateTagTemplateFieldRequest.toObject = function toObject(message, options) { + UpdateEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.parent = ""; - object.tagTemplateFieldId = ""; - object.tagTemplateField = null; + object.entry = null; + object.updateMask = null; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.tagTemplateFieldId != null && message.hasOwnProperty("tagTemplateFieldId")) - object.tagTemplateFieldId = message.tagTemplateFieldId; - if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) - object.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.tagTemplateField, options); + if (message.entry != null && message.hasOwnProperty("entry")) + object.entry = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entry, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this CreateTagTemplateFieldRequest to JSON. + * Converts this UpdateEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @instance * @returns {Object.} JSON object */ - CreateTagTemplateFieldRequest.prototype.toJSON = function toJSON() { + UpdateEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreateTagTemplateFieldRequest + * Gets the default type url for UpdateEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.UpdateEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreateTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateEntryRequest"; }; - return CreateTagTemplateFieldRequest; + return UpdateEntryRequest; })(); - v1beta1.UpdateTagTemplateFieldRequest = (function() { + v1beta1.DeleteEntryRequest = (function() { /** - * Properties of an UpdateTagTemplateFieldRequest. + * Properties of a DeleteEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateTagTemplateFieldRequest - * @property {string|null} [name] UpdateTagTemplateFieldRequest name - * @property {google.cloud.datacatalog.v1beta1.ITagTemplateField|null} [tagTemplateField] UpdateTagTemplateFieldRequest tagTemplateField - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagTemplateFieldRequest updateMask + * @interface IDeleteEntryRequest + * @property {string|null} [name] DeleteEntryRequest name */ /** - * Constructs a new UpdateTagTemplateFieldRequest. + * Constructs a new DeleteEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateTagTemplateFieldRequest. - * @implements IUpdateTagTemplateFieldRequest + * @classdesc Represents a DeleteEntryRequest. + * @implements IDeleteEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest=} [properties] Properties to set */ - function UpdateTagTemplateFieldRequest(properties) { + function DeleteEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -36985,90 +38076,70 @@ } /** - * UpdateTagTemplateFieldRequest name. + * DeleteEntryRequest name. * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest - * @instance - */ - UpdateTagTemplateFieldRequest.prototype.name = ""; - - /** - * UpdateTagTemplateFieldRequest tagTemplateField. - * @member {google.cloud.datacatalog.v1beta1.ITagTemplateField|null|undefined} tagTemplateField - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest - * @instance - */ - UpdateTagTemplateFieldRequest.prototype.tagTemplateField = null; - - /** - * UpdateTagTemplateFieldRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @instance */ - UpdateTagTemplateFieldRequest.prototype.updateMask = null; + DeleteEntryRequest.prototype.name = ""; /** - * Creates a new UpdateTagTemplateFieldRequest instance using the specified properties. + * Creates a new DeleteEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest instance */ - UpdateTagTemplateFieldRequest.create = function create(properties) { - return new UpdateTagTemplateFieldRequest(properties); + DeleteEntryRequest.create = function create(properties) { + return new DeleteEntryRequest(properties); }; /** - * Encodes the specified UpdateTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified DeleteEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} message DeleteEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagTemplateFieldRequest.encode = function encode(message, writer) { + DeleteEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.tagTemplateField != null && Object.hasOwnProperty.call(message, "tagTemplateField")) - $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.tagTemplateField, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified UpdateTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified DeleteEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteEntryRequest} message DeleteEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { + DeleteEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateTagTemplateFieldRequest message from the specified reader or buffer. + * Decodes a DeleteEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagTemplateFieldRequest.decode = function decode(reader, length) { + DeleteEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -37076,14 +38147,6 @@ message.name = reader.string(); break; } - case 2: { - message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); - break; - } - case 3: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); - break; - } default: reader.skipType(tag & 7); break; @@ -37093,150 +38156,122 @@ }; /** - * Decodes an UpdateTagTemplateFieldRequest message from the specified reader or buffer, length delimited. + * Decodes a DeleteEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { + DeleteEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateTagTemplateFieldRequest message. + * Verifies a DeleteEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateTagTemplateFieldRequest.verify = function verify(message) { + DeleteEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; - if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) { - var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.tagTemplateField); - if (error) - return "tagTemplateField." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } return null; }; /** - * Creates an UpdateTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} DeleteEntryRequest */ - UpdateTagTemplateFieldRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest) + DeleteEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteEntryRequest(); if (object.name != null) message.name = String(object.name); - if (object.tagTemplateField != null) { - if (typeof object.tagTemplateField !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.tagTemplateField: object expected"); - message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.tagTemplateField); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } return message; }; /** - * Creates a plain object from an UpdateTagTemplateFieldRequest message. Also converts values to other types if specified. + * Creates a plain object from a DeleteEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest + * @param {google.cloud.datacatalog.v1beta1.DeleteEntryRequest} message DeleteEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateTagTemplateFieldRequest.toObject = function toObject(message, options) { + DeleteEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { + if (options.defaults) object.name = ""; - object.tagTemplateField = null; - object.updateMask = null; - } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) - object.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.tagTemplateField, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this UpdateTagTemplateFieldRequest to JSON. + * Converts this DeleteEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @instance * @returns {Object.} JSON object */ - UpdateTagTemplateFieldRequest.prototype.toJSON = function toJSON() { + DeleteEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateTagTemplateFieldRequest + * Gets the default type url for DeleteEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteEntryRequest"; }; - return UpdateTagTemplateFieldRequest; + return DeleteEntryRequest; })(); - v1beta1.RenameTagTemplateFieldRequest = (function() { + v1beta1.GetEntryRequest = (function() { /** - * Properties of a RenameTagTemplateFieldRequest. + * Properties of a GetEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IRenameTagTemplateFieldRequest - * @property {string|null} [name] RenameTagTemplateFieldRequest name - * @property {string|null} [newTagTemplateFieldId] RenameTagTemplateFieldRequest newTagTemplateFieldId + * @interface IGetEntryRequest + * @property {string|null} [name] GetEntryRequest name */ /** - * Constructs a new RenameTagTemplateFieldRequest. + * Constructs a new GetEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a RenameTagTemplateFieldRequest. - * @implements IRenameTagTemplateFieldRequest + * @classdesc Represents a GetEntryRequest. + * @implements IGetEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest=} [properties] Properties to set */ - function RenameTagTemplateFieldRequest(properties) { + function GetEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -37244,80 +38279,70 @@ } /** - * RenameTagTemplateFieldRequest name. + * GetEntryRequest name. * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest - * @instance - */ - RenameTagTemplateFieldRequest.prototype.name = ""; - - /** - * RenameTagTemplateFieldRequest newTagTemplateFieldId. - * @member {string} newTagTemplateFieldId - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @instance */ - RenameTagTemplateFieldRequest.prototype.newTagTemplateFieldId = ""; + GetEntryRequest.prototype.name = ""; /** - * Creates a new RenameTagTemplateFieldRequest instance using the specified properties. + * Creates a new GetEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest instance + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest instance */ - RenameTagTemplateFieldRequest.create = function create(properties) { - return new RenameTagTemplateFieldRequest(properties); + GetEntryRequest.create = function create(properties) { + return new GetEntryRequest(properties); }; /** - * Encodes the specified RenameTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified GetEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} message GetEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RenameTagTemplateFieldRequest.encode = function encode(message, writer) { + GetEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.newTagTemplateFieldId != null && Object.hasOwnProperty.call(message, "newTagTemplateFieldId")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.newTagTemplateFieldId); return writer; }; /** - * Encodes the specified RenameTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified GetEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetEntryRequest} message GetEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - RenameTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { + GetEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a RenameTagTemplateFieldRequest message from the specified reader or buffer. + * Decodes a GetEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RenameTagTemplateFieldRequest.decode = function decode(reader, length) { + GetEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -37325,10 +38350,6 @@ message.name = reader.string(); break; } - case 2: { - message.newTagTemplateFieldId = reader.string(); - break; - } default: reader.skipType(tag & 7); break; @@ -37338,132 +38359,123 @@ }; /** - * Decodes a RenameTagTemplateFieldRequest message from the specified reader or buffer, length delimited. + * Decodes a GetEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - RenameTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { + GetEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a RenameTagTemplateFieldRequest message. + * Verifies a GetEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - RenameTagTemplateFieldRequest.verify = function verify(message) { + GetEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; - if (message.newTagTemplateFieldId != null && message.hasOwnProperty("newTagTemplateFieldId")) - if (!$util.isString(message.newTagTemplateFieldId)) - return "newTagTemplateFieldId: string expected"; return null; }; /** - * Creates a RenameTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. + * Creates a GetEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.GetEntryRequest} GetEntryRequest */ - RenameTagTemplateFieldRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest) + GetEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.GetEntryRequest(); if (object.name != null) message.name = String(object.name); - if (object.newTagTemplateFieldId != null) - message.newTagTemplateFieldId = String(object.newTagTemplateFieldId); return message; }; /** - * Creates a plain object from a RenameTagTemplateFieldRequest message. Also converts values to other types if specified. + * Creates a plain object from a GetEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest + * @param {google.cloud.datacatalog.v1beta1.GetEntryRequest} message GetEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - RenameTagTemplateFieldRequest.toObject = function toObject(message, options) { + GetEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { + if (options.defaults) object.name = ""; - object.newTagTemplateFieldId = ""; - } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message.newTagTemplateFieldId != null && message.hasOwnProperty("newTagTemplateFieldId")) - object.newTagTemplateFieldId = message.newTagTemplateFieldId; return object; }; /** - * Converts this RenameTagTemplateFieldRequest to JSON. + * Converts this GetEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @instance * @returns {Object.} JSON object */ - RenameTagTemplateFieldRequest.prototype.toJSON = function toJSON() { + GetEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for RenameTagTemplateFieldRequest + * Gets the default type url for GetEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.GetEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - RenameTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetEntryRequest"; }; - return RenameTagTemplateFieldRequest; + return GetEntryRequest; })(); - v1beta1.DeleteTagTemplateFieldRequest = (function() { + v1beta1.LookupEntryRequest = (function() { /** - * Properties of a DeleteTagTemplateFieldRequest. + * Properties of a LookupEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteTagTemplateFieldRequest - * @property {string|null} [name] DeleteTagTemplateFieldRequest name - * @property {boolean|null} [force] DeleteTagTemplateFieldRequest force + * @interface ILookupEntryRequest + * @property {string|null} [linkedResource] LookupEntryRequest linkedResource + * @property {string|null} [sqlResource] LookupEntryRequest sqlResource */ /** - * Constructs a new DeleteTagTemplateFieldRequest. + * Constructs a new LookupEntryRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteTagTemplateFieldRequest. - * @implements IDeleteTagTemplateFieldRequest + * @classdesc Represents a LookupEntryRequest. + * @implements ILookupEntryRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest=} [properties] Properties to set */ - function DeleteTagTemplateFieldRequest(properties) { + function LookupEntryRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -37471,89 +38483,103 @@ } /** - * DeleteTagTemplateFieldRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * LookupEntryRequest linkedResource. + * @member {string|null|undefined} linkedResource + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @instance */ - DeleteTagTemplateFieldRequest.prototype.name = ""; + LookupEntryRequest.prototype.linkedResource = null; /** - * DeleteTagTemplateFieldRequest force. - * @member {boolean} force - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * LookupEntryRequest sqlResource. + * @member {string|null|undefined} sqlResource + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @instance */ - DeleteTagTemplateFieldRequest.prototype.force = false; + LookupEntryRequest.prototype.sqlResource = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * Creates a new DeleteTagTemplateFieldRequest instance using the specified properties. + * LookupEntryRequest targetName. + * @member {"linkedResource"|"sqlResource"|undefined} targetName + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest + * @instance + */ + Object.defineProperty(LookupEntryRequest.prototype, "targetName", { + get: $util.oneOfGetter($oneOfFields = ["linkedResource", "sqlResource"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new LookupEntryRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest instance + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest instance */ - DeleteTagTemplateFieldRequest.create = function create(properties) { - return new DeleteTagTemplateFieldRequest(properties); + LookupEntryRequest.create = function create(properties) { + return new LookupEntryRequest(properties); }; /** - * Encodes the specified DeleteTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified LookupEntryRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.LookupEntryRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} message LookupEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagTemplateFieldRequest.encode = function encode(message, writer) { + LookupEntryRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.force != null && Object.hasOwnProperty.call(message, "force")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.force); + if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.linkedResource); + if (message.sqlResource != null && Object.hasOwnProperty.call(message, "sqlResource")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.sqlResource); return writer; }; /** - * Encodes the specified DeleteTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest.verify|verify} messages. + * Encodes the specified LookupEntryRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.LookupEntryRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ILookupEntryRequest} message LookupEntryRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { + LookupEntryRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteTagTemplateFieldRequest message from the specified reader or buffer. + * Decodes a LookupEntryRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagTemplateFieldRequest.decode = function decode(reader, length) { + LookupEntryRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.linkedResource = reader.string(); break; } - case 2: { - message.force = reader.bool(); + case 3: { + message.sqlResource = reader.string(); break; } default: @@ -37565,133 +38591,152 @@ }; /** - * Decodes a DeleteTagTemplateFieldRequest message from the specified reader or buffer, length delimited. + * Decodes a LookupEntryRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { + LookupEntryRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteTagTemplateFieldRequest message. + * Verifies a LookupEntryRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteTagTemplateFieldRequest.verify = function verify(message) { + LookupEntryRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.force != null && message.hasOwnProperty("force")) - if (typeof message.force !== "boolean") - return "force: boolean expected"; + var properties = {}; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) { + properties.targetName = 1; + if (!$util.isString(message.linkedResource)) + return "linkedResource: string expected"; + } + if (message.sqlResource != null && message.hasOwnProperty("sqlResource")) { + if (properties.targetName === 1) + return "targetName: multiple values"; + properties.targetName = 1; + if (!$util.isString(message.sqlResource)) + return "sqlResource: string expected"; + } return null; }; /** - * Creates a DeleteTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. + * Creates a LookupEntryRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest + * @returns {google.cloud.datacatalog.v1beta1.LookupEntryRequest} LookupEntryRequest */ - DeleteTagTemplateFieldRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest) + LookupEntryRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest(); - if (object.name != null) - message.name = String(object.name); - if (object.force != null) - message.force = Boolean(object.force); + var message = new $root.google.cloud.datacatalog.v1beta1.LookupEntryRequest(); + if (object.linkedResource != null) + message.linkedResource = String(object.linkedResource); + if (object.sqlResource != null) + message.sqlResource = String(object.sqlResource); return message; }; /** - * Creates a plain object from a DeleteTagTemplateFieldRequest message. Also converts values to other types if specified. + * Creates a plain object from a LookupEntryRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest + * @param {google.cloud.datacatalog.v1beta1.LookupEntryRequest} message LookupEntryRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteTagTemplateFieldRequest.toObject = function toObject(message, options) { + LookupEntryRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.force = false; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) { + object.linkedResource = message.linkedResource; + if (options.oneofs) + object.targetName = "linkedResource"; + } + if (message.sqlResource != null && message.hasOwnProperty("sqlResource")) { + object.sqlResource = message.sqlResource; + if (options.oneofs) + object.targetName = "sqlResource"; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.force != null && message.hasOwnProperty("force")) - object.force = message.force; return object; }; /** - * Converts this DeleteTagTemplateFieldRequest to JSON. + * Converts this LookupEntryRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @instance * @returns {Object.} JSON object */ - DeleteTagTemplateFieldRequest.prototype.toJSON = function toJSON() { + LookupEntryRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteTagTemplateFieldRequest + * Gets the default type url for LookupEntryRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @memberof google.cloud.datacatalog.v1beta1.LookupEntryRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + LookupEntryRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.LookupEntryRequest"; }; - return DeleteTagTemplateFieldRequest; + return LookupEntryRequest; })(); - v1beta1.ListTagsRequest = (function() { + v1beta1.Entry = (function() { /** - * Properties of a ListTagsRequest. + * Properties of an Entry. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListTagsRequest - * @property {string|null} [parent] ListTagsRequest parent - * @property {number|null} [pageSize] ListTagsRequest pageSize - * @property {string|null} [pageToken] ListTagsRequest pageToken + * @interface IEntry + * @property {string|null} [name] Entry name + * @property {string|null} [linkedResource] Entry linkedResource + * @property {google.cloud.datacatalog.v1beta1.EntryType|null} [type] Entry type + * @property {string|null} [userSpecifiedType] Entry userSpecifiedType + * @property {google.cloud.datacatalog.v1beta1.IntegratedSystem|null} [integratedSystem] Entry integratedSystem + * @property {string|null} [userSpecifiedSystem] Entry userSpecifiedSystem + * @property {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec|null} [gcsFilesetSpec] Entry gcsFilesetSpec + * @property {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec|null} [bigqueryTableSpec] Entry bigqueryTableSpec + * @property {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec|null} [bigqueryDateShardedSpec] Entry bigqueryDateShardedSpec + * @property {string|null} [displayName] Entry displayName + * @property {string|null} [description] Entry description + * @property {google.cloud.datacatalog.v1beta1.ISchema|null} [schema] Entry schema + * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [sourceSystemTimestamps] Entry sourceSystemTimestamps */ /** - * Constructs a new ListTagsRequest. + * Constructs a new Entry. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListTagsRequest. - * @implements IListTagsRequest + * @classdesc Represents an Entry. + * @implements IEntry * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IEntry=} [properties] Properties to set */ - function ListTagsRequest(properties) { + function Entry(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -37699,249 +38744,629 @@ } /** - * ListTagsRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * Entry name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.Entry * @instance */ - ListTagsRequest.prototype.parent = ""; + Entry.prototype.name = ""; /** - * ListTagsRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * Entry linkedResource. + * @member {string} linkedResource + * @memberof google.cloud.datacatalog.v1beta1.Entry * @instance */ - ListTagsRequest.prototype.pageSize = 0; + Entry.prototype.linkedResource = ""; /** - * ListTagsRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * Entry type. + * @member {google.cloud.datacatalog.v1beta1.EntryType|null|undefined} type + * @memberof google.cloud.datacatalog.v1beta1.Entry * @instance */ - ListTagsRequest.prototype.pageToken = ""; + Entry.prototype.type = null; /** - * Creates a new ListTagsRequest instance using the specified properties. + * Entry userSpecifiedType. + * @member {string|null|undefined} userSpecifiedType + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.userSpecifiedType = null; + + /** + * Entry integratedSystem. + * @member {google.cloud.datacatalog.v1beta1.IntegratedSystem|null|undefined} integratedSystem + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.integratedSystem = null; + + /** + * Entry userSpecifiedSystem. + * @member {string|null|undefined} userSpecifiedSystem + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.userSpecifiedSystem = null; + + /** + * Entry gcsFilesetSpec. + * @member {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec|null|undefined} gcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.gcsFilesetSpec = null; + + /** + * Entry bigqueryTableSpec. + * @member {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec|null|undefined} bigqueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.bigqueryTableSpec = null; + + /** + * Entry bigqueryDateShardedSpec. + * @member {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec|null|undefined} bigqueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.bigqueryDateShardedSpec = null; + + /** + * Entry displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.displayName = ""; + + /** + * Entry description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.description = ""; + + /** + * Entry schema. + * @member {google.cloud.datacatalog.v1beta1.ISchema|null|undefined} schema + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.schema = null; + + /** + * Entry sourceSystemTimestamps. + * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} sourceSystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Entry.prototype.sourceSystemTimestamps = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * Entry entryType. + * @member {"type"|"userSpecifiedType"|undefined} entryType + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Object.defineProperty(Entry.prototype, "entryType", { + get: $util.oneOfGetter($oneOfFields = ["type", "userSpecifiedType"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Entry system. + * @member {"integratedSystem"|"userSpecifiedSystem"|undefined} system + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Object.defineProperty(Entry.prototype, "system", { + get: $util.oneOfGetter($oneOfFields = ["integratedSystem", "userSpecifiedSystem"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Entry typeSpec. + * @member {"gcsFilesetSpec"|"bigqueryTableSpec"|"bigqueryDateShardedSpec"|undefined} typeSpec + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @instance + */ + Object.defineProperty(Entry.prototype, "typeSpec", { + get: $util.oneOfGetter($oneOfFields = ["gcsFilesetSpec", "bigqueryTableSpec", "bigqueryDateShardedSpec"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new Entry instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest instance + * @param {google.cloud.datacatalog.v1beta1.IEntry=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry instance */ - ListTagsRequest.create = function create(properties) { - return new ListTagsRequest(properties); + Entry.create = function create(properties) { + return new Entry(properties); }; /** - * Encodes the specified ListTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsRequest.verify|verify} messages. + * Encodes the specified Entry message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Entry.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} message ListTagsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IEntry} message Entry message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTagsRequest.encode = function encode(message, writer) { + Entry.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.type); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.description); + if (message.schema != null && Object.hasOwnProperty.call(message, "schema")) + $root.google.cloud.datacatalog.v1beta1.Schema.encode(message.schema, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.gcsFilesetSpec != null && Object.hasOwnProperty.call(message, "gcsFilesetSpec")) + $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.encode(message.gcsFilesetSpec, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.sourceSystemTimestamps != null && Object.hasOwnProperty.call(message, "sourceSystemTimestamps")) + $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.sourceSystemTimestamps, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) + writer.uint32(/* id 9, wireType 2 =*/74).string(message.linkedResource); + if (message.bigqueryTableSpec != null && Object.hasOwnProperty.call(message, "bigqueryTableSpec")) + $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.encode(message.bigqueryTableSpec, writer.uint32(/* id 12, wireType 2 =*/98).fork()).ldelim(); + if (message.bigqueryDateShardedSpec != null && Object.hasOwnProperty.call(message, "bigqueryDateShardedSpec")) + $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.encode(message.bigqueryDateShardedSpec, writer.uint32(/* id 15, wireType 2 =*/122).fork()).ldelim(); + if (message.userSpecifiedType != null && Object.hasOwnProperty.call(message, "userSpecifiedType")) + writer.uint32(/* id 16, wireType 2 =*/130).string(message.userSpecifiedType); + if (message.integratedSystem != null && Object.hasOwnProperty.call(message, "integratedSystem")) + writer.uint32(/* id 17, wireType 0 =*/136).int32(message.integratedSystem); + if (message.userSpecifiedSystem != null && Object.hasOwnProperty.call(message, "userSpecifiedSystem")) + writer.uint32(/* id 18, wireType 2 =*/146).string(message.userSpecifiedSystem); return writer; }; /** - * Encodes the specified ListTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsRequest.verify|verify} messages. + * Encodes the specified Entry message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Entry.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} message ListTagsRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IEntry} message Entry message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { + Entry.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTagsRequest message from the specified reader or buffer. + * Decodes an Entry message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest + * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTagsRequest.decode = function decode(reader, length) { + Entry.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTagsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Entry(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.name = reader.string(); + break; + } + case 9: { + message.linkedResource = reader.string(); break; } case 2: { - message.pageSize = reader.int32(); + message.type = reader.int32(); break; } - case 3: { - message.pageToken = reader.string(); + case 16: { + message.userSpecifiedType = reader.string(); break; } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a ListTagsRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest - * @throws {Error} If the payload is not a reader or valid buffer + case 17: { + message.integratedSystem = reader.int32(); + break; + } + case 18: { + message.userSpecifiedSystem = reader.string(); + break; + } + case 6: { + message.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.decode(reader, reader.uint32()); + break; + } + case 12: { + message.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.decode(reader, reader.uint32()); + break; + } + case 15: { + message.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.decode(reader, reader.uint32()); + break; + } + case 3: { + message.displayName = reader.string(); + break; + } + case 4: { + message.description = reader.string(); + break; + } + case 5: { + message.schema = $root.google.cloud.datacatalog.v1beta1.Schema.decode(reader, reader.uint32()); + break; + } + case 7: { + message.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an Entry message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.Entry + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry + * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTagsRequest.decodeDelimited = function decodeDelimited(reader) { + Entry.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTagsRequest message. + * Verifies an Entry message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTagsRequest.verify = function verify(message) { + Entry.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; + var properties = {}; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + if (!$util.isString(message.linkedResource)) + return "linkedResource: string expected"; + if (message.type != null && message.hasOwnProperty("type")) { + properties.entryType = 1; + switch (message.type) { + default: + return "type: enum value expected"; + case 0: + case 2: + case 5: + case 3: + case 4: + break; + } + } + if (message.userSpecifiedType != null && message.hasOwnProperty("userSpecifiedType")) { + if (properties.entryType === 1) + return "entryType: multiple values"; + properties.entryType = 1; + if (!$util.isString(message.userSpecifiedType)) + return "userSpecifiedType: string expected"; + } + if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { + properties.system = 1; + switch (message.integratedSystem) { + default: + return "integratedSystem: enum value expected"; + case 0: + case 1: + case 2: + break; + } + } + if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { + if (properties.system === 1) + return "system: multiple values"; + properties.system = 1; + if (!$util.isString(message.userSpecifiedSystem)) + return "userSpecifiedSystem: string expected"; + } + if (message.gcsFilesetSpec != null && message.hasOwnProperty("gcsFilesetSpec")) { + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify(message.gcsFilesetSpec); + if (error) + return "gcsFilesetSpec." + error; + } + } + if (message.bigqueryTableSpec != null && message.hasOwnProperty("bigqueryTableSpec")) { + if (properties.typeSpec === 1) + return "typeSpec: multiple values"; + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify(message.bigqueryTableSpec); + if (error) + return "bigqueryTableSpec." + error; + } + } + if (message.bigqueryDateShardedSpec != null && message.hasOwnProperty("bigqueryDateShardedSpec")) { + if (properties.typeSpec === 1) + return "typeSpec: multiple values"; + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify(message.bigqueryDateShardedSpec); + if (error) + return "bigqueryDateShardedSpec." + error; + } + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.schema != null && message.hasOwnProperty("schema")) { + var error = $root.google.cloud.datacatalog.v1beta1.Schema.verify(message.schema); + if (error) + return "schema." + error; + } + if (message.sourceSystemTimestamps != null && message.hasOwnProperty("sourceSystemTimestamps")) { + var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.sourceSystemTimestamps); + if (error) + return "sourceSystemTimestamps." + error; + } return null; }; /** - * Creates a ListTagsRequest message from a plain object. Also converts values to their respective internal types. + * Creates an Entry message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest + * @returns {google.cloud.datacatalog.v1beta1.Entry} Entry */ - ListTagsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTagsRequest) + Entry.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.Entry) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListTagsRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); + var message = new $root.google.cloud.datacatalog.v1beta1.Entry(); + if (object.name != null) + message.name = String(object.name); + if (object.linkedResource != null) + message.linkedResource = String(object.linkedResource); + switch (object.type) { + default: + if (typeof object.type === "number") { + message.type = object.type; + break; + } + break; + case "ENTRY_TYPE_UNSPECIFIED": + case 0: + message.type = 0; + break; + case "TABLE": + case 2: + message.type = 2; + break; + case "MODEL": + case 5: + message.type = 5; + break; + case "DATA_STREAM": + case 3: + message.type = 3; + break; + case "FILESET": + case 4: + message.type = 4; + break; + } + if (object.userSpecifiedType != null) + message.userSpecifiedType = String(object.userSpecifiedType); + switch (object.integratedSystem) { + default: + if (typeof object.integratedSystem === "number") { + message.integratedSystem = object.integratedSystem; + break; + } + break; + case "INTEGRATED_SYSTEM_UNSPECIFIED": + case 0: + message.integratedSystem = 0; + break; + case "BIGQUERY": + case 1: + message.integratedSystem = 1; + break; + case "CLOUD_PUBSUB": + case 2: + message.integratedSystem = 2; + break; + } + if (object.userSpecifiedSystem != null) + message.userSpecifiedSystem = String(object.userSpecifiedSystem); + if (object.gcsFilesetSpec != null) { + if (typeof object.gcsFilesetSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.gcsFilesetSpec: object expected"); + message.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.fromObject(object.gcsFilesetSpec); + } + if (object.bigqueryTableSpec != null) { + if (typeof object.bigqueryTableSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.bigqueryTableSpec: object expected"); + message.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.fromObject(object.bigqueryTableSpec); + } + if (object.bigqueryDateShardedSpec != null) { + if (typeof object.bigqueryDateShardedSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.bigqueryDateShardedSpec: object expected"); + message.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.fromObject(object.bigqueryDateShardedSpec); + } + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.schema != null) { + if (typeof object.schema !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.schema: object expected"); + message.schema = $root.google.cloud.datacatalog.v1beta1.Schema.fromObject(object.schema); + } + if (object.sourceSystemTimestamps != null) { + if (typeof object.sourceSystemTimestamps !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Entry.sourceSystemTimestamps: object expected"); + message.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.sourceSystemTimestamps); + } return message; }; /** - * Creates a plain object from a ListTagsRequest message. Also converts values to other types if specified. + * Creates a plain object from an Entry message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static - * @param {google.cloud.datacatalog.v1beta1.ListTagsRequest} message ListTagsRequest + * @param {google.cloud.datacatalog.v1beta1.Entry} message Entry * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTagsRequest.toObject = function toObject(message, options) { + Entry.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; + object.name = ""; + object.displayName = ""; + object.description = ""; + object.schema = null; + object.sourceSystemTimestamps = null; + object.linkedResource = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.type != null && message.hasOwnProperty("type")) { + object.type = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.EntryType[message.type] === undefined ? message.type : $root.google.cloud.datacatalog.v1beta1.EntryType[message.type] : message.type; + if (options.oneofs) + object.entryType = "type"; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.schema != null && message.hasOwnProperty("schema")) + object.schema = $root.google.cloud.datacatalog.v1beta1.Schema.toObject(message.schema, options); + if (message.gcsFilesetSpec != null && message.hasOwnProperty("gcsFilesetSpec")) { + object.gcsFilesetSpec = $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec.toObject(message.gcsFilesetSpec, options); + if (options.oneofs) + object.typeSpec = "gcsFilesetSpec"; + } + if (message.sourceSystemTimestamps != null && message.hasOwnProperty("sourceSystemTimestamps")) + object.sourceSystemTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.sourceSystemTimestamps, options); + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + object.linkedResource = message.linkedResource; + if (message.bigqueryTableSpec != null && message.hasOwnProperty("bigqueryTableSpec")) { + object.bigqueryTableSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec.toObject(message.bigqueryTableSpec, options); + if (options.oneofs) + object.typeSpec = "bigqueryTableSpec"; + } + if (message.bigqueryDateShardedSpec != null && message.hasOwnProperty("bigqueryDateShardedSpec")) { + object.bigqueryDateShardedSpec = $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.toObject(message.bigqueryDateShardedSpec, options); + if (options.oneofs) + object.typeSpec = "bigqueryDateShardedSpec"; + } + if (message.userSpecifiedType != null && message.hasOwnProperty("userSpecifiedType")) { + object.userSpecifiedType = message.userSpecifiedType; + if (options.oneofs) + object.entryType = "userSpecifiedType"; + } + if (message.integratedSystem != null && message.hasOwnProperty("integratedSystem")) { + object.integratedSystem = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.IntegratedSystem[message.integratedSystem] === undefined ? message.integratedSystem : $root.google.cloud.datacatalog.v1beta1.IntegratedSystem[message.integratedSystem] : message.integratedSystem; + if (options.oneofs) + object.system = "integratedSystem"; + } + if (message.userSpecifiedSystem != null && message.hasOwnProperty("userSpecifiedSystem")) { + object.userSpecifiedSystem = message.userSpecifiedSystem; + if (options.oneofs) + object.system = "userSpecifiedSystem"; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; return object; }; /** - * Converts this ListTagsRequest to JSON. + * Converts this Entry to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @instance * @returns {Object.} JSON object */ - ListTagsRequest.prototype.toJSON = function toJSON() { + Entry.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTagsRequest + * Gets the default type url for Entry * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest + * @memberof google.cloud.datacatalog.v1beta1.Entry * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Entry.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTagsRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Entry"; }; - return ListTagsRequest; + return Entry; })(); - v1beta1.ListTagsResponse = (function() { + v1beta1.EntryGroup = (function() { /** - * Properties of a ListTagsResponse. + * Properties of an EntryGroup. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListTagsResponse - * @property {Array.|null} [tags] ListTagsResponse tags - * @property {string|null} [nextPageToken] ListTagsResponse nextPageToken + * @interface IEntryGroup + * @property {string|null} [name] EntryGroup name + * @property {string|null} [displayName] EntryGroup displayName + * @property {string|null} [description] EntryGroup description + * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [dataCatalogTimestamps] EntryGroup dataCatalogTimestamps */ /** - * Constructs a new ListTagsResponse. + * Constructs a new EntryGroup. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListTagsResponse. - * @implements IListTagsResponse + * @classdesc Represents an EntryGroup. + * @implements IEntryGroup * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IEntryGroup=} [properties] Properties to set */ - function ListTagsResponse(properties) { - this.tags = []; + function EntryGroup(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -37949,92 +39374,117 @@ } /** - * ListTagsResponse tags. - * @member {Array.} tags - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * EntryGroup name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @instance */ - ListTagsResponse.prototype.tags = $util.emptyArray; + EntryGroup.prototype.name = ""; /** - * ListTagsResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * EntryGroup displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @instance */ - ListTagsResponse.prototype.nextPageToken = ""; + EntryGroup.prototype.displayName = ""; /** - * Creates a new ListTagsResponse instance using the specified properties. + * EntryGroup description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @instance + */ + EntryGroup.prototype.description = ""; + + /** + * EntryGroup dataCatalogTimestamps. + * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} dataCatalogTimestamps + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup + * @instance + */ + EntryGroup.prototype.dataCatalogTimestamps = null; + + /** + * Creates a new EntryGroup instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse instance + * @param {google.cloud.datacatalog.v1beta1.IEntryGroup=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup instance */ - ListTagsResponse.create = function create(properties) { - return new ListTagsResponse(properties); + EntryGroup.create = function create(properties) { + return new EntryGroup(properties); }; /** - * Encodes the specified ListTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsResponse.verify|verify} messages. + * Encodes the specified EntryGroup message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.EntryGroup.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse} message ListTagsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IEntryGroup} message EntryGroup message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTagsResponse.encode = function encode(message, writer) { + EntryGroup.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.tags != null && message.tags.length) - for (var i = 0; i < message.tags.length; ++i) - $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.dataCatalogTimestamps != null && Object.hasOwnProperty.call(message, "dataCatalogTimestamps")) + $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.dataCatalogTimestamps, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified ListTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsResponse.verify|verify} messages. + * Encodes the specified EntryGroup message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.EntryGroup.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static - * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse} message ListTagsResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IEntryGroup} message EntryGroup message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { + EntryGroup.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTagsResponse message from the specified reader or buffer. + * Decodes an EntryGroup message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse + * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTagsResponse.decode = function decode(reader, length) { + EntryGroup.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTagsResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.EntryGroup(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.tags && message.tags.length)) - message.tags = []; - message.tags.push($root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32())); + message.name = reader.string(); break; } case 2: { - message.nextPageToken = reader.string(); + message.displayName = reader.string(); + break; + } + case 3: { + message.description = reader.string(); + break; + } + case 4: { + message.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); break; } default: @@ -38046,151 +39496,154 @@ }; /** - * Decodes a ListTagsResponse message from the specified reader or buffer, length delimited. + * Decodes an EntryGroup message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse + * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTagsResponse.decodeDelimited = function decodeDelimited(reader) { + EntryGroup.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTagsResponse message. + * Verifies an EntryGroup message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTagsResponse.verify = function verify(message) { + EntryGroup.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.tags != null && message.hasOwnProperty("tags")) { - if (!Array.isArray(message.tags)) - return "tags: array expected"; - for (var i = 0; i < message.tags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tags[i]); - if (error) - return "tags." + error; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.dataCatalogTimestamps != null && message.hasOwnProperty("dataCatalogTimestamps")) { + var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.dataCatalogTimestamps); + if (error) + return "dataCatalogTimestamps." + error; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; return null; }; /** - * Creates a ListTagsResponse message from a plain object. Also converts values to their respective internal types. + * Creates an EntryGroup message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse + * @returns {google.cloud.datacatalog.v1beta1.EntryGroup} EntryGroup */ - ListTagsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTagsResponse) + EntryGroup.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.EntryGroup) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListTagsResponse(); - if (object.tags) { - if (!Array.isArray(object.tags)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ListTagsResponse.tags: array expected"); - message.tags = []; - for (var i = 0; i < object.tags.length; ++i) { - if (typeof object.tags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListTagsResponse.tags: object expected"); - message.tags[i] = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tags[i]); - } + var message = new $root.google.cloud.datacatalog.v1beta1.EntryGroup(); + if (object.name != null) + message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.dataCatalogTimestamps != null) { + if (typeof object.dataCatalogTimestamps !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.EntryGroup.dataCatalogTimestamps: object expected"); + message.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.dataCatalogTimestamps); } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a ListTagsResponse message. Also converts values to other types if specified. + * Creates a plain object from an EntryGroup message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static - * @param {google.cloud.datacatalog.v1beta1.ListTagsResponse} message ListTagsResponse + * @param {google.cloud.datacatalog.v1beta1.EntryGroup} message EntryGroup * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTagsResponse.toObject = function toObject(message, options) { + EntryGroup.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.tags = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.tags && message.tags.length) { - object.tags = []; - for (var j = 0; j < message.tags.length; ++j) - object.tags[j] = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tags[j], options); + if (options.defaults) { + object.name = ""; + object.displayName = ""; + object.description = ""; + object.dataCatalogTimestamps = null; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.dataCatalogTimestamps != null && message.hasOwnProperty("dataCatalogTimestamps")) + object.dataCatalogTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.dataCatalogTimestamps, options); return object; }; /** - * Converts this ListTagsResponse to JSON. + * Converts this EntryGroup to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @instance * @returns {Object.} JSON object */ - ListTagsResponse.prototype.toJSON = function toJSON() { + EntryGroup.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTagsResponse + * Gets the default type url for EntryGroup * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse + * @memberof google.cloud.datacatalog.v1beta1.EntryGroup * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + EntryGroup.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTagsResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.EntryGroup"; }; - return ListTagsResponse; + return EntryGroup; })(); - v1beta1.ListEntriesRequest = (function() { + v1beta1.CreateTagTemplateRequest = (function() { /** - * Properties of a ListEntriesRequest. + * Properties of a CreateTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListEntriesRequest - * @property {string|null} [parent] ListEntriesRequest parent - * @property {number|null} [pageSize] ListEntriesRequest pageSize - * @property {string|null} [pageToken] ListEntriesRequest pageToken - * @property {google.protobuf.IFieldMask|null} [readMask] ListEntriesRequest readMask + * @interface ICreateTagTemplateRequest + * @property {string|null} [parent] CreateTagTemplateRequest parent + * @property {string|null} [tagTemplateId] CreateTagTemplateRequest tagTemplateId + * @property {google.cloud.datacatalog.v1beta1.ITagTemplate|null} [tagTemplate] CreateTagTemplateRequest tagTemplate */ /** - * Constructs a new ListEntriesRequest. + * Constructs a new CreateTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListEntriesRequest. - * @implements IListEntriesRequest + * @classdesc Represents a CreateTagTemplateRequest. + * @implements ICreateTagTemplateRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest=} [properties] Properties to set */ - function ListEntriesRequest(properties) { + function CreateTagTemplateRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -38198,100 +39651,90 @@ } /** - * ListEntriesRequest parent. + * CreateTagTemplateRequest parent. * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest - * @instance - */ - ListEntriesRequest.prototype.parent = ""; - - /** - * ListEntriesRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @instance */ - ListEntriesRequest.prototype.pageSize = 0; + CreateTagTemplateRequest.prototype.parent = ""; /** - * ListEntriesRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * CreateTagTemplateRequest tagTemplateId. + * @member {string} tagTemplateId + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @instance */ - ListEntriesRequest.prototype.pageToken = ""; + CreateTagTemplateRequest.prototype.tagTemplateId = ""; /** - * ListEntriesRequest readMask. - * @member {google.protobuf.IFieldMask|null|undefined} readMask - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * CreateTagTemplateRequest tagTemplate. + * @member {google.cloud.datacatalog.v1beta1.ITagTemplate|null|undefined} tagTemplate + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @instance */ - ListEntriesRequest.prototype.readMask = null; + CreateTagTemplateRequest.prototype.tagTemplate = null; /** - * Creates a new ListEntriesRequest instance using the specified properties. + * Creates a new CreateTagTemplateRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest instance */ - ListEntriesRequest.create = function create(properties) { - return new ListEntriesRequest(properties); + CreateTagTemplateRequest.create = function create(properties) { + return new CreateTagTemplateRequest(properties); }; /** - * Encodes the specified ListEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesRequest.verify|verify} messages. + * Encodes the specified CreateTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} message CreateTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesRequest.encode = function encode(message, writer) { + CreateTagTemplateRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); - if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) - $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.tagTemplate != null && Object.hasOwnProperty.call(message, "tagTemplate")) + $root.google.cloud.datacatalog.v1beta1.TagTemplate.encode(message.tagTemplate, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.tagTemplateId != null && Object.hasOwnProperty.call(message, "tagTemplateId")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.tagTemplateId); return writer; }; /** - * Encodes the specified ListEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesRequest.verify|verify} messages. + * Encodes the specified CreateTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateRequest} message CreateTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesRequest.encodeDelimited = function encodeDelimited(message, writer) { + CreateTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntriesRequest message from the specified reader or buffer. + * Decodes a CreateTagTemplateRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesRequest.decode = function decode(reader, length) { + CreateTagTemplateRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -38299,16 +39742,12 @@ message.parent = reader.string(); break; } - case 2: { - message.pageSize = reader.int32(); - break; - } case 3: { - message.pageToken = reader.string(); + message.tagTemplateId = reader.string(); break; } - case 4: { - message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + case 2: { + message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.decode(reader, reader.uint32()); break; } default: @@ -38320,154 +39759,144 @@ }; /** - * Decodes a ListEntriesRequest message from the specified reader or buffer, length delimited. + * Decodes a CreateTagTemplateRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesRequest.decodeDelimited = function decodeDelimited(reader) { + CreateTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntriesRequest message. + * Verifies a CreateTagTemplateRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntriesRequest.verify = function verify(message) { + CreateTagTemplateRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.parent != null && message.hasOwnProperty("parent")) if (!$util.isString(message.parent)) return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; - if (message.readMask != null && message.hasOwnProperty("readMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.readMask); + if (message.tagTemplateId != null && message.hasOwnProperty("tagTemplateId")) + if (!$util.isString(message.tagTemplateId)) + return "tagTemplateId: string expected"; + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) { + var error = $root.google.cloud.datacatalog.v1beta1.TagTemplate.verify(message.tagTemplate); if (error) - return "readMask." + error; + return "tagTemplate." + error; } return null; }; /** - * Creates a ListEntriesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a CreateTagTemplateRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} CreateTagTemplateRequest */ - ListEntriesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest) + CreateTagTemplateRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest(); if (object.parent != null) message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); - if (object.readMask != null) { - if (typeof object.readMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesRequest.readMask: object expected"); - message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); + if (object.tagTemplateId != null) + message.tagTemplateId = String(object.tagTemplateId); + if (object.tagTemplate != null) { + if (typeof object.tagTemplate !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest.tagTemplate: object expected"); + message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.fromObject(object.tagTemplate); } return message; }; /** - * Creates a plain object from a ListEntriesRequest message. Also converts values to other types if specified. + * Creates a plain object from a CreateTagTemplateRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ListEntriesRequest} message ListEntriesRequest + * @param {google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest} message CreateTagTemplateRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntriesRequest.toObject = function toObject(message, options) { + CreateTagTemplateRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; - object.readMask = null; + object.tagTemplate = null; + object.tagTemplateId = ""; } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; - if (message.readMask != null && message.hasOwnProperty("readMask")) - object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) + object.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.toObject(message.tagTemplate, options); + if (message.tagTemplateId != null && message.hasOwnProperty("tagTemplateId")) + object.tagTemplateId = message.tagTemplateId; return object; }; /** - * Converts this ListEntriesRequest to JSON. + * Converts this CreateTagTemplateRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @instance * @returns {Object.} JSON object */ - ListEntriesRequest.prototype.toJSON = function toJSON() { + CreateTagTemplateRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntriesRequest + * Gets the default type url for CreateTagTemplateRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntriesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntriesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagTemplateRequest"; }; - return ListEntriesRequest; + return CreateTagTemplateRequest; })(); - v1beta1.ListEntriesResponse = (function() { + v1beta1.GetTagTemplateRequest = (function() { /** - * Properties of a ListEntriesResponse. + * Properties of a GetTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListEntriesResponse - * @property {Array.|null} [entries] ListEntriesResponse entries - * @property {string|null} [nextPageToken] ListEntriesResponse nextPageToken + * @interface IGetTagTemplateRequest + * @property {string|null} [name] GetTagTemplateRequest name */ /** - * Constructs a new ListEntriesResponse. + * Constructs a new GetTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListEntriesResponse. - * @implements IListEntriesResponse + * @classdesc Represents a GetTagTemplateRequest. + * @implements IGetTagTemplateRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest=} [properties] Properties to set */ - function ListEntriesResponse(properties) { - this.entries = []; + function GetTagTemplateRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -38475,92 +39904,75 @@ } /** - * ListEntriesResponse entries. - * @member {Array.} entries - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse - * @instance - */ - ListEntriesResponse.prototype.entries = $util.emptyArray; - - /** - * ListEntriesResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * GetTagTemplateRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @instance */ - ListEntriesResponse.prototype.nextPageToken = ""; + GetTagTemplateRequest.prototype.name = ""; /** - * Creates a new ListEntriesResponse instance using the specified properties. + * Creates a new GetTagTemplateRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse instance + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest instance */ - ListEntriesResponse.create = function create(properties) { - return new ListEntriesResponse(properties); + GetTagTemplateRequest.create = function create(properties) { + return new GetTagTemplateRequest(properties); }; /** - * Encodes the specified ListEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesResponse.verify|verify} messages. + * Encodes the specified GetTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTagTemplateRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} message GetTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesResponse.encode = function encode(message, writer) { + GetTagTemplateRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.entries != null && message.entries.length) - for (var i = 0; i < message.entries.length; ++i) - $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entries[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified ListEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesResponse.verify|verify} messages. + * Encodes the specified GetTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTagTemplateRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetTagTemplateRequest} message GetTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListEntriesResponse.encodeDelimited = function encodeDelimited(message, writer) { + GetTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListEntriesResponse message from the specified reader or buffer. + * Decodes a GetTagTemplateRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesResponse.decode = function decode(reader, length) { + GetTagTemplateRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.entries && message.entries.length)) - message.entries = []; - message.entries.push($root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32())); - break; - } - case 2: { - message.nextPageToken = reader.string(); + message.name = reader.string(); break; } default: @@ -38572,171 +39984,123 @@ }; /** - * Decodes a ListEntriesResponse message from the specified reader or buffer, length delimited. + * Decodes a GetTagTemplateRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListEntriesResponse.decodeDelimited = function decodeDelimited(reader) { + GetTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListEntriesResponse message. + * Verifies a GetTagTemplateRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListEntriesResponse.verify = function verify(message) { + GetTagTemplateRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.entries != null && message.hasOwnProperty("entries")) { - if (!Array.isArray(message.entries)) - return "entries: array expected"; - for (var i = 0; i < message.entries.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entries[i]); - if (error) - return "entries." + error; - } - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates a ListEntriesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a GetTagTemplateRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} GetTagTemplateRequest */ - ListEntriesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse) + GetTagTemplateRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse(); - if (object.entries) { - if (!Array.isArray(object.entries)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesResponse.entries: array expected"); - message.entries = []; - for (var i = 0; i < object.entries.length; ++i) { - if (typeof object.entries[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesResponse.entries: object expected"); - message.entries[i] = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entries[i]); - } - } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); + var message = new $root.google.cloud.datacatalog.v1beta1.GetTagTemplateRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from a ListEntriesResponse message. Also converts values to other types if specified. + * Creates a plain object from a GetTagTemplateRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ListEntriesResponse} message ListEntriesResponse + * @param {google.cloud.datacatalog.v1beta1.GetTagTemplateRequest} message GetTagTemplateRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListEntriesResponse.toObject = function toObject(message, options) { + GetTagTemplateRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.entries = []; if (options.defaults) - object.nextPageToken = ""; - if (message.entries && message.entries.length) { - object.entries = []; - for (var j = 0; j < message.entries.length; ++j) - object.entries[j] = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entries[j], options); - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this ListEntriesResponse to JSON. + * Converts this GetTagTemplateRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @instance * @returns {Object.} JSON object */ - ListEntriesResponse.prototype.toJSON = function toJSON() { + GetTagTemplateRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListEntriesResponse + * Gets the default type url for GetTagTemplateRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTagTemplateRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListEntriesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntriesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetTagTemplateRequest"; }; - return ListEntriesResponse; - })(); - - /** - * EntryType enum. - * @name google.cloud.datacatalog.v1beta1.EntryType - * @enum {number} - * @property {number} ENTRY_TYPE_UNSPECIFIED=0 ENTRY_TYPE_UNSPECIFIED value - * @property {number} TABLE=2 TABLE value - * @property {number} MODEL=5 MODEL value - * @property {number} DATA_STREAM=3 DATA_STREAM value - * @property {number} FILESET=4 FILESET value - */ - v1beta1.EntryType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ENTRY_TYPE_UNSPECIFIED"] = 0; - values[valuesById[2] = "TABLE"] = 2; - values[valuesById[5] = "MODEL"] = 5; - values[valuesById[3] = "DATA_STREAM"] = 3; - values[valuesById[4] = "FILESET"] = 4; - return values; + return GetTagTemplateRequest; })(); - v1beta1.GcsFilesetSpec = (function() { + v1beta1.UpdateTagTemplateRequest = (function() { /** - * Properties of a GcsFilesetSpec. + * Properties of an UpdateTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGcsFilesetSpec - * @property {Array.|null} [filePatterns] GcsFilesetSpec filePatterns - * @property {Array.|null} [sampleGcsFileSpecs] GcsFilesetSpec sampleGcsFileSpecs + * @interface IUpdateTagTemplateRequest + * @property {google.cloud.datacatalog.v1beta1.ITagTemplate|null} [tagTemplate] UpdateTagTemplateRequest tagTemplate + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagTemplateRequest updateMask */ /** - * Constructs a new GcsFilesetSpec. + * Constructs a new UpdateTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GcsFilesetSpec. - * @implements IGcsFilesetSpec + * @classdesc Represents an UpdateTagTemplateRequest. + * @implements IUpdateTagTemplateRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest=} [properties] Properties to set */ - function GcsFilesetSpec(properties) { - this.filePatterns = []; - this.sampleGcsFileSpecs = []; + function UpdateTagTemplateRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -38744,95 +40108,89 @@ } /** - * GcsFilesetSpec filePatterns. - * @member {Array.} filePatterns - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * UpdateTagTemplateRequest tagTemplate. + * @member {google.cloud.datacatalog.v1beta1.ITagTemplate|null|undefined} tagTemplate + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @instance */ - GcsFilesetSpec.prototype.filePatterns = $util.emptyArray; + UpdateTagTemplateRequest.prototype.tagTemplate = null; /** - * GcsFilesetSpec sampleGcsFileSpecs. - * @member {Array.} sampleGcsFileSpecs - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * UpdateTagTemplateRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @instance */ - GcsFilesetSpec.prototype.sampleGcsFileSpecs = $util.emptyArray; + UpdateTagTemplateRequest.prototype.updateMask = null; /** - * Creates a new GcsFilesetSpec instance using the specified properties. + * Creates a new UpdateTagTemplateRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest instance */ - GcsFilesetSpec.create = function create(properties) { - return new GcsFilesetSpec(properties); + UpdateTagTemplateRequest.create = function create(properties) { + return new UpdateTagTemplateRequest(properties); }; /** - * Encodes the specified GcsFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify|verify} messages. + * Encodes the specified UpdateTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} message UpdateTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFilesetSpec.encode = function encode(message, writer) { + UpdateTagTemplateRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.filePatterns != null && message.filePatterns.length) - for (var i = 0; i < message.filePatterns.length; ++i) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePatterns[i]); - if (message.sampleGcsFileSpecs != null && message.sampleGcsFileSpecs.length) - for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) - $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.encode(message.sampleGcsFileSpecs[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.tagTemplate != null && Object.hasOwnProperty.call(message, "tagTemplate")) + $root.google.cloud.datacatalog.v1beta1.TagTemplate.encode(message.tagTemplate, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified GcsFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify|verify} messages. + * Encodes the specified UpdateTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateRequest} message UpdateTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { + UpdateTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GcsFilesetSpec message from the specified reader or buffer. + * Decodes an UpdateTagTemplateRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFilesetSpec.decode = function decode(reader, length) { + UpdateTagTemplateRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.filePatterns && message.filePatterns.length)) - message.filePatterns = []; - message.filePatterns.push(reader.string()); + message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.decode(reader, reader.uint32()); break; } case 2: { - if (!(message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length)) - message.sampleGcsFileSpecs = []; - message.sampleGcsFileSpecs.push($root.google.cloud.datacatalog.v1beta1.GcsFileSpec.decode(reader, reader.uint32())); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -38844,162 +40202,142 @@ }; /** - * Decodes a GcsFilesetSpec message from the specified reader or buffer, length delimited. + * Decodes an UpdateTagTemplateRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFilesetSpec.decodeDelimited = function decodeDelimited(reader) { + UpdateTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GcsFilesetSpec message. + * Verifies an UpdateTagTemplateRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GcsFilesetSpec.verify = function verify(message) { + UpdateTagTemplateRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.filePatterns != null && message.hasOwnProperty("filePatterns")) { - if (!Array.isArray(message.filePatterns)) - return "filePatterns: array expected"; - for (var i = 0; i < message.filePatterns.length; ++i) - if (!$util.isString(message.filePatterns[i])) - return "filePatterns: string[] expected"; + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) { + var error = $root.google.cloud.datacatalog.v1beta1.TagTemplate.verify(message.tagTemplate); + if (error) + return "tagTemplate." + error; } - if (message.sampleGcsFileSpecs != null && message.hasOwnProperty("sampleGcsFileSpecs")) { - if (!Array.isArray(message.sampleGcsFileSpecs)) - return "sampleGcsFileSpecs: array expected"; - for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.verify(message.sampleGcsFileSpecs[i]); - if (error) - return "sampleGcsFileSpecs." + error; - } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates a GcsFilesetSpec message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateTagTemplateRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} UpdateTagTemplateRequest */ - GcsFilesetSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec) + UpdateTagTemplateRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec(); - if (object.filePatterns) { - if (!Array.isArray(object.filePatterns)) - throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.filePatterns: array expected"); - message.filePatterns = []; - for (var i = 0; i < object.filePatterns.length; ++i) - message.filePatterns[i] = String(object.filePatterns[i]); + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest(); + if (object.tagTemplate != null) { + if (typeof object.tagTemplate !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.tagTemplate: object expected"); + message.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.fromObject(object.tagTemplate); } - if (object.sampleGcsFileSpecs) { - if (!Array.isArray(object.sampleGcsFileSpecs)) - throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.sampleGcsFileSpecs: array expected"); - message.sampleGcsFileSpecs = []; - for (var i = 0; i < object.sampleGcsFileSpecs.length; ++i) { - if (typeof object.sampleGcsFileSpecs[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.sampleGcsFileSpecs: object expected"); - message.sampleGcsFileSpecs[i] = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.fromObject(object.sampleGcsFileSpecs[i]); - } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from a GcsFilesetSpec message. Also converts values to other types if specified. + * Creates a plain object from an UpdateTagTemplateRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} message GcsFilesetSpec + * @param {google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest} message UpdateTagTemplateRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GcsFilesetSpec.toObject = function toObject(message, options) { + UpdateTagTemplateRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.filePatterns = []; - object.sampleGcsFileSpecs = []; - } - if (message.filePatterns && message.filePatterns.length) { - object.filePatterns = []; - for (var j = 0; j < message.filePatterns.length; ++j) - object.filePatterns[j] = message.filePatterns[j]; - } - if (message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length) { - object.sampleGcsFileSpecs = []; - for (var j = 0; j < message.sampleGcsFileSpecs.length; ++j) - object.sampleGcsFileSpecs[j] = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.toObject(message.sampleGcsFileSpecs[j], options); + if (options.defaults) { + object.tagTemplate = null; + object.updateMask = null; } + if (message.tagTemplate != null && message.hasOwnProperty("tagTemplate")) + object.tagTemplate = $root.google.cloud.datacatalog.v1beta1.TagTemplate.toObject(message.tagTemplate, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this GcsFilesetSpec to JSON. + * Converts this UpdateTagTemplateRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @instance * @returns {Object.} JSON object */ - GcsFilesetSpec.prototype.toJSON = function toJSON() { + UpdateTagTemplateRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GcsFilesetSpec + * Gets the default type url for UpdateTagTemplateRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GcsFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GcsFilesetSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagTemplateRequest"; }; - return GcsFilesetSpec; + return UpdateTagTemplateRequest; })(); - v1beta1.GcsFileSpec = (function() { + v1beta1.DeleteTagTemplateRequest = (function() { /** - * Properties of a GcsFileSpec. + * Properties of a DeleteTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGcsFileSpec - * @property {string|null} [filePath] GcsFileSpec filePath - * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [gcsTimestamps] GcsFileSpec gcsTimestamps - * @property {number|Long|null} [sizeBytes] GcsFileSpec sizeBytes + * @interface IDeleteTagTemplateRequest + * @property {string|null} [name] DeleteTagTemplateRequest name + * @property {boolean|null} [force] DeleteTagTemplateRequest force */ /** - * Constructs a new GcsFileSpec. + * Constructs a new DeleteTagTemplateRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GcsFileSpec. - * @implements IGcsFileSpec + * @classdesc Represents a DeleteTagTemplateRequest. + * @implements IDeleteTagTemplateRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest=} [properties] Properties to set */ - function GcsFileSpec(properties) { + function DeleteTagTemplateRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -39007,103 +40345,89 @@ } /** - * GcsFileSpec filePath. - * @member {string} filePath - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec - * @instance - */ - GcsFileSpec.prototype.filePath = ""; - - /** - * GcsFileSpec gcsTimestamps. - * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} gcsTimestamps - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * DeleteTagTemplateRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @instance */ - GcsFileSpec.prototype.gcsTimestamps = null; + DeleteTagTemplateRequest.prototype.name = ""; /** - * GcsFileSpec sizeBytes. - * @member {number|Long} sizeBytes - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * DeleteTagTemplateRequest force. + * @member {boolean} force + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @instance */ - GcsFileSpec.prototype.sizeBytes = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + DeleteTagTemplateRequest.prototype.force = false; /** - * Creates a new GcsFileSpec instance using the specified properties. + * Creates a new DeleteTagTemplateRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest instance */ - GcsFileSpec.create = function create(properties) { - return new GcsFileSpec(properties); + DeleteTagTemplateRequest.create = function create(properties) { + return new DeleteTagTemplateRequest(properties); }; /** - * Encodes the specified GcsFileSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFileSpec.verify|verify} messages. + * Encodes the specified DeleteTagTemplateRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec} message GcsFileSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} message DeleteTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFileSpec.encode = function encode(message, writer) { + DeleteTagTemplateRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.filePath != null && Object.hasOwnProperty.call(message, "filePath")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePath); - if (message.gcsTimestamps != null && Object.hasOwnProperty.call(message, "gcsTimestamps")) - $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.gcsTimestamps, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.sizeBytes != null && Object.hasOwnProperty.call(message, "sizeBytes")) - writer.uint32(/* id 4, wireType 0 =*/32).int64(message.sizeBytes); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.force != null && Object.hasOwnProperty.call(message, "force")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.force); return writer; }; /** - * Encodes the specified GcsFileSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFileSpec.verify|verify} messages. + * Encodes the specified DeleteTagTemplateRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec} message GcsFileSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateRequest} message DeleteTagTemplateRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GcsFileSpec.encodeDelimited = function encodeDelimited(message, writer) { + DeleteTagTemplateRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GcsFileSpec message from the specified reader or buffer. + * Decodes a DeleteTagTemplateRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFileSpec.decode = function decode(reader, length) { + DeleteTagTemplateRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GcsFileSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.filePath = reader.string(); + message.name = reader.string(); break; } case 2: { - message.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); - break; - } - case 4: { - message.sizeBytes = reader.int64(); + message.force = reader.bool(); break; } default: @@ -39115,160 +40439,132 @@ }; /** - * Decodes a GcsFileSpec message from the specified reader or buffer, length delimited. + * Decodes a DeleteTagTemplateRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GcsFileSpec.decodeDelimited = function decodeDelimited(reader) { + DeleteTagTemplateRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GcsFileSpec message. + * Verifies a DeleteTagTemplateRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GcsFileSpec.verify = function verify(message) { + DeleteTagTemplateRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.filePath != null && message.hasOwnProperty("filePath")) - if (!$util.isString(message.filePath)) - return "filePath: string expected"; - if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) { - var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.gcsTimestamps); - if (error) - return "gcsTimestamps." + error; - } - if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) - if (!$util.isInteger(message.sizeBytes) && !(message.sizeBytes && $util.isInteger(message.sizeBytes.low) && $util.isInteger(message.sizeBytes.high))) - return "sizeBytes: integer|Long expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.force != null && message.hasOwnProperty("force")) + if (typeof message.force !== "boolean") + return "force: boolean expected"; return null; }; /** - * Creates a GcsFileSpec message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteTagTemplateRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} DeleteTagTemplateRequest */ - GcsFileSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GcsFileSpec) + DeleteTagTemplateRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GcsFileSpec(); - if (object.filePath != null) - message.filePath = String(object.filePath); - if (object.gcsTimestamps != null) { - if (typeof object.gcsTimestamps !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFileSpec.gcsTimestamps: object expected"); - message.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.gcsTimestamps); - } - if (object.sizeBytes != null) - if ($util.Long) - (message.sizeBytes = $util.Long.fromValue(object.sizeBytes)).unsigned = false; - else if (typeof object.sizeBytes === "string") - message.sizeBytes = parseInt(object.sizeBytes, 10); - else if (typeof object.sizeBytes === "number") - message.sizeBytes = object.sizeBytes; - else if (typeof object.sizeBytes === "object") - message.sizeBytes = new $util.LongBits(object.sizeBytes.low >>> 0, object.sizeBytes.high >>> 0).toNumber(); + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.force != null) + message.force = Boolean(object.force); return message; }; /** - * Creates a plain object from a GcsFileSpec message. Also converts values to other types if specified. + * Creates a plain object from a DeleteTagTemplateRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static - * @param {google.cloud.datacatalog.v1beta1.GcsFileSpec} message GcsFileSpec + * @param {google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest} message DeleteTagTemplateRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GcsFileSpec.toObject = function toObject(message, options) { + DeleteTagTemplateRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.filePath = ""; - object.gcsTimestamps = null; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.sizeBytes = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.sizeBytes = options.longs === String ? "0" : 0; + object.name = ""; + object.force = false; } - if (message.filePath != null && message.hasOwnProperty("filePath")) - object.filePath = message.filePath; - if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) - object.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.gcsTimestamps, options); - if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) - if (typeof message.sizeBytes === "number") - object.sizeBytes = options.longs === String ? String(message.sizeBytes) : message.sizeBytes; - else - object.sizeBytes = options.longs === String ? $util.Long.prototype.toString.call(message.sizeBytes) : options.longs === Number ? new $util.LongBits(message.sizeBytes.low >>> 0, message.sizeBytes.high >>> 0).toNumber() : message.sizeBytes; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.force != null && message.hasOwnProperty("force")) + object.force = message.force; return object; }; /** - * Converts this GcsFileSpec to JSON. + * Converts this DeleteTagTemplateRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @instance * @returns {Object.} JSON object */ - GcsFileSpec.prototype.toJSON = function toJSON() { + DeleteTagTemplateRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GcsFileSpec + * Gets the default type url for DeleteTagTemplateRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GcsFileSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteTagTemplateRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GcsFileSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagTemplateRequest"; }; - return GcsFileSpec; + return DeleteTagTemplateRequest; })(); - v1beta1.SystemTimestamps = (function() { + v1beta1.CreateTagRequest = (function() { /** - * Properties of a SystemTimestamps. + * Properties of a CreateTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISystemTimestamps - * @property {google.protobuf.ITimestamp|null} [createTime] SystemTimestamps createTime - * @property {google.protobuf.ITimestamp|null} [updateTime] SystemTimestamps updateTime - * @property {google.protobuf.ITimestamp|null} [expireTime] SystemTimestamps expireTime + * @interface ICreateTagRequest + * @property {string|null} [parent] CreateTagRequest parent + * @property {google.cloud.datacatalog.v1beta1.ITag|null} [tag] CreateTagRequest tag */ /** - * Constructs a new SystemTimestamps. + * Constructs a new CreateTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SystemTimestamps. - * @implements ISystemTimestamps + * @classdesc Represents a CreateTagRequest. + * @implements ICreateTagRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest=} [properties] Properties to set */ - function SystemTimestamps(properties) { + function CreateTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -39276,103 +40572,89 @@ } /** - * SystemTimestamps createTime. - * @member {google.protobuf.ITimestamp|null|undefined} createTime - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps - * @instance - */ - SystemTimestamps.prototype.createTime = null; - - /** - * SystemTimestamps updateTime. - * @member {google.protobuf.ITimestamp|null|undefined} updateTime - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * CreateTagRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @instance */ - SystemTimestamps.prototype.updateTime = null; + CreateTagRequest.prototype.parent = ""; /** - * SystemTimestamps expireTime. - * @member {google.protobuf.ITimestamp|null|undefined} expireTime - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * CreateTagRequest tag. + * @member {google.cloud.datacatalog.v1beta1.ITag|null|undefined} tag + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @instance */ - SystemTimestamps.prototype.expireTime = null; + CreateTagRequest.prototype.tag = null; /** - * Creates a new SystemTimestamps instance using the specified properties. + * Creates a new CreateTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest instance */ - SystemTimestamps.create = function create(properties) { - return new SystemTimestamps(properties); + CreateTagRequest.create = function create(properties) { + return new CreateTagRequest(properties); }; /** - * Encodes the specified SystemTimestamps message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SystemTimestamps.verify|verify} messages. + * Encodes the specified CreateTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps} message SystemTimestamps message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} message CreateTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SystemTimestamps.encode = function encode(message, writer) { + CreateTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) - $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) - $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.expireTime != null && Object.hasOwnProperty.call(message, "expireTime")) - $root.google.protobuf.Timestamp.encode(message.expireTime, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.tag != null && Object.hasOwnProperty.call(message, "tag")) + $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified SystemTimestamps message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SystemTimestamps.verify|verify} messages. + * Encodes the specified CreateTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps} message SystemTimestamps message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagRequest} message CreateTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SystemTimestamps.encodeDelimited = function encodeDelimited(message, writer) { + CreateTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SystemTimestamps message from the specified reader or buffer. + * Decodes a CreateTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps + * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SystemTimestamps.decode = function decode(reader, length) { + CreateTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SystemTimestamps(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.parent = reader.string(); break; } case 2: { - message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 3: { - message.expireTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32()); break; } default: @@ -39384,155 +40666,137 @@ }; /** - * Decodes a SystemTimestamps message from the specified reader or buffer, length delimited. + * Decodes a CreateTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps + * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SystemTimestamps.decodeDelimited = function decodeDelimited(reader) { + CreateTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SystemTimestamps message. + * Verifies a CreateTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SystemTimestamps.verify = function verify(message) { + CreateTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.createTime != null && message.hasOwnProperty("createTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.createTime); + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.tag != null && message.hasOwnProperty("tag")) { + var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tag); if (error) - return "createTime." + error; - } - if (message.updateTime != null && message.hasOwnProperty("updateTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.updateTime); - if (error) - return "updateTime." + error; - } - if (message.expireTime != null && message.hasOwnProperty("expireTime")) { - var error = $root.google.protobuf.Timestamp.verify(message.expireTime); - if (error) - return "expireTime." + error; + return "tag." + error; } return null; }; /** - * Creates a SystemTimestamps message from a plain object. Also converts values to their respective internal types. + * Creates a CreateTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps + * @returns {google.cloud.datacatalog.v1beta1.CreateTagRequest} CreateTagRequest */ - SystemTimestamps.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SystemTimestamps) + CreateTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SystemTimestamps(); - if (object.createTime != null) { - if (typeof object.createTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.createTime: object expected"); - message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); - } - if (object.updateTime != null) { - if (typeof object.updateTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.updateTime: object expected"); - message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); - } - if (object.expireTime != null) { - if (typeof object.expireTime !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.expireTime: object expected"); - message.expireTime = $root.google.protobuf.Timestamp.fromObject(object.expireTime); + var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.tag != null) { + if (typeof object.tag !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagRequest.tag: object expected"); + message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tag); } return message; }; /** - * Creates a plain object from a SystemTimestamps message. Also converts values to other types if specified. + * Creates a plain object from a CreateTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.SystemTimestamps} message SystemTimestamps + * @param {google.cloud.datacatalog.v1beta1.CreateTagRequest} message CreateTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SystemTimestamps.toObject = function toObject(message, options) { + CreateTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.createTime = null; - object.updateTime = null; - object.expireTime = null; + object.parent = ""; + object.tag = null; } - if (message.createTime != null && message.hasOwnProperty("createTime")) - object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); - if (message.updateTime != null && message.hasOwnProperty("updateTime")) - object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); - if (message.expireTime != null && message.hasOwnProperty("expireTime")) - object.expireTime = $root.google.protobuf.Timestamp.toObject(message.expireTime, options); + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.tag != null && message.hasOwnProperty("tag")) + object.tag = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tag, options); return object; }; /** - * Converts this SystemTimestamps to JSON. + * Converts this CreateTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @instance * @returns {Object.} JSON object */ - SystemTimestamps.prototype.toJSON = function toJSON() { + CreateTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SystemTimestamps + * Gets the default type url for CreateTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @memberof google.cloud.datacatalog.v1beta1.CreateTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SystemTimestamps.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SystemTimestamps"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagRequest"; }; - return SystemTimestamps; + return CreateTagRequest; })(); - v1beta1.Schema = (function() { + v1beta1.UpdateTagRequest = (function() { /** - * Properties of a Schema. + * Properties of an UpdateTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISchema - * @property {Array.|null} [columns] Schema columns + * @interface IUpdateTagRequest + * @property {google.cloud.datacatalog.v1beta1.ITag|null} [tag] UpdateTagRequest tag + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagRequest updateMask */ /** - * Constructs a new Schema. + * Constructs a new UpdateTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a Schema. - * @implements ISchema + * @classdesc Represents an UpdateTagRequest. + * @implements IUpdateTagRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISchema=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest=} [properties] Properties to set */ - function Schema(properties) { - this.columns = []; + function UpdateTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -39540,78 +40804,89 @@ } /** - * Schema columns. - * @member {Array.} columns - * @memberof google.cloud.datacatalog.v1beta1.Schema + * UpdateTagRequest tag. + * @member {google.cloud.datacatalog.v1beta1.ITag|null|undefined} tag + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @instance */ - Schema.prototype.columns = $util.emptyArray; + UpdateTagRequest.prototype.tag = null; /** - * Creates a new Schema instance using the specified properties. + * UpdateTagRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest + * @instance + */ + UpdateTagRequest.prototype.updateMask = null; + + /** + * Creates a new UpdateTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest instance */ - Schema.create = function create(properties) { - return new Schema(properties); + UpdateTagRequest.create = function create(properties) { + return new UpdateTagRequest(properties); }; /** - * Encodes the specified Schema message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Schema.verify|verify} messages. + * Encodes the specified UpdateTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISchema} message Schema message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} message UpdateTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Schema.encode = function encode(message, writer) { + UpdateTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.columns != null && message.columns.length) - for (var i = 0; i < message.columns.length; ++i) - $root.google.cloud.datacatalog.v1beta1.ColumnSchema.encode(message.columns[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.tag != null && Object.hasOwnProperty.call(message, "tag")) + $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified Schema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Schema.verify|verify} messages. + * Encodes the specified UpdateTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISchema} message Schema message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagRequest} message UpdateTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Schema.encodeDelimited = function encodeDelimited(message, writer) { + UpdateTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Schema message from the specified reader or buffer. + * Decodes an UpdateTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Schema.decode = function decode(reader, length) { + UpdateTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Schema(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32()); + break; + } case 2: { - if (!(message.columns && message.columns.length)) - message.columns = []; - message.columns.push($root.google.cloud.datacatalog.v1beta1.ColumnSchema.decode(reader, reader.uint32())); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -39623,144 +40898,141 @@ }; /** - * Decodes a Schema message from the specified reader or buffer, length delimited. + * Decodes an UpdateTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Schema.decodeDelimited = function decodeDelimited(reader) { + UpdateTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Schema message. + * Verifies an UpdateTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Schema.verify = function verify(message) { + UpdateTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.columns != null && message.hasOwnProperty("columns")) { - if (!Array.isArray(message.columns)) - return "columns: array expected"; - for (var i = 0; i < message.columns.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.verify(message.columns[i]); - if (error) - return "columns." + error; - } + if (message.tag != null && message.hasOwnProperty("tag")) { + var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tag); + if (error) + return "tag." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates a Schema message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagRequest} UpdateTagRequest */ - Schema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.Schema) + UpdateTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.Schema(); - if (object.columns) { - if (!Array.isArray(object.columns)) - throw TypeError(".google.cloud.datacatalog.v1beta1.Schema.columns: array expected"); - message.columns = []; - for (var i = 0; i < object.columns.length; ++i) { - if (typeof object.columns[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Schema.columns: object expected"); - message.columns[i] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.fromObject(object.columns[i]); - } + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagRequest(); + if (object.tag != null) { + if (typeof object.tag !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagRequest.tag: object expected"); + message.tag = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tag); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from a Schema message. Also converts values to other types if specified. + * Creates a plain object from an UpdateTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.Schema} message Schema + * @param {google.cloud.datacatalog.v1beta1.UpdateTagRequest} message UpdateTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Schema.toObject = function toObject(message, options) { + UpdateTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.columns = []; - if (message.columns && message.columns.length) { - object.columns = []; - for (var j = 0; j < message.columns.length; ++j) - object.columns[j] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.toObject(message.columns[j], options); + if (options.defaults) { + object.tag = null; + object.updateMask = null; } + if (message.tag != null && message.hasOwnProperty("tag")) + object.tag = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tag, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this Schema to JSON. + * Converts this UpdateTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @instance * @returns {Object.} JSON object */ - Schema.prototype.toJSON = function toJSON() { + UpdateTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Schema + * Gets the default type url for UpdateTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.Schema + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Schema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Schema"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagRequest"; }; - return Schema; + return UpdateTagRequest; })(); - v1beta1.ColumnSchema = (function() { + v1beta1.DeleteTagRequest = (function() { /** - * Properties of a ColumnSchema. + * Properties of a DeleteTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IColumnSchema - * @property {string|null} [column] ColumnSchema column - * @property {string|null} [type] ColumnSchema type - * @property {string|null} [description] ColumnSchema description - * @property {string|null} [mode] ColumnSchema mode - * @property {Array.|null} [subcolumns] ColumnSchema subcolumns + * @interface IDeleteTagRequest + * @property {string|null} [name] DeleteTagRequest name */ /** - * Constructs a new ColumnSchema. + * Constructs a new DeleteTagRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ColumnSchema. - * @implements IColumnSchema + * @classdesc Represents a DeleteTagRequest. + * @implements IDeleteTagRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IColumnSchema=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest=} [properties] Properties to set */ - function ColumnSchema(properties) { - this.subcolumns = []; + function DeleteTagRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -39768,134 +41040,75 @@ } /** - * ColumnSchema column. - * @member {string} column - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.column = ""; - - /** - * ColumnSchema type. - * @member {string} type - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.type = ""; - - /** - * ColumnSchema description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.description = ""; - - /** - * ColumnSchema mode. - * @member {string} mode - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema - * @instance - */ - ColumnSchema.prototype.mode = ""; - - /** - * ColumnSchema subcolumns. - * @member {Array.} subcolumns - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * DeleteTagRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @instance */ - ColumnSchema.prototype.subcolumns = $util.emptyArray; + DeleteTagRequest.prototype.name = ""; /** - * Creates a new ColumnSchema instance using the specified properties. + * Creates a new DeleteTagRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IColumnSchema=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest instance */ - ColumnSchema.create = function create(properties) { - return new ColumnSchema(properties); + DeleteTagRequest.create = function create(properties) { + return new DeleteTagRequest(properties); }; /** - * Encodes the specified ColumnSchema message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ColumnSchema.verify|verify} messages. + * Encodes the specified DeleteTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IColumnSchema} message ColumnSchema message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} message DeleteTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ColumnSchema.encode = function encode(message, writer) { + DeleteTagRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); - if (message.mode != null && Object.hasOwnProperty.call(message, "mode")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.mode); - if (message.column != null && Object.hasOwnProperty.call(message, "column")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.column); - if (message.subcolumns != null && message.subcolumns.length) - for (var i = 0; i < message.subcolumns.length; ++i) - $root.google.cloud.datacatalog.v1beta1.ColumnSchema.encode(message.subcolumns[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified ColumnSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ColumnSchema.verify|verify} messages. + * Encodes the specified DeleteTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IColumnSchema} message ColumnSchema message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagRequest} message DeleteTagRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ColumnSchema.encodeDelimited = function encodeDelimited(message, writer) { + DeleteTagRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ColumnSchema message from the specified reader or buffer. + * Decodes a DeleteTagRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ColumnSchema.decode = function decode(reader, length) { + DeleteTagRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ColumnSchema(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 6: { - message.column = reader.string(); - break; - } case 1: { - message.type = reader.string(); - break; - } - case 2: { - message.description = reader.string(); - break; - } - case 3: { - message.mode = reader.string(); - break; - } - case 7: { - if (!(message.subcolumns && message.subcolumns.length)) - message.subcolumns = []; - message.subcolumns.push($root.google.cloud.datacatalog.v1beta1.ColumnSchema.decode(reader, reader.uint32())); + message.name = reader.string(); break; } default: @@ -39907,176 +41120,124 @@ }; /** - * Decodes a ColumnSchema message from the specified reader or buffer, length delimited. + * Decodes a DeleteTagRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ColumnSchema.decodeDelimited = function decodeDelimited(reader) { + DeleteTagRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ColumnSchema message. + * Verifies a DeleteTagRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ColumnSchema.verify = function verify(message) { + DeleteTagRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.column != null && message.hasOwnProperty("column")) - if (!$util.isString(message.column)) - return "column: string expected"; - if (message.type != null && message.hasOwnProperty("type")) - if (!$util.isString(message.type)) - return "type: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.mode != null && message.hasOwnProperty("mode")) - if (!$util.isString(message.mode)) - return "mode: string expected"; - if (message.subcolumns != null && message.hasOwnProperty("subcolumns")) { - if (!Array.isArray(message.subcolumns)) - return "subcolumns: array expected"; - for (var i = 0; i < message.subcolumns.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.verify(message.subcolumns[i]); - if (error) - return "subcolumns." + error; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates a ColumnSchema message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteTagRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagRequest} DeleteTagRequest */ - ColumnSchema.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ColumnSchema) + DeleteTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ColumnSchema(); - if (object.column != null) - message.column = String(object.column); - if (object.type != null) - message.type = String(object.type); - if (object.description != null) - message.description = String(object.description); - if (object.mode != null) - message.mode = String(object.mode); - if (object.subcolumns) { - if (!Array.isArray(object.subcolumns)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ColumnSchema.subcolumns: array expected"); - message.subcolumns = []; - for (var i = 0; i < object.subcolumns.length; ++i) { - if (typeof object.subcolumns[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ColumnSchema.subcolumns: object expected"); - message.subcolumns[i] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.fromObject(object.subcolumns[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from a ColumnSchema message. Also converts values to other types if specified. + * Creates a plain object from a DeleteTagRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ColumnSchema} message ColumnSchema + * @param {google.cloud.datacatalog.v1beta1.DeleteTagRequest} message DeleteTagRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ColumnSchema.toObject = function toObject(message, options) { + DeleteTagRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.subcolumns = []; - if (options.defaults) { - object.type = ""; - object.description = ""; - object.mode = ""; - object.column = ""; - } - if (message.type != null && message.hasOwnProperty("type")) - object.type = message.type; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.mode != null && message.hasOwnProperty("mode")) - object.mode = message.mode; - if (message.column != null && message.hasOwnProperty("column")) - object.column = message.column; - if (message.subcolumns && message.subcolumns.length) { - object.subcolumns = []; - for (var j = 0; j < message.subcolumns.length; ++j) - object.subcolumns[j] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.toObject(message.subcolumns[j], options); - } + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this ColumnSchema to JSON. + * Converts this DeleteTagRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @instance * @returns {Object.} JSON object */ - ColumnSchema.prototype.toJSON = function toJSON() { + DeleteTagRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ColumnSchema + * Gets the default type url for DeleteTagRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ColumnSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ColumnSchema"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagRequest"; }; - return ColumnSchema; + return DeleteTagRequest; })(); - v1beta1.SearchCatalogResult = (function() { + v1beta1.CreateTagTemplateFieldRequest = (function() { /** - * Properties of a SearchCatalogResult. + * Properties of a CreateTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISearchCatalogResult - * @property {google.cloud.datacatalog.v1beta1.SearchResultType|null} [searchResultType] SearchCatalogResult searchResultType - * @property {string|null} [searchResultSubtype] SearchCatalogResult searchResultSubtype - * @property {string|null} [relativeResourceName] SearchCatalogResult relativeResourceName - * @property {string|null} [linkedResource] SearchCatalogResult linkedResource + * @interface ICreateTagTemplateFieldRequest + * @property {string|null} [parent] CreateTagTemplateFieldRequest parent + * @property {string|null} [tagTemplateFieldId] CreateTagTemplateFieldRequest tagTemplateFieldId + * @property {google.cloud.datacatalog.v1beta1.ITagTemplateField|null} [tagTemplateField] CreateTagTemplateFieldRequest tagTemplateField */ /** - * Constructs a new SearchCatalogResult. + * Constructs a new CreateTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SearchCatalogResult. - * @implements ISearchCatalogResult + * @classdesc Represents a CreateTagTemplateFieldRequest. + * @implements ICreateTagTemplateFieldRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest=} [properties] Properties to set */ - function SearchCatalogResult(properties) { + function CreateTagTemplateFieldRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -40084,117 +41245,103 @@ } /** - * SearchCatalogResult searchResultType. - * @member {google.cloud.datacatalog.v1beta1.SearchResultType} searchResultType - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult - * @instance - */ - SearchCatalogResult.prototype.searchResultType = 0; - - /** - * SearchCatalogResult searchResultSubtype. - * @member {string} searchResultSubtype - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * CreateTagTemplateFieldRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @instance */ - SearchCatalogResult.prototype.searchResultSubtype = ""; + CreateTagTemplateFieldRequest.prototype.parent = ""; /** - * SearchCatalogResult relativeResourceName. - * @member {string} relativeResourceName - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * CreateTagTemplateFieldRequest tagTemplateFieldId. + * @member {string} tagTemplateFieldId + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @instance */ - SearchCatalogResult.prototype.relativeResourceName = ""; + CreateTagTemplateFieldRequest.prototype.tagTemplateFieldId = ""; /** - * SearchCatalogResult linkedResource. - * @member {string} linkedResource - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * CreateTagTemplateFieldRequest tagTemplateField. + * @member {google.cloud.datacatalog.v1beta1.ITagTemplateField|null|undefined} tagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @instance */ - SearchCatalogResult.prototype.linkedResource = ""; + CreateTagTemplateFieldRequest.prototype.tagTemplateField = null; /** - * Creates a new SearchCatalogResult instance using the specified properties. + * Creates a new CreateTagTemplateFieldRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest instance */ - SearchCatalogResult.create = function create(properties) { - return new SearchCatalogResult(properties); + CreateTagTemplateFieldRequest.create = function create(properties) { + return new CreateTagTemplateFieldRequest(properties); }; /** - * Encodes the specified SearchCatalogResult message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify|verify} messages. + * Encodes the specified CreateTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogResult.encode = function encode(message, writer) { + CreateTagTemplateFieldRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.searchResultType != null && Object.hasOwnProperty.call(message, "searchResultType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.searchResultType); - if (message.searchResultSubtype != null && Object.hasOwnProperty.call(message, "searchResultSubtype")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.searchResultSubtype); - if (message.relativeResourceName != null && Object.hasOwnProperty.call(message, "relativeResourceName")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.relativeResourceName); - if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.linkedResource); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.tagTemplateFieldId != null && Object.hasOwnProperty.call(message, "tagTemplateFieldId")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.tagTemplateFieldId); + if (message.tagTemplateField != null && Object.hasOwnProperty.call(message, "tagTemplateField")) + $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.tagTemplateField, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified SearchCatalogResult message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify|verify} messages. + * Encodes the specified CreateTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SearchCatalogResult.encodeDelimited = function encodeDelimited(message, writer) { + CreateTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SearchCatalogResult message from the specified reader or buffer. + * Decodes a CreateTagTemplateFieldRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogResult.decode = function decode(reader, length) { + CreateTagTemplateFieldRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.searchResultType = reader.int32(); + message.parent = reader.string(); break; } case 2: { - message.searchResultSubtype = reader.string(); + message.tagTemplateFieldId = reader.string(); break; } case 3: { - message.relativeResourceName = reader.string(); - break; - } - case 4: { - message.linkedResource = reader.string(); + message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); break; } default: @@ -40206,196 +41353,146 @@ }; /** - * Decodes a SearchCatalogResult message from the specified reader or buffer, length delimited. + * Decodes a CreateTagTemplateFieldRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SearchCatalogResult.decodeDelimited = function decodeDelimited(reader) { + CreateTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SearchCatalogResult message. + * Verifies a CreateTagTemplateFieldRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SearchCatalogResult.verify = function verify(message) { + CreateTagTemplateFieldRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) - switch (message.searchResultType) { - default: - return "searchResultType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } - if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) - if (!$util.isString(message.searchResultSubtype)) - return "searchResultSubtype: string expected"; - if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) - if (!$util.isString(message.relativeResourceName)) - return "relativeResourceName: string expected"; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - if (!$util.isString(message.linkedResource)) - return "linkedResource: string expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.tagTemplateFieldId != null && message.hasOwnProperty("tagTemplateFieldId")) + if (!$util.isString(message.tagTemplateFieldId)) + return "tagTemplateFieldId: string expected"; + if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) { + var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.tagTemplateField); + if (error) + return "tagTemplateField." + error; + } return null; }; /** - * Creates a SearchCatalogResult message from a plain object. Also converts values to their respective internal types. + * Creates a CreateTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult + * @returns {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} CreateTagTemplateFieldRequest */ - SearchCatalogResult.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult) + CreateTagTemplateFieldRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult(); - switch (object.searchResultType) { - default: - if (typeof object.searchResultType === "number") { - message.searchResultType = object.searchResultType; - break; - } - break; - case "SEARCH_RESULT_TYPE_UNSPECIFIED": - case 0: - message.searchResultType = 0; - break; - case "ENTRY": - case 1: - message.searchResultType = 1; - break; - case "TAG_TEMPLATE": - case 2: - message.searchResultType = 2; - break; - case "ENTRY_GROUP": - case 3: - message.searchResultType = 3; - break; + var message = new $root.google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.tagTemplateFieldId != null) + message.tagTemplateFieldId = String(object.tagTemplateFieldId); + if (object.tagTemplateField != null) { + if (typeof object.tagTemplateField !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest.tagTemplateField: object expected"); + message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.tagTemplateField); } - if (object.searchResultSubtype != null) - message.searchResultSubtype = String(object.searchResultSubtype); - if (object.relativeResourceName != null) - message.relativeResourceName = String(object.relativeResourceName); - if (object.linkedResource != null) - message.linkedResource = String(object.linkedResource); return message; }; /** - * Creates a plain object from a SearchCatalogResult message. Also converts values to other types if specified. + * Creates a plain object from a CreateTagTemplateFieldRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResult} message SearchCatalogResult + * @param {google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest} message CreateTagTemplateFieldRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SearchCatalogResult.toObject = function toObject(message, options) { + CreateTagTemplateFieldRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.searchResultType = options.enums === String ? "SEARCH_RESULT_TYPE_UNSPECIFIED" : 0; - object.searchResultSubtype = ""; - object.relativeResourceName = ""; - object.linkedResource = ""; + object.parent = ""; + object.tagTemplateFieldId = ""; + object.tagTemplateField = null; } - if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) - object.searchResultType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.SearchResultType[message.searchResultType] === undefined ? message.searchResultType : $root.google.cloud.datacatalog.v1beta1.SearchResultType[message.searchResultType] : message.searchResultType; - if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) - object.searchResultSubtype = message.searchResultSubtype; - if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) - object.relativeResourceName = message.relativeResourceName; - if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) - object.linkedResource = message.linkedResource; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.tagTemplateFieldId != null && message.hasOwnProperty("tagTemplateFieldId")) + object.tagTemplateFieldId = message.tagTemplateFieldId; + if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) + object.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.tagTemplateField, options); return object; }; /** - * Converts this SearchCatalogResult to JSON. + * Converts this CreateTagTemplateFieldRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @instance * @returns {Object.} JSON object */ - SearchCatalogResult.prototype.toJSON = function toJSON() { + CreateTagTemplateFieldRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SearchCatalogResult + * Gets the default type url for CreateTagTemplateFieldRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult + * @memberof google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SearchCatalogResult.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogResult"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTagTemplateFieldRequest"; }; - return SearchCatalogResult; - })(); - - /** - * SearchResultType enum. - * @name google.cloud.datacatalog.v1beta1.SearchResultType - * @enum {number} - * @property {number} SEARCH_RESULT_TYPE_UNSPECIFIED=0 SEARCH_RESULT_TYPE_UNSPECIFIED value - * @property {number} ENTRY=1 ENTRY value - * @property {number} TAG_TEMPLATE=2 TAG_TEMPLATE value - * @property {number} ENTRY_GROUP=3 ENTRY_GROUP value - */ - v1beta1.SearchResultType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "SEARCH_RESULT_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "ENTRY"] = 1; - values[valuesById[2] = "TAG_TEMPLATE"] = 2; - values[valuesById[3] = "ENTRY_GROUP"] = 3; - return values; + return CreateTagTemplateFieldRequest; })(); - v1beta1.BigQueryTableSpec = (function() { + v1beta1.UpdateTagTemplateFieldRequest = (function() { /** - * Properties of a BigQueryTableSpec. + * Properties of an UpdateTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IBigQueryTableSpec - * @property {google.cloud.datacatalog.v1beta1.TableSourceType|null} [tableSourceType] BigQueryTableSpec tableSourceType - * @property {google.cloud.datacatalog.v1beta1.IViewSpec|null} [viewSpec] BigQueryTableSpec viewSpec - * @property {google.cloud.datacatalog.v1beta1.ITableSpec|null} [tableSpec] BigQueryTableSpec tableSpec + * @interface IUpdateTagTemplateFieldRequest + * @property {string|null} [name] UpdateTagTemplateFieldRequest name + * @property {google.cloud.datacatalog.v1beta1.ITagTemplateField|null} [tagTemplateField] UpdateTagTemplateFieldRequest tagTemplateField + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTagTemplateFieldRequest updateMask */ /** - * Constructs a new BigQueryTableSpec. + * Constructs a new UpdateTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a BigQueryTableSpec. - * @implements IBigQueryTableSpec + * @classdesc Represents an UpdateTagTemplateFieldRequest. + * @implements IUpdateTagTemplateFieldRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest=} [properties] Properties to set */ - function BigQueryTableSpec(properties) { + function UpdateTagTemplateFieldRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -40403,117 +41500,103 @@ } /** - * BigQueryTableSpec tableSourceType. - * @member {google.cloud.datacatalog.v1beta1.TableSourceType} tableSourceType - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec - * @instance - */ - BigQueryTableSpec.prototype.tableSourceType = 0; - - /** - * BigQueryTableSpec viewSpec. - * @member {google.cloud.datacatalog.v1beta1.IViewSpec|null|undefined} viewSpec - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * UpdateTagTemplateFieldRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @instance */ - BigQueryTableSpec.prototype.viewSpec = null; + UpdateTagTemplateFieldRequest.prototype.name = ""; /** - * BigQueryTableSpec tableSpec. - * @member {google.cloud.datacatalog.v1beta1.ITableSpec|null|undefined} tableSpec - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * UpdateTagTemplateFieldRequest tagTemplateField. + * @member {google.cloud.datacatalog.v1beta1.ITagTemplateField|null|undefined} tagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @instance */ - BigQueryTableSpec.prototype.tableSpec = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + UpdateTagTemplateFieldRequest.prototype.tagTemplateField = null; /** - * BigQueryTableSpec typeSpec. - * @member {"viewSpec"|"tableSpec"|undefined} typeSpec - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * UpdateTagTemplateFieldRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @instance */ - Object.defineProperty(BigQueryTableSpec.prototype, "typeSpec", { - get: $util.oneOfGetter($oneOfFields = ["viewSpec", "tableSpec"]), - set: $util.oneOfSetter($oneOfFields) - }); + UpdateTagTemplateFieldRequest.prototype.updateMask = null; /** - * Creates a new BigQueryTableSpec instance using the specified properties. + * Creates a new UpdateTagTemplateFieldRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest instance */ - BigQueryTableSpec.create = function create(properties) { - return new BigQueryTableSpec(properties); + UpdateTagTemplateFieldRequest.create = function create(properties) { + return new UpdateTagTemplateFieldRequest(properties); }; /** - * Encodes the specified BigQueryTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify|verify} messages. + * Encodes the specified UpdateTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryTableSpec.encode = function encode(message, writer) { + UpdateTagTemplateFieldRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.tableSourceType != null && Object.hasOwnProperty.call(message, "tableSourceType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.tableSourceType); - if (message.viewSpec != null && Object.hasOwnProperty.call(message, "viewSpec")) - $root.google.cloud.datacatalog.v1beta1.ViewSpec.encode(message.viewSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.tableSpec != null && Object.hasOwnProperty.call(message, "tableSpec")) - $root.google.cloud.datacatalog.v1beta1.TableSpec.encode(message.tableSpec, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.tagTemplateField != null && Object.hasOwnProperty.call(message, "tagTemplateField")) + $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.tagTemplateField, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified BigQueryTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify|verify} messages. + * Encodes the specified UpdateTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryTableSpec.encodeDelimited = function encodeDelimited(message, writer) { + UpdateTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a BigQueryTableSpec message from the specified reader or buffer. + * Decodes an UpdateTagTemplateFieldRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryTableSpec.decode = function decode(reader, length) { + UpdateTagTemplateFieldRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.tableSourceType = reader.int32(); + message.name = reader.string(); break; } case 2: { - message.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.decode(reader, reader.uint32()); + message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); break; } case 3: { - message.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.decode(reader, reader.uint32()); + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -40525,201 +41608,150 @@ }; /** - * Decodes a BigQueryTableSpec message from the specified reader or buffer, length delimited. + * Decodes an UpdateTagTemplateFieldRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryTableSpec.decodeDelimited = function decodeDelimited(reader) { + UpdateTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a BigQueryTableSpec message. + * Verifies an UpdateTagTemplateFieldRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - BigQueryTableSpec.verify = function verify(message) { + UpdateTagTemplateFieldRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) - switch (message.tableSourceType) { - default: - return "tableSourceType: enum value expected"; - case 0: - case 2: - case 5: - break; - } - if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.ViewSpec.verify(message.viewSpec); - if (error) - return "viewSpec." + error; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) { + var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.tagTemplateField); + if (error) + return "tagTemplateField." + error; } - if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { - if (properties.typeSpec === 1) - return "typeSpec: multiple values"; - properties.typeSpec = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.TableSpec.verify(message.tableSpec); - if (error) - return "tableSpec." + error; - } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates a BigQueryTableSpec message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec + * @returns {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} UpdateTagTemplateFieldRequest */ - BigQueryTableSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec) + UpdateTagTemplateFieldRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec(); - switch (object.tableSourceType) { - default: - if (typeof object.tableSourceType === "number") { - message.tableSourceType = object.tableSourceType; - break; - } - break; - case "TABLE_SOURCE_TYPE_UNSPECIFIED": - case 0: - message.tableSourceType = 0; - break; - case "BIGQUERY_VIEW": - case 2: - message.tableSourceType = 2; - break; - case "BIGQUERY_TABLE": - case 5: - message.tableSourceType = 5; - break; - } - if (object.viewSpec != null) { - if (typeof object.viewSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.BigQueryTableSpec.viewSpec: object expected"); - message.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.fromObject(object.viewSpec); + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.tagTemplateField != null) { + if (typeof object.tagTemplateField !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.tagTemplateField: object expected"); + message.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.tagTemplateField); } - if (object.tableSpec != null) { - if (typeof object.tableSpec !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.BigQueryTableSpec.tableSpec: object expected"); - message.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.fromObject(object.tableSpec); + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from a BigQueryTableSpec message. Also converts values to other types if specified. + * Creates a plain object from an UpdateTagTemplateFieldRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} message BigQueryTableSpec + * @param {google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest} message UpdateTagTemplateFieldRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - BigQueryTableSpec.toObject = function toObject(message, options) { + UpdateTagTemplateFieldRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.tableSourceType = options.enums === String ? "TABLE_SOURCE_TYPE_UNSPECIFIED" : 0; - if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) - object.tableSourceType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.TableSourceType[message.tableSourceType] === undefined ? message.tableSourceType : $root.google.cloud.datacatalog.v1beta1.TableSourceType[message.tableSourceType] : message.tableSourceType; - if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { - object.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.toObject(message.viewSpec, options); - if (options.oneofs) - object.typeSpec = "viewSpec"; - } - if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { - object.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.toObject(message.tableSpec, options); - if (options.oneofs) - object.typeSpec = "tableSpec"; + if (options.defaults) { + object.name = ""; + object.tagTemplateField = null; + object.updateMask = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.tagTemplateField != null && message.hasOwnProperty("tagTemplateField")) + object.tagTemplateField = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.tagTemplateField, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this BigQueryTableSpec to JSON. + * Converts this UpdateTagTemplateFieldRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @instance * @returns {Object.} JSON object */ - BigQueryTableSpec.prototype.toJSON = function toJSON() { + UpdateTagTemplateFieldRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for BigQueryTableSpec + * Gets the default type url for UpdateTagTemplateFieldRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec + * @memberof google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - BigQueryTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.BigQueryTableSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTagTemplateFieldRequest"; }; - return BigQueryTableSpec; - })(); - - /** - * TableSourceType enum. - * @name google.cloud.datacatalog.v1beta1.TableSourceType - * @enum {number} - * @property {number} TABLE_SOURCE_TYPE_UNSPECIFIED=0 TABLE_SOURCE_TYPE_UNSPECIFIED value - * @property {number} BIGQUERY_VIEW=2 BIGQUERY_VIEW value - * @property {number} BIGQUERY_TABLE=5 BIGQUERY_TABLE value - */ - v1beta1.TableSourceType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "TABLE_SOURCE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[2] = "BIGQUERY_VIEW"] = 2; - values[valuesById[5] = "BIGQUERY_TABLE"] = 5; - return values; + return UpdateTagTemplateFieldRequest; })(); - v1beta1.ViewSpec = (function() { + v1beta1.RenameTagTemplateFieldRequest = (function() { /** - * Properties of a ViewSpec. + * Properties of a RenameTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IViewSpec - * @property {string|null} [viewQuery] ViewSpec viewQuery + * @interface IRenameTagTemplateFieldRequest + * @property {string|null} [name] RenameTagTemplateFieldRequest name + * @property {string|null} [newTagTemplateFieldId] RenameTagTemplateFieldRequest newTagTemplateFieldId */ /** - * Constructs a new ViewSpec. + * Constructs a new RenameTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ViewSpec. - * @implements IViewSpec + * @classdesc Represents a RenameTagTemplateFieldRequest. + * @implements IRenameTagTemplateFieldRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IViewSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest=} [properties] Properties to set */ - function ViewSpec(properties) { + function RenameTagTemplateFieldRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -40727,75 +41759,89 @@ } /** - * ViewSpec viewQuery. - * @member {string} viewQuery - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * RenameTagTemplateFieldRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @instance */ - ViewSpec.prototype.viewQuery = ""; + RenameTagTemplateFieldRequest.prototype.name = ""; /** - * Creates a new ViewSpec instance using the specified properties. + * RenameTagTemplateFieldRequest newTagTemplateFieldId. + * @member {string} newTagTemplateFieldId + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest + * @instance + */ + RenameTagTemplateFieldRequest.prototype.newTagTemplateFieldId = ""; + + /** + * Creates a new RenameTagTemplateFieldRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IViewSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec instance + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest instance */ - ViewSpec.create = function create(properties) { - return new ViewSpec(properties); + RenameTagTemplateFieldRequest.create = function create(properties) { + return new RenameTagTemplateFieldRequest(properties); }; /** - * Encodes the specified ViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ViewSpec.verify|verify} messages. + * Encodes the specified RenameTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IViewSpec} message ViewSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ViewSpec.encode = function encode(message, writer) { + RenameTagTemplateFieldRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.viewQuery != null && Object.hasOwnProperty.call(message, "viewQuery")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.viewQuery); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.newTagTemplateFieldId != null && Object.hasOwnProperty.call(message, "newTagTemplateFieldId")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.newTagTemplateFieldId); return writer; }; /** - * Encodes the specified ViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ViewSpec.verify|verify} messages. + * Encodes the specified RenameTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IViewSpec} message ViewSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IRenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ViewSpec.encodeDelimited = function encodeDelimited(message, writer) { + RenameTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ViewSpec message from the specified reader or buffer. + * Decodes a RenameTagTemplateFieldRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ViewSpec.decode = function decode(reader, length) { + RenameTagTemplateFieldRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ViewSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.viewQuery = reader.string(); + message.name = reader.string(); + break; + } + case 2: { + message.newTagTemplateFieldId = reader.string(); break; } default: @@ -40807,122 +41853,132 @@ }; /** - * Decodes a ViewSpec message from the specified reader or buffer, length delimited. + * Decodes a RenameTagTemplateFieldRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ViewSpec.decodeDelimited = function decodeDelimited(reader) { + RenameTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ViewSpec message. + * Verifies a RenameTagTemplateFieldRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ViewSpec.verify = function verify(message) { + RenameTagTemplateFieldRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) - if (!$util.isString(message.viewQuery)) - return "viewQuery: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.newTagTemplateFieldId != null && message.hasOwnProperty("newTagTemplateFieldId")) + if (!$util.isString(message.newTagTemplateFieldId)) + return "newTagTemplateFieldId: string expected"; return null; }; /** - * Creates a ViewSpec message from a plain object. Also converts values to their respective internal types. + * Creates a RenameTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec + * @returns {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} RenameTagTemplateFieldRequest */ - ViewSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ViewSpec) + RenameTagTemplateFieldRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ViewSpec(); - if (object.viewQuery != null) - message.viewQuery = String(object.viewQuery); + var message = new $root.google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.newTagTemplateFieldId != null) + message.newTagTemplateFieldId = String(object.newTagTemplateFieldId); return message; }; /** - * Creates a plain object from a ViewSpec message. Also converts values to other types if specified. + * Creates a plain object from a RenameTagTemplateFieldRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ViewSpec} message ViewSpec + * @param {google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest} message RenameTagTemplateFieldRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ViewSpec.toObject = function toObject(message, options) { + RenameTagTemplateFieldRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.viewQuery = ""; - if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) - object.viewQuery = message.viewQuery; + if (options.defaults) { + object.name = ""; + object.newTagTemplateFieldId = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.newTagTemplateFieldId != null && message.hasOwnProperty("newTagTemplateFieldId")) + object.newTagTemplateFieldId = message.newTagTemplateFieldId; return object; }; /** - * Converts this ViewSpec to JSON. + * Converts this RenameTagTemplateFieldRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @instance * @returns {Object.} JSON object */ - ViewSpec.prototype.toJSON = function toJSON() { + RenameTagTemplateFieldRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ViewSpec + * Gets the default type url for RenameTagTemplateFieldRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ViewSpec + * @memberof google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ViewSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + RenameTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ViewSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.RenameTagTemplateFieldRequest"; }; - return ViewSpec; + return RenameTagTemplateFieldRequest; })(); - v1beta1.TableSpec = (function() { + v1beta1.DeleteTagTemplateFieldRequest = (function() { /** - * Properties of a TableSpec. + * Properties of a DeleteTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITableSpec - * @property {string|null} [groupedEntry] TableSpec groupedEntry + * @interface IDeleteTagTemplateFieldRequest + * @property {string|null} [name] DeleteTagTemplateFieldRequest name + * @property {boolean|null} [force] DeleteTagTemplateFieldRequest force */ /** - * Constructs a new TableSpec. + * Constructs a new DeleteTagTemplateFieldRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a TableSpec. - * @implements ITableSpec + * @classdesc Represents a DeleteTagTemplateFieldRequest. + * @implements IDeleteTagTemplateFieldRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITableSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest=} [properties] Properties to set */ - function TableSpec(properties) { + function DeleteTagTemplateFieldRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -40930,75 +41986,89 @@ } /** - * TableSpec groupedEntry. - * @member {string} groupedEntry - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * DeleteTagTemplateFieldRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @instance */ - TableSpec.prototype.groupedEntry = ""; + DeleteTagTemplateFieldRequest.prototype.name = ""; /** - * Creates a new TableSpec instance using the specified properties. + * DeleteTagTemplateFieldRequest force. + * @member {boolean} force + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest + * @instance + */ + DeleteTagTemplateFieldRequest.prototype.force = false; + + /** + * Creates a new DeleteTagTemplateFieldRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITableSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest instance */ - TableSpec.create = function create(properties) { - return new TableSpec(properties); + DeleteTagTemplateFieldRequest.create = function create(properties) { + return new DeleteTagTemplateFieldRequest(properties); }; /** - * Encodes the specified TableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TableSpec.verify|verify} messages. + * Encodes the specified DeleteTagTemplateFieldRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITableSpec} message TableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TableSpec.encode = function encode(message, writer) { + DeleteTagTemplateFieldRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.groupedEntry != null && Object.hasOwnProperty.call(message, "groupedEntry")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.groupedEntry); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.force != null && Object.hasOwnProperty.call(message, "force")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.force); return writer; }; /** - * Encodes the specified TableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TableSpec.verify|verify} messages. + * Encodes the specified DeleteTagTemplateFieldRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITableSpec} message TableSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TableSpec.encodeDelimited = function encodeDelimited(message, writer) { + DeleteTagTemplateFieldRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TableSpec message from the specified reader or buffer. + * Decodes a DeleteTagTemplateFieldRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TableSpec.decode = function decode(reader, length) { + DeleteTagTemplateFieldRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TableSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.groupedEntry = reader.string(); + message.name = reader.string(); + break; + } + case 2: { + message.force = reader.bool(); break; } default: @@ -41010,124 +42080,133 @@ }; /** - * Decodes a TableSpec message from the specified reader or buffer, length delimited. + * Decodes a DeleteTagTemplateFieldRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TableSpec.decodeDelimited = function decodeDelimited(reader) { + DeleteTagTemplateFieldRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TableSpec message. + * Verifies a DeleteTagTemplateFieldRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TableSpec.verify = function verify(message) { + DeleteTagTemplateFieldRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) - if (!$util.isString(message.groupedEntry)) - return "groupedEntry: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.force != null && message.hasOwnProperty("force")) + if (typeof message.force !== "boolean") + return "force: boolean expected"; return null; }; /** - * Creates a TableSpec message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteTagTemplateFieldRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec + * @returns {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} DeleteTagTemplateFieldRequest */ - TableSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.TableSpec) + DeleteTagTemplateFieldRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.TableSpec(); - if (object.groupedEntry != null) - message.groupedEntry = String(object.groupedEntry); + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.force != null) + message.force = Boolean(object.force); return message; }; /** - * Creates a plain object from a TableSpec message. Also converts values to other types if specified. + * Creates a plain object from a DeleteTagTemplateFieldRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static - * @param {google.cloud.datacatalog.v1beta1.TableSpec} message TableSpec + * @param {google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest} message DeleteTagTemplateFieldRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TableSpec.toObject = function toObject(message, options) { + DeleteTagTemplateFieldRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.groupedEntry = ""; - if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) - object.groupedEntry = message.groupedEntry; + if (options.defaults) { + object.name = ""; + object.force = false; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.force != null && message.hasOwnProperty("force")) + object.force = message.force; return object; }; /** - * Converts this TableSpec to JSON. + * Converts this DeleteTagTemplateFieldRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @instance * @returns {Object.} JSON object */ - TableSpec.prototype.toJSON = function toJSON() { + DeleteTagTemplateFieldRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TableSpec + * Gets the default type url for DeleteTagTemplateFieldRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.TableSpec + * @memberof google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteTagTemplateFieldRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TableSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTagTemplateFieldRequest"; }; - return TableSpec; + return DeleteTagTemplateFieldRequest; })(); - v1beta1.BigQueryDateShardedSpec = (function() { + v1beta1.ListTagsRequest = (function() { /** - * Properties of a BigQueryDateShardedSpec. + * Properties of a ListTagsRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IBigQueryDateShardedSpec - * @property {string|null} [dataset] BigQueryDateShardedSpec dataset - * @property {string|null} [tablePrefix] BigQueryDateShardedSpec tablePrefix - * @property {number|Long|null} [shardCount] BigQueryDateShardedSpec shardCount + * @interface IListTagsRequest + * @property {string|null} [parent] ListTagsRequest parent + * @property {number|null} [pageSize] ListTagsRequest pageSize + * @property {string|null} [pageToken] ListTagsRequest pageToken */ /** - * Constructs a new BigQueryDateShardedSpec. + * Constructs a new ListTagsRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a BigQueryDateShardedSpec. - * @implements IBigQueryDateShardedSpec + * @classdesc Represents a ListTagsRequest. + * @implements IListTagsRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest=} [properties] Properties to set */ - function BigQueryDateShardedSpec(properties) { + function ListTagsRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -41135,103 +42214,103 @@ } /** - * BigQueryDateShardedSpec dataset. - * @member {string} dataset - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * ListTagsRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @instance */ - BigQueryDateShardedSpec.prototype.dataset = ""; + ListTagsRequest.prototype.parent = ""; /** - * BigQueryDateShardedSpec tablePrefix. - * @member {string} tablePrefix - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * ListTagsRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @instance */ - BigQueryDateShardedSpec.prototype.tablePrefix = ""; + ListTagsRequest.prototype.pageSize = 0; /** - * BigQueryDateShardedSpec shardCount. - * @member {number|Long} shardCount - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * ListTagsRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @instance */ - BigQueryDateShardedSpec.prototype.shardCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + ListTagsRequest.prototype.pageToken = ""; /** - * Creates a new BigQueryDateShardedSpec instance using the specified properties. + * Creates a new ListTagsRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec instance + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest instance */ - BigQueryDateShardedSpec.create = function create(properties) { - return new BigQueryDateShardedSpec(properties); + ListTagsRequest.create = function create(properties) { + return new ListTagsRequest(properties); }; /** - * Encodes the specified BigQueryDateShardedSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify|verify} messages. + * Encodes the specified ListTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} message ListTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryDateShardedSpec.encode = function encode(message, writer) { + ListTagsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.dataset != null && Object.hasOwnProperty.call(message, "dataset")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.dataset); - if (message.tablePrefix != null && Object.hasOwnProperty.call(message, "tablePrefix")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.tablePrefix); - if (message.shardCount != null && Object.hasOwnProperty.call(message, "shardCount")) - writer.uint32(/* id 3, wireType 0 =*/24).int64(message.shardCount); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); return writer; }; /** - * Encodes the specified BigQueryDateShardedSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify|verify} messages. + * Encodes the specified ListTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTagsRequest} message ListTagsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - BigQueryDateShardedSpec.encodeDelimited = function encodeDelimited(message, writer) { + ListTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer. + * Decodes a ListTagsRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryDateShardedSpec.decode = function decode(reader, length) { + ListTagsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTagsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.dataset = reader.string(); + message.parent = reader.string(); break; } case 2: { - message.tablePrefix = reader.string(); + message.pageSize = reader.int32(); break; } case 3: { - message.shardCount = reader.int64(); + message.pageToken = reader.string(); break; } default: @@ -41243,158 +42322,141 @@ }; /** - * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer, length delimited. + * Decodes a ListTagsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - BigQueryDateShardedSpec.decodeDelimited = function decodeDelimited(reader) { + ListTagsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a BigQueryDateShardedSpec message. + * Verifies a ListTagsRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - BigQueryDateShardedSpec.verify = function verify(message) { + ListTagsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.dataset != null && message.hasOwnProperty("dataset")) - if (!$util.isString(message.dataset)) - return "dataset: string expected"; - if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) - if (!$util.isString(message.tablePrefix)) - return "tablePrefix: string expected"; - if (message.shardCount != null && message.hasOwnProperty("shardCount")) - if (!$util.isInteger(message.shardCount) && !(message.shardCount && $util.isInteger(message.shardCount.low) && $util.isInteger(message.shardCount.high))) - return "shardCount: integer|Long expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; return null; }; /** - * Creates a BigQueryDateShardedSpec message from a plain object. Also converts values to their respective internal types. + * Creates a ListTagsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec + * @returns {google.cloud.datacatalog.v1beta1.ListTagsRequest} ListTagsRequest */ - BigQueryDateShardedSpec.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec) + ListTagsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTagsRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec(); - if (object.dataset != null) - message.dataset = String(object.dataset); - if (object.tablePrefix != null) - message.tablePrefix = String(object.tablePrefix); - if (object.shardCount != null) - if ($util.Long) - (message.shardCount = $util.Long.fromValue(object.shardCount)).unsigned = false; - else if (typeof object.shardCount === "string") - message.shardCount = parseInt(object.shardCount, 10); - else if (typeof object.shardCount === "number") - message.shardCount = object.shardCount; - else if (typeof object.shardCount === "object") - message.shardCount = new $util.LongBits(object.shardCount.low >>> 0, object.shardCount.high >>> 0).toNumber(); + var message = new $root.google.cloud.datacatalog.v1beta1.ListTagsRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); return message; }; /** - * Creates a plain object from a BigQueryDateShardedSpec message. Also converts values to other types if specified. + * Creates a plain object from a ListTagsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static - * @param {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} message BigQueryDateShardedSpec + * @param {google.cloud.datacatalog.v1beta1.ListTagsRequest} message ListTagsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - BigQueryDateShardedSpec.toObject = function toObject(message, options) { + ListTagsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.dataset = ""; - object.tablePrefix = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.shardCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.shardCount = options.longs === String ? "0" : 0; + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; } - if (message.dataset != null && message.hasOwnProperty("dataset")) - object.dataset = message.dataset; - if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) - object.tablePrefix = message.tablePrefix; - if (message.shardCount != null && message.hasOwnProperty("shardCount")) - if (typeof message.shardCount === "number") - object.shardCount = options.longs === String ? String(message.shardCount) : message.shardCount; - else - object.shardCount = options.longs === String ? $util.Long.prototype.toString.call(message.shardCount) : options.longs === Number ? new $util.LongBits(message.shardCount.low >>> 0, message.shardCount.high >>> 0).toNumber() : message.shardCount; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; return object; }; /** - * Converts this BigQueryDateShardedSpec to JSON. + * Converts this ListTagsRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @instance * @returns {Object.} JSON object */ - BigQueryDateShardedSpec.prototype.toJSON = function toJSON() { + ListTagsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for BigQueryDateShardedSpec + * Gets the default type url for ListTagsRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @memberof google.cloud.datacatalog.v1beta1.ListTagsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - BigQueryDateShardedSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTagsRequest"; }; - return BigQueryDateShardedSpec; + return ListTagsRequest; })(); - v1beta1.Tag = (function() { + v1beta1.ListTagsResponse = (function() { /** - * Properties of a Tag. + * Properties of a ListTagsResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITag - * @property {string|null} [name] Tag name - * @property {string|null} [template] Tag template - * @property {string|null} [templateDisplayName] Tag templateDisplayName - * @property {string|null} [column] Tag column - * @property {Object.|null} [fields] Tag fields + * @interface IListTagsResponse + * @property {Array.|null} [tags] ListTagsResponse tags + * @property {string|null} [nextPageToken] ListTagsResponse nextPageToken */ /** - * Constructs a new Tag. + * Constructs a new ListTagsResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a Tag. - * @implements ITag + * @classdesc Represents a ListTagsResponse. + * @implements IListTagsResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse=} [properties] Properties to set */ - function Tag(properties) { - this.fields = {}; + function ListTagsResponse(properties) { + this.tags = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -41402,167 +42464,92 @@ } /** - * Tag name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.Tag - * @instance - */ - Tag.prototype.name = ""; - - /** - * Tag template. - * @member {string} template - * @memberof google.cloud.datacatalog.v1beta1.Tag - * @instance - */ - Tag.prototype.template = ""; - - /** - * Tag templateDisplayName. - * @member {string} templateDisplayName - * @memberof google.cloud.datacatalog.v1beta1.Tag - * @instance - */ - Tag.prototype.templateDisplayName = ""; - - /** - * Tag column. - * @member {string|null|undefined} column - * @memberof google.cloud.datacatalog.v1beta1.Tag - * @instance - */ - Tag.prototype.column = null; - - /** - * Tag fields. - * @member {Object.} fields - * @memberof google.cloud.datacatalog.v1beta1.Tag + * ListTagsResponse tags. + * @member {Array.} tags + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @instance */ - Tag.prototype.fields = $util.emptyObject; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + ListTagsResponse.prototype.tags = $util.emptyArray; /** - * Tag scope. - * @member {"column"|undefined} scope - * @memberof google.cloud.datacatalog.v1beta1.Tag + * ListTagsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @instance */ - Object.defineProperty(Tag.prototype, "scope", { - get: $util.oneOfGetter($oneOfFields = ["column"]), - set: $util.oneOfSetter($oneOfFields) - }); + ListTagsResponse.prototype.nextPageToken = ""; /** - * Creates a new Tag instance using the specified properties. + * Creates a new ListTagsResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag instance + * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse instance */ - Tag.create = function create(properties) { - return new Tag(properties); + ListTagsResponse.create = function create(properties) { + return new ListTagsResponse(properties); }; /** - * Encodes the specified Tag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Tag.verify|verify} messages. + * Encodes the specified ListTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITag} message Tag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse} message ListTagsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Tag.encode = function encode(message, writer) { + ListTagsResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.template != null && Object.hasOwnProperty.call(message, "template")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.template); - if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) - for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { - writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); - $root.google.cloud.datacatalog.v1beta1.TagField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); - } - if (message.column != null && Object.hasOwnProperty.call(message, "column")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.column); - if (message.templateDisplayName != null && Object.hasOwnProperty.call(message, "templateDisplayName")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.templateDisplayName); + if (message.tags != null && message.tags.length) + for (var i = 0; i < message.tags.length; ++i) + $root.google.cloud.datacatalog.v1beta1.Tag.encode(message.tags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); return writer; }; /** - * Encodes the specified Tag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Tag.verify|verify} messages. + * Encodes the specified ListTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTagsResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITag} message Tag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTagsResponse} message ListTagsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Tag.encodeDelimited = function encodeDelimited(message, writer) { + ListTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Tag message from the specified reader or buffer. + * Decodes a ListTagsResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag + * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Tag.decode = function decode(reader, length) { + ListTagsResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Tag(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTagsResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + if (!(message.tags && message.tags.length)) + message.tags = []; + message.tags.push($root.google.cloud.datacatalog.v1beta1.Tag.decode(reader, reader.uint32())); break; } case 2: { - message.template = reader.string(); - break; - } - case 5: { - message.templateDisplayName = reader.string(); - break; - } - case 4: { - message.column = reader.string(); - break; - } - case 3: { - if (message.fields === $util.emptyObject) - message.fields = {}; - var end2 = reader.uint32() + reader.pos; - key = ""; - value = null; - while (reader.pos < end2) { - var tag2 = reader.uint32(); - switch (tag2 >>> 3) { - case 1: - key = reader.string(); - break; - case 2: - value = $root.google.cloud.datacatalog.v1beta1.TagField.decode(reader, reader.uint32()); - break; - default: - reader.skipType(tag2 & 7); - break; - } - } - message.fields[key] = value; + message.nextPageToken = reader.string(); break; } default: @@ -41574,186 +42561,151 @@ }; /** - * Decodes a Tag message from the specified reader or buffer, length delimited. + * Decodes a ListTagsResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag + * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Tag.decodeDelimited = function decodeDelimited(reader) { + ListTagsResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Tag message. + * Verifies a ListTagsResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Tag.verify = function verify(message) { + ListTagsResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.template != null && message.hasOwnProperty("template")) - if (!$util.isString(message.template)) - return "template: string expected"; - if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) - if (!$util.isString(message.templateDisplayName)) - return "templateDisplayName: string expected"; - if (message.column != null && message.hasOwnProperty("column")) { - properties.scope = 1; - if (!$util.isString(message.column)) - return "column: string expected"; - } - if (message.fields != null && message.hasOwnProperty("fields")) { - if (!$util.isObject(message.fields)) - return "fields: object expected"; - var key = Object.keys(message.fields); - for (var i = 0; i < key.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.TagField.verify(message.fields[key[i]]); + if (message.tags != null && message.hasOwnProperty("tags")) { + if (!Array.isArray(message.tags)) + return "tags: array expected"; + for (var i = 0; i < message.tags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.Tag.verify(message.tags[i]); if (error) - return "fields." + error; + return "tags." + error; } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates a Tag message from a plain object. Also converts values to their respective internal types. + * Creates a ListTagsResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag + * @returns {google.cloud.datacatalog.v1beta1.ListTagsResponse} ListTagsResponse */ - Tag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.Tag) + ListTagsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTagsResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.Tag(); - if (object.name != null) - message.name = String(object.name); - if (object.template != null) - message.template = String(object.template); - if (object.templateDisplayName != null) - message.templateDisplayName = String(object.templateDisplayName); - if (object.column != null) - message.column = String(object.column); - if (object.fields) { - if (typeof object.fields !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Tag.fields: object expected"); - message.fields = {}; - for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { - if (typeof object.fields[keys[i]] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.Tag.fields: object expected"); - message.fields[keys[i]] = $root.google.cloud.datacatalog.v1beta1.TagField.fromObject(object.fields[keys[i]]); + var message = new $root.google.cloud.datacatalog.v1beta1.ListTagsResponse(); + if (object.tags) { + if (!Array.isArray(object.tags)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ListTagsResponse.tags: array expected"); + message.tags = []; + for (var i = 0; i < object.tags.length; ++i) { + if (typeof object.tags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListTagsResponse.tags: object expected"); + message.tags[i] = $root.google.cloud.datacatalog.v1beta1.Tag.fromObject(object.tags[i]); } } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a Tag message. Also converts values to other types if specified. + * Creates a plain object from a ListTagsResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static - * @param {google.cloud.datacatalog.v1beta1.Tag} message Tag + * @param {google.cloud.datacatalog.v1beta1.ListTagsResponse} message ListTagsResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Tag.toObject = function toObject(message, options) { + ListTagsResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.objects || options.defaults) - object.fields = {}; - if (options.defaults) { - object.name = ""; - object.template = ""; - object.templateDisplayName = ""; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.template != null && message.hasOwnProperty("template")) - object.template = message.template; - var keys2; - if (message.fields && (keys2 = Object.keys(message.fields)).length) { - object.fields = {}; - for (var j = 0; j < keys2.length; ++j) - object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1beta1.TagField.toObject(message.fields[keys2[j]], options); - } - if (message.column != null && message.hasOwnProperty("column")) { - object.column = message.column; - if (options.oneofs) - object.scope = "column"; + if (options.arrays || options.defaults) + object.tags = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.tags && message.tags.length) { + object.tags = []; + for (var j = 0; j < message.tags.length; ++j) + object.tags[j] = $root.google.cloud.datacatalog.v1beta1.Tag.toObject(message.tags[j], options); } - if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) - object.templateDisplayName = message.templateDisplayName; + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this Tag to JSON. + * Converts this ListTagsResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @instance * @returns {Object.} JSON object */ - Tag.prototype.toJSON = function toJSON() { + ListTagsResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Tag + * Gets the default type url for ListTagsResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.Tag + * @memberof google.cloud.datacatalog.v1beta1.ListTagsResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Tag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Tag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTagsResponse"; }; - return Tag; + return ListTagsResponse; })(); - v1beta1.TagField = (function() { + v1beta1.ListEntriesRequest = (function() { /** - * Properties of a TagField. + * Properties of a ListEntriesRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITagField - * @property {string|null} [displayName] TagField displayName - * @property {number|null} [doubleValue] TagField doubleValue - * @property {string|null} [stringValue] TagField stringValue - * @property {boolean|null} [boolValue] TagField boolValue - * @property {google.protobuf.ITimestamp|null} [timestampValue] TagField timestampValue - * @property {google.cloud.datacatalog.v1beta1.TagField.IEnumValue|null} [enumValue] TagField enumValue - * @property {number|null} [order] TagField order + * @interface IListEntriesRequest + * @property {string|null} [parent] ListEntriesRequest parent + * @property {number|null} [pageSize] ListEntriesRequest pageSize + * @property {string|null} [pageToken] ListEntriesRequest pageToken + * @property {google.protobuf.IFieldMask|null} [readMask] ListEntriesRequest readMask */ /** - * Constructs a new TagField. + * Constructs a new ListEntriesRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a TagField. - * @implements ITagField + * @classdesc Represents a ListEntriesRequest. + * @implements IListEntriesRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITagField=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest=} [properties] Properties to set */ - function TagField(properties) { + function ListEntriesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -41761,173 +42713,117 @@ } /** - * TagField displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @instance - */ - TagField.prototype.displayName = ""; - - /** - * TagField doubleValue. - * @member {number|null|undefined} doubleValue - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @instance - */ - TagField.prototype.doubleValue = null; - - /** - * TagField stringValue. - * @member {string|null|undefined} stringValue - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @instance - */ - TagField.prototype.stringValue = null; - - /** - * TagField boolValue. - * @member {boolean|null|undefined} boolValue - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @instance - */ - TagField.prototype.boolValue = null; - - /** - * TagField timestampValue. - * @member {google.protobuf.ITimestamp|null|undefined} timestampValue - * @memberof google.cloud.datacatalog.v1beta1.TagField + * ListEntriesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @instance */ - TagField.prototype.timestampValue = null; + ListEntriesRequest.prototype.parent = ""; /** - * TagField enumValue. - * @member {google.cloud.datacatalog.v1beta1.TagField.IEnumValue|null|undefined} enumValue - * @memberof google.cloud.datacatalog.v1beta1.TagField + * ListEntriesRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @instance */ - TagField.prototype.enumValue = null; + ListEntriesRequest.prototype.pageSize = 0; /** - * TagField order. - * @member {number} order - * @memberof google.cloud.datacatalog.v1beta1.TagField + * ListEntriesRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @instance */ - TagField.prototype.order = 0; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + ListEntriesRequest.prototype.pageToken = ""; /** - * TagField kind. - * @member {"doubleValue"|"stringValue"|"boolValue"|"timestampValue"|"enumValue"|undefined} kind - * @memberof google.cloud.datacatalog.v1beta1.TagField + * ListEntriesRequest readMask. + * @member {google.protobuf.IFieldMask|null|undefined} readMask + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @instance */ - Object.defineProperty(TagField.prototype, "kind", { - get: $util.oneOfGetter($oneOfFields = ["doubleValue", "stringValue", "boolValue", "timestampValue", "enumValue"]), - set: $util.oneOfSetter($oneOfFields) - }); + ListEntriesRequest.prototype.readMask = null; /** - * Creates a new TagField instance using the specified properties. + * Creates a new ListEntriesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITagField=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField instance + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest instance */ - TagField.create = function create(properties) { - return new TagField(properties); + ListEntriesRequest.create = function create(properties) { + return new ListEntriesRequest(properties); }; /** - * Encodes the specified TagField message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.verify|verify} messages. + * Encodes the specified ListEntriesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITagField} message TagField message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagField.encode = function encode(message, writer) { + ListEntriesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) - writer.uint32(/* id 2, wireType 1 =*/17).double(message.doubleValue); - if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.stringValue); - if (message.boolValue != null && Object.hasOwnProperty.call(message, "boolValue")) - writer.uint32(/* id 4, wireType 0 =*/32).bool(message.boolValue); - if (message.timestampValue != null && Object.hasOwnProperty.call(message, "timestampValue")) - $root.google.protobuf.Timestamp.encode(message.timestampValue, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.enumValue != null && Object.hasOwnProperty.call(message, "enumValue")) - $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.encode(message.enumValue, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - if (message.order != null && Object.hasOwnProperty.call(message, "order")) - writer.uint32(/* id 7, wireType 0 =*/56).int32(message.order); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.readMask != null && Object.hasOwnProperty.call(message, "readMask")) + $root.google.protobuf.FieldMask.encode(message.readMask, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified TagField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.verify|verify} messages. + * Encodes the specified ListEntriesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ITagField} message TagField message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntriesRequest} message ListEntriesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagField.encodeDelimited = function encodeDelimited(message, writer) { + ListEntriesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagField message from the specified reader or buffer. + * Decodes a ListEntriesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagField.decode = function decode(reader, length) { + ListEntriesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagField(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); + message.parent = reader.string(); break; } case 2: { - message.doubleValue = reader.double(); + message.pageSize = reader.int32(); break; } case 3: { - message.stringValue = reader.string(); + message.pageToken = reader.string(); break; } case 4: { - message.boolValue = reader.bool(); - break; - } - case 5: { - message.timestampValue = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); - break; - } - case 6: { - message.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.decode(reader, reader.uint32()); - break; - } - case 7: { - message.order = reader.int32(); + message.readMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -41939,418 +42835,154 @@ }; /** - * Decodes a TagField message from the specified reader or buffer, length delimited. + * Decodes a ListEntriesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagField.decodeDelimited = function decodeDelimited(reader) { + ListEntriesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagField message. + * Verifies a ListEntriesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagField.verify = function verify(message) { + ListEntriesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { - properties.kind = 1; - if (typeof message.doubleValue !== "number") - return "doubleValue: number expected"; - } - if (message.stringValue != null && message.hasOwnProperty("stringValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - if (!$util.isString(message.stringValue)) - return "stringValue: string expected"; - } - if (message.boolValue != null && message.hasOwnProperty("boolValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - if (typeof message.boolValue !== "boolean") - return "boolValue: boolean expected"; - } - if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - { - var error = $root.google.protobuf.Timestamp.verify(message.timestampValue); - if (error) - return "timestampValue." + error; - } - } - if (message.enumValue != null && message.hasOwnProperty("enumValue")) { - if (properties.kind === 1) - return "kind: multiple values"; - properties.kind = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify(message.enumValue); - if (error) - return "enumValue." + error; - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + if (message.readMask != null && message.hasOwnProperty("readMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.readMask); + if (error) + return "readMask." + error; } - if (message.order != null && message.hasOwnProperty("order")) - if (!$util.isInteger(message.order)) - return "order: integer expected"; return null; }; /** - * Creates a TagField message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntriesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesRequest} ListEntriesRequest */ - TagField.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagField) + ListEntriesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.TagField(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.doubleValue != null) - message.doubleValue = Number(object.doubleValue); - if (object.stringValue != null) - message.stringValue = String(object.stringValue); - if (object.boolValue != null) - message.boolValue = Boolean(object.boolValue); - if (object.timestampValue != null) { - if (typeof object.timestampValue !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.TagField.timestampValue: object expected"); - message.timestampValue = $root.google.protobuf.Timestamp.fromObject(object.timestampValue); - } - if (object.enumValue != null) { - if (typeof object.enumValue !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.TagField.enumValue: object expected"); - message.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.fromObject(object.enumValue); + var message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + if (object.readMask != null) { + if (typeof object.readMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesRequest.readMask: object expected"); + message.readMask = $root.google.protobuf.FieldMask.fromObject(object.readMask); } - if (object.order != null) - message.order = object.order | 0; return message; }; /** - * Creates a plain object from a TagField message. Also converts values to other types if specified. + * Creates a plain object from a ListEntriesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.TagField} message TagField + * @param {google.cloud.datacatalog.v1beta1.ListEntriesRequest} message ListEntriesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagField.toObject = function toObject(message, options) { + ListEntriesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.displayName = ""; - object.order = 0; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { - object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; - if (options.oneofs) - object.kind = "doubleValue"; - } - if (message.stringValue != null && message.hasOwnProperty("stringValue")) { - object.stringValue = message.stringValue; - if (options.oneofs) - object.kind = "stringValue"; - } - if (message.boolValue != null && message.hasOwnProperty("boolValue")) { - object.boolValue = message.boolValue; - if (options.oneofs) - object.kind = "boolValue"; - } - if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { - object.timestampValue = $root.google.protobuf.Timestamp.toObject(message.timestampValue, options); - if (options.oneofs) - object.kind = "timestampValue"; - } - if (message.enumValue != null && message.hasOwnProperty("enumValue")) { - object.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.toObject(message.enumValue, options); - if (options.oneofs) - object.kind = "enumValue"; + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; + object.readMask = null; } - if (message.order != null && message.hasOwnProperty("order")) - object.order = message.order; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.readMask != null && message.hasOwnProperty("readMask")) + object.readMask = $root.google.protobuf.FieldMask.toObject(message.readMask, options); return object; }; /** - * Converts this TagField to JSON. + * Converts this ListEntriesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @instance * @returns {Object.} JSON object */ - TagField.prototype.toJSON = function toJSON() { + ListEntriesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagField + * Gets the default type url for ListEntriesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.TagField + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntriesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagField"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntriesRequest"; }; - TagField.EnumValue = (function() { - - /** - * Properties of an EnumValue. - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @interface IEnumValue - * @property {string|null} [displayName] EnumValue displayName - */ - - /** - * Constructs a new EnumValue. - * @memberof google.cloud.datacatalog.v1beta1.TagField - * @classdesc Represents an EnumValue. - * @implements IEnumValue - * @constructor - * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue=} [properties] Properties to set - */ - function EnumValue(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * EnumValue displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @instance - */ - EnumValue.prototype.displayName = ""; - - /** - * Creates a new EnumValue instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue instance - */ - EnumValue.create = function create(properties) { - return new EnumValue(properties); - }; - - /** - * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - return writer; - }; - - /** - * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValue message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValue.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - return null; - }; - - /** - * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue - */ - EnumValue.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue(); - if (object.displayName != null) - message.displayName = String(object.displayName); - return message; - }; - - /** - * Creates a plain object from an EnumValue message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.TagField.EnumValue} message EnumValue - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValue.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.displayName = ""; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - return object; - }; - - /** - * Converts this EnumValue to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @instance - * @returns {Object.} JSON object - */ - EnumValue.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValue - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagField.EnumValue"; - }; - - return EnumValue; - })(); - - return TagField; + return ListEntriesRequest; })(); - v1beta1.TagTemplate = (function() { + v1beta1.ListEntriesResponse = (function() { /** - * Properties of a TagTemplate. + * Properties of a ListEntriesResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITagTemplate - * @property {string|null} [name] TagTemplate name - * @property {string|null} [displayName] TagTemplate displayName - * @property {Object.|null} [fields] TagTemplate fields + * @interface IListEntriesResponse + * @property {Array.|null} [entries] ListEntriesResponse entries + * @property {string|null} [nextPageToken] ListEntriesResponse nextPageToken */ /** - * Constructs a new TagTemplate. + * Constructs a new ListEntriesResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a TagTemplate. - * @implements ITagTemplate + * @classdesc Represents a ListEntriesResponse. + * @implements IListEntriesResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITagTemplate=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse=} [properties] Properties to set */ - function TagTemplate(properties) { - this.fields = {}; + function ListEntriesResponse(properties) { + this.entries = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -42358,125 +42990,92 @@ } /** - * TagTemplate name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate - * @instance - */ - TagTemplate.prototype.name = ""; - - /** - * TagTemplate displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * ListEntriesResponse entries. + * @member {Array.} entries + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @instance */ - TagTemplate.prototype.displayName = ""; + ListEntriesResponse.prototype.entries = $util.emptyArray; /** - * TagTemplate fields. - * @member {Object.} fields - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * ListEntriesResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @instance */ - TagTemplate.prototype.fields = $util.emptyObject; + ListEntriesResponse.prototype.nextPageToken = ""; /** - * Creates a new TagTemplate instance using the specified properties. + * Creates a new ListEntriesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplate=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate instance + * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse instance */ - TagTemplate.create = function create(properties) { - return new TagTemplate(properties); + ListEntriesResponse.create = function create(properties) { + return new ListEntriesResponse(properties); }; /** - * Encodes the specified TagTemplate message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplate.verify|verify} messages. + * Encodes the specified ListEntriesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplate} message TagTemplate message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplate.encode = function encode(message, writer) { + ListEntriesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) - for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { - writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); - $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); - } - return writer; - }; + if (message.entries != null && message.entries.length) + for (var i = 0; i < message.entries.length; ++i) + $root.google.cloud.datacatalog.v1beta1.Entry.encode(message.entries[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + return writer; + }; /** - * Encodes the specified TagTemplate message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplate.verify|verify} messages. + * Encodes the specified ListEntriesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListEntriesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplate} message TagTemplate message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListEntriesResponse} message ListEntriesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplate.encodeDelimited = function encodeDelimited(message, writer) { + ListEntriesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagTemplate message from the specified reader or buffer. + * Decodes a ListEntriesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplate.decode = function decode(reader, length) { + ListEntriesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagTemplate(), key, value; + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + if (!(message.entries && message.entries.length)) + message.entries = []; + message.entries.push($root.google.cloud.datacatalog.v1beta1.Entry.decode(reader, reader.uint32())); break; } case 2: { - message.displayName = reader.string(); - break; - } - case 3: { - if (message.fields === $util.emptyObject) - message.fields = {}; - var end2 = reader.uint32() + reader.pos; - key = ""; - value = null; - while (reader.pos < end2) { - var tag2 = reader.uint32(); - switch (tag2 >>> 3) { - case 1: - key = reader.string(); - break; - case 2: - value = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); - break; - default: - reader.skipType(tag2 & 7); - break; - } - } - message.fields[key] = value; + message.nextPageToken = reader.string(); break; } default: @@ -42488,163 +43087,171 @@ }; /** - * Decodes a TagTemplate message from the specified reader or buffer, length delimited. + * Decodes a ListEntriesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplate.decodeDelimited = function decodeDelimited(reader) { + ListEntriesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagTemplate message. + * Verifies a ListEntriesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagTemplate.verify = function verify(message) { + ListEntriesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.fields != null && message.hasOwnProperty("fields")) { - if (!$util.isObject(message.fields)) - return "fields: object expected"; - var key = Object.keys(message.fields); - for (var i = 0; i < key.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.fields[key[i]]); + if (message.entries != null && message.hasOwnProperty("entries")) { + if (!Array.isArray(message.entries)) + return "entries: array expected"; + for (var i = 0; i < message.entries.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.Entry.verify(message.entries[i]); if (error) - return "fields." + error; + return "entries." + error; } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates a TagTemplate message from a plain object. Also converts values to their respective internal types. + * Creates a ListEntriesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate + * @returns {google.cloud.datacatalog.v1beta1.ListEntriesResponse} ListEntriesResponse */ - TagTemplate.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagTemplate) + ListEntriesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.TagTemplate(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.fields) { - if (typeof object.fields !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplate.fields: object expected"); - message.fields = {}; - for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { - if (typeof object.fields[keys[i]] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplate.fields: object expected"); - message.fields[keys[i]] = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.fields[keys[i]]); + var message = new $root.google.cloud.datacatalog.v1beta1.ListEntriesResponse(); + if (object.entries) { + if (!Array.isArray(object.entries)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesResponse.entries: array expected"); + message.entries = []; + for (var i = 0; i < object.entries.length; ++i) { + if (typeof object.entries[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListEntriesResponse.entries: object expected"); + message.entries[i] = $root.google.cloud.datacatalog.v1beta1.Entry.fromObject(object.entries[i]); } } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from a TagTemplate message. Also converts values to other types if specified. + * Creates a plain object from a ListEntriesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.TagTemplate} message TagTemplate + * @param {google.cloud.datacatalog.v1beta1.ListEntriesResponse} message ListEntriesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagTemplate.toObject = function toObject(message, options) { + ListEntriesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.objects || options.defaults) - object.fields = {}; - if (options.defaults) { - object.name = ""; - object.displayName = ""; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - var keys2; - if (message.fields && (keys2 = Object.keys(message.fields)).length) { - object.fields = {}; - for (var j = 0; j < keys2.length; ++j) - object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.fields[keys2[j]], options); + if (options.arrays || options.defaults) + object.entries = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.entries && message.entries.length) { + object.entries = []; + for (var j = 0; j < message.entries.length; ++j) + object.entries[j] = $root.google.cloud.datacatalog.v1beta1.Entry.toObject(message.entries[j], options); } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this TagTemplate to JSON. + * Converts this ListEntriesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @instance * @returns {Object.} JSON object */ - TagTemplate.prototype.toJSON = function toJSON() { + ListEntriesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagTemplate + * Gets the default type url for ListEntriesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @memberof google.cloud.datacatalog.v1beta1.ListEntriesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagTemplate.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListEntriesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagTemplate"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListEntriesResponse"; }; - return TagTemplate; + return ListEntriesResponse; })(); - v1beta1.TagTemplateField = (function() { + /** + * EntryType enum. + * @name google.cloud.datacatalog.v1beta1.EntryType + * @enum {number} + * @property {number} ENTRY_TYPE_UNSPECIFIED=0 ENTRY_TYPE_UNSPECIFIED value + * @property {number} TABLE=2 TABLE value + * @property {number} MODEL=5 MODEL value + * @property {number} DATA_STREAM=3 DATA_STREAM value + * @property {number} FILESET=4 FILESET value + */ + v1beta1.EntryType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "ENTRY_TYPE_UNSPECIFIED"] = 0; + values[valuesById[2] = "TABLE"] = 2; + values[valuesById[5] = "MODEL"] = 5; + values[valuesById[3] = "DATA_STREAM"] = 3; + values[valuesById[4] = "FILESET"] = 4; + return values; + })(); + + v1beta1.GcsFilesetSpec = (function() { /** - * Properties of a TagTemplateField. + * Properties of a GcsFilesetSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITagTemplateField - * @property {string|null} [name] TagTemplateField name - * @property {string|null} [displayName] TagTemplateField displayName - * @property {google.cloud.datacatalog.v1beta1.IFieldType|null} [type] TagTemplateField type - * @property {boolean|null} [isRequired] TagTemplateField isRequired - * @property {number|null} [order] TagTemplateField order + * @interface IGcsFilesetSpec + * @property {Array.|null} [filePatterns] GcsFilesetSpec filePatterns + * @property {Array.|null} [sampleGcsFileSpecs] GcsFilesetSpec sampleGcsFileSpecs */ /** - * Constructs a new TagTemplateField. + * Constructs a new GcsFilesetSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a TagTemplateField. - * @implements ITagTemplateField + * @classdesc Represents a GcsFilesetSpec. + * @implements IGcsFilesetSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec=} [properties] Properties to set */ - function TagTemplateField(properties) { + function GcsFilesetSpec(properties) { + this.filePatterns = []; + this.sampleGcsFileSpecs = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -42652,131 +43259,95 @@ } /** - * TagTemplateField name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.name = ""; - - /** - * TagTemplateField displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.displayName = ""; - - /** - * TagTemplateField type. - * @member {google.cloud.datacatalog.v1beta1.IFieldType|null|undefined} type - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField - * @instance - */ - TagTemplateField.prototype.type = null; - - /** - * TagTemplateField isRequired. - * @member {boolean} isRequired - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * GcsFilesetSpec filePatterns. + * @member {Array.} filePatterns + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @instance */ - TagTemplateField.prototype.isRequired = false; + GcsFilesetSpec.prototype.filePatterns = $util.emptyArray; /** - * TagTemplateField order. - * @member {number} order - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * GcsFilesetSpec sampleGcsFileSpecs. + * @member {Array.} sampleGcsFileSpecs + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @instance */ - TagTemplateField.prototype.order = 0; + GcsFilesetSpec.prototype.sampleGcsFileSpecs = $util.emptyArray; /** - * Creates a new TagTemplateField instance using the specified properties. + * Creates a new GcsFilesetSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField instance + * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec instance */ - TagTemplateField.create = function create(properties) { - return new TagTemplateField(properties); + GcsFilesetSpec.create = function create(properties) { + return new GcsFilesetSpec(properties); }; /** - * Encodes the specified TagTemplateField message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplateField.verify|verify} messages. + * Encodes the specified GcsFilesetSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField} message TagTemplateField message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplateField.encode = function encode(message, writer) { + GcsFilesetSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - $root.google.cloud.datacatalog.v1beta1.FieldType.encode(message.type, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.isRequired != null && Object.hasOwnProperty.call(message, "isRequired")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.isRequired); - if (message.order != null && Object.hasOwnProperty.call(message, "order")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.order); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.name); + if (message.filePatterns != null && message.filePatterns.length) + for (var i = 0; i < message.filePatterns.length; ++i) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePatterns[i]); + if (message.sampleGcsFileSpecs != null && message.sampleGcsFileSpecs.length) + for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) + $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.encode(message.sampleGcsFileSpecs[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified TagTemplateField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplateField.verify|verify} messages. + * Encodes the specified GcsFilesetSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFilesetSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField} message TagTemplateField message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGcsFilesetSpec} message GcsFilesetSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TagTemplateField.encodeDelimited = function encodeDelimited(message, writer) { + GcsFilesetSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TagTemplateField message from the specified reader or buffer. + * Decodes a GcsFilesetSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplateField.decode = function decode(reader, length) { + GcsFilesetSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagTemplateField(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 6: { - message.name = reader.string(); - break; - } case 1: { - message.displayName = reader.string(); + if (!(message.filePatterns && message.filePatterns.length)) + message.filePatterns = []; + message.filePatterns.push(reader.string()); break; } case 2: { - message.type = $root.google.cloud.datacatalog.v1beta1.FieldType.decode(reader, reader.uint32()); - break; - } - case 3: { - message.isRequired = reader.bool(); - break; - } - case 5: { - message.order = reader.int32(); + if (!(message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length)) + message.sampleGcsFileSpecs = []; + message.sampleGcsFileSpecs.push($root.google.cloud.datacatalog.v1beta1.GcsFileSpec.decode(reader, reader.uint32())); break; } default: @@ -42788,161 +43359,162 @@ }; /** - * Decodes a TagTemplateField message from the specified reader or buffer, length delimited. + * Decodes a GcsFilesetSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TagTemplateField.decodeDelimited = function decodeDelimited(reader) { + GcsFilesetSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TagTemplateField message. + * Verifies a GcsFilesetSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TagTemplateField.verify = function verify(message) { + GcsFilesetSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.type != null && message.hasOwnProperty("type")) { - var error = $root.google.cloud.datacatalog.v1beta1.FieldType.verify(message.type); - if (error) - return "type." + error; + if (message.filePatterns != null && message.hasOwnProperty("filePatterns")) { + if (!Array.isArray(message.filePatterns)) + return "filePatterns: array expected"; + for (var i = 0; i < message.filePatterns.length; ++i) + if (!$util.isString(message.filePatterns[i])) + return "filePatterns: string[] expected"; + } + if (message.sampleGcsFileSpecs != null && message.hasOwnProperty("sampleGcsFileSpecs")) { + if (!Array.isArray(message.sampleGcsFileSpecs)) + return "sampleGcsFileSpecs: array expected"; + for (var i = 0; i < message.sampleGcsFileSpecs.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.verify(message.sampleGcsFileSpecs[i]); + if (error) + return "sampleGcsFileSpecs." + error; + } } - if (message.isRequired != null && message.hasOwnProperty("isRequired")) - if (typeof message.isRequired !== "boolean") - return "isRequired: boolean expected"; - if (message.order != null && message.hasOwnProperty("order")) - if (!$util.isInteger(message.order)) - return "order: integer expected"; return null; }; /** - * Creates a TagTemplateField message from a plain object. Also converts values to their respective internal types. + * Creates a GcsFilesetSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField + * @returns {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} GcsFilesetSpec */ - TagTemplateField.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagTemplateField) + GcsFilesetSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.TagTemplateField(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.type != null) { - if (typeof object.type !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplateField.type: object expected"); - message.type = $root.google.cloud.datacatalog.v1beta1.FieldType.fromObject(object.type); + var message = new $root.google.cloud.datacatalog.v1beta1.GcsFilesetSpec(); + if (object.filePatterns) { + if (!Array.isArray(object.filePatterns)) + throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.filePatterns: array expected"); + message.filePatterns = []; + for (var i = 0; i < object.filePatterns.length; ++i) + message.filePatterns[i] = String(object.filePatterns[i]); + } + if (object.sampleGcsFileSpecs) { + if (!Array.isArray(object.sampleGcsFileSpecs)) + throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.sampleGcsFileSpecs: array expected"); + message.sampleGcsFileSpecs = []; + for (var i = 0; i < object.sampleGcsFileSpecs.length; ++i) { + if (typeof object.sampleGcsFileSpecs[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFilesetSpec.sampleGcsFileSpecs: object expected"); + message.sampleGcsFileSpecs[i] = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.fromObject(object.sampleGcsFileSpecs[i]); + } } - if (object.isRequired != null) - message.isRequired = Boolean(object.isRequired); - if (object.order != null) - message.order = object.order | 0; return message; }; /** - * Creates a plain object from a TagTemplateField message. Also converts values to other types if specified. + * Creates a plain object from a GcsFilesetSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static - * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} message TagTemplateField + * @param {google.cloud.datacatalog.v1beta1.GcsFilesetSpec} message GcsFilesetSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TagTemplateField.toObject = function toObject(message, options) { + GcsFilesetSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.displayName = ""; - object.type = null; - object.isRequired = false; - object.order = 0; - object.name = ""; + if (options.arrays || options.defaults) { + object.filePatterns = []; + object.sampleGcsFileSpecs = []; + } + if (message.filePatterns && message.filePatterns.length) { + object.filePatterns = []; + for (var j = 0; j < message.filePatterns.length; ++j) + object.filePatterns[j] = message.filePatterns[j]; + } + if (message.sampleGcsFileSpecs && message.sampleGcsFileSpecs.length) { + object.sampleGcsFileSpecs = []; + for (var j = 0; j < message.sampleGcsFileSpecs.length; ++j) + object.sampleGcsFileSpecs[j] = $root.google.cloud.datacatalog.v1beta1.GcsFileSpec.toObject(message.sampleGcsFileSpecs[j], options); } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.type != null && message.hasOwnProperty("type")) - object.type = $root.google.cloud.datacatalog.v1beta1.FieldType.toObject(message.type, options); - if (message.isRequired != null && message.hasOwnProperty("isRequired")) - object.isRequired = message.isRequired; - if (message.order != null && message.hasOwnProperty("order")) - object.order = message.order; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; return object; }; /** - * Converts this TagTemplateField to JSON. + * Converts this GcsFilesetSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @instance * @returns {Object.} JSON object */ - TagTemplateField.prototype.toJSON = function toJSON() { + GcsFilesetSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for TagTemplateField + * Gets the default type url for GcsFilesetSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @memberof google.cloud.datacatalog.v1beta1.GcsFilesetSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - TagTemplateField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GcsFilesetSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagTemplateField"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GcsFilesetSpec"; }; - return TagTemplateField; + return GcsFilesetSpec; })(); - v1beta1.FieldType = (function() { + v1beta1.GcsFileSpec = (function() { /** - * Properties of a FieldType. + * Properties of a GcsFileSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IFieldType - * @property {google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType|null} [primitiveType] FieldType primitiveType - * @property {google.cloud.datacatalog.v1beta1.FieldType.IEnumType|null} [enumType] FieldType enumType + * @interface IGcsFileSpec + * @property {string|null} [filePath] GcsFileSpec filePath + * @property {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null} [gcsTimestamps] GcsFileSpec gcsTimestamps + * @property {number|Long|null} [sizeBytes] GcsFileSpec sizeBytes */ /** - * Constructs a new FieldType. + * Constructs a new GcsFileSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a FieldType. - * @implements IFieldType + * @classdesc Represents a GcsFileSpec. + * @implements IGcsFileSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.IFieldType=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec=} [properties] Properties to set */ - function FieldType(properties) { + function GcsFileSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -42950,103 +43522,103 @@ } /** - * FieldType primitiveType. - * @member {google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType|null|undefined} primitiveType - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * GcsFileSpec filePath. + * @member {string} filePath + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @instance */ - FieldType.prototype.primitiveType = null; + GcsFileSpec.prototype.filePath = ""; /** - * FieldType enumType. - * @member {google.cloud.datacatalog.v1beta1.FieldType.IEnumType|null|undefined} enumType - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * GcsFileSpec gcsTimestamps. + * @member {google.cloud.datacatalog.v1beta1.ISystemTimestamps|null|undefined} gcsTimestamps + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @instance */ - FieldType.prototype.enumType = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + GcsFileSpec.prototype.gcsTimestamps = null; /** - * FieldType typeDecl. - * @member {"primitiveType"|"enumType"|undefined} typeDecl - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * GcsFileSpec sizeBytes. + * @member {number|Long} sizeBytes + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @instance */ - Object.defineProperty(FieldType.prototype, "typeDecl", { - get: $util.oneOfGetter($oneOfFields = ["primitiveType", "enumType"]), - set: $util.oneOfSetter($oneOfFields) - }); + GcsFileSpec.prototype.sizeBytes = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * Creates a new FieldType instance using the specified properties. + * Creates a new GcsFileSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IFieldType=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType instance + * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec instance */ - FieldType.create = function create(properties) { - return new FieldType(properties); + GcsFileSpec.create = function create(properties) { + return new GcsFileSpec(properties); }; /** - * Encodes the specified FieldType message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.verify|verify} messages. + * Encodes the specified GcsFileSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFileSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IFieldType} message FieldType message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec} message GcsFileSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldType.encode = function encode(message, writer) { + GcsFileSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.primitiveType != null && Object.hasOwnProperty.call(message, "primitiveType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.primitiveType); - if (message.enumType != null && Object.hasOwnProperty.call(message, "enumType")) - $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.encode(message.enumType, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.filePath != null && Object.hasOwnProperty.call(message, "filePath")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.filePath); + if (message.gcsTimestamps != null && Object.hasOwnProperty.call(message, "gcsTimestamps")) + $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.encode(message.gcsTimestamps, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.sizeBytes != null && Object.hasOwnProperty.call(message, "sizeBytes")) + writer.uint32(/* id 4, wireType 0 =*/32).int64(message.sizeBytes); return writer; }; /** - * Encodes the specified FieldType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.verify|verify} messages. + * Encodes the specified GcsFileSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GcsFileSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IFieldType} message FieldType message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGcsFileSpec} message GcsFileSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldType.encodeDelimited = function encodeDelimited(message, writer) { + GcsFileSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FieldType message from the specified reader or buffer. + * Decodes a GcsFileSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldType.decode = function decode(reader, length) { + GcsFileSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GcsFileSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.primitiveType = reader.int32(); + message.filePath = reader.string(); break; } case 2: { - message.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.decode(reader, reader.uint32()); + message.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.decode(reader, reader.uint32()); + break; + } + case 4: { + message.sizeBytes = reader.int64(); break; } default: @@ -43058,1095 +43630,968 @@ }; /** - * Decodes a FieldType message from the specified reader or buffer, length delimited. + * Decodes a GcsFileSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldType.decodeDelimited = function decodeDelimited(reader) { + GcsFileSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FieldType message. + * Verifies a GcsFileSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FieldType.verify = function verify(message) { + GcsFileSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { - properties.typeDecl = 1; - switch (message.primitiveType) { - default: - return "primitiveType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - break; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (properties.typeDecl === 1) - return "typeDecl: multiple values"; - properties.typeDecl = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify(message.enumType); - if (error) - return "enumType." + error; - } + if (message.filePath != null && message.hasOwnProperty("filePath")) + if (!$util.isString(message.filePath)) + return "filePath: string expected"; + if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) { + var error = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.verify(message.gcsTimestamps); + if (error) + return "gcsTimestamps." + error; } + if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) + if (!$util.isInteger(message.sizeBytes) && !(message.sizeBytes && $util.isInteger(message.sizeBytes.low) && $util.isInteger(message.sizeBytes.high))) + return "sizeBytes: integer|Long expected"; return null; }; /** - * Creates a FieldType message from a plain object. Also converts values to their respective internal types. + * Creates a GcsFileSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType + * @returns {google.cloud.datacatalog.v1beta1.GcsFileSpec} GcsFileSpec */ - FieldType.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType) + GcsFileSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GcsFileSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.FieldType(); - switch (object.primitiveType) { - default: - if (typeof object.primitiveType === "number") { - message.primitiveType = object.primitiveType; - break; - } - break; - case "PRIMITIVE_TYPE_UNSPECIFIED": - case 0: - message.primitiveType = 0; - break; - case "DOUBLE": - case 1: - message.primitiveType = 1; - break; - case "STRING": - case 2: - message.primitiveType = 2; - break; - case "BOOL": - case 3: - message.primitiveType = 3; - break; - case "TIMESTAMP": - case 4: - message.primitiveType = 4; - break; - } - if (object.enumType != null) { - if (typeof object.enumType !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.enumType: object expected"); - message.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.fromObject(object.enumType); + var message = new $root.google.cloud.datacatalog.v1beta1.GcsFileSpec(); + if (object.filePath != null) + message.filePath = String(object.filePath); + if (object.gcsTimestamps != null) { + if (typeof object.gcsTimestamps !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.GcsFileSpec.gcsTimestamps: object expected"); + message.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.fromObject(object.gcsTimestamps); } + if (object.sizeBytes != null) + if ($util.Long) + (message.sizeBytes = $util.Long.fromValue(object.sizeBytes)).unsigned = false; + else if (typeof object.sizeBytes === "string") + message.sizeBytes = parseInt(object.sizeBytes, 10); + else if (typeof object.sizeBytes === "number") + message.sizeBytes = object.sizeBytes; + else if (typeof object.sizeBytes === "object") + message.sizeBytes = new $util.LongBits(object.sizeBytes.low >>> 0, object.sizeBytes.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from a FieldType message. Also converts values to other types if specified. + * Creates a plain object from a GcsFileSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType} message FieldType + * @param {google.cloud.datacatalog.v1beta1.GcsFileSpec} message GcsFileSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FieldType.toObject = function toObject(message, options) { + GcsFileSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { - object.primitiveType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType[message.primitiveType] === undefined ? message.primitiveType : $root.google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType[message.primitiveType] : message.primitiveType; - if (options.oneofs) - object.typeDecl = "primitiveType"; - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - object.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.toObject(message.enumType, options); - if (options.oneofs) - object.typeDecl = "enumType"; + if (options.defaults) { + object.filePath = ""; + object.gcsTimestamps = null; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.sizeBytes = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.sizeBytes = options.longs === String ? "0" : 0; } + if (message.filePath != null && message.hasOwnProperty("filePath")) + object.filePath = message.filePath; + if (message.gcsTimestamps != null && message.hasOwnProperty("gcsTimestamps")) + object.gcsTimestamps = $root.google.cloud.datacatalog.v1beta1.SystemTimestamps.toObject(message.gcsTimestamps, options); + if (message.sizeBytes != null && message.hasOwnProperty("sizeBytes")) + if (typeof message.sizeBytes === "number") + object.sizeBytes = options.longs === String ? String(message.sizeBytes) : message.sizeBytes; + else + object.sizeBytes = options.longs === String ? $util.Long.prototype.toString.call(message.sizeBytes) : options.longs === Number ? new $util.LongBits(message.sizeBytes.low >>> 0, message.sizeBytes.high >>> 0).toNumber() : message.sizeBytes; return object; }; /** - * Converts this FieldType to JSON. + * Converts this GcsFileSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @instance * @returns {Object.} JSON object */ - FieldType.prototype.toJSON = function toJSON() { + GcsFileSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FieldType + * Gets the default type url for GcsFileSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @memberof google.cloud.datacatalog.v1beta1.GcsFileSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FieldType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GcsFileSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GcsFileSpec"; }; - FieldType.EnumType = (function() { + return GcsFileSpec; + })(); - /** - * Properties of an EnumType. - * @memberof google.cloud.datacatalog.v1beta1.FieldType - * @interface IEnumType - * @property {Array.|null} [allowedValues] EnumType allowedValues - */ + v1beta1.SystemTimestamps = (function() { - /** - * Constructs a new EnumType. - * @memberof google.cloud.datacatalog.v1beta1.FieldType - * @classdesc Represents an EnumType. - * @implements IEnumType - * @constructor - * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType=} [properties] Properties to set - */ - function EnumType(properties) { - this.allowedValues = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Properties of a SystemTimestamps. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISystemTimestamps + * @property {google.protobuf.ITimestamp|null} [createTime] SystemTimestamps createTime + * @property {google.protobuf.ITimestamp|null} [updateTime] SystemTimestamps updateTime + * @property {google.protobuf.ITimestamp|null} [expireTime] SystemTimestamps expireTime + */ - /** - * EnumType allowedValues. - * @member {Array.} allowedValues - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @instance - */ - EnumType.prototype.allowedValues = $util.emptyArray; + /** + * Constructs a new SystemTimestamps. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a SystemTimestamps. + * @implements ISystemTimestamps + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps=} [properties] Properties to set + */ + function SystemTimestamps(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new EnumType instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType instance - */ - EnumType.create = function create(properties) { - return new EnumType(properties); - }; + /** + * SystemTimestamps createTime. + * @member {google.protobuf.ITimestamp|null|undefined} createTime + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @instance + */ + SystemTimestamps.prototype.createTime = null; - /** - * Encodes the specified EnumType message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType} message EnumType message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumType.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.allowedValues != null && message.allowedValues.length) - for (var i = 0; i < message.allowedValues.length; ++i) - $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.encode(message.allowedValues[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - return writer; - }; + /** + * SystemTimestamps updateTime. + * @member {google.protobuf.ITimestamp|null|undefined} updateTime + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @instance + */ + SystemTimestamps.prototype.updateTime = null; - /** - * Encodes the specified EnumType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType} message EnumType message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumType.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * SystemTimestamps expireTime. + * @member {google.protobuf.ITimestamp|null|undefined} expireTime + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @instance + */ + SystemTimestamps.prototype.expireTime = null; - /** - * Decodes an EnumType message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumType.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.allowedValues && message.allowedValues.length)) - message.allowedValues = []; - message.allowedValues.push($root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Creates a new SystemTimestamps instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps instance + */ + SystemTimestamps.create = function create(properties) { + return new SystemTimestamps(properties); + }; - /** - * Decodes an EnumType message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumType.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified SystemTimestamps message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SystemTimestamps.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps} message SystemTimestamps message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SystemTimestamps.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.createTime != null && Object.hasOwnProperty.call(message, "createTime")) + $root.google.protobuf.Timestamp.encode(message.createTime, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateTime != null && Object.hasOwnProperty.call(message, "updateTime")) + $root.google.protobuf.Timestamp.encode(message.updateTime, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.expireTime != null && Object.hasOwnProperty.call(message, "expireTime")) + $root.google.protobuf.Timestamp.encode(message.expireTime, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; - /** - * Verifies an EnumType message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumType.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.allowedValues != null && message.hasOwnProperty("allowedValues")) { - if (!Array.isArray(message.allowedValues)) - return "allowedValues: array expected"; - for (var i = 0; i < message.allowedValues.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify(message.allowedValues[i]); - if (error) - return "allowedValues." + error; - } - } - return null; - }; + /** + * Encodes the specified SystemTimestamps message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SystemTimestamps.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {google.cloud.datacatalog.v1beta1.ISystemTimestamps} message SystemTimestamps message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SystemTimestamps.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Creates an EnumType message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType - */ - EnumType.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType(); - if (object.allowedValues) { - if (!Array.isArray(object.allowedValues)) - throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.EnumType.allowedValues: array expected"); - message.allowedValues = []; - for (var i = 0; i < object.allowedValues.length; ++i) { - if (typeof object.allowedValues[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.EnumType.allowedValues: object expected"); - message.allowedValues[i] = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.fromObject(object.allowedValues[i]); + /** + * Decodes a SystemTimestamps message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SystemTimestamps.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SystemTimestamps(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.createTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 2: { + message.updateTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 3: { + message.expireTime = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Creates a plain object from an EnumType message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType} message EnumType - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumType.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.allowedValues = []; - if (message.allowedValues && message.allowedValues.length) { - object.allowedValues = []; - for (var j = 0; j < message.allowedValues.length; ++j) - object.allowedValues[j] = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.toObject(message.allowedValues[j], options); - } - return object; - }; - - /** - * Converts this EnumType to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @instance - * @returns {Object.} JSON object - */ - EnumType.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumType - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType.EnumType"; - }; - - EnumType.EnumValue = (function() { - - /** - * Properties of an EnumValue. - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @interface IEnumValue - * @property {string|null} [displayName] EnumValue displayName - */ - - /** - * Constructs a new EnumValue. - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType - * @classdesc Represents an EnumValue. - * @implements IEnumValue - * @constructor - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue=} [properties] Properties to set - */ - function EnumValue(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * EnumValue displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @instance - */ - EnumValue.prototype.displayName = ""; - - /** - * Creates a new EnumValue instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue instance - */ - EnumValue.create = function create(properties) { - return new EnumValue(properties); - }; - - /** - * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); - return writer; - }; - - /** - * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumValue.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.displayName = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumValue message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumValue.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumValue message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumValue.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - return null; - }; - - /** - * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue - */ - EnumValue.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue(); - if (object.displayName != null) - message.displayName = String(object.displayName); - return message; - }; - - /** - * Creates a plain object from an EnumValue message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} message EnumValue - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumValue.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.displayName = ""; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - return object; - }; - - /** - * Converts this EnumValue to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @instance - * @returns {Object.} JSON object - */ - EnumValue.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumValue - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue"; - }; - - return EnumValue; - })(); - - return EnumType; - })(); + } + return message; + }; /** - * PrimitiveType enum. - * @name google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType - * @enum {number} - * @property {number} PRIMITIVE_TYPE_UNSPECIFIED=0 PRIMITIVE_TYPE_UNSPECIFIED value - * @property {number} DOUBLE=1 DOUBLE value - * @property {number} STRING=2 STRING value - * @property {number} BOOL=3 BOOL value - * @property {number} TIMESTAMP=4 TIMESTAMP value + * Decodes a SystemTimestamps message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldType.PrimitiveType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "PRIMITIVE_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "DOUBLE"] = 1; - values[valuesById[2] = "STRING"] = 2; - values[valuesById[3] = "BOOL"] = 3; - values[valuesById[4] = "TIMESTAMP"] = 4; - return values; - })(); - - return FieldType; - })(); - - v1beta1.PolicyTagManager = (function() { + SystemTimestamps.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Constructs a new PolicyTagManager service. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a PolicyTagManager - * @extends $protobuf.rpc.Service - * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * Verifies a SystemTimestamps message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - function PolicyTagManager(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); - } - - (PolicyTagManager.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManager; + SystemTimestamps.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.createTime != null && message.hasOwnProperty("createTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.createTime); + if (error) + return "createTime." + error; + } + if (message.updateTime != null && message.hasOwnProperty("updateTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.updateTime); + if (error) + return "updateTime." + error; + } + if (message.expireTime != null && message.hasOwnProperty("expireTime")) { + var error = $root.google.protobuf.Timestamp.verify(message.expireTime); + if (error) + return "expireTime." + error; + } + return null; + }; /** - * Creates new PolicyTagManager service using the specified rpc implementation. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * Creates a SystemTimestamps message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {PolicyTagManager} RPC service. Useful where requests and/or responses are streamed. + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.SystemTimestamps} SystemTimestamps */ - PolicyTagManager.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); + SystemTimestamps.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SystemTimestamps) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.SystemTimestamps(); + if (object.createTime != null) { + if (typeof object.createTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.createTime: object expected"); + message.createTime = $root.google.protobuf.Timestamp.fromObject(object.createTime); + } + if (object.updateTime != null) { + if (typeof object.updateTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.updateTime: object expected"); + message.updateTime = $root.google.protobuf.Timestamp.fromObject(object.updateTime); + } + if (object.expireTime != null) { + if (typeof object.expireTime !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SystemTimestamps.expireTime: object expected"); + message.expireTime = $root.google.protobuf.Timestamp.fromObject(object.expireTime); + } + return message; }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|createTaxonomy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef CreateTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy + * Creates a plain object from a SystemTimestamps message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {google.cloud.datacatalog.v1beta1.SystemTimestamps} message SystemTimestamps + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ + SystemTimestamps.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.createTime = null; + object.updateTime = null; + object.expireTime = null; + } + if (message.createTime != null && message.hasOwnProperty("createTime")) + object.createTime = $root.google.protobuf.Timestamp.toObject(message.createTime, options); + if (message.updateTime != null && message.hasOwnProperty("updateTime")) + object.updateTime = $root.google.protobuf.Timestamp.toObject(message.updateTime, options); + if (message.expireTime != null && message.hasOwnProperty("expireTime")) + object.expireTime = $root.google.protobuf.Timestamp.toObject(message.expireTime, options); + return object; + }; /** - * Calls CreateTaxonomy. - * @function createTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * Converts this SystemTimestamps to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.CreateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 + * @returns {Object.} JSON object */ - Object.defineProperty(PolicyTagManager.prototype.createTaxonomy = function createTaxonomy(request, callback) { - return this.rpcCall(createTaxonomy, $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); - }, "name", { value: "CreateTaxonomy" }); + SystemTimestamps.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Calls CreateTaxonomy. - * @function createTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Gets the default type url for SystemTimestamps + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.SystemTimestamps + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + SystemTimestamps.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SystemTimestamps"; + }; + + return SystemTimestamps; + })(); + + v1beta1.Schema = (function() { /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|deleteTaxonomy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef DeleteTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Properties of a Schema. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISchema + * @property {Array.|null} [columns] Schema columns */ /** - * Calls DeleteTaxonomy. - * @function deleteTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.DeleteTaxonomyCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * Constructs a new Schema. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a Schema. + * @implements ISchema + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISchema=} [properties] Properties to set */ - Object.defineProperty(PolicyTagManager.prototype.deleteTaxonomy = function deleteTaxonomy(request, callback) { - return this.rpcCall(deleteTaxonomy, $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeleteTaxonomy" }); + function Schema(properties) { + this.columns = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Calls DeleteTaxonomy. - * @function deleteTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * Schema columns. + * @member {Array.} columns + * @memberof google.cloud.datacatalog.v1beta1.Schema * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + Schema.prototype.columns = $util.emptyArray; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|updateTaxonomy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef UpdateTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy + * Creates a new Schema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {google.cloud.datacatalog.v1beta1.ISchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema instance */ + Schema.create = function create(properties) { + return new Schema(properties); + }; /** - * Calls UpdateTaxonomy. - * @function updateTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.UpdateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 + * Encodes the specified Schema message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Schema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {google.cloud.datacatalog.v1beta1.ISchema} message Schema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(PolicyTagManager.prototype.updateTaxonomy = function updateTaxonomy(request, callback) { - return this.rpcCall(updateTaxonomy, $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); - }, "name", { value: "UpdateTaxonomy" }); + Schema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.columns != null && message.columns.length) + for (var i = 0; i < message.columns.length; ++i) + $root.google.cloud.datacatalog.v1beta1.ColumnSchema.encode(message.columns[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; /** - * Calls UpdateTaxonomy. - * @function updateTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Encodes the specified Schema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Schema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {google.cloud.datacatalog.v1beta1.ISchema} message Schema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + Schema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|listTaxonomies}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef ListTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} [response] ListTaxonomiesResponse + * Decodes a Schema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + Schema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Schema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 2: { + if (!(message.columns && message.columns.length)) + message.columns = []; + message.columns.push($root.google.cloud.datacatalog.v1beta1.ColumnSchema.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Calls ListTaxonomies. - * @function listTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.ListTaxonomiesCallback} callback Node-style callback called with the error, if any, and ListTaxonomiesResponse - * @returns {undefined} - * @variation 1 + * Decodes a Schema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Object.defineProperty(PolicyTagManager.prototype.listTaxonomies = function listTaxonomies(request, callback) { - return this.rpcCall(listTaxonomies, $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse, request, callback); - }, "name", { value: "ListTaxonomies" }); + Schema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls ListTaxonomies. - * @function listTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Verifies a Schema message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ + Schema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.columns != null && message.hasOwnProperty("columns")) { + if (!Array.isArray(message.columns)) + return "columns: array expected"; + for (var i = 0; i < message.columns.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.verify(message.columns[i]); + if (error) + return "columns." + error; + } + } + return null; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getTaxonomy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef GetTaxonomyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy + * Creates a Schema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.Schema} Schema */ + Schema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.Schema) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.Schema(); + if (object.columns) { + if (!Array.isArray(object.columns)) + throw TypeError(".google.cloud.datacatalog.v1beta1.Schema.columns: array expected"); + message.columns = []; + for (var i = 0; i < object.columns.length; ++i) { + if (typeof object.columns[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Schema.columns: object expected"); + message.columns[i] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.fromObject(object.columns[i]); + } + } + return message; + }; /** - * Calls GetTaxonomy. - * @function getTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy - * @returns {undefined} - * @variation 1 + * Creates a plain object from a Schema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {google.cloud.datacatalog.v1beta1.Schema} message Schema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ - Object.defineProperty(PolicyTagManager.prototype.getTaxonomy = function getTaxonomy(request, callback) { - return this.rpcCall(getTaxonomy, $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); - }, "name", { value: "GetTaxonomy" }); + Schema.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.columns = []; + if (message.columns && message.columns.length) { + object.columns = []; + for (var j = 0; j < message.columns.length; ++j) + object.columns[j] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.toObject(message.columns[j], options); + } + return object; + }; /** - * Calls GetTaxonomy. - * @function getTaxonomy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * Converts this Schema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.Schema * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * @returns {Object.} JSON object */ + Schema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|createPolicyTag}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef CreatePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag + * Gets the default type url for Schema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.Schema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + Schema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Schema"; + }; - /** - * Calls CreatePolicyTag. - * @function createPolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.CreatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.createPolicyTag = function createPolicyTag(request, callback) { - return this.rpcCall(createPolicyTag, $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); - }, "name", { value: "CreatePolicyTag" }); + return Schema; + })(); - /** - * Calls CreatePolicyTag. - * @function createPolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ + v1beta1.ColumnSchema = (function() { /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|deletePolicyTag}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef DeletePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.protobuf.Empty} [response] Empty + * Properties of a ColumnSchema. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IColumnSchema + * @property {string|null} [column] ColumnSchema column + * @property {string|null} [type] ColumnSchema type + * @property {string|null} [description] ColumnSchema description + * @property {string|null} [mode] ColumnSchema mode + * @property {Array.|null} [subcolumns] ColumnSchema subcolumns */ /** - * Calls DeletePolicyTag. - * @function deletePolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.DeletePolicyTagCallback} callback Node-style callback called with the error, if any, and Empty - * @returns {undefined} - * @variation 1 + * Constructs a new ColumnSchema. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a ColumnSchema. + * @implements IColumnSchema + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IColumnSchema=} [properties] Properties to set */ - Object.defineProperty(PolicyTagManager.prototype.deletePolicyTag = function deletePolicyTag(request, callback) { - return this.rpcCall(deletePolicyTag, $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest, $root.google.protobuf.Empty, request, callback); - }, "name", { value: "DeletePolicyTag" }); + function ColumnSchema(properties) { + this.subcolumns = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Calls DeletePolicyTag. - * @function deletePolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * ColumnSchema column. + * @member {string} column + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|updatePolicyTag}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef UpdatePolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag */ + ColumnSchema.prototype.column = ""; /** - * Calls UpdatePolicyTag. - * @function updatePolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * ColumnSchema type. + * @member {string} type + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.UpdatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManager.prototype.updatePolicyTag = function updatePolicyTag(request, callback) { - return this.rpcCall(updatePolicyTag, $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); - }, "name", { value: "UpdatePolicyTag" }); + ColumnSchema.prototype.type = ""; /** - * Calls UpdatePolicyTag. - * @function updatePolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * ColumnSchema description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|listPolicyTags}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef ListPolicyTagsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} [response] ListPolicyTagsResponse */ + ColumnSchema.prototype.description = ""; /** - * Calls ListPolicyTags. - * @function listPolicyTags - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * ColumnSchema mode. + * @member {string} mode + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.ListPolicyTagsCallback} callback Node-style callback called with the error, if any, and ListPolicyTagsResponse - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManager.prototype.listPolicyTags = function listPolicyTags(request, callback) { - return this.rpcCall(listPolicyTags, $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest, $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse, request, callback); - }, "name", { value: "ListPolicyTags" }); + ColumnSchema.prototype.mode = ""; /** - * Calls ListPolicyTags. - * @function listPolicyTags - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * ColumnSchema subcolumns. + * @member {Array.} subcolumns + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + ColumnSchema.prototype.subcolumns = $util.emptyArray; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getPolicyTag}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef GetPolicyTagCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag + * Creates a new ColumnSchema instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {google.cloud.datacatalog.v1beta1.IColumnSchema=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema instance */ + ColumnSchema.create = function create(properties) { + return new ColumnSchema(properties); + }; /** - * Calls GetPolicyTag. - * @function getPolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetPolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag - * @returns {undefined} - * @variation 1 + * Encodes the specified ColumnSchema message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ColumnSchema.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {google.cloud.datacatalog.v1beta1.IColumnSchema} message ColumnSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(PolicyTagManager.prototype.getPolicyTag = function getPolicyTag(request, callback) { - return this.rpcCall(getPolicyTag, $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); - }, "name", { value: "GetPolicyTag" }); + ColumnSchema.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); + if (message.mode != null && Object.hasOwnProperty.call(message, "mode")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.mode); + if (message.column != null && Object.hasOwnProperty.call(message, "column")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.column); + if (message.subcolumns != null && message.subcolumns.length) + for (var i = 0; i < message.subcolumns.length; ++i) + $root.google.cloud.datacatalog.v1beta1.ColumnSchema.encode(message.subcolumns[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + return writer; + }; /** - * Calls GetPolicyTag. - * @function getPolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Encodes the specified ColumnSchema message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ColumnSchema.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {google.cloud.datacatalog.v1beta1.IColumnSchema} message ColumnSchema message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + ColumnSchema.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getIamPolicy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef GetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy + * Decodes a ColumnSchema message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + ColumnSchema.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ColumnSchema(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 6: { + message.column = reader.string(); + break; + } + case 1: { + message.type = reader.string(); + break; + } + case 2: { + message.description = reader.string(); + break; + } + case 3: { + message.mode = reader.string(); + break; + } + case 7: { + if (!(message.subcolumns && message.subcolumns.length)) + message.subcolumns = []; + message.subcolumns.push($root.google.cloud.datacatalog.v1beta1.ColumnSchema.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 + * Decodes a ColumnSchema message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Object.defineProperty(PolicyTagManager.prototype.getIamPolicy = function getIamPolicy(request, callback) { - return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "GetIamPolicy" }); + ColumnSchema.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Verifies a ColumnSchema message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ + ColumnSchema.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.column != null && message.hasOwnProperty("column")) + if (!$util.isString(message.column)) + return "column: string expected"; + if (message.type != null && message.hasOwnProperty("type")) + if (!$util.isString(message.type)) + return "type: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.mode != null && message.hasOwnProperty("mode")) + if (!$util.isString(message.mode)) + return "mode: string expected"; + if (message.subcolumns != null && message.hasOwnProperty("subcolumns")) { + if (!Array.isArray(message.subcolumns)) + return "subcolumns: array expected"; + for (var i = 0; i < message.subcolumns.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.verify(message.subcolumns[i]); + if (error) + return "subcolumns." + error; + } + } + return null; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|setIamPolicy}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef SetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy - */ - - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManager.prototype.setIamPolicy = function setIamPolicy(request, callback) { - return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "SetIamPolicy" }); - - /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates a ColumnSchema message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ColumnSchema} ColumnSchema */ + ColumnSchema.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ColumnSchema) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ColumnSchema(); + if (object.column != null) + message.column = String(object.column); + if (object.type != null) + message.type = String(object.type); + if (object.description != null) + message.description = String(object.description); + if (object.mode != null) + message.mode = String(object.mode); + if (object.subcolumns) { + if (!Array.isArray(object.subcolumns)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ColumnSchema.subcolumns: array expected"); + message.subcolumns = []; + for (var i = 0; i < object.subcolumns.length; ++i) { + if (typeof object.subcolumns[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ColumnSchema.subcolumns: object expected"); + message.subcolumns[i] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.fromObject(object.subcolumns[i]); + } + } + return message; + }; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|testIamPermissions}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @typedef TestIamPermissionsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse + * Creates a plain object from a ColumnSchema message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {google.cloud.datacatalog.v1beta1.ColumnSchema} message ColumnSchema + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ + ColumnSchema.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.subcolumns = []; + if (options.defaults) { + object.type = ""; + object.description = ""; + object.mode = ""; + object.column = ""; + } + if (message.type != null && message.hasOwnProperty("type")) + object.type = message.type; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.mode != null && message.hasOwnProperty("mode")) + object.mode = message.mode; + if (message.column != null && message.hasOwnProperty("column")) + object.column = message.column; + if (message.subcolumns && message.subcolumns.length) { + object.subcolumns = []; + for (var j = 0; j < message.subcolumns.length; ++j) + object.subcolumns[j] = $root.google.cloud.datacatalog.v1beta1.ColumnSchema.toObject(message.subcolumns[j], options); + } + return object; + }; /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * Converts this ColumnSchema to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse - * @returns {undefined} - * @variation 1 + * @returns {Object.} JSON object */ - Object.defineProperty(PolicyTagManager.prototype.testIamPermissions = function testIamPermissions(request, callback) { - return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); - }, "name", { value: "TestIamPermissions" }); + ColumnSchema.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Gets the default type url for ColumnSchema + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ColumnSchema + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + ColumnSchema.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ColumnSchema"; + }; - return PolicyTagManager; + return ColumnSchema; })(); - v1beta1.Taxonomy = (function() { + v1beta1.SearchCatalogResult = (function() { /** - * Properties of a Taxonomy. + * Properties of a SearchCatalogResult. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ITaxonomy - * @property {string|null} [name] Taxonomy name - * @property {string|null} [displayName] Taxonomy displayName - * @property {string|null} [description] Taxonomy description - * @property {Array.|null} [activatedPolicyTypes] Taxonomy activatedPolicyTypes + * @interface ISearchCatalogResult + * @property {google.cloud.datacatalog.v1beta1.SearchResultType|null} [searchResultType] SearchCatalogResult searchResultType + * @property {string|null} [searchResultSubtype] SearchCatalogResult searchResultSubtype + * @property {string|null} [relativeResourceName] SearchCatalogResult relativeResourceName + * @property {string|null} [linkedResource] SearchCatalogResult linkedResource */ /** - * Constructs a new Taxonomy. + * Constructs a new SearchCatalogResult. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a Taxonomy. - * @implements ITaxonomy + * @classdesc Represents a SearchCatalogResult. + * @implements ISearchCatalogResult * @constructor - * @param {google.cloud.datacatalog.v1beta1.ITaxonomy=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult=} [properties] Properties to set */ - function Taxonomy(properties) { - this.activatedPolicyTypes = []; + function SearchCatalogResult(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -44154,128 +44599,117 @@ } /** - * Taxonomy name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * SearchCatalogResult searchResultType. + * @member {google.cloud.datacatalog.v1beta1.SearchResultType} searchResultType + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @instance */ - Taxonomy.prototype.name = ""; + SearchCatalogResult.prototype.searchResultType = 0; /** - * Taxonomy displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * SearchCatalogResult searchResultSubtype. + * @member {string} searchResultSubtype + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @instance */ - Taxonomy.prototype.displayName = ""; + SearchCatalogResult.prototype.searchResultSubtype = ""; /** - * Taxonomy description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * SearchCatalogResult relativeResourceName. + * @member {string} relativeResourceName + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @instance */ - Taxonomy.prototype.description = ""; + SearchCatalogResult.prototype.relativeResourceName = ""; /** - * Taxonomy activatedPolicyTypes. - * @member {Array.} activatedPolicyTypes - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * SearchCatalogResult linkedResource. + * @member {string} linkedResource + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @instance */ - Taxonomy.prototype.activatedPolicyTypes = $util.emptyArray; + SearchCatalogResult.prototype.linkedResource = ""; /** - * Creates a new Taxonomy instance using the specified properties. + * Creates a new SearchCatalogResult instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1beta1.ITaxonomy=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy instance + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult instance */ - Taxonomy.create = function create(properties) { - return new Taxonomy(properties); + SearchCatalogResult.create = function create(properties) { + return new SearchCatalogResult(properties); }; /** - * Encodes the specified Taxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Taxonomy.verify|verify} messages. + * Encodes the specified SearchCatalogResult message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1beta1.ITaxonomy} message Taxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Taxonomy.encode = function encode(message, writer) { + SearchCatalogResult.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { - writer.uint32(/* id 6, wireType 2 =*/50).fork(); - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - writer.int32(message.activatedPolicyTypes[i]); - writer.ldelim(); - } + if (message.searchResultType != null && Object.hasOwnProperty.call(message, "searchResultType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.searchResultType); + if (message.searchResultSubtype != null && Object.hasOwnProperty.call(message, "searchResultSubtype")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.searchResultSubtype); + if (message.relativeResourceName != null && Object.hasOwnProperty.call(message, "relativeResourceName")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.relativeResourceName); + if (message.linkedResource != null && Object.hasOwnProperty.call(message, "linkedResource")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.linkedResource); return writer; }; /** - * Encodes the specified Taxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Taxonomy.verify|verify} messages. + * Encodes the specified SearchCatalogResult message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SearchCatalogResult.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1beta1.ITaxonomy} message Taxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ISearchCatalogResult} message SearchCatalogResult message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Taxonomy.encodeDelimited = function encodeDelimited(message, writer) { + SearchCatalogResult.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Taxonomy message from the specified reader or buffer. + * Decodes a SearchCatalogResult message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Taxonomy.decode = function decode(reader, length) { + SearchCatalogResult.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Taxonomy(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.searchResultType = reader.int32(); break; } case 2: { - message.displayName = reader.string(); + message.searchResultSubtype = reader.string(); break; } case 3: { - message.description = reader.string(); + message.relativeResourceName = reader.string(); break; } - case 6: { - if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) - message.activatedPolicyTypes = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.activatedPolicyTypes.push(reader.int32()); - } else - message.activatedPolicyTypes.push(reader.int32()); + case 4: { + message.linkedResource = reader.string(); break; } default: @@ -44287,198 +44721,196 @@ }; /** - * Decodes a Taxonomy message from the specified reader or buffer, length delimited. + * Decodes a SearchCatalogResult message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Taxonomy.decodeDelimited = function decodeDelimited(reader) { + SearchCatalogResult.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Taxonomy message. + * Verifies a SearchCatalogResult message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Taxonomy.verify = function verify(message) { + SearchCatalogResult.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { - if (!Array.isArray(message.activatedPolicyTypes)) - return "activatedPolicyTypes: array expected"; - for (var i = 0; i < message.activatedPolicyTypes.length; ++i) - switch (message.activatedPolicyTypes[i]) { - default: - return "activatedPolicyTypes: enum value[] expected"; - case 0: - case 1: - break; - } - } + if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) + switch (message.searchResultType) { + default: + return "searchResultType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + break; + } + if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) + if (!$util.isString(message.searchResultSubtype)) + return "searchResultSubtype: string expected"; + if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) + if (!$util.isString(message.relativeResourceName)) + return "relativeResourceName: string expected"; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + if (!$util.isString(message.linkedResource)) + return "linkedResource: string expected"; return null; }; /** - * Creates a Taxonomy message from a plain object. Also converts values to their respective internal types. + * Creates a SearchCatalogResult message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy + * @returns {google.cloud.datacatalog.v1beta1.SearchCatalogResult} SearchCatalogResult */ - Taxonomy.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.Taxonomy) + SearchCatalogResult.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.Taxonomy(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.activatedPolicyTypes) { - if (!Array.isArray(object.activatedPolicyTypes)) - throw TypeError(".google.cloud.datacatalog.v1beta1.Taxonomy.activatedPolicyTypes: array expected"); - message.activatedPolicyTypes = []; - for (var i = 0; i < object.activatedPolicyTypes.length; ++i) - switch (object.activatedPolicyTypes[i]) { - default: - if (typeof object.activatedPolicyTypes[i] === "number") { - message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; - break; - } - case "POLICY_TYPE_UNSPECIFIED": - case 0: - message.activatedPolicyTypes[i] = 0; - break; - case "FINE_GRAINED_ACCESS_CONTROL": - case 1: - message.activatedPolicyTypes[i] = 1; - break; - } + var message = new $root.google.cloud.datacatalog.v1beta1.SearchCatalogResult(); + switch (object.searchResultType) { + default: + if (typeof object.searchResultType === "number") { + message.searchResultType = object.searchResultType; + break; + } + break; + case "SEARCH_RESULT_TYPE_UNSPECIFIED": + case 0: + message.searchResultType = 0; + break; + case "ENTRY": + case 1: + message.searchResultType = 1; + break; + case "TAG_TEMPLATE": + case 2: + message.searchResultType = 2; + break; + case "ENTRY_GROUP": + case 3: + message.searchResultType = 3; + break; } + if (object.searchResultSubtype != null) + message.searchResultSubtype = String(object.searchResultSubtype); + if (object.relativeResourceName != null) + message.relativeResourceName = String(object.relativeResourceName); + if (object.linkedResource != null) + message.linkedResource = String(object.linkedResource); return message; }; /** - * Creates a plain object from a Taxonomy message. Also converts values to other types if specified. + * Creates a plain object from a SearchCatalogResult message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static - * @param {google.cloud.datacatalog.v1beta1.Taxonomy} message Taxonomy + * @param {google.cloud.datacatalog.v1beta1.SearchCatalogResult} message SearchCatalogResult * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Taxonomy.toObject = function toObject(message, options) { + SearchCatalogResult.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.activatedPolicyTypes = []; if (options.defaults) { - object.name = ""; - object.displayName = ""; - object.description = ""; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { - object.activatedPolicyTypes = []; - for (var j = 0; j < message.activatedPolicyTypes.length; ++j) - object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; + object.searchResultType = options.enums === String ? "SEARCH_RESULT_TYPE_UNSPECIFIED" : 0; + object.searchResultSubtype = ""; + object.relativeResourceName = ""; + object.linkedResource = ""; } + if (message.searchResultType != null && message.hasOwnProperty("searchResultType")) + object.searchResultType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.SearchResultType[message.searchResultType] === undefined ? message.searchResultType : $root.google.cloud.datacatalog.v1beta1.SearchResultType[message.searchResultType] : message.searchResultType; + if (message.searchResultSubtype != null && message.hasOwnProperty("searchResultSubtype")) + object.searchResultSubtype = message.searchResultSubtype; + if (message.relativeResourceName != null && message.hasOwnProperty("relativeResourceName")) + object.relativeResourceName = message.relativeResourceName; + if (message.linkedResource != null && message.hasOwnProperty("linkedResource")) + object.linkedResource = message.linkedResource; return object; }; /** - * Converts this Taxonomy to JSON. + * Converts this SearchCatalogResult to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @instance * @returns {Object.} JSON object */ - Taxonomy.prototype.toJSON = function toJSON() { + SearchCatalogResult.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Taxonomy + * Gets the default type url for SearchCatalogResult * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @memberof google.cloud.datacatalog.v1beta1.SearchCatalogResult * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Taxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + SearchCatalogResult.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Taxonomy"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SearchCatalogResult"; }; - /** - * PolicyType enum. - * @name google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType - * @enum {number} - * @property {number} POLICY_TYPE_UNSPECIFIED=0 POLICY_TYPE_UNSPECIFIED value - * @property {number} FINE_GRAINED_ACCESS_CONTROL=1 FINE_GRAINED_ACCESS_CONTROL value - */ - Taxonomy.PolicyType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "POLICY_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "FINE_GRAINED_ACCESS_CONTROL"] = 1; - return values; - })(); + return SearchCatalogResult; + })(); - return Taxonomy; + /** + * SearchResultType enum. + * @name google.cloud.datacatalog.v1beta1.SearchResultType + * @enum {number} + * @property {number} SEARCH_RESULT_TYPE_UNSPECIFIED=0 SEARCH_RESULT_TYPE_UNSPECIFIED value + * @property {number} ENTRY=1 ENTRY value + * @property {number} TAG_TEMPLATE=2 TAG_TEMPLATE value + * @property {number} ENTRY_GROUP=3 ENTRY_GROUP value + */ + v1beta1.SearchResultType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "SEARCH_RESULT_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "ENTRY"] = 1; + values[valuesById[2] = "TAG_TEMPLATE"] = 2; + values[valuesById[3] = "ENTRY_GROUP"] = 3; + return values; })(); - v1beta1.PolicyTag = (function() { + v1beta1.BigQueryTableSpec = (function() { /** - * Properties of a PolicyTag. + * Properties of a BigQueryTableSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IPolicyTag - * @property {string|null} [name] PolicyTag name - * @property {string|null} [displayName] PolicyTag displayName - * @property {string|null} [description] PolicyTag description - * @property {string|null} [parentPolicyTag] PolicyTag parentPolicyTag - * @property {Array.|null} [childPolicyTags] PolicyTag childPolicyTags + * @interface IBigQueryTableSpec + * @property {google.cloud.datacatalog.v1beta1.TableSourceType|null} [tableSourceType] BigQueryTableSpec tableSourceType + * @property {google.cloud.datacatalog.v1beta1.IViewSpec|null} [viewSpec] BigQueryTableSpec viewSpec + * @property {google.cloud.datacatalog.v1beta1.ITableSpec|null} [tableSpec] BigQueryTableSpec tableSpec */ /** - * Constructs a new PolicyTag. + * Constructs a new BigQueryTableSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a PolicyTag. - * @implements IPolicyTag + * @classdesc Represents a BigQueryTableSpec. + * @implements IBigQueryTableSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.IPolicyTag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec=} [properties] Properties to set */ - function PolicyTag(properties) { - this.childPolicyTags = []; + function BigQueryTableSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -44486,134 +44918,117 @@ } /** - * PolicyTag name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * BigQueryTableSpec tableSourceType. + * @member {google.cloud.datacatalog.v1beta1.TableSourceType} tableSourceType + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @instance */ - PolicyTag.prototype.name = ""; + BigQueryTableSpec.prototype.tableSourceType = 0; /** - * PolicyTag displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * BigQueryTableSpec viewSpec. + * @member {google.cloud.datacatalog.v1beta1.IViewSpec|null|undefined} viewSpec + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @instance */ - PolicyTag.prototype.displayName = ""; + BigQueryTableSpec.prototype.viewSpec = null; /** - * PolicyTag description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * BigQueryTableSpec tableSpec. + * @member {google.cloud.datacatalog.v1beta1.ITableSpec|null|undefined} tableSpec + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @instance */ - PolicyTag.prototype.description = ""; + BigQueryTableSpec.prototype.tableSpec = null; - /** - * PolicyTag parentPolicyTag. - * @member {string} parentPolicyTag - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag - * @instance - */ - PolicyTag.prototype.parentPolicyTag = ""; + // OneOf field names bound to virtual getters and setters + var $oneOfFields; /** - * PolicyTag childPolicyTags. - * @member {Array.} childPolicyTags - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * BigQueryTableSpec typeSpec. + * @member {"viewSpec"|"tableSpec"|undefined} typeSpec + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @instance */ - PolicyTag.prototype.childPolicyTags = $util.emptyArray; + Object.defineProperty(BigQueryTableSpec.prototype, "typeSpec", { + get: $util.oneOfGetter($oneOfFields = ["viewSpec", "tableSpec"]), + set: $util.oneOfSetter($oneOfFields) + }); /** - * Creates a new PolicyTag instance using the specified properties. + * Creates a new BigQueryTableSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IPolicyTag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag instance + * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec instance */ - PolicyTag.create = function create(properties) { - return new PolicyTag(properties); + BigQueryTableSpec.create = function create(properties) { + return new BigQueryTableSpec(properties); }; /** - * Encodes the specified PolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.PolicyTag.verify|verify} messages. + * Encodes the specified BigQueryTableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IPolicyTag} message PolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PolicyTag.encode = function encode(message, writer) { + BigQueryTableSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.parentPolicyTag != null && Object.hasOwnProperty.call(message, "parentPolicyTag")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.parentPolicyTag); - if (message.childPolicyTags != null && message.childPolicyTags.length) - for (var i = 0; i < message.childPolicyTags.length; ++i) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.childPolicyTags[i]); + if (message.tableSourceType != null && Object.hasOwnProperty.call(message, "tableSourceType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.tableSourceType); + if (message.viewSpec != null && Object.hasOwnProperty.call(message, "viewSpec")) + $root.google.cloud.datacatalog.v1beta1.ViewSpec.encode(message.viewSpec, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.tableSpec != null && Object.hasOwnProperty.call(message, "tableSpec")) + $root.google.cloud.datacatalog.v1beta1.TableSpec.encode(message.tableSpec, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified PolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.PolicyTag.verify|verify} messages. + * Encodes the specified BigQueryTableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryTableSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IPolicyTag} message PolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IBigQueryTableSpec} message BigQueryTableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - PolicyTag.encodeDelimited = function encodeDelimited(message, writer) { + BigQueryTableSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a PolicyTag message from the specified reader or buffer. + * Decodes a BigQueryTableSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PolicyTag.decode = function decode(reader, length) { + BigQueryTableSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.PolicyTag(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.tableSourceType = reader.int32(); break; } case 2: { - message.displayName = reader.string(); + message.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.decode(reader, reader.uint32()); break; } case 3: { - message.description = reader.string(); - break; - } - case 4: { - message.parentPolicyTag = reader.string(); - break; - } - case 5: { - if (!(message.childPolicyTags && message.childPolicyTags.length)) - message.childPolicyTags = []; - message.childPolicyTags.push(reader.string()); + message.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.decode(reader, reader.uint32()); break; } default: @@ -44625,169 +45040,201 @@ }; /** - * Decodes a PolicyTag message from the specified reader or buffer, length delimited. + * Decodes a BigQueryTableSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - PolicyTag.decodeDelimited = function decodeDelimited(reader) { + BigQueryTableSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a PolicyTag message. + * Verifies a BigQueryTableSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - PolicyTag.verify = function verify(message) { + BigQueryTableSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) - if (!$util.isString(message.parentPolicyTag)) - return "parentPolicyTag: string expected"; - if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { - if (!Array.isArray(message.childPolicyTags)) - return "childPolicyTags: array expected"; - for (var i = 0; i < message.childPolicyTags.length; ++i) - if (!$util.isString(message.childPolicyTags[i])) - return "childPolicyTags: string[] expected"; + var properties = {}; + if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) + switch (message.tableSourceType) { + default: + return "tableSourceType: enum value expected"; + case 0: + case 2: + case 5: + break; + } + if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.ViewSpec.verify(message.viewSpec); + if (error) + return "viewSpec." + error; + } + } + if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { + if (properties.typeSpec === 1) + return "typeSpec: multiple values"; + properties.typeSpec = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.TableSpec.verify(message.tableSpec); + if (error) + return "tableSpec." + error; + } } return null; }; /** - * Creates a PolicyTag message from a plain object. Also converts values to their respective internal types. + * Creates a BigQueryTableSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag + * @returns {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} BigQueryTableSpec */ - PolicyTag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.PolicyTag) + BigQueryTableSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.PolicyTag(); - if (object.name != null) - message.name = String(object.name); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.parentPolicyTag != null) - message.parentPolicyTag = String(object.parentPolicyTag); - if (object.childPolicyTags) { - if (!Array.isArray(object.childPolicyTags)) - throw TypeError(".google.cloud.datacatalog.v1beta1.PolicyTag.childPolicyTags: array expected"); - message.childPolicyTags = []; - for (var i = 0; i < object.childPolicyTags.length; ++i) - message.childPolicyTags[i] = String(object.childPolicyTags[i]); + var message = new $root.google.cloud.datacatalog.v1beta1.BigQueryTableSpec(); + switch (object.tableSourceType) { + default: + if (typeof object.tableSourceType === "number") { + message.tableSourceType = object.tableSourceType; + break; + } + break; + case "TABLE_SOURCE_TYPE_UNSPECIFIED": + case 0: + message.tableSourceType = 0; + break; + case "BIGQUERY_VIEW": + case 2: + message.tableSourceType = 2; + break; + case "BIGQUERY_TABLE": + case 5: + message.tableSourceType = 5; + break; + } + if (object.viewSpec != null) { + if (typeof object.viewSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.BigQueryTableSpec.viewSpec: object expected"); + message.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.fromObject(object.viewSpec); + } + if (object.tableSpec != null) { + if (typeof object.tableSpec !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.BigQueryTableSpec.tableSpec: object expected"); + message.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.fromObject(object.tableSpec); } return message; }; /** - * Creates a plain object from a PolicyTag message. Also converts values to other types if specified. + * Creates a plain object from a BigQueryTableSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.PolicyTag} message PolicyTag + * @param {google.cloud.datacatalog.v1beta1.BigQueryTableSpec} message BigQueryTableSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - PolicyTag.toObject = function toObject(message, options) { + BigQueryTableSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.childPolicyTags = []; - if (options.defaults) { - object.name = ""; - object.displayName = ""; - object.description = ""; - object.parentPolicyTag = ""; + if (options.defaults) + object.tableSourceType = options.enums === String ? "TABLE_SOURCE_TYPE_UNSPECIFIED" : 0; + if (message.tableSourceType != null && message.hasOwnProperty("tableSourceType")) + object.tableSourceType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.TableSourceType[message.tableSourceType] === undefined ? message.tableSourceType : $root.google.cloud.datacatalog.v1beta1.TableSourceType[message.tableSourceType] : message.tableSourceType; + if (message.viewSpec != null && message.hasOwnProperty("viewSpec")) { + object.viewSpec = $root.google.cloud.datacatalog.v1beta1.ViewSpec.toObject(message.viewSpec, options); + if (options.oneofs) + object.typeSpec = "viewSpec"; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) - object.parentPolicyTag = message.parentPolicyTag; - if (message.childPolicyTags && message.childPolicyTags.length) { - object.childPolicyTags = []; - for (var j = 0; j < message.childPolicyTags.length; ++j) - object.childPolicyTags[j] = message.childPolicyTags[j]; + if (message.tableSpec != null && message.hasOwnProperty("tableSpec")) { + object.tableSpec = $root.google.cloud.datacatalog.v1beta1.TableSpec.toObject(message.tableSpec, options); + if (options.oneofs) + object.typeSpec = "tableSpec"; } return object; }; /** - * Converts this PolicyTag to JSON. + * Converts this BigQueryTableSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @instance * @returns {Object.} JSON object */ - PolicyTag.prototype.toJSON = function toJSON() { + BigQueryTableSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for PolicyTag + * Gets the default type url for BigQueryTableSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @memberof google.cloud.datacatalog.v1beta1.BigQueryTableSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - PolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + BigQueryTableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.PolicyTag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.BigQueryTableSpec"; }; - return PolicyTag; + return BigQueryTableSpec; })(); - v1beta1.CreateTaxonomyRequest = (function() { + /** + * TableSourceType enum. + * @name google.cloud.datacatalog.v1beta1.TableSourceType + * @enum {number} + * @property {number} TABLE_SOURCE_TYPE_UNSPECIFIED=0 TABLE_SOURCE_TYPE_UNSPECIFIED value + * @property {number} BIGQUERY_VIEW=2 BIGQUERY_VIEW value + * @property {number} BIGQUERY_TABLE=5 BIGQUERY_TABLE value + */ + v1beta1.TableSourceType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "TABLE_SOURCE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[2] = "BIGQUERY_VIEW"] = 2; + values[valuesById[5] = "BIGQUERY_TABLE"] = 5; + return values; + })(); + + v1beta1.ViewSpec = (function() { /** - * Properties of a CreateTaxonomyRequest. + * Properties of a ViewSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreateTaxonomyRequest - * @property {string|null} [parent] CreateTaxonomyRequest parent - * @property {google.cloud.datacatalog.v1beta1.ITaxonomy|null} [taxonomy] CreateTaxonomyRequest taxonomy + * @interface IViewSpec + * @property {string|null} [viewQuery] ViewSpec viewQuery */ /** - * Constructs a new CreateTaxonomyRequest. + * Constructs a new ViewSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreateTaxonomyRequest. - * @implements ICreateTaxonomyRequest + * @classdesc Represents a ViewSpec. + * @implements IViewSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IViewSpec=} [properties] Properties to set */ - function CreateTaxonomyRequest(properties) { + function ViewSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -44795,89 +45242,75 @@ } /** - * CreateTaxonomyRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest - * @instance - */ - CreateTaxonomyRequest.prototype.parent = ""; - - /** - * CreateTaxonomyRequest taxonomy. - * @member {google.cloud.datacatalog.v1beta1.ITaxonomy|null|undefined} taxonomy - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * ViewSpec viewQuery. + * @member {string} viewQuery + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @instance */ - CreateTaxonomyRequest.prototype.taxonomy = null; + ViewSpec.prototype.viewQuery = ""; /** - * Creates a new CreateTaxonomyRequest instance using the specified properties. + * Creates a new ViewSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1beta1.IViewSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec instance */ - CreateTaxonomyRequest.create = function create(properties) { - return new CreateTaxonomyRequest(properties); + ViewSpec.create = function create(properties) { + return new ViewSpec(properties); }; /** - * Encodes the specified CreateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.verify|verify} messages. + * Encodes the specified ViewSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ViewSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IViewSpec} message ViewSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTaxonomyRequest.encode = function encode(message, writer) { + ViewSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) - $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.viewQuery != null && Object.hasOwnProperty.call(message, "viewQuery")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.viewQuery); return writer; }; /** - * Encodes the specified CreateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.verify|verify} messages. + * Encodes the specified ViewSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ViewSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IViewSpec} message ViewSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + ViewSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreateTaxonomyRequest message from the specified reader or buffer. + * Decodes a ViewSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTaxonomyRequest.decode = function decode(reader, length) { + ViewSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ViewSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); - break; - } - case 2: { - message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32()); + message.viewQuery = reader.string(); break; } default: @@ -44889,136 +45322,122 @@ }; /** - * Decodes a CreateTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a ViewSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + ViewSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreateTaxonomyRequest message. + * Verifies a ViewSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreateTaxonomyRequest.verify = function verify(message) { + ViewSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { - var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomy); - if (error) - return "taxonomy." + error; - } + if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) + if (!$util.isString(message.viewQuery)) + return "viewQuery: string expected"; return null; }; /** - * Creates a CreateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ViewSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.ViewSpec} ViewSpec */ - CreateTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest) + ViewSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ViewSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.taxonomy != null) { - if (typeof object.taxonomy !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.taxonomy: object expected"); - message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomy); - } + var message = new $root.google.cloud.datacatalog.v1beta1.ViewSpec(); + if (object.viewQuery != null) + message.viewQuery = String(object.viewQuery); return message; }; /** - * Creates a plain object from a CreateTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a ViewSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static - * @param {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} message CreateTaxonomyRequest + * @param {google.cloud.datacatalog.v1beta1.ViewSpec} message ViewSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreateTaxonomyRequest.toObject = function toObject(message, options) { + ViewSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.parent = ""; - object.taxonomy = null; - } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - object.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomy, options); + if (options.defaults) + object.viewQuery = ""; + if (message.viewQuery != null && message.hasOwnProperty("viewQuery")) + object.viewQuery = message.viewQuery; return object; }; /** - * Converts this CreateTaxonomyRequest to JSON. + * Converts this ViewSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @instance * @returns {Object.} JSON object */ - CreateTaxonomyRequest.prototype.toJSON = function toJSON() { + ViewSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreateTaxonomyRequest + * Gets the default type url for ViewSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.ViewSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ViewSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ViewSpec"; }; - return CreateTaxonomyRequest; + return ViewSpec; })(); - v1beta1.DeleteTaxonomyRequest = (function() { + v1beta1.TableSpec = (function() { /** - * Properties of a DeleteTaxonomyRequest. + * Properties of a TableSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeleteTaxonomyRequest - * @property {string|null} [name] DeleteTaxonomyRequest name + * @interface ITableSpec + * @property {string|null} [groupedEntry] TableSpec groupedEntry */ /** - * Constructs a new DeleteTaxonomyRequest. + * Constructs a new TableSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeleteTaxonomyRequest. - * @implements IDeleteTaxonomyRequest + * @classdesc Represents a TableSpec. + * @implements ITableSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ITableSpec=} [properties] Properties to set */ - function DeleteTaxonomyRequest(properties) { + function TableSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -45026,75 +45445,75 @@ } /** - * DeleteTaxonomyRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * TableSpec groupedEntry. + * @member {string} groupedEntry + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @instance */ - DeleteTaxonomyRequest.prototype.name = ""; + TableSpec.prototype.groupedEntry = ""; /** - * Creates a new DeleteTaxonomyRequest instance using the specified properties. + * Creates a new TableSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1beta1.ITableSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec instance */ - DeleteTaxonomyRequest.create = function create(properties) { - return new DeleteTaxonomyRequest(properties); + TableSpec.create = function create(properties) { + return new TableSpec(properties); }; /** - * Encodes the specified DeleteTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest.verify|verify} messages. + * Encodes the specified TableSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TableSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITableSpec} message TableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTaxonomyRequest.encode = function encode(message, writer) { + TableSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.groupedEntry != null && Object.hasOwnProperty.call(message, "groupedEntry")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.groupedEntry); return writer; }; /** - * Encodes the specified DeleteTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest.verify|verify} messages. + * Encodes the specified TableSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TableSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITableSpec} message TableSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeleteTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + TableSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer. + * Decodes a TableSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTaxonomyRequest.decode = function decode(reader, length) { + TableSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TableSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.groupedEntry = reader.string(); break; } default: @@ -45106,123 +45525,124 @@ }; /** - * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a TableSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeleteTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + TableSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeleteTaxonomyRequest message. + * Verifies a TableSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeleteTaxonomyRequest.verify = function verify(message) { + TableSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) + if (!$util.isString(message.groupedEntry)) + return "groupedEntry: string expected"; return null; }; /** - * Creates a DeleteTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a TableSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TableSpec} TableSpec */ - DeleteTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest) + TableSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.TableSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1beta1.TableSpec(); + if (object.groupedEntry != null) + message.groupedEntry = String(object.groupedEntry); return message; }; /** - * Creates a plain object from a DeleteTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a TableSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static - * @param {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} message DeleteTaxonomyRequest + * @param {google.cloud.datacatalog.v1beta1.TableSpec} message TableSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeleteTaxonomyRequest.toObject = function toObject(message, options) { + TableSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + object.groupedEntry = ""; + if (message.groupedEntry != null && message.hasOwnProperty("groupedEntry")) + object.groupedEntry = message.groupedEntry; return object; }; /** - * Converts this DeleteTaxonomyRequest to JSON. + * Converts this TableSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @instance * @returns {Object.} JSON object */ - DeleteTaxonomyRequest.prototype.toJSON = function toJSON() { + TableSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeleteTaxonomyRequest + * Gets the default type url for TableSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TableSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeleteTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TableSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TableSpec"; }; - return DeleteTaxonomyRequest; + return TableSpec; })(); - v1beta1.UpdateTaxonomyRequest = (function() { + v1beta1.BigQueryDateShardedSpec = (function() { /** - * Properties of an UpdateTaxonomyRequest. + * Properties of a BigQueryDateShardedSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdateTaxonomyRequest - * @property {google.cloud.datacatalog.v1beta1.ITaxonomy|null} [taxonomy] UpdateTaxonomyRequest taxonomy - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTaxonomyRequest updateMask + * @interface IBigQueryDateShardedSpec + * @property {string|null} [dataset] BigQueryDateShardedSpec dataset + * @property {string|null} [tablePrefix] BigQueryDateShardedSpec tablePrefix + * @property {number|Long|null} [shardCount] BigQueryDateShardedSpec shardCount */ /** - * Constructs a new UpdateTaxonomyRequest. + * Constructs a new BigQueryDateShardedSpec. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdateTaxonomyRequest. - * @implements IUpdateTaxonomyRequest + * @classdesc Represents a BigQueryDateShardedSpec. + * @implements IBigQueryDateShardedSpec * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec=} [properties] Properties to set */ - function UpdateTaxonomyRequest(properties) { + function BigQueryDateShardedSpec(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -45230,89 +45650,103 @@ } /** - * UpdateTaxonomyRequest taxonomy. - * @member {google.cloud.datacatalog.v1beta1.ITaxonomy|null|undefined} taxonomy - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * BigQueryDateShardedSpec dataset. + * @member {string} dataset + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @instance */ - UpdateTaxonomyRequest.prototype.taxonomy = null; + BigQueryDateShardedSpec.prototype.dataset = ""; /** - * UpdateTaxonomyRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * BigQueryDateShardedSpec tablePrefix. + * @member {string} tablePrefix + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @instance */ - UpdateTaxonomyRequest.prototype.updateMask = null; + BigQueryDateShardedSpec.prototype.tablePrefix = ""; /** - * Creates a new UpdateTaxonomyRequest instance using the specified properties. + * BigQueryDateShardedSpec shardCount. + * @member {number|Long} shardCount + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec + * @instance + */ + BigQueryDateShardedSpec.prototype.shardCount = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + + /** + * Creates a new BigQueryDateShardedSpec instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest instance + * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec instance */ - UpdateTaxonomyRequest.create = function create(properties) { - return new UpdateTaxonomyRequest(properties); + BigQueryDateShardedSpec.create = function create(properties) { + return new BigQueryDateShardedSpec(properties); }; /** - * Encodes the specified UpdateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.verify|verify} messages. + * Encodes the specified BigQueryDateShardedSpec message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTaxonomyRequest.encode = function encode(message, writer) { + BigQueryDateShardedSpec.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) - $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.dataset != null && Object.hasOwnProperty.call(message, "dataset")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.dataset); + if (message.tablePrefix != null && Object.hasOwnProperty.call(message, "tablePrefix")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.tablePrefix); + if (message.shardCount != null && Object.hasOwnProperty.call(message, "shardCount")) + writer.uint32(/* id 3, wireType 0 =*/24).int64(message.shardCount); return writer; }; /** - * Encodes the specified UpdateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.verify|verify} messages. + * Encodes the specified BigQueryDateShardedSpec message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IBigQueryDateShardedSpec} message BigQueryDateShardedSpec message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - UpdateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + BigQueryDateShardedSpec.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer. + * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTaxonomyRequest.decode = function decode(reader, length) { + BigQueryDateShardedSpec.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32()); + message.dataset = reader.string(); break; } case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + message.tablePrefix = reader.string(); + break; + } + case 3: { + message.shardCount = reader.int64(); break; } default: @@ -45324,143 +45758,158 @@ }; /** - * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a BigQueryDateShardedSpec message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - UpdateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + BigQueryDateShardedSpec.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an UpdateTaxonomyRequest message. + * Verifies a BigQueryDateShardedSpec message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - UpdateTaxonomyRequest.verify = function verify(message) { + BigQueryDateShardedSpec.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { - var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomy); - if (error) - return "taxonomy." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } + if (message.dataset != null && message.hasOwnProperty("dataset")) + if (!$util.isString(message.dataset)) + return "dataset: string expected"; + if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) + if (!$util.isString(message.tablePrefix)) + return "tablePrefix: string expected"; + if (message.shardCount != null && message.hasOwnProperty("shardCount")) + if (!$util.isInteger(message.shardCount) && !(message.shardCount && $util.isInteger(message.shardCount.low) && $util.isInteger(message.shardCount.high))) + return "shardCount: integer|Long expected"; return null; }; /** - * Creates an UpdateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a BigQueryDateShardedSpec message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} BigQueryDateShardedSpec */ - UpdateTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest) + BigQueryDateShardedSpec.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest(); - if (object.taxonomy != null) { - if (typeof object.taxonomy !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.taxonomy: object expected"); - message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomy); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } + var message = new $root.google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec(); + if (object.dataset != null) + message.dataset = String(object.dataset); + if (object.tablePrefix != null) + message.tablePrefix = String(object.tablePrefix); + if (object.shardCount != null) + if ($util.Long) + (message.shardCount = $util.Long.fromValue(object.shardCount)).unsigned = false; + else if (typeof object.shardCount === "string") + message.shardCount = parseInt(object.shardCount, 10); + else if (typeof object.shardCount === "number") + message.shardCount = object.shardCount; + else if (typeof object.shardCount === "object") + message.shardCount = new $util.LongBits(object.shardCount.low >>> 0, object.shardCount.high >>> 0).toNumber(); return message; }; /** - * Creates a plain object from an UpdateTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a BigQueryDateShardedSpec message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static - * @param {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} message UpdateTaxonomyRequest + * @param {google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec} message BigQueryDateShardedSpec * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - UpdateTaxonomyRequest.toObject = function toObject(message, options) { + BigQueryDateShardedSpec.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.taxonomy = null; - object.updateMask = null; + object.dataset = ""; + object.tablePrefix = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.shardCount = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.shardCount = options.longs === String ? "0" : 0; } - if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) - object.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomy, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + if (message.dataset != null && message.hasOwnProperty("dataset")) + object.dataset = message.dataset; + if (message.tablePrefix != null && message.hasOwnProperty("tablePrefix")) + object.tablePrefix = message.tablePrefix; + if (message.shardCount != null && message.hasOwnProperty("shardCount")) + if (typeof message.shardCount === "number") + object.shardCount = options.longs === String ? String(message.shardCount) : message.shardCount; + else + object.shardCount = options.longs === String ? $util.Long.prototype.toString.call(message.shardCount) : options.longs === Number ? new $util.LongBits(message.shardCount.low >>> 0, message.shardCount.high >>> 0).toNumber() : message.shardCount; return object; }; /** - * Converts this UpdateTaxonomyRequest to JSON. + * Converts this BigQueryDateShardedSpec to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @instance * @returns {Object.} JSON object */ - UpdateTaxonomyRequest.prototype.toJSON = function toJSON() { + BigQueryDateShardedSpec.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for UpdateTaxonomyRequest + * Gets the default type url for BigQueryDateShardedSpec * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - UpdateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + BigQueryDateShardedSpec.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.BigQueryDateShardedSpec"; }; - return UpdateTaxonomyRequest; + return BigQueryDateShardedSpec; })(); - v1beta1.ListTaxonomiesRequest = (function() { + v1beta1.Tag = (function() { /** - * Properties of a ListTaxonomiesRequest. + * Properties of a Tag. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListTaxonomiesRequest - * @property {string|null} [parent] ListTaxonomiesRequest parent - * @property {number|null} [pageSize] ListTaxonomiesRequest pageSize - * @property {string|null} [pageToken] ListTaxonomiesRequest pageToken + * @interface ITag + * @property {string|null} [name] Tag name + * @property {string|null} [template] Tag template + * @property {string|null} [templateDisplayName] Tag templateDisplayName + * @property {string|null} [column] Tag column + * @property {Object.|null} [fields] Tag fields */ /** - * Constructs a new ListTaxonomiesRequest. + * Constructs a new Tag. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListTaxonomiesRequest. - * @implements IListTaxonomiesRequest + * @classdesc Represents a Tag. + * @implements ITag * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ITag=} [properties] Properties to set */ - function ListTaxonomiesRequest(properties) { + function Tag(properties) { + this.fields = {}; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -45468,103 +45917,167 @@ } /** - * ListTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * Tag name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.Tag * @instance */ - ListTaxonomiesRequest.prototype.parent = ""; + Tag.prototype.name = ""; /** - * ListTaxonomiesRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * Tag template. + * @member {string} template + * @memberof google.cloud.datacatalog.v1beta1.Tag * @instance */ - ListTaxonomiesRequest.prototype.pageSize = 0; + Tag.prototype.template = ""; /** - * ListTaxonomiesRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * Tag templateDisplayName. + * @member {string} templateDisplayName + * @memberof google.cloud.datacatalog.v1beta1.Tag * @instance */ - ListTaxonomiesRequest.prototype.pageToken = ""; + Tag.prototype.templateDisplayName = ""; /** - * Creates a new ListTaxonomiesRequest instance using the specified properties. + * Tag column. + * @member {string|null|undefined} column + * @memberof google.cloud.datacatalog.v1beta1.Tag + * @instance + */ + Tag.prototype.column = null; + + /** + * Tag fields. + * @member {Object.} fields + * @memberof google.cloud.datacatalog.v1beta1.Tag + * @instance + */ + Tag.prototype.fields = $util.emptyObject; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * Tag scope. + * @member {"column"|undefined} scope + * @memberof google.cloud.datacatalog.v1beta1.Tag + * @instance + */ + Object.defineProperty(Tag.prototype, "scope", { + get: $util.oneOfGetter($oneOfFields = ["column"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new Tag instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest instance + * @param {google.cloud.datacatalog.v1beta1.ITag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag instance */ - ListTaxonomiesRequest.create = function create(properties) { - return new ListTaxonomiesRequest(properties); + Tag.create = function create(properties) { + return new Tag(properties); }; /** - * Encodes the specified ListTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest.verify|verify} messages. + * Encodes the specified Tag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Tag.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITag} message Tag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesRequest.encode = function encode(message, writer) { + Tag.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.template != null && Object.hasOwnProperty.call(message, "template")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.template); + if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) + for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1beta1.TagField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } + if (message.column != null && Object.hasOwnProperty.call(message, "column")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.column); + if (message.templateDisplayName != null && Object.hasOwnProperty.call(message, "templateDisplayName")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.templateDisplayName); return writer; }; /** - * Encodes the specified ListTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest.verify|verify} messages. + * Encodes the specified Tag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Tag.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITag} message Tag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + Tag.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTaxonomiesRequest message from the specified reader or buffer. + * Decodes a Tag message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesRequest.decode = function decode(reader, length) { + Tag.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Tag(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); + message.name = reader.string(); break; } case 2: { - message.pageSize = reader.int32(); + message.template = reader.string(); + break; + } + case 5: { + message.templateDisplayName = reader.string(); + break; + } + case 4: { + message.column = reader.string(); break; } case 3: { - message.pageToken = reader.string(); + if (message.fields === $util.emptyObject) + message.fields = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.cloud.datacatalog.v1beta1.TagField.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.fields[key] = value; break; } default: @@ -45576,141 +46089,186 @@ }; /** - * Decodes a ListTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes a Tag message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + Tag.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTaxonomiesRequest message. + * Verifies a Tag message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTaxonomiesRequest.verify = function verify(message) { + Tag.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; + var properties = {}; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.template != null && message.hasOwnProperty("template")) + if (!$util.isString(message.template)) + return "template: string expected"; + if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) + if (!$util.isString(message.templateDisplayName)) + return "templateDisplayName: string expected"; + if (message.column != null && message.hasOwnProperty("column")) { + properties.scope = 1; + if (!$util.isString(message.column)) + return "column: string expected"; + } + if (message.fields != null && message.hasOwnProperty("fields")) { + if (!$util.isObject(message.fields)) + return "fields: object expected"; + var key = Object.keys(message.fields); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.TagField.verify(message.fields[key[i]]); + if (error) + return "fields." + error; + } + } return null; }; /** - * Creates a ListTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a Tag message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.Tag} Tag */ - ListTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest) + Tag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.Tag) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); + var message = new $root.google.cloud.datacatalog.v1beta1.Tag(); + if (object.name != null) + message.name = String(object.name); + if (object.template != null) + message.template = String(object.template); + if (object.templateDisplayName != null) + message.templateDisplayName = String(object.templateDisplayName); + if (object.column != null) + message.column = String(object.column); + if (object.fields) { + if (typeof object.fields !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Tag.fields: object expected"); + message.fields = {}; + for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { + if (typeof object.fields[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.Tag.fields: object expected"); + message.fields[keys[i]] = $root.google.cloud.datacatalog.v1beta1.TagField.fromObject(object.fields[keys[i]]); + } + } return message; }; /** - * Creates a plain object from a ListTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from a Tag message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static - * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} message ListTaxonomiesRequest + * @param {google.cloud.datacatalog.v1beta1.Tag} message Tag * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTaxonomiesRequest.toObject = function toObject(message, options) { + Tag.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.objects || options.defaults) + object.fields = {}; if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; + object.name = ""; + object.template = ""; + object.templateDisplayName = ""; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.template != null && message.hasOwnProperty("template")) + object.template = message.template; + var keys2; + if (message.fields && (keys2 = Object.keys(message.fields)).length) { + object.fields = {}; + for (var j = 0; j < keys2.length; ++j) + object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1beta1.TagField.toObject(message.fields[keys2[j]], options); + } + if (message.column != null && message.hasOwnProperty("column")) { + object.column = message.column; + if (options.oneofs) + object.scope = "column"; + } + if (message.templateDisplayName != null && message.hasOwnProperty("templateDisplayName")) + object.templateDisplayName = message.templateDisplayName; return object; }; /** - * Converts this ListTaxonomiesRequest to JSON. + * Converts this Tag to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @instance * @returns {Object.} JSON object */ - ListTaxonomiesRequest.prototype.toJSON = function toJSON() { + Tag.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTaxonomiesRequest + * Gets the default type url for Tag * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.Tag * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Tag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Tag"; }; - return ListTaxonomiesRequest; + return Tag; })(); - v1beta1.ListTaxonomiesResponse = (function() { + v1beta1.TagField = (function() { /** - * Properties of a ListTaxonomiesResponse. + * Properties of a TagField. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListTaxonomiesResponse - * @property {Array.|null} [taxonomies] ListTaxonomiesResponse taxonomies - * @property {string|null} [nextPageToken] ListTaxonomiesResponse nextPageToken + * @interface ITagField + * @property {string|null} [displayName] TagField displayName + * @property {number|null} [doubleValue] TagField doubleValue + * @property {string|null} [stringValue] TagField stringValue + * @property {boolean|null} [boolValue] TagField boolValue + * @property {google.protobuf.ITimestamp|null} [timestampValue] TagField timestampValue + * @property {google.cloud.datacatalog.v1beta1.TagField.IEnumValue|null} [enumValue] TagField enumValue + * @property {number|null} [order] TagField order */ /** - * Constructs a new ListTaxonomiesResponse. + * Constructs a new TagField. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListTaxonomiesResponse. - * @implements IListTaxonomiesResponse + * @classdesc Represents a TagField. + * @implements ITagField * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ITagField=} [properties] Properties to set */ - function ListTaxonomiesResponse(properties) { - this.taxonomies = []; + function TagField(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -45718,92 +46276,173 @@ } /** - * ListTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * TagField displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.TagField * @instance */ - ListTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + TagField.prototype.displayName = ""; /** - * ListTaxonomiesResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * TagField doubleValue. + * @member {number|null|undefined} doubleValue + * @memberof google.cloud.datacatalog.v1beta1.TagField * @instance */ - ListTaxonomiesResponse.prototype.nextPageToken = ""; + TagField.prototype.doubleValue = null; /** - * Creates a new ListTaxonomiesResponse instance using the specified properties. + * TagField stringValue. + * @member {string|null|undefined} stringValue + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + TagField.prototype.stringValue = null; + + /** + * TagField boolValue. + * @member {boolean|null|undefined} boolValue + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + TagField.prototype.boolValue = null; + + /** + * TagField timestampValue. + * @member {google.protobuf.ITimestamp|null|undefined} timestampValue + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + TagField.prototype.timestampValue = null; + + /** + * TagField enumValue. + * @member {google.cloud.datacatalog.v1beta1.TagField.IEnumValue|null|undefined} enumValue + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + TagField.prototype.enumValue = null; + + /** + * TagField order. + * @member {number} order + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + TagField.prototype.order = 0; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * TagField kind. + * @member {"doubleValue"|"stringValue"|"boolValue"|"timestampValue"|"enumValue"|undefined} kind + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @instance + */ + Object.defineProperty(TagField.prototype, "kind", { + get: $util.oneOfGetter($oneOfFields = ["doubleValue", "stringValue", "boolValue", "timestampValue", "enumValue"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new TagField instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1beta1.ITagField=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField instance */ - ListTaxonomiesResponse.create = function create(properties) { - return new ListTaxonomiesResponse(properties); + TagField.create = function create(properties) { + return new TagField(properties); }; /** - * Encodes the specified ListTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.verify|verify} messages. + * Encodes the specified TagField message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagField} message TagField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesResponse.encode = function encode(message, writer) { + TagField.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) + writer.uint32(/* id 2, wireType 1 =*/17).double(message.doubleValue); + if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.stringValue); + if (message.boolValue != null && Object.hasOwnProperty.call(message, "boolValue")) + writer.uint32(/* id 4, wireType 0 =*/32).bool(message.boolValue); + if (message.timestampValue != null && Object.hasOwnProperty.call(message, "timestampValue")) + $root.google.protobuf.Timestamp.encode(message.timestampValue, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.enumValue != null && Object.hasOwnProperty.call(message, "enumValue")) + $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.encode(message.enumValue, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.order != null && Object.hasOwnProperty.call(message, "order")) + writer.uint32(/* id 7, wireType 0 =*/56).int32(message.order); return writer; }; /** - * Encodes the specified ListTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.verify|verify} messages. + * Encodes the specified TagField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static - * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagField} message TagField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ListTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + TagField.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ListTaxonomiesResponse message from the specified reader or buffer. + * Decodes a TagField message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesResponse.decode = function decode(reader, length) { + TagField.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagField(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32())); + message.displayName = reader.string(); break; } case 2: { - message.nextPageToken = reader.string(); + message.doubleValue = reader.double(); + break; + } + case 3: { + message.stringValue = reader.string(); + break; + } + case 4: { + message.boolValue = reader.bool(); + break; + } + case 5: { + message.timestampValue = $root.google.protobuf.Timestamp.decode(reader, reader.uint32()); + break; + } + case 6: { + message.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.decode(reader, reader.uint32()); + break; + } + case 7: { + message.order = reader.int32(); break; } default: @@ -45815,219 +46454,512 @@ }; /** - * Decodes a ListTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a TagField message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ListTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + TagField.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ListTaxonomiesResponse message. + * Verifies a TagField message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ListTaxonomiesResponse.verify = function verify(message) { + TagField.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomies[i]); + var properties = {}; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { + properties.kind = 1; + if (typeof message.doubleValue !== "number") + return "doubleValue: number expected"; + } + if (message.stringValue != null && message.hasOwnProperty("stringValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + if (!$util.isString(message.stringValue)) + return "stringValue: string expected"; + } + if (message.boolValue != null && message.hasOwnProperty("boolValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + if (typeof message.boolValue !== "boolean") + return "boolValue: boolean expected"; + } + if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + { + var error = $root.google.protobuf.Timestamp.verify(message.timestampValue); if (error) - return "taxonomies." + error; + return "timestampValue." + error; } } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; + if (message.enumValue != null && message.hasOwnProperty("enumValue")) { + if (properties.kind === 1) + return "kind: multiple values"; + properties.kind = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify(message.enumValue); + if (error) + return "enumValue." + error; + } + } + if (message.order != null && message.hasOwnProperty("order")) + if (!$util.isInteger(message.order)) + return "order: integer expected"; return null; }; /** - * Creates a ListTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a TagField message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.TagField} TagField */ - ListTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse) + TagField.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagField) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomies[i]); - } + var message = new $root.google.cloud.datacatalog.v1beta1.TagField(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.doubleValue != null) + message.doubleValue = Number(object.doubleValue); + if (object.stringValue != null) + message.stringValue = String(object.stringValue); + if (object.boolValue != null) + message.boolValue = Boolean(object.boolValue); + if (object.timestampValue != null) { + if (typeof object.timestampValue !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.TagField.timestampValue: object expected"); + message.timestampValue = $root.google.protobuf.Timestamp.fromObject(object.timestampValue); } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); + if (object.enumValue != null) { + if (typeof object.enumValue !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.TagField.enumValue: object expected"); + message.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.fromObject(object.enumValue); + } + if (object.order != null) + message.order = object.order | 0; return message; }; /** - * Creates a plain object from a ListTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a TagField message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static - * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} message ListTaxonomiesResponse + * @param {google.cloud.datacatalog.v1beta1.TagField} message TagField * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ListTaxonomiesResponse.toObject = function toObject(message, options) { + TagField.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomies[j], options); + if (options.defaults) { + object.displayName = ""; + object.order = 0; } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) { + object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; + if (options.oneofs) + object.kind = "doubleValue"; + } + if (message.stringValue != null && message.hasOwnProperty("stringValue")) { + object.stringValue = message.stringValue; + if (options.oneofs) + object.kind = "stringValue"; + } + if (message.boolValue != null && message.hasOwnProperty("boolValue")) { + object.boolValue = message.boolValue; + if (options.oneofs) + object.kind = "boolValue"; + } + if (message.timestampValue != null && message.hasOwnProperty("timestampValue")) { + object.timestampValue = $root.google.protobuf.Timestamp.toObject(message.timestampValue, options); + if (options.oneofs) + object.kind = "timestampValue"; + } + if (message.enumValue != null && message.hasOwnProperty("enumValue")) { + object.enumValue = $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue.toObject(message.enumValue, options); + if (options.oneofs) + object.kind = "enumValue"; + } + if (message.order != null && message.hasOwnProperty("order")) + object.order = message.order; return object; }; /** - * Converts this ListTaxonomiesResponse to JSON. + * Converts this TagField to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @instance * @returns {Object.} JSON object */ - ListTaxonomiesResponse.prototype.toJSON = function toJSON() { + TagField.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ListTaxonomiesResponse + * Gets the default type url for TagField * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.TagField * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ListTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TagField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagField"; }; - return ListTaxonomiesResponse; - })(); + TagField.EnumValue = (function() { - v1beta1.GetTaxonomyRequest = (function() { + /** + * Properties of an EnumValue. + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @interface IEnumValue + * @property {string|null} [displayName] EnumValue displayName + */ - /** - * Properties of a GetTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGetTaxonomyRequest - * @property {string|null} [name] GetTaxonomyRequest name - */ + /** + * Constructs a new EnumValue. + * @memberof google.cloud.datacatalog.v1beta1.TagField + * @classdesc Represents an EnumValue. + * @implements IEnumValue + * @constructor + * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue=} [properties] Properties to set + */ + function EnumValue(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Constructs a new GetTaxonomyRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GetTaxonomyRequest. - * @implements IGetTaxonomyRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest=} [properties] Properties to set - */ - function GetTaxonomyRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * EnumValue displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @instance + */ + EnumValue.prototype.displayName = ""; - /** - * GetTaxonomyRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest - * @instance - */ - GetTaxonomyRequest.prototype.name = ""; + /** + * Creates a new EnumValue instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue instance + */ + EnumValue.create = function create(properties) { + return new EnumValue(properties); + }; - /** - * Creates a new GetTaxonomyRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest instance + /** + * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + return writer; + }; + + /** + * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagField.EnumValue.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.TagField.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EnumValue message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumValue.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + return null; + }; + + /** + * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.TagField.EnumValue} EnumValue + */ + EnumValue.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.TagField.EnumValue(); + if (object.displayName != null) + message.displayName = String(object.displayName); + return message; + }; + + /** + * Creates a plain object from an EnumValue message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.TagField.EnumValue} message EnumValue + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumValue.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.displayName = ""; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + return object; + }; + + /** + * Converts this EnumValue to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @instance + * @returns {Object.} JSON object + */ + EnumValue.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EnumValue + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.TagField.EnumValue + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagField.EnumValue"; + }; + + return EnumValue; + })(); + + return TagField; + })(); + + v1beta1.TagTemplate = (function() { + + /** + * Properties of a TagTemplate. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ITagTemplate + * @property {string|null} [name] TagTemplate name + * @property {string|null} [displayName] TagTemplate displayName + * @property {Object.|null} [fields] TagTemplate fields */ - GetTaxonomyRequest.create = function create(properties) { - return new GetTaxonomyRequest(properties); + + /** + * Constructs a new TagTemplate. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a TagTemplate. + * @implements ITagTemplate + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ITagTemplate=} [properties] Properties to set + */ + function TagTemplate(properties) { + this.fields = {}; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * TagTemplate name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @instance + */ + TagTemplate.prototype.name = ""; + + /** + * TagTemplate displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @instance + */ + TagTemplate.prototype.displayName = ""; + + /** + * TagTemplate fields. + * @member {Object.} fields + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @instance + */ + TagTemplate.prototype.fields = $util.emptyObject; + + /** + * Creates a new TagTemplate instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate + * @static + * @param {google.cloud.datacatalog.v1beta1.ITagTemplate=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate instance + */ + TagTemplate.create = function create(properties) { + return new TagTemplate(properties); }; /** - * Encodes the specified GetTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTaxonomyRequest.verify|verify} messages. + * Encodes the specified TagTemplate message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplate.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagTemplate} message TagTemplate message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTaxonomyRequest.encode = function encode(message, writer) { + TagTemplate.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.fields != null && Object.hasOwnProperty.call(message, "fields")) + for (var keys = Object.keys(message.fields), i = 0; i < keys.length; ++i) { + writer.uint32(/* id 3, wireType 2 =*/26).fork().uint32(/* id 1, wireType 2 =*/10).string(keys[i]); + $root.google.cloud.datacatalog.v1beta1.TagTemplateField.encode(message.fields[keys[i]], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim().ldelim(); + } return writer; }; /** - * Encodes the specified GetTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTaxonomyRequest.verify|verify} messages. + * Encodes the specified TagTemplate message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplate.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagTemplate} message TagTemplate message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { + TagTemplate.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetTaxonomyRequest message from the specified reader or buffer. + * Decodes a TagTemplate message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTaxonomyRequest.decode = function decode(reader, length) { + TagTemplate.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagTemplate(), key, value; while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -46035,6 +46967,33 @@ message.name = reader.string(); break; } + case 2: { + message.displayName = reader.string(); + break; + } + case 3: { + if (message.fields === $util.emptyObject) + message.fields = {}; + var end2 = reader.uint32() + reader.pos; + key = ""; + value = null; + while (reader.pos < end2) { + var tag2 = reader.uint32(); + switch (tag2 >>> 3) { + case 1: + key = reader.string(); + break; + case 2: + value = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.decode(reader, reader.uint32()); + break; + default: + reader.skipType(tag2 & 7); + break; + } + } + message.fields[key] = value; + break; + } default: reader.skipType(tag & 7); break; @@ -46044,123 +47003,163 @@ }; /** - * Decodes a GetTaxonomyRequest message from the specified reader or buffer, length delimited. + * Decodes a TagTemplate message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { + TagTemplate.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetTaxonomyRequest message. + * Verifies a TagTemplate message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetTaxonomyRequest.verify = function verify(message) { + TagTemplate.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.fields != null && message.hasOwnProperty("fields")) { + if (!$util.isObject(message.fields)) + return "fields: object expected"; + var key = Object.keys(message.fields); + for (var i = 0; i < key.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.verify(message.fields[key[i]]); + if (error) + return "fields." + error; + } + } return null; }; /** - * Creates a GetTaxonomyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a TagTemplate message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplate} TagTemplate */ - GetTaxonomyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest) + TagTemplate.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagTemplate) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.TagTemplate(); if (object.name != null) message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.fields) { + if (typeof object.fields !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplate.fields: object expected"); + message.fields = {}; + for (var keys = Object.keys(object.fields), i = 0; i < keys.length; ++i) { + if (typeof object.fields[keys[i]] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplate.fields: object expected"); + message.fields[keys[i]] = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.fromObject(object.fields[keys[i]]); + } + } return message; }; /** - * Creates a plain object from a GetTaxonomyRequest message. Also converts values to other types if specified. + * Creates a plain object from a TagTemplate message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static - * @param {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} message GetTaxonomyRequest + * @param {google.cloud.datacatalog.v1beta1.TagTemplate} message TagTemplate * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetTaxonomyRequest.toObject = function toObject(message, options) { + TagTemplate.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) + if (options.objects || options.defaults) + object.fields = {}; + if (options.defaults) { object.name = ""; + object.displayName = ""; + } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + var keys2; + if (message.fields && (keys2 = Object.keys(message.fields)).length) { + object.fields = {}; + for (var j = 0; j < keys2.length; ++j) + object.fields[keys2[j]] = $root.google.cloud.datacatalog.v1beta1.TagTemplateField.toObject(message.fields[keys2[j]], options); + } return object; }; /** - * Converts this GetTaxonomyRequest to JSON. + * Converts this TagTemplate to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @instance * @returns {Object.} JSON object */ - GetTaxonomyRequest.prototype.toJSON = function toJSON() { + TagTemplate.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetTaxonomyRequest + * Gets the default type url for TagTemplate * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplate * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TagTemplate.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetTaxonomyRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagTemplate"; }; - return GetTaxonomyRequest; + return TagTemplate; })(); - v1beta1.CreatePolicyTagRequest = (function() { + v1beta1.TagTemplateField = (function() { /** - * Properties of a CreatePolicyTagRequest. + * Properties of a TagTemplateField. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ICreatePolicyTagRequest - * @property {string|null} [parent] CreatePolicyTagRequest parent - * @property {google.cloud.datacatalog.v1beta1.IPolicyTag|null} [policyTag] CreatePolicyTagRequest policyTag + * @interface ITagTemplateField + * @property {string|null} [name] TagTemplateField name + * @property {string|null} [displayName] TagTemplateField displayName + * @property {google.cloud.datacatalog.v1beta1.IFieldType|null} [type] TagTemplateField type + * @property {boolean|null} [isRequired] TagTemplateField isRequired + * @property {number|null} [order] TagTemplateField order */ /** - * Constructs a new CreatePolicyTagRequest. + * Constructs a new TagTemplateField. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a CreatePolicyTagRequest. - * @implements ICreatePolicyTagRequest + * @classdesc Represents a TagTemplateField. + * @implements ITagTemplateField * @constructor - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField=} [properties] Properties to set */ - function CreatePolicyTagRequest(properties) { + function TagTemplateField(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -46168,89 +47167,131 @@ } /** - * CreatePolicyTagRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * TagTemplateField name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @instance */ - CreatePolicyTagRequest.prototype.parent = ""; + TagTemplateField.prototype.name = ""; /** - * CreatePolicyTagRequest policyTag. - * @member {google.cloud.datacatalog.v1beta1.IPolicyTag|null|undefined} policyTag - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * TagTemplateField displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @instance */ - CreatePolicyTagRequest.prototype.policyTag = null; + TagTemplateField.prototype.displayName = ""; /** - * Creates a new CreatePolicyTagRequest instance using the specified properties. + * TagTemplateField type. + * @member {google.cloud.datacatalog.v1beta1.IFieldType|null|undefined} type + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @instance + */ + TagTemplateField.prototype.type = null; + + /** + * TagTemplateField isRequired. + * @member {boolean} isRequired + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @instance + */ + TagTemplateField.prototype.isRequired = false; + + /** + * TagTemplateField order. + * @member {number} order + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField + * @instance + */ + TagTemplateField.prototype.order = 0; + + /** + * Creates a new TagTemplateField instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField instance */ - CreatePolicyTagRequest.create = function create(properties) { - return new CreatePolicyTagRequest(properties); + TagTemplateField.create = function create(properties) { + return new TagTemplateField(properties); }; /** - * Encodes the specified CreatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.verify|verify} messages. + * Encodes the specified TagTemplateField message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplateField.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField} message TagTemplateField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreatePolicyTagRequest.encode = function encode(message, writer) { + TagTemplateField.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) - $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + $root.google.cloud.datacatalog.v1beta1.FieldType.encode(message.type, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.isRequired != null && Object.hasOwnProperty.call(message, "isRequired")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.isRequired); + if (message.order != null && Object.hasOwnProperty.call(message, "order")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.order); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.name); return writer; }; /** - * Encodes the specified CreatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.verify|verify} messages. + * Encodes the specified TagTemplateField message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.TagTemplateField.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITagTemplateField} message TagTemplateField message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CreatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + TagTemplateField.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CreatePolicyTagRequest message from the specified reader or buffer. + * Decodes a TagTemplateField message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreatePolicyTagRequest.decode = function decode(reader, length) { + TagTemplateField.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.TagTemplateField(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 6: { + message.name = reader.string(); + break; + } case 1: { - message.parent = reader.string(); + message.displayName = reader.string(); break; } case 2: { - message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32()); + message.type = $root.google.cloud.datacatalog.v1beta1.FieldType.decode(reader, reader.uint32()); + break; + } + case 3: { + message.isRequired = reader.bool(); + break; + } + case 5: { + message.order = reader.int32(); break; } default: @@ -46262,136 +47303,161 @@ }; /** - * Decodes a CreatePolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a TagTemplateField message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CreatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + TagTemplateField.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CreatePolicyTagRequest message. + * Verifies a TagTemplateField message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CreatePolicyTagRequest.verify = function verify(message) { + TagTemplateField.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) { - var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTag); + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.type != null && message.hasOwnProperty("type")) { + var error = $root.google.cloud.datacatalog.v1beta1.FieldType.verify(message.type); if (error) - return "policyTag." + error; + return "type." + error; } + if (message.isRequired != null && message.hasOwnProperty("isRequired")) + if (typeof message.isRequired !== "boolean") + return "isRequired: boolean expected"; + if (message.order != null && message.hasOwnProperty("order")) + if (!$util.isInteger(message.order)) + return "order: integer expected"; return null; }; /** - * Creates a CreatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a TagTemplateField message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.TagTemplateField} TagTemplateField */ - CreatePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest) + TagTemplateField.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.TagTemplateField) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.policyTag != null) { - if (typeof object.policyTag !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.policyTag: object expected"); - message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTag); + var message = new $root.google.cloud.datacatalog.v1beta1.TagTemplateField(); + if (object.name != null) + message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.type != null) { + if (typeof object.type !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.TagTemplateField.type: object expected"); + message.type = $root.google.cloud.datacatalog.v1beta1.FieldType.fromObject(object.type); } + if (object.isRequired != null) + message.isRequired = Boolean(object.isRequired); + if (object.order != null) + message.order = object.order | 0; return message; }; /** - * Creates a plain object from a CreatePolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a TagTemplateField message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static - * @param {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} message CreatePolicyTagRequest + * @param {google.cloud.datacatalog.v1beta1.TagTemplateField} message TagTemplateField * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CreatePolicyTagRequest.toObject = function toObject(message, options) { + TagTemplateField.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.parent = ""; - object.policyTag = null; + object.displayName = ""; + object.type = null; + object.isRequired = false; + object.order = 0; + object.name = ""; } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - object.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTag, options); + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.type != null && message.hasOwnProperty("type")) + object.type = $root.google.cloud.datacatalog.v1beta1.FieldType.toObject(message.type, options); + if (message.isRequired != null && message.hasOwnProperty("isRequired")) + object.isRequired = message.isRequired; + if (message.order != null && message.hasOwnProperty("order")) + object.order = message.order; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this CreatePolicyTagRequest to JSON. + * Converts this TagTemplateField to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @instance * @returns {Object.} JSON object */ - CreatePolicyTagRequest.prototype.toJSON = function toJSON() { + TagTemplateField.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CreatePolicyTagRequest + * Gets the default type url for TagTemplateField * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.TagTemplateField * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CreatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TagTemplateField.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.TagTemplateField"; }; - return CreatePolicyTagRequest; + return TagTemplateField; })(); - v1beta1.DeletePolicyTagRequest = (function() { + v1beta1.FieldType = (function() { /** - * Properties of a DeletePolicyTagRequest. + * Properties of a FieldType. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IDeletePolicyTagRequest - * @property {string|null} [name] DeletePolicyTagRequest name + * @interface IFieldType + * @property {google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType|null} [primitiveType] FieldType primitiveType + * @property {google.cloud.datacatalog.v1beta1.FieldType.IEnumType|null} [enumType] FieldType enumType */ /** - * Constructs a new DeletePolicyTagRequest. + * Constructs a new FieldType. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a DeletePolicyTagRequest. - * @implements IDeletePolicyTagRequest + * @classdesc Represents a FieldType. + * @implements IFieldType * @constructor - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IFieldType=} [properties] Properties to set */ - function DeletePolicyTagRequest(properties) { + function FieldType(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -46399,75 +47465,103 @@ } /** - * DeletePolicyTagRequest name. - * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * FieldType primitiveType. + * @member {google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType|null|undefined} primitiveType + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @instance */ - DeletePolicyTagRequest.prototype.name = ""; + FieldType.prototype.primitiveType = null; /** - * Creates a new DeletePolicyTagRequest instance using the specified properties. + * FieldType enumType. + * @member {google.cloud.datacatalog.v1beta1.FieldType.IEnumType|null|undefined} enumType + * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @instance + */ + FieldType.prototype.enumType = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * FieldType typeDecl. + * @member {"primitiveType"|"enumType"|undefined} typeDecl + * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @instance + */ + Object.defineProperty(FieldType.prototype, "typeDecl", { + get: $util.oneOfGetter($oneOfFields = ["primitiveType", "enumType"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new FieldType instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.IFieldType=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType instance */ - DeletePolicyTagRequest.create = function create(properties) { - return new DeletePolicyTagRequest(properties); + FieldType.create = function create(properties) { + return new FieldType(properties); }; /** - * Encodes the specified DeletePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest.verify|verify} messages. + * Encodes the specified FieldType message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IFieldType} message FieldType message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeletePolicyTagRequest.encode = function encode(message, writer) { + FieldType.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.primitiveType != null && Object.hasOwnProperty.call(message, "primitiveType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.primitiveType); + if (message.enumType != null && Object.hasOwnProperty.call(message, "enumType")) + $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.encode(message.enumType, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified DeletePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest.verify|verify} messages. + * Encodes the specified FieldType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static - * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IFieldType} message FieldType message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DeletePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + FieldType.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DeletePolicyTagRequest message from the specified reader or buffer. + * Decodes a FieldType message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeletePolicyTagRequest.decode = function decode(reader, length) { + FieldType.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.primitiveType = reader.int32(); + break; + } + case 2: { + message.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.decode(reader, reader.uint32()); break; } default: @@ -46479,857 +47573,1095 @@ }; /** - * Decodes a DeletePolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a FieldType message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DeletePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + FieldType.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DeletePolicyTagRequest message. + * Verifies a FieldType message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - DeletePolicyTagRequest.verify = function verify(message) { + FieldType.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; + var properties = {}; + if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { + properties.typeDecl = 1; + switch (message.primitiveType) { + default: + return "primitiveType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + break; + } + } + if (message.enumType != null && message.hasOwnProperty("enumType")) { + if (properties.typeDecl === 1) + return "typeDecl: multiple values"; + properties.typeDecl = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify(message.enumType); + if (error) + return "enumType." + error; + } + } return null; }; /** - * Creates a DeletePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a FieldType message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.FieldType} FieldType */ - DeletePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest) + FieldType.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest(); - if (object.name != null) - message.name = String(object.name); + var message = new $root.google.cloud.datacatalog.v1beta1.FieldType(); + switch (object.primitiveType) { + default: + if (typeof object.primitiveType === "number") { + message.primitiveType = object.primitiveType; + break; + } + break; + case "PRIMITIVE_TYPE_UNSPECIFIED": + case 0: + message.primitiveType = 0; + break; + case "DOUBLE": + case 1: + message.primitiveType = 1; + break; + case "STRING": + case 2: + message.primitiveType = 2; + break; + case "BOOL": + case 3: + message.primitiveType = 3; + break; + case "TIMESTAMP": + case 4: + message.primitiveType = 4; + break; + } + if (object.enumType != null) { + if (typeof object.enumType !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.enumType: object expected"); + message.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.fromObject(object.enumType); + } return message; }; /** - * Creates a plain object from a DeletePolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a FieldType message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static - * @param {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} message DeletePolicyTagRequest + * @param {google.cloud.datacatalog.v1beta1.FieldType} message FieldType * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DeletePolicyTagRequest.toObject = function toObject(message, options) { + FieldType.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) - object.name = ""; - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; + if (message.primitiveType != null && message.hasOwnProperty("primitiveType")) { + object.primitiveType = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType[message.primitiveType] === undefined ? message.primitiveType : $root.google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType[message.primitiveType] : message.primitiveType; + if (options.oneofs) + object.typeDecl = "primitiveType"; + } + if (message.enumType != null && message.hasOwnProperty("enumType")) { + object.enumType = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.toObject(message.enumType, options); + if (options.oneofs) + object.typeDecl = "enumType"; + } return object; }; /** - * Converts this DeletePolicyTagRequest to JSON. + * Converts this FieldType to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @instance * @returns {Object.} JSON object */ - DeletePolicyTagRequest.prototype.toJSON = function toJSON() { + FieldType.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DeletePolicyTagRequest + * Gets the default type url for FieldType * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.FieldType * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DeletePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FieldType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType"; }; - return DeletePolicyTagRequest; - })(); - - v1beta1.UpdatePolicyTagRequest = (function() { + FieldType.EnumType = (function() { - /** - * Properties of an UpdatePolicyTagRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IUpdatePolicyTagRequest - * @property {google.cloud.datacatalog.v1beta1.IPolicyTag|null} [policyTag] UpdatePolicyTagRequest policyTag - * @property {google.protobuf.IFieldMask|null} [updateMask] UpdatePolicyTagRequest updateMask - */ + /** + * Properties of an EnumType. + * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @interface IEnumType + * @property {Array.|null} [allowedValues] EnumType allowedValues + */ - /** - * Constructs a new UpdatePolicyTagRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an UpdatePolicyTagRequest. - * @implements IUpdatePolicyTagRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest=} [properties] Properties to set - */ - function UpdatePolicyTagRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Constructs a new EnumType. + * @memberof google.cloud.datacatalog.v1beta1.FieldType + * @classdesc Represents an EnumType. + * @implements IEnumType + * @constructor + * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType=} [properties] Properties to set + */ + function EnumType(properties) { + this.allowedValues = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * UpdatePolicyTagRequest policyTag. - * @member {google.cloud.datacatalog.v1beta1.IPolicyTag|null|undefined} policyTag - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @instance - */ - UpdatePolicyTagRequest.prototype.policyTag = null; + /** + * EnumType allowedValues. + * @member {Array.} allowedValues + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @instance + */ + EnumType.prototype.allowedValues = $util.emptyArray; - /** - * UpdatePolicyTagRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @instance - */ - UpdatePolicyTagRequest.prototype.updateMask = null; + /** + * Creates a new EnumType instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType instance + */ + EnumType.create = function create(properties) { + return new EnumType(properties); + }; - /** - * Creates a new UpdatePolicyTagRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest instance - */ - UpdatePolicyTagRequest.create = function create(properties) { - return new UpdatePolicyTagRequest(properties); - }; + /** + * Encodes the specified EnumType message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType} message EnumType message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumType.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.allowedValues != null && message.allowedValues.length) + for (var i = 0; i < message.allowedValues.length; ++i) + $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.encode(message.allowedValues[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; - /** - * Encodes the specified UpdatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UpdatePolicyTagRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) - $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - return writer; - }; + /** + * Encodes the specified EnumType message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.IEnumType} message EnumType message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumType.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Encodes the specified UpdatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UpdatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Decodes an EnumType message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumType.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.allowedValues && message.allowedValues.length)) + message.allowedValues = []; + message.allowedValues.push($root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UpdatePolicyTagRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32()); - break; + /** + * Decodes an EnumType message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumType.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EnumType message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumType.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.allowedValues != null && message.hasOwnProperty("allowedValues")) { + if (!Array.isArray(message.allowedValues)) + return "allowedValues: array expected"; + for (var i = 0; i < message.allowedValues.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify(message.allowedValues[i]); + if (error) + return "allowedValues." + error; } - case 2: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); - break; + } + return null; + }; + + /** + * Creates an EnumType message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType} EnumType + */ + EnumType.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType(); + if (object.allowedValues) { + if (!Array.isArray(object.allowedValues)) + throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.EnumType.allowedValues: array expected"); + message.allowedValues = []; + for (var i = 0; i < object.allowedValues.length; ++i) { + if (typeof object.allowedValues[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.FieldType.EnumType.allowedValues: object expected"); + message.allowedValues[i] = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.fromObject(object.allowedValues[i]); } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; + + /** + * Creates a plain object from an EnumType message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType} message EnumType + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumType.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.allowedValues = []; + if (message.allowedValues && message.allowedValues.length) { + object.allowedValues = []; + for (var j = 0; j < message.allowedValues.length; ++j) + object.allowedValues[j] = $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.toObject(message.allowedValues[j], options); + } + return object; + }; + + /** + * Converts this EnumType to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @instance + * @returns {Object.} JSON object + */ + EnumType.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EnumType + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumType.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType.EnumType"; + }; + + EnumType.EnumValue = (function() { + + /** + * Properties of an EnumValue. + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @interface IEnumValue + * @property {string|null} [displayName] EnumValue displayName + */ + + /** + * Constructs a new EnumValue. + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType + * @classdesc Represents an EnumValue. + * @implements IEnumValue + * @constructor + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue=} [properties] Properties to set + */ + function EnumValue(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * EnumValue displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @instance + */ + EnumValue.prototype.displayName = ""; + + /** + * Creates a new EnumValue instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue instance + */ + EnumValue.create = function create(properties) { + return new EnumValue(properties); + }; + + /** + * Encodes the specified EnumValue message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + return writer; + }; + + /** + * Encodes the specified EnumValue message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.IEnumValue} message EnumValue message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumValue.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an EnumValue message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumValue.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EnumValue message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumValue.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + return null; + }; + + /** + * Creates an EnumValue message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} EnumValue + */ + EnumValue.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue(); + if (object.displayName != null) + message.displayName = String(object.displayName); + return message; + }; + + /** + * Creates a plain object from an EnumValue message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue} message EnumValue + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumValue.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.displayName = ""; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + return object; + }; + + /** + * Converts this EnumValue to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @instance + * @returns {Object.} JSON object + */ + EnumValue.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EnumValue + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumValue.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.FieldType.EnumType.EnumValue"; + }; + + return EnumValue; + })(); + + return EnumType; + })(); /** - * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * PrimitiveType enum. + * @name google.cloud.datacatalog.v1beta1.FieldType.PrimitiveType + * @enum {number} + * @property {number} PRIMITIVE_TYPE_UNSPECIFIED=0 PRIMITIVE_TYPE_UNSPECIFIED value + * @property {number} DOUBLE=1 DOUBLE value + * @property {number} STRING=2 STRING value + * @property {number} BOOL=3 BOOL value + * @property {number} TIMESTAMP=4 TIMESTAMP value */ - UpdatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + FieldType.PrimitiveType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "PRIMITIVE_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "DOUBLE"] = 1; + values[valuesById[2] = "STRING"] = 2; + values[valuesById[3] = "BOOL"] = 3; + values[valuesById[4] = "TIMESTAMP"] = 4; + return values; + })(); + + return FieldType; + })(); + + v1beta1.PolicyTagManager = (function() { /** - * Verifies an UpdatePolicyTagRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Constructs a new PolicyTagManager service. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a PolicyTagManager + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited */ - UpdatePolicyTagRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.policyTag != null && message.hasOwnProperty("policyTag")) { - var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTag); - if (error) - return "policyTag." + error; - } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; - } - return null; - }; + function PolicyTagManager(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } + + (PolicyTagManager.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManager; /** - * Creates an UpdatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * Creates new PolicyTagManager service using the specified rpc implementation. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {PolicyTagManager} RPC service. Useful where requests and/or responses are streamed. */ - UpdatePolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest(); - if (object.policyTag != null) { - if (typeof object.policyTag !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.policyTag: object expected"); - message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTag); - } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); - } - return message; + PolicyTagManager.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); }; /** - * Creates a plain object from an UpdatePolicyTagRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} message UpdatePolicyTagRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|createTaxonomy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef CreateTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy */ - UpdatePolicyTagRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.policyTag = null; - object.updateMask = null; - } - if (message.policyTag != null && message.hasOwnProperty("policyTag")) - object.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTag, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); - return object; - }; /** - * Converts this UpdatePolicyTagRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * Calls CreateTaxonomy. + * @function createTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.CreateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 */ - UpdatePolicyTagRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + Object.defineProperty(PolicyTagManager.prototype.createTaxonomy = function createTaxonomy(request, callback) { + return this.rpcCall(createTaxonomy, $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); + }, "name", { value: "CreateTaxonomy" }); /** - * Gets the default type url for UpdatePolicyTagRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Calls CreateTaxonomy. + * @function createTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} request CreateTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - UpdatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest"; - }; - - return UpdatePolicyTagRequest; - })(); - v1beta1.ListPolicyTagsRequest = (function() { + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|deleteTaxonomy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef DeleteTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty + */ /** - * Properties of a ListPolicyTagsRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListPolicyTagsRequest - * @property {string|null} [parent] ListPolicyTagsRequest parent - * @property {number|null} [pageSize] ListPolicyTagsRequest pageSize - * @property {string|null} [pageToken] ListPolicyTagsRequest pageToken + * Calls DeleteTaxonomy. + * @function deleteTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.DeleteTaxonomyCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 */ + Object.defineProperty(PolicyTagManager.prototype.deleteTaxonomy = function deleteTaxonomy(request, callback) { + return this.rpcCall(deleteTaxonomy, $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteTaxonomy" }); /** - * Constructs a new ListPolicyTagsRequest. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListPolicyTagsRequest. - * @implements IListPolicyTagsRequest - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest=} [properties] Properties to set + * Calls DeleteTaxonomy. + * @function deleteTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} request DeleteTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - function ListPolicyTagsRequest(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * ListPolicyTagsRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|updateTaxonomy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef UpdateTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy */ - ListPolicyTagsRequest.prototype.parent = ""; /** - * ListPolicyTagsRequest pageSize. - * @member {number} pageSize - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * Calls UpdateTaxonomy. + * @function updateTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.UpdateTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsRequest.prototype.pageSize = 0; + Object.defineProperty(PolicyTagManager.prototype.updateTaxonomy = function updateTaxonomy(request, callback) { + return this.rpcCall(updateTaxonomy, $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); + }, "name", { value: "UpdateTaxonomy" }); /** - * ListPolicyTagsRequest pageToken. - * @member {string} pageToken - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * Calls UpdateTaxonomy. + * @function updateTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} request UpdateTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsRequest.prototype.pageToken = ""; /** - * Creates a new ListPolicyTagsRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|listTaxonomies}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef ListTaxonomiesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} [response] ListTaxonomiesResponse */ - ListPolicyTagsRequest.create = function create(properties) { - return new ListPolicyTagsRequest(properties); - }; /** - * Encodes the specified ListPolicyTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls ListTaxonomies. + * @function listTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.ListTaxonomiesCallback} callback Node-style callback called with the error, if any, and ListTaxonomiesResponse + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsRequest.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); - if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); - return writer; - }; + Object.defineProperty(PolicyTagManager.prototype.listTaxonomies = function listTaxonomies(request, callback) { + return this.rpcCall(listTaxonomies, $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse, request, callback); + }, "name", { value: "ListTaxonomies" }); /** - * Encodes the specified ListPolicyTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls ListTaxonomies. + * @function listTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} request ListTaxonomiesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; /** - * Decodes a ListPolicyTagsRequest message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getTaxonomy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef GetTaxonomyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.Taxonomy} [response] Taxonomy */ - ListPolicyTagsRequest.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.parent = reader.string(); - break; - } - case 2: { - message.pageSize = reader.int32(); - break; - } - case 3: { - message.pageToken = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a ListPolicyTagsRequest message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls GetTaxonomy. + * @function getTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetTaxonomyCallback} callback Node-style callback called with the error, if any, and Taxonomy + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsRequest.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + Object.defineProperty(PolicyTagManager.prototype.getTaxonomy = function getTaxonomy(request, callback) { + return this.rpcCall(getTaxonomy, $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest, $root.google.cloud.datacatalog.v1beta1.Taxonomy, request, callback); + }, "name", { value: "GetTaxonomy" }); /** - * Verifies a ListPolicyTagsRequest message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls GetTaxonomy. + * @function getTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} request GetTaxonomyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsRequest.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - if (!$util.isInteger(message.pageSize)) - return "pageSize: integer expected"; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - if (!$util.isString(message.pageToken)) - return "pageToken: string expected"; - return null; - }; /** - * Creates a ListPolicyTagsRequest message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|createPolicyTag}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef CreatePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag */ - ListPolicyTagsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.pageSize != null) - message.pageSize = object.pageSize | 0; - if (object.pageToken != null) - message.pageToken = String(object.pageToken); - return message; - }; /** - * Creates a plain object from a ListPolicyTagsRequest message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} message ListPolicyTagsRequest - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Calls CreatePolicyTag. + * @function createPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.CreatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsRequest.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.parent = ""; - object.pageSize = 0; - object.pageToken = ""; - } - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.pageSize != null && message.hasOwnProperty("pageSize")) - object.pageSize = message.pageSize; - if (message.pageToken != null && message.hasOwnProperty("pageToken")) - object.pageToken = message.pageToken; - return object; - }; + Object.defineProperty(PolicyTagManager.prototype.createPolicyTag = function createPolicyTag(request, callback) { + return this.rpcCall(createPolicyTag, $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); + }, "name", { value: "CreatePolicyTag" }); /** - * Converts this ListPolicyTagsRequest to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * Calls CreatePolicyTag. + * @function createPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance - * @returns {Object.} JSON object + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} request CreatePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; /** - * Gets the default type url for ListPolicyTagsRequest - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|deletePolicyTag}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef DeletePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty */ - ListPolicyTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest"; - }; - - return ListPolicyTagsRequest; - })(); - v1beta1.ListPolicyTagsResponse = (function() { + /** + * Calls DeletePolicyTag. + * @function deletePolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.DeletePolicyTagCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.deletePolicyTag = function deletePolicyTag(request, callback) { + return this.rpcCall(deletePolicyTag, $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeletePolicyTag" }); /** - * Properties of a ListPolicyTagsResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface IListPolicyTagsResponse - * @property {Array.|null} [policyTags] ListPolicyTagsResponse policyTags - * @property {string|null} [nextPageToken] ListPolicyTagsResponse nextPageToken + * Calls DeletePolicyTag. + * @function deletePolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} request DeletePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ /** - * Constructs a new ListPolicyTagsResponse. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a ListPolicyTagsResponse. - * @implements IListPolicyTagsResponse - * @constructor - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse=} [properties] Properties to set + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|updatePolicyTag}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef UpdatePolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag */ - function ListPolicyTagsResponse(properties) { - this.policyTags = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } /** - * ListPolicyTagsResponse policyTags. - * @member {Array.} policyTags - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * Calls UpdatePolicyTag. + * @function updatePolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.UpdatePolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsResponse.prototype.policyTags = $util.emptyArray; + Object.defineProperty(PolicyTagManager.prototype.updatePolicyTag = function updatePolicyTag(request, callback) { + return this.rpcCall(updatePolicyTag, $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); + }, "name", { value: "UpdatePolicyTag" }); /** - * ListPolicyTagsResponse nextPageToken. - * @member {string} nextPageToken - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * Calls UpdatePolicyTag. + * @function updatePolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} request UpdatePolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsResponse.prototype.nextPageToken = ""; /** - * Creates a new ListPolicyTagsResponse instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse instance + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|listPolicyTags}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef ListPolicyTagsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} [response] ListPolicyTagsResponse */ - ListPolicyTagsResponse.create = function create(properties) { - return new ListPolicyTagsResponse(properties); - }; /** - * Encodes the specified ListPolicyTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.verify|verify} messages. - * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls ListPolicyTags. + * @function listPolicyTags + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.ListPolicyTagsCallback} callback Node-style callback called with the error, if any, and ListPolicyTagsResponse + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsResponse.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.policyTags != null && message.policyTags.length) - for (var i = 0; i < message.policyTags.length; ++i) - $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); - return writer; - }; + Object.defineProperty(PolicyTagManager.prototype.listPolicyTags = function listPolicyTags(request, callback) { + return this.rpcCall(listPolicyTags, $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest, $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse, request, callback); + }, "name", { value: "ListPolicyTags" }); /** - * Encodes the specified ListPolicyTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.verify|verify} messages. - * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer + * Calls ListPolicyTags. + * @function listPolicyTags + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} request ListPolicyTagsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; /** - * Decodes a ListPolicyTagsResponse message from the specified reader or buffer. - * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getPolicyTag}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef GetPolicyTagCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.PolicyTag} [response] PolicyTag */ - ListPolicyTagsResponse.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.policyTags && message.policyTags.length)) - message.policyTags = []; - message.policyTags.push($root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32())); - break; - } - case 2: { - message.nextPageToken = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; /** - * Decodes a ListPolicyTagsResponse message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing + * Calls GetPolicyTag. + * @function getPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetPolicyTagCallback} callback Node-style callback called with the error, if any, and PolicyTag + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsResponse.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + Object.defineProperty(PolicyTagManager.prototype.getPolicyTag = function getPolicyTag(request, callback) { + return this.rpcCall(getPolicyTag, $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest, $root.google.cloud.datacatalog.v1beta1.PolicyTag, request, callback); + }, "name", { value: "GetPolicyTag" }); /** - * Verifies a ListPolicyTagsResponse message. - * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not + * Calls GetPolicyTag. + * @function getPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} request GetPolicyTagRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsResponse.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.policyTags != null && message.hasOwnProperty("policyTags")) { - if (!Array.isArray(message.policyTags)) - return "policyTags: array expected"; - for (var i = 0; i < message.policyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTags[i]); - if (error) - return "policyTags." + error; - } - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - if (!$util.isString(message.nextPageToken)) - return "nextPageToken: string expected"; - return null; - }; /** - * Creates a ListPolicyTagsResponse message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|getIamPolicy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef GetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy */ - ListPolicyTagsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse) - return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse(); - if (object.policyTags) { - if (!Array.isArray(object.policyTags)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.policyTags: array expected"); - message.policyTags = []; - for (var i = 0; i < object.policyTags.length; ++i) { - if (typeof object.policyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.policyTags: object expected"); - message.policyTags[i] = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTags[i]); - } - } - if (object.nextPageToken != null) - message.nextPageToken = String(object.nextPageToken); - return message; - }; /** - * Creates a plain object from a ListPolicyTagsResponse message. Also converts values to other types if specified. - * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} message ListPolicyTagsResponse - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 */ - ListPolicyTagsResponse.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.policyTags = []; - if (options.defaults) - object.nextPageToken = ""; - if (message.policyTags && message.policyTags.length) { - object.policyTags = []; - for (var j = 0; j < message.policyTags.length; ++j) - object.policyTags[j] = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTags[j], options); - } - if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) - object.nextPageToken = message.nextPageToken; - return object; - }; + Object.defineProperty(PolicyTagManager.prototype.getIamPolicy = function getIamPolicy(request, callback) { + return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "GetIamPolicy" }); /** - * Converts this ListPolicyTagsResponse to JSON. - * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager * @instance - * @returns {Object.} JSON object + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 */ - ListPolicyTagsResponse.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; /** - * Gets the default type url for ListPolicyTagsResponse - * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|setIamPolicy}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef SetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy */ - ListPolicyTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse"; - }; - return ListPolicyTagsResponse; + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.setIamPolicy = function setIamPolicy(request, callback) { + return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "SetIamPolicy" }); + + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManager|testIamPermissions}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @typedef TestIamPermissionsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse + */ + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManager.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManager.prototype.testIamPermissions = function testIamPermissions(request, callback) { + return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); + }, "name", { value: "TestIamPermissions" }); + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManager + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + return PolicyTagManager; })(); - v1beta1.GetPolicyTagRequest = (function() { + v1beta1.Taxonomy = (function() { /** - * Properties of a GetPolicyTagRequest. + * Properties of a Taxonomy. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IGetPolicyTagRequest - * @property {string|null} [name] GetPolicyTagRequest name + * @interface ITaxonomy + * @property {string|null} [name] Taxonomy name + * @property {string|null} [displayName] Taxonomy displayName + * @property {string|null} [description] Taxonomy description + * @property {Array.|null} [activatedPolicyTypes] Taxonomy activatedPolicyTypes */ /** - * Constructs a new GetPolicyTagRequest. + * Constructs a new Taxonomy. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a GetPolicyTagRequest. - * @implements IGetPolicyTagRequest + * @classdesc Represents a Taxonomy. + * @implements ITaxonomy * @constructor - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ITaxonomy=} [properties] Properties to set */ - function GetPolicyTagRequest(properties) { + function Taxonomy(properties) { + this.activatedPolicyTypes = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -47337,70 +48669,104 @@ } /** - * GetPolicyTagRequest name. + * Taxonomy name. * @member {string} name - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @instance */ - GetPolicyTagRequest.prototype.name = ""; + Taxonomy.prototype.name = ""; /** - * Creates a new GetPolicyTagRequest instance using the specified properties. + * Taxonomy displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @instance + */ + Taxonomy.prototype.displayName = ""; + + /** + * Taxonomy description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @instance + */ + Taxonomy.prototype.description = ""; + + /** + * Taxonomy activatedPolicyTypes. + * @member {Array.} activatedPolicyTypes + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy + * @instance + */ + Taxonomy.prototype.activatedPolicyTypes = $util.emptyArray; + + /** + * Creates a new Taxonomy instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest instance + * @param {google.cloud.datacatalog.v1beta1.ITaxonomy=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy instance */ - GetPolicyTagRequest.create = function create(properties) { - return new GetPolicyTagRequest(properties); + Taxonomy.create = function create(properties) { + return new Taxonomy(properties); }; /** - * Encodes the specified GetPolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetPolicyTagRequest.verify|verify} messages. + * Encodes the specified Taxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Taxonomy.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITaxonomy} message Taxonomy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetPolicyTagRequest.encode = function encode(message, writer) { + Taxonomy.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.activatedPolicyTypes != null && message.activatedPolicyTypes.length) { + writer.uint32(/* id 6, wireType 2 =*/50).fork(); + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + writer.int32(message.activatedPolicyTypes[i]); + writer.ldelim(); + } return writer; }; /** - * Encodes the specified GetPolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetPolicyTagRequest.verify|verify} messages. + * Encodes the specified Taxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.Taxonomy.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ITaxonomy} message Taxonomy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetPolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + Taxonomy.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetPolicyTagRequest message from the specified reader or buffer. + * Decodes a Taxonomy message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetPolicyTagRequest.decode = function decode(reader, length) { + Taxonomy.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.Taxonomy(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -47408,6 +48774,25 @@ message.name = reader.string(); break; } + case 2: { + message.displayName = reader.string(); + break; + } + case 3: { + message.description = reader.string(); + break; + } + case 6: { + if (!(message.activatedPolicyTypes && message.activatedPolicyTypes.length)) + message.activatedPolicyTypes = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.activatedPolicyTypes.push(reader.int32()); + } else + message.activatedPolicyTypes.push(reader.int32()); + break; + } default: reader.skipType(tag & 7); break; @@ -47417,333 +48802,333 @@ }; /** - * Decodes a GetPolicyTagRequest message from the specified reader or buffer, length delimited. + * Decodes a Taxonomy message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetPolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + Taxonomy.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetPolicyTagRequest message. + * Verifies a Taxonomy message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetPolicyTagRequest.verify = function verify(message) { + Taxonomy.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.activatedPolicyTypes != null && message.hasOwnProperty("activatedPolicyTypes")) { + if (!Array.isArray(message.activatedPolicyTypes)) + return "activatedPolicyTypes: array expected"; + for (var i = 0; i < message.activatedPolicyTypes.length; ++i) + switch (message.activatedPolicyTypes[i]) { + default: + return "activatedPolicyTypes: enum value[] expected"; + case 0: + case 1: + break; + } + } return null; }; /** - * Creates a GetPolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * Creates a Taxonomy message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + * @returns {google.cloud.datacatalog.v1beta1.Taxonomy} Taxonomy */ - GetPolicyTagRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest) + Taxonomy.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.Taxonomy) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest(); + var message = new $root.google.cloud.datacatalog.v1beta1.Taxonomy(); if (object.name != null) message.name = String(object.name); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.activatedPolicyTypes) { + if (!Array.isArray(object.activatedPolicyTypes)) + throw TypeError(".google.cloud.datacatalog.v1beta1.Taxonomy.activatedPolicyTypes: array expected"); + message.activatedPolicyTypes = []; + for (var i = 0; i < object.activatedPolicyTypes.length; ++i) + switch (object.activatedPolicyTypes[i]) { + default: + if (typeof object.activatedPolicyTypes[i] === "number") { + message.activatedPolicyTypes[i] = object.activatedPolicyTypes[i]; + break; + } + case "POLICY_TYPE_UNSPECIFIED": + case 0: + message.activatedPolicyTypes[i] = 0; + break; + case "FINE_GRAINED_ACCESS_CONTROL": + case 1: + message.activatedPolicyTypes[i] = 1; + break; + } + } return message; }; /** - * Creates a plain object from a GetPolicyTagRequest message. Also converts values to other types if specified. + * Creates a plain object from a Taxonomy message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static - * @param {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} message GetPolicyTagRequest + * @param {google.cloud.datacatalog.v1beta1.Taxonomy} message Taxonomy * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetPolicyTagRequest.toObject = function toObject(message, options) { + Taxonomy.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) + if (options.arrays || options.defaults) + object.activatedPolicyTypes = []; + if (options.defaults) { object.name = ""; + object.displayName = ""; + object.description = ""; + } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.activatedPolicyTypes && message.activatedPolicyTypes.length) { + object.activatedPolicyTypes = []; + for (var j = 0; j < message.activatedPolicyTypes.length; ++j) + object.activatedPolicyTypes[j] = options.enums === String ? $root.google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] === undefined ? message.activatedPolicyTypes[j] : $root.google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType[message.activatedPolicyTypes[j]] : message.activatedPolicyTypes[j]; + } return object; }; /** - * Converts this GetPolicyTagRequest to JSON. + * Converts this Taxonomy to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @instance * @returns {Object.} JSON object */ - GetPolicyTagRequest.prototype.toJSON = function toJSON() { + Taxonomy.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetPolicyTagRequest + * Gets the default type url for Taxonomy * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @memberof google.cloud.datacatalog.v1beta1.Taxonomy * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetPolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Taxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetPolicyTagRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.Taxonomy"; }; - return GetPolicyTagRequest; + /** + * PolicyType enum. + * @name google.cloud.datacatalog.v1beta1.Taxonomy.PolicyType + * @enum {number} + * @property {number} POLICY_TYPE_UNSPECIFIED=0 POLICY_TYPE_UNSPECIFIED value + * @property {number} FINE_GRAINED_ACCESS_CONTROL=1 FINE_GRAINED_ACCESS_CONTROL value + */ + Taxonomy.PolicyType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "POLICY_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "FINE_GRAINED_ACCESS_CONTROL"] = 1; + return values; + })(); + + return Taxonomy; })(); - v1beta1.PolicyTagManagerSerialization = (function() { + v1beta1.PolicyTag = (function() { /** - * Constructs a new PolicyTagManagerSerialization service. + * Properties of a PolicyTag. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a PolicyTagManagerSerialization - * @extends $protobuf.rpc.Service + * @interface IPolicyTag + * @property {string|null} [name] PolicyTag name + * @property {string|null} [displayName] PolicyTag displayName + * @property {string|null} [description] PolicyTag description + * @property {string|null} [parentPolicyTag] PolicyTag parentPolicyTag + * @property {Array.|null} [childPolicyTags] PolicyTag childPolicyTags + */ + + /** + * Constructs a new PolicyTag. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a PolicyTag. + * @implements IPolicyTag * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @param {google.cloud.datacatalog.v1beta1.IPolicyTag=} [properties] Properties to set */ - function PolicyTagManagerSerialization(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + function PolicyTag(properties) { + this.childPolicyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - (PolicyTagManagerSerialization.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManagerSerialization; - /** - * Creates new PolicyTagManagerSerialization service using the specified rpc implementation. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization - * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {PolicyTagManagerSerialization} RPC service. Useful where requests and/or responses are streamed. + * PolicyTag name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @instance */ - PolicyTagManagerSerialization.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); - }; + PolicyTag.prototype.name = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization|importTaxonomies}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization - * @typedef ImportTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} [response] ImportTaxonomiesResponse + * PolicyTag displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag + * @instance */ + PolicyTag.prototype.displayName = ""; /** - * Calls ImportTaxonomies. - * @function importTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * PolicyTag description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @instance - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization.ImportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ImportTaxonomiesResponse - * @returns {undefined} - * @variation 1 */ - Object.defineProperty(PolicyTagManagerSerialization.prototype.importTaxonomies = function importTaxonomies(request, callback) { - return this.rpcCall(importTaxonomies, $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse, request, callback); - }, "name", { value: "ImportTaxonomies" }); + PolicyTag.prototype.description = ""; /** - * Calls ImportTaxonomies. - * @function importTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * PolicyTag parentPolicyTag. + * @member {string} parentPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @instance - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 */ + PolicyTag.prototype.parentPolicyTag = ""; /** - * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization|exportTaxonomies}. - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization - * @typedef ExportTaxonomiesCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} [response] ExportTaxonomiesResponse - */ - - /** - * Calls ExportTaxonomies. - * @function exportTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object - * @param {google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization.ExportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ExportTaxonomiesResponse - * @returns {undefined} - * @variation 1 - */ - Object.defineProperty(PolicyTagManagerSerialization.prototype.exportTaxonomies = function exportTaxonomies(request, callback) { - return this.rpcCall(exportTaxonomies, $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse, request, callback); - }, "name", { value: "ExportTaxonomies" }); - - /** - * Calls ExportTaxonomies. - * @function exportTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization - * @instance - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object - * @returns {Promise} Promise - * @variation 2 - */ - - return PolicyTagManagerSerialization; - })(); - - v1beta1.SerializedTaxonomy = (function() { - - /** - * Properties of a SerializedTaxonomy. - * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISerializedTaxonomy - * @property {string|null} [displayName] SerializedTaxonomy displayName - * @property {string|null} [description] SerializedTaxonomy description - * @property {Array.|null} [policyTags] SerializedTaxonomy policyTags - */ - - /** - * Constructs a new SerializedTaxonomy. - * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SerializedTaxonomy. - * @implements ISerializedTaxonomy - * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy=} [properties] Properties to set - */ - function SerializedTaxonomy(properties) { - this.policyTags = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * SerializedTaxonomy displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy - * @instance - */ - SerializedTaxonomy.prototype.displayName = ""; - - /** - * SerializedTaxonomy description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy - * @instance - */ - SerializedTaxonomy.prototype.description = ""; - - /** - * SerializedTaxonomy policyTags. - * @member {Array.} policyTags - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * PolicyTag childPolicyTags. + * @member {Array.} childPolicyTags + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @instance */ - SerializedTaxonomy.prototype.policyTags = $util.emptyArray; + PolicyTag.prototype.childPolicyTags = $util.emptyArray; /** - * Creates a new SerializedTaxonomy instance using the specified properties. + * Creates a new PolicyTag instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy instance + * @param {google.cloud.datacatalog.v1beta1.IPolicyTag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag instance */ - SerializedTaxonomy.create = function create(properties) { - return new SerializedTaxonomy(properties); + PolicyTag.create = function create(properties) { + return new PolicyTag(properties); }; /** - * Encodes the specified SerializedTaxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify|verify} messages. + * Encodes the specified PolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.PolicyTag.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IPolicyTag} message PolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedTaxonomy.encode = function encode(message, writer) { + PolicyTag.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); - if (message.policyTags != null && message.policyTags.length) - for (var i = 0; i < message.policyTags.length; ++i) - $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.encode(message.policyTags[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.parentPolicyTag != null && Object.hasOwnProperty.call(message, "parentPolicyTag")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.parentPolicyTag); + if (message.childPolicyTags != null && message.childPolicyTags.length) + for (var i = 0; i < message.childPolicyTags.length; ++i) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.childPolicyTags[i]); return writer; }; /** - * Encodes the specified SerializedTaxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify|verify} messages. + * Encodes the specified PolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.PolicyTag.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IPolicyTag} message PolicyTag message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedTaxonomy.encodeDelimited = function encodeDelimited(message, writer) { + PolicyTag.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SerializedTaxonomy message from the specified reader or buffer. + * Decodes a PolicyTag message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedTaxonomy.decode = function decode(reader, length) { + PolicyTag.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.PolicyTag(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.displayName = reader.string(); + message.name = reader.string(); break; } case 2: { - message.description = reader.string(); + message.displayName = reader.string(); break; } case 3: { - if (!(message.policyTags && message.policyTags.length)) - message.policyTags = []; - message.policyTags.push($root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.decode(reader, reader.uint32())); + message.description = reader.string(); + break; + } + case 4: { + message.parentPolicyTag = reader.string(); + break; + } + case 5: { + if (!(message.childPolicyTags && message.childPolicyTags.length)) + message.childPolicyTags = []; + message.childPolicyTags.push(reader.string()); break; } default: @@ -47755,160 +49140,169 @@ }; /** - * Decodes a SerializedTaxonomy message from the specified reader or buffer, length delimited. + * Decodes a PolicyTag message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedTaxonomy.decodeDelimited = function decodeDelimited(reader) { + PolicyTag.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SerializedTaxonomy message. + * Verifies a PolicyTag message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SerializedTaxonomy.verify = function verify(message) { + PolicyTag.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; if (message.displayName != null && message.hasOwnProperty("displayName")) if (!$util.isString(message.displayName)) return "displayName: string expected"; if (message.description != null && message.hasOwnProperty("description")) if (!$util.isString(message.description)) return "description: string expected"; - if (message.policyTags != null && message.hasOwnProperty("policyTags")) { - if (!Array.isArray(message.policyTags)) - return "policyTags: array expected"; - for (var i = 0; i < message.policyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify(message.policyTags[i]); - if (error) - return "policyTags." + error; - } + if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) + if (!$util.isString(message.parentPolicyTag)) + return "parentPolicyTag: string expected"; + if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { + if (!Array.isArray(message.childPolicyTags)) + return "childPolicyTags: array expected"; + for (var i = 0; i < message.childPolicyTags.length; ++i) + if (!$util.isString(message.childPolicyTags[i])) + return "childPolicyTags: string[] expected"; } return null; }; /** - * Creates a SerializedTaxonomy message from a plain object. Also converts values to their respective internal types. + * Creates a PolicyTag message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + * @returns {google.cloud.datacatalog.v1beta1.PolicyTag} PolicyTag */ - SerializedTaxonomy.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy) + PolicyTag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.PolicyTag) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy(); + var message = new $root.google.cloud.datacatalog.v1beta1.PolicyTag(); + if (object.name != null) + message.name = String(object.name); if (object.displayName != null) message.displayName = String(object.displayName); if (object.description != null) message.description = String(object.description); - if (object.policyTags) { - if (!Array.isArray(object.policyTags)) - throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedTaxonomy.policyTags: array expected"); - message.policyTags = []; - for (var i = 0; i < object.policyTags.length; ++i) { - if (typeof object.policyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedTaxonomy.policyTags: object expected"); - message.policyTags[i] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.fromObject(object.policyTags[i]); - } + if (object.parentPolicyTag != null) + message.parentPolicyTag = String(object.parentPolicyTag); + if (object.childPolicyTags) { + if (!Array.isArray(object.childPolicyTags)) + throw TypeError(".google.cloud.datacatalog.v1beta1.PolicyTag.childPolicyTags: array expected"); + message.childPolicyTags = []; + for (var i = 0; i < object.childPolicyTags.length; ++i) + message.childPolicyTags[i] = String(object.childPolicyTags[i]); } return message; }; /** - * Creates a plain object from a SerializedTaxonomy message. Also converts values to other types if specified. + * Creates a plain object from a PolicyTag message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static - * @param {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} message SerializedTaxonomy + * @param {google.cloud.datacatalog.v1beta1.PolicyTag} message PolicyTag * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SerializedTaxonomy.toObject = function toObject(message, options) { + PolicyTag.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.policyTags = []; + object.childPolicyTags = []; if (options.defaults) { + object.name = ""; object.displayName = ""; object.description = ""; + object.parentPolicyTag = ""; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; if (message.displayName != null && message.hasOwnProperty("displayName")) object.displayName = message.displayName; if (message.description != null && message.hasOwnProperty("description")) object.description = message.description; - if (message.policyTags && message.policyTags.length) { - object.policyTags = []; - for (var j = 0; j < message.policyTags.length; ++j) - object.policyTags[j] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.toObject(message.policyTags[j], options); + if (message.parentPolicyTag != null && message.hasOwnProperty("parentPolicyTag")) + object.parentPolicyTag = message.parentPolicyTag; + if (message.childPolicyTags && message.childPolicyTags.length) { + object.childPolicyTags = []; + for (var j = 0; j < message.childPolicyTags.length; ++j) + object.childPolicyTags[j] = message.childPolicyTags[j]; } return object; }; /** - * Converts this SerializedTaxonomy to JSON. + * Converts this PolicyTag to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @instance * @returns {Object.} JSON object */ - SerializedTaxonomy.prototype.toJSON = function toJSON() { + PolicyTag.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SerializedTaxonomy + * Gets the default type url for PolicyTag * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @memberof google.cloud.datacatalog.v1beta1.PolicyTag * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SerializedTaxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + PolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SerializedTaxonomy"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.PolicyTag"; }; - return SerializedTaxonomy; + return PolicyTag; })(); - v1beta1.SerializedPolicyTag = (function() { + v1beta1.CreateTaxonomyRequest = (function() { /** - * Properties of a SerializedPolicyTag. + * Properties of a CreateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface ISerializedPolicyTag - * @property {string|null} [displayName] SerializedPolicyTag displayName - * @property {string|null} [description] SerializedPolicyTag description - * @property {Array.|null} [childPolicyTags] SerializedPolicyTag childPolicyTags + * @interface ICreateTaxonomyRequest + * @property {string|null} [parent] CreateTaxonomyRequest parent + * @property {google.cloud.datacatalog.v1beta1.ITaxonomy|null} [taxonomy] CreateTaxonomyRequest taxonomy */ /** - * Constructs a new SerializedPolicyTag. + * Constructs a new CreateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents a SerializedPolicyTag. - * @implements ISerializedPolicyTag + * @classdesc Represents a CreateTaxonomyRequest. + * @implements ICreateTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest=} [properties] Properties to set */ - function SerializedPolicyTag(properties) { - this.childPolicyTags = []; + function CreateTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -47916,106 +49310,89 @@ } /** - * SerializedPolicyTag displayName. - * @member {string} displayName - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag - * @instance - */ - SerializedPolicyTag.prototype.displayName = ""; - - /** - * SerializedPolicyTag description. - * @member {string} description - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * CreateTaxonomyRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @instance */ - SerializedPolicyTag.prototype.description = ""; + CreateTaxonomyRequest.prototype.parent = ""; /** - * SerializedPolicyTag childPolicyTags. - * @member {Array.} childPolicyTags - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * CreateTaxonomyRequest taxonomy. + * @member {google.cloud.datacatalog.v1beta1.ITaxonomy|null|undefined} taxonomy + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @instance */ - SerializedPolicyTag.prototype.childPolicyTags = $util.emptyArray; + CreateTaxonomyRequest.prototype.taxonomy = null; /** - * Creates a new SerializedPolicyTag instance using the specified properties. + * Creates a new CreateTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag instance + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest instance */ - SerializedPolicyTag.create = function create(properties) { - return new SerializedPolicyTag(properties); + CreateTaxonomyRequest.create = function create(properties) { + return new CreateTaxonomyRequest(properties); }; /** - * Encodes the specified SerializedPolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify|verify} messages. + * Encodes the specified CreateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedPolicyTag.encode = function encode(message, writer) { + CreateTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.childPolicyTags != null && message.childPolicyTags.length) - for (var i = 0; i < message.childPolicyTags.length; ++i) - $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.encode(message.childPolicyTags[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) + $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified SerializedPolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify|verify} messages. + * Encodes the specified CreateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.ICreateTaxonomyRequest} message CreateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SerializedPolicyTag.encodeDelimited = function encodeDelimited(message, writer) { + CreateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SerializedPolicyTag message from the specified reader or buffer. + * Decodes a CreateTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedPolicyTag.decode = function decode(reader, length) { + CreateTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 2: { - message.displayName = reader.string(); - break; - } - case 3: { - message.description = reader.string(); + case 1: { + message.parent = reader.string(); break; } - case 4: { - if (!(message.childPolicyTags && message.childPolicyTags.length)) - message.childPolicyTags = []; - message.childPolicyTags.push($root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.decode(reader, reader.uint32())); + case 2: { + message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32()); break; } default: @@ -48027,158 +49404,136 @@ }; /** - * Decodes a SerializedPolicyTag message from the specified reader or buffer, length delimited. + * Decodes a CreateTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SerializedPolicyTag.decodeDelimited = function decodeDelimited(reader) { + CreateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SerializedPolicyTag message. + * Verifies a CreateTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SerializedPolicyTag.verify = function verify(message) { + CreateTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.displayName != null && message.hasOwnProperty("displayName")) - if (!$util.isString(message.displayName)) - return "displayName: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { - if (!Array.isArray(message.childPolicyTags)) - return "childPolicyTags: array expected"; - for (var i = 0; i < message.childPolicyTags.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify(message.childPolicyTags[i]); - if (error) - return "childPolicyTags." + error; - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { + var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomy); + if (error) + return "taxonomy." + error; } return null; }; /** - * Creates a SerializedPolicyTag message from a plain object. Also converts values to their respective internal types. + * Creates a CreateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + * @returns {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} CreateTaxonomyRequest */ - SerializedPolicyTag.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag) + CreateTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag(); - if (object.displayName != null) - message.displayName = String(object.displayName); - if (object.description != null) - message.description = String(object.description); - if (object.childPolicyTags) { - if (!Array.isArray(object.childPolicyTags)) - throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedPolicyTag.childPolicyTags: array expected"); - message.childPolicyTags = []; - for (var i = 0; i < object.childPolicyTags.length; ++i) { - if (typeof object.childPolicyTags[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedPolicyTag.childPolicyTags: object expected"); - message.childPolicyTags[i] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.fromObject(object.childPolicyTags[i]); - } + var message = new $root.google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.taxonomy != null) { + if (typeof object.taxonomy !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest.taxonomy: object expected"); + message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomy); } return message; }; /** - * Creates a plain object from a SerializedPolicyTag message. Also converts values to other types if specified. + * Creates a plain object from a CreateTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} message SerializedPolicyTag + * @param {google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest} message CreateTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SerializedPolicyTag.toObject = function toObject(message, options) { + CreateTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.childPolicyTags = []; if (options.defaults) { - object.displayName = ""; - object.description = ""; - } - if (message.displayName != null && message.hasOwnProperty("displayName")) - object.displayName = message.displayName; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.childPolicyTags && message.childPolicyTags.length) { - object.childPolicyTags = []; - for (var j = 0; j < message.childPolicyTags.length; ++j) - object.childPolicyTags[j] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.toObject(message.childPolicyTags[j], options); + object.parent = ""; + object.taxonomy = null; } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + object.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomy, options); return object; }; /** - * Converts this SerializedPolicyTag to JSON. + * Converts this CreateTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @instance * @returns {Object.} JSON object */ - SerializedPolicyTag.prototype.toJSON = function toJSON() { + CreateTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SerializedPolicyTag + * Gets the default type url for CreateTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @memberof google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SerializedPolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + CreateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SerializedPolicyTag"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreateTaxonomyRequest"; }; - return SerializedPolicyTag; + return CreateTaxonomyRequest; })(); - v1beta1.ImportTaxonomiesRequest = (function() { + v1beta1.DeleteTaxonomyRequest = (function() { /** - * Properties of an ImportTaxonomiesRequest. + * Properties of a DeleteTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IImportTaxonomiesRequest - * @property {string|null} [parent] ImportTaxonomiesRequest parent - * @property {google.cloud.datacatalog.v1beta1.IInlineSource|null} [inlineSource] ImportTaxonomiesRequest inlineSource + * @interface IDeleteTaxonomyRequest + * @property {string|null} [name] DeleteTaxonomyRequest name */ /** - * Constructs a new ImportTaxonomiesRequest. + * Constructs a new DeleteTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an ImportTaxonomiesRequest. - * @implements IImportTaxonomiesRequest + * @classdesc Represents a DeleteTaxonomyRequest. + * @implements IDeleteTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest=} [properties] Properties to set */ - function ImportTaxonomiesRequest(properties) { + function DeleteTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -48186,103 +49541,75 @@ } /** - * ImportTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * DeleteTaxonomyRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @instance */ - ImportTaxonomiesRequest.prototype.parent = ""; + DeleteTaxonomyRequest.prototype.name = ""; /** - * ImportTaxonomiesRequest inlineSource. - * @member {google.cloud.datacatalog.v1beta1.IInlineSource|null|undefined} inlineSource - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest - * @instance + * Creates a new DeleteTaxonomyRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest instance */ - ImportTaxonomiesRequest.prototype.inlineSource = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; - - /** - * ImportTaxonomiesRequest source. - * @member {"inlineSource"|undefined} source - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest - * @instance - */ - Object.defineProperty(ImportTaxonomiesRequest.prototype, "source", { - get: $util.oneOfGetter($oneOfFields = ["inlineSource"]), - set: $util.oneOfSetter($oneOfFields) - }); - - /** - * Creates a new ImportTaxonomiesRequest instance using the specified properties. - * @function create - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest - * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest instance - */ - ImportTaxonomiesRequest.create = function create(properties) { - return new ImportTaxonomiesRequest(properties); + DeleteTaxonomyRequest.create = function create(properties) { + return new DeleteTaxonomyRequest(properties); }; /** - * Encodes the specified ImportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified DeleteTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesRequest.encode = function encode(message, writer) { + DeleteTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); - if (message.inlineSource != null && Object.hasOwnProperty.call(message, "inlineSource")) - $root.google.cloud.datacatalog.v1beta1.InlineSource.encode(message.inlineSource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified ImportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified DeleteTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IDeleteTaxonomyRequest} message DeleteTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + DeleteTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer. + * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesRequest.decode = function decode(reader, length) { + DeleteTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); - break; - } - case 2: { - message.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.decode(reader, reader.uint32()); + message.name = reader.string(); break; } default: @@ -48294,142 +49621,123 @@ }; /** - * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes a DeleteTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + DeleteTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ImportTaxonomiesRequest message. + * Verifies a DeleteTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ImportTaxonomiesRequest.verify = function verify(message) { + DeleteTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; - if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { - properties.source = 1; - { - var error = $root.google.cloud.datacatalog.v1beta1.InlineSource.verify(message.inlineSource); - if (error) - return "inlineSource." + error; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates an ImportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a DeleteTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} DeleteTaxonomyRequest */ - ImportTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest) + DeleteTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); - if (object.inlineSource != null) { - if (typeof object.inlineSource !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.inlineSource: object expected"); - message.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.fromObject(object.inlineSource); - } + var message = new $root.google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from an ImportTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from a DeleteTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} message ImportTaxonomiesRequest + * @param {google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest} message DeleteTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ImportTaxonomiesRequest.toObject = function toObject(message, options) { + DeleteTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) - object.parent = ""; - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; - if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { - object.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.toObject(message.inlineSource, options); - if (options.oneofs) - object.source = "inlineSource"; - } + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this ImportTaxonomiesRequest to JSON. + * Converts this DeleteTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @instance * @returns {Object.} JSON object */ - ImportTaxonomiesRequest.prototype.toJSON = function toJSON() { + DeleteTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ImportTaxonomiesRequest + * Gets the default type url for DeleteTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ImportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + DeleteTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeleteTaxonomyRequest"; }; - return ImportTaxonomiesRequest; + return DeleteTaxonomyRequest; })(); - v1beta1.InlineSource = (function() { + v1beta1.UpdateTaxonomyRequest = (function() { /** - * Properties of an InlineSource. + * Properties of an UpdateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IInlineSource - * @property {Array.|null} [taxonomies] InlineSource taxonomies + * @interface IUpdateTaxonomyRequest + * @property {google.cloud.datacatalog.v1beta1.ITaxonomy|null} [taxonomy] UpdateTaxonomyRequest taxonomy + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdateTaxonomyRequest updateMask */ /** - * Constructs a new InlineSource. + * Constructs a new UpdateTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an InlineSource. - * @implements IInlineSource + * @classdesc Represents an UpdateTaxonomyRequest. + * @implements IUpdateTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IInlineSource=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest=} [properties] Properties to set */ - function InlineSource(properties) { - this.taxonomies = []; + function UpdateTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -48437,78 +49745,89 @@ } /** - * InlineSource taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * UpdateTaxonomyRequest taxonomy. + * @member {google.cloud.datacatalog.v1beta1.ITaxonomy|null|undefined} taxonomy + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @instance */ - InlineSource.prototype.taxonomies = $util.emptyArray; + UpdateTaxonomyRequest.prototype.taxonomy = null; /** - * Creates a new InlineSource instance using the specified properties. + * UpdateTaxonomyRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest + * @instance + */ + UpdateTaxonomyRequest.prototype.updateMask = null; + + /** + * Creates a new UpdateTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IInlineSource=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource instance + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest instance */ - InlineSource.create = function create(properties) { - return new InlineSource(properties); + UpdateTaxonomyRequest.create = function create(properties) { + return new UpdateTaxonomyRequest(properties); }; /** - * Encodes the specified InlineSource message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.InlineSource.verify|verify} messages. + * Encodes the specified UpdateTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IInlineSource} message InlineSource message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - InlineSource.encode = function encode(message, writer) { + UpdateTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.taxonomy != null && Object.hasOwnProperty.call(message, "taxonomy")) + $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomy, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified InlineSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.InlineSource.verify|verify} messages. + * Encodes the specified UpdateTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IInlineSource} message InlineSource message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IUpdateTaxonomyRequest} message UpdateTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - InlineSource.encodeDelimited = function encodeDelimited(message, writer) { + UpdateTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an InlineSource message from the specified reader or buffer. + * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - InlineSource.decode = function decode(reader, length) { + UpdateTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.InlineSource(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.decode(reader, reader.uint32())); + message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32()); + break; + } + case 2: { + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); break; } default: @@ -48520,140 +49839,143 @@ }; /** - * Decodes an InlineSource message from the specified reader or buffer, length delimited. + * Decodes an UpdateTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - InlineSource.decodeDelimited = function decodeDelimited(reader) { + UpdateTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an InlineSource message. + * Verifies an UpdateTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - InlineSource.verify = function verify(message) { + UpdateTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) { + var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomy); + if (error) + return "taxonomy." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } return null; }; /** - * Creates an InlineSource message from a plain object. Also converts values to their respective internal types. + * Creates an UpdateTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + * @returns {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} UpdateTaxonomyRequest */ - InlineSource.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.InlineSource) + UpdateTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.InlineSource(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1beta1.InlineSource.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.InlineSource.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.fromObject(object.taxonomies[i]); - } + var message = new $root.google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest(); + if (object.taxonomy != null) { + if (typeof object.taxonomy !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.taxonomy: object expected"); + message.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomy); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } return message; }; /** - * Creates a plain object from an InlineSource message. Also converts values to other types if specified. + * Creates a plain object from an UpdateTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.InlineSource} message InlineSource + * @param {google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest} message UpdateTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - InlineSource.toObject = function toObject(message, options) { + UpdateTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.toObject(message.taxonomies[j], options); + if (options.defaults) { + object.taxonomy = null; + object.updateMask = null; } + if (message.taxonomy != null && message.hasOwnProperty("taxonomy")) + object.taxonomy = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomy, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this InlineSource to JSON. + * Converts this UpdateTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @instance * @returns {Object.} JSON object */ - InlineSource.prototype.toJSON = function toJSON() { + UpdateTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for InlineSource + * Gets the default type url for UpdateTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @memberof google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - InlineSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UpdateTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.InlineSource"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdateTaxonomyRequest"; }; - return InlineSource; + return UpdateTaxonomyRequest; })(); - v1beta1.ImportTaxonomiesResponse = (function() { + v1beta1.ListTaxonomiesRequest = (function() { /** - * Properties of an ImportTaxonomiesResponse. + * Properties of a ListTaxonomiesRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IImportTaxonomiesResponse - * @property {Array.|null} [taxonomies] ImportTaxonomiesResponse taxonomies + * @interface IListTaxonomiesRequest + * @property {string|null} [parent] ListTaxonomiesRequest parent + * @property {number|null} [pageSize] ListTaxonomiesRequest pageSize + * @property {string|null} [pageToken] ListTaxonomiesRequest pageToken */ /** - * Constructs a new ImportTaxonomiesResponse. + * Constructs a new ListTaxonomiesRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an ImportTaxonomiesResponse. - * @implements IImportTaxonomiesResponse + * @classdesc Represents a ListTaxonomiesRequest. + * @implements IListTaxonomiesRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest=} [properties] Properties to set */ - function ImportTaxonomiesResponse(properties) { - this.taxonomies = []; + function ListTaxonomiesRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -48661,78 +49983,103 @@ } /** - * ImportTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * ListTaxonomiesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @instance */ - ImportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + ListTaxonomiesRequest.prototype.parent = ""; /** - * Creates a new ImportTaxonomiesResponse instance using the specified properties. + * ListTaxonomiesRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @instance + */ + ListTaxonomiesRequest.prototype.pageSize = 0; + + /** + * ListTaxonomiesRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest + * @instance + */ + ListTaxonomiesRequest.prototype.pageToken = ""; + + /** + * Creates a new ListTaxonomiesRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest instance */ - ImportTaxonomiesResponse.create = function create(properties) { - return new ImportTaxonomiesResponse(properties); + ListTaxonomiesRequest.create = function create(properties) { + return new ListTaxonomiesRequest(properties); }; /** - * Encodes the specified ImportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified ListTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesResponse.encode = function encode(message, writer) { + ListTaxonomiesRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); return writer; }; /** - * Encodes the specified ImportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified ListTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesRequest} message ListTaxonomiesRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ImportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + ListTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer. + * Decodes a ListTaxonomiesRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesResponse.decode = function decode(reader, length) { + ListTaxonomiesRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32())); + message.parent = reader.string(); + break; + } + case 2: { + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); break; } default: @@ -48744,141 +50091,140 @@ }; /** - * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a ListTaxonomiesRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ImportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + ListTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ImportTaxonomiesResponse message. + * Verifies a ListTaxonomiesRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ImportTaxonomiesResponse.verify = function verify(message) { + ListTaxonomiesRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } - } + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; return null; }; /** - * Creates an ImportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a ListTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} ListTaxonomiesRequest */ - ImportTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse) + ListTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomies[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); return message; }; /** - * Creates a plain object from an ImportTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a ListTaxonomiesRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} message ImportTaxonomiesResponse + * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest} message ListTaxonomiesRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ImportTaxonomiesResponse.toObject = function toObject(message, options) { + ListTaxonomiesRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomies[j], options); + if (options.defaults) { + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; return object; }; /** - * Converts this ImportTaxonomiesResponse to JSON. + * Converts this ListTaxonomiesRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @instance * @returns {Object.} JSON object */ - ImportTaxonomiesResponse.prototype.toJSON = function toJSON() { + ListTaxonomiesRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ImportTaxonomiesResponse + * Gets the default type url for ListTaxonomiesRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ImportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTaxonomiesRequest"; }; - return ImportTaxonomiesResponse; + return ListTaxonomiesRequest; })(); - v1beta1.ExportTaxonomiesRequest = (function() { + v1beta1.ListTaxonomiesResponse = (function() { /** - * Properties of an ExportTaxonomiesRequest. + * Properties of a ListTaxonomiesResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IExportTaxonomiesRequest - * @property {string|null} [parent] ExportTaxonomiesRequest parent - * @property {Array.|null} [taxonomies] ExportTaxonomiesRequest taxonomies - * @property {boolean|null} [serializedTaxonomies] ExportTaxonomiesRequest serializedTaxonomies + * @interface IListTaxonomiesResponse + * @property {Array.|null} [taxonomies] ListTaxonomiesResponse taxonomies + * @property {string|null} [nextPageToken] ListTaxonomiesResponse nextPageToken */ /** - * Constructs a new ExportTaxonomiesRequest. + * Constructs a new ListTaxonomiesResponse. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an ExportTaxonomiesRequest. - * @implements IExportTaxonomiesRequest + * @classdesc Represents a ListTaxonomiesResponse. + * @implements IListTaxonomiesResponse * @constructor - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse=} [properties] Properties to set */ - function ExportTaxonomiesRequest(properties) { + function ListTaxonomiesResponse(properties) { this.taxonomies = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) @@ -48887,120 +50233,92 @@ } /** - * ExportTaxonomiesRequest parent. - * @member {string} parent - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest - * @instance - */ - ExportTaxonomiesRequest.prototype.parent = ""; - - /** - * ExportTaxonomiesRequest taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest - * @instance - */ - ExportTaxonomiesRequest.prototype.taxonomies = $util.emptyArray; - - /** - * ExportTaxonomiesRequest serializedTaxonomies. - * @member {boolean|null|undefined} serializedTaxonomies - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * ListTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @instance */ - ExportTaxonomiesRequest.prototype.serializedTaxonomies = null; - - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + ListTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; /** - * ExportTaxonomiesRequest destination. - * @member {"serializedTaxonomies"|undefined} destination - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * ListTaxonomiesResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @instance */ - Object.defineProperty(ExportTaxonomiesRequest.prototype, "destination", { - get: $util.oneOfGetter($oneOfFields = ["serializedTaxonomies"]), - set: $util.oneOfSetter($oneOfFields) - }); + ListTaxonomiesResponse.prototype.nextPageToken = ""; /** - * Creates a new ExportTaxonomiesRequest instance using the specified properties. + * Creates a new ListTaxonomiesResponse instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest instance + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse instance */ - ExportTaxonomiesRequest.create = function create(properties) { - return new ExportTaxonomiesRequest(properties); + ListTaxonomiesResponse.create = function create(properties) { + return new ListTaxonomiesResponse(properties); }; /** - * Encodes the specified ExportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesRequest.encode = function encode(message, writer) { + ListTaxonomiesResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); if (message.taxonomies != null && message.taxonomies.length) for (var i = 0; i < message.taxonomies.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.taxonomies[i]); - if (message.serializedTaxonomies != null && Object.hasOwnProperty.call(message, "serializedTaxonomies")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.serializedTaxonomies); + $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); return writer; }; /** - * Encodes the specified ExportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.verify|verify} messages. + * Encodes the specified ListTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IListTaxonomiesResponse} message ListTaxonomiesResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + ListTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer. + * Decodes a ListTaxonomiesResponse message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesRequest.decode = function decode(reader, length) { + ListTaxonomiesResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.parent = reader.string(); - break; - } - case 2: { if (!(message.taxonomies && message.taxonomies.length)) message.taxonomies = []; - message.taxonomies.push(reader.string()); + message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32())); break; } - case 3: { - message.serializedTaxonomies = reader.bool(); + case 2: { + message.nextPageToken = reader.string(); break; } default: @@ -49012,157 +50330,148 @@ }; /** - * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * Decodes a ListTaxonomiesResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + ListTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ExportTaxonomiesRequest message. + * Verifies a ListTaxonomiesResponse message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ExportTaxonomiesRequest.verify = function verify(message) { + ListTaxonomiesResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - var properties = {}; - if (message.parent != null && message.hasOwnProperty("parent")) - if (!$util.isString(message.parent)) - return "parent: string expected"; if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { if (!Array.isArray(message.taxonomies)) return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) - if (!$util.isString(message.taxonomies[i])) - return "taxonomies: string[] expected"; - } - if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { - properties.destination = 1; - if (typeof message.serializedTaxonomies !== "boolean") - return "serializedTaxonomies: boolean expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; return null; }; /** - * Creates an ExportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * Creates a ListTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @returns {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} ListTaxonomiesResponse */ - ExportTaxonomiesRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest) + ListTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest(); - if (object.parent != null) - message.parent = String(object.parent); + var message = new $root.google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse(); if (object.taxonomies) { if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.taxonomies: array expected"); + throw TypeError(".google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.taxonomies: array expected"); message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) - message.taxonomies[i] = String(object.taxonomies[i]); + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomies[i]); + } } - if (object.serializedTaxonomies != null) - message.serializedTaxonomies = Boolean(object.serializedTaxonomies); + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); return message; }; /** - * Creates a plain object from an ExportTaxonomiesRequest message. Also converts values to other types if specified. + * Creates a plain object from a ListTaxonomiesResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static - * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} message ExportTaxonomiesRequest + * @param {google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse} message ListTaxonomiesResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ExportTaxonomiesRequest.toObject = function toObject(message, options) { + ListTaxonomiesResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) object.taxonomies = []; if (options.defaults) - object.parent = ""; - if (message.parent != null && message.hasOwnProperty("parent")) - object.parent = message.parent; + object.nextPageToken = ""; if (message.taxonomies && message.taxonomies.length) { object.taxonomies = []; for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = message.taxonomies[j]; - } - if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { - object.serializedTaxonomies = message.serializedTaxonomies; - if (options.oneofs) - object.destination = "serializedTaxonomies"; + object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomies[j], options); } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; return object; }; /** - * Converts this ExportTaxonomiesRequest to JSON. + * Converts this ListTaxonomiesResponse to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @instance * @returns {Object.} JSON object */ - ExportTaxonomiesRequest.prototype.toJSON = function toJSON() { + ListTaxonomiesResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ExportTaxonomiesRequest + * Gets the default type url for ListTaxonomiesResponse * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @memberof google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ExportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ListTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListTaxonomiesResponse"; }; - return ExportTaxonomiesRequest; + return ListTaxonomiesResponse; })(); - v1beta1.ExportTaxonomiesResponse = (function() { + v1beta1.GetTaxonomyRequest = (function() { /** - * Properties of an ExportTaxonomiesResponse. + * Properties of a GetTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @interface IExportTaxonomiesResponse - * @property {Array.|null} [taxonomies] ExportTaxonomiesResponse taxonomies + * @interface IGetTaxonomyRequest + * @property {string|null} [name] GetTaxonomyRequest name */ /** - * Constructs a new ExportTaxonomiesResponse. + * Constructs a new GetTaxonomyRequest. * @memberof google.cloud.datacatalog.v1beta1 - * @classdesc Represents an ExportTaxonomiesResponse. - * @implements IExportTaxonomiesResponse + * @classdesc Represents a GetTaxonomyRequest. + * @implements IGetTaxonomyRequest * @constructor - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse=} [properties] Properties to set + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest=} [properties] Properties to set */ - function ExportTaxonomiesResponse(properties) { - this.taxonomies = []; + function GetTaxonomyRequest(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -49170,78 +50479,75 @@ } /** - * ExportTaxonomiesResponse taxonomies. - * @member {Array.} taxonomies - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * GetTaxonomyRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @instance */ - ExportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + GetTaxonomyRequest.prototype.name = ""; /** - * Creates a new ExportTaxonomiesResponse instance using the specified properties. + * Creates a new GetTaxonomyRequest instance using the specified properties. * @function create - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse=} [properties] Properties to set - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse instance + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest instance */ - ExportTaxonomiesResponse.create = function create(properties) { - return new ExportTaxonomiesResponse(properties); + GetTaxonomyRequest.create = function create(properties) { + return new GetTaxonomyRequest(properties); }; /** - * Encodes the specified ExportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified GetTaxonomyRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTaxonomyRequest.verify|verify} messages. * @function encode - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesResponse.encode = function encode(message, writer) { + GetTaxonomyRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.taxonomies != null && message.taxonomies.length) - for (var i = 0; i < message.taxonomies.length; ++i) - $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); return writer; }; /** - * Encodes the specified ExportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.verify|verify} messages. + * Encodes the specified GetTaxonomyRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetTaxonomyRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {google.cloud.datacatalog.v1beta1.IGetTaxonomyRequest} message GetTaxonomyRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + GetTaxonomyRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer. + * Decodes a GetTaxonomyRequest message from the specified reader or buffer. * @function decode - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesResponse.decode = function decode(reader, length) { + GetTaxonomyRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.taxonomies && message.taxonomies.length)) - message.taxonomies = []; - message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.decode(reader, reader.uint32())); + message.name = reader.string(); break; } default: @@ -49253,699 +50559,3908 @@ }; /** - * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * Decodes a GetTaxonomyRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + GetTaxonomyRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ExportTaxonomiesResponse message. + * Verifies a GetTaxonomyRequest message. * @function verify - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ExportTaxonomiesResponse.verify = function verify(message) { + GetTaxonomyRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { - if (!Array.isArray(message.taxonomies)) - return "taxonomies: array expected"; - for (var i = 0; i < message.taxonomies.length; ++i) { - var error = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify(message.taxonomies[i]); - if (error) - return "taxonomies." + error; - } - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; return null; }; /** - * Creates an ExportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * Creates a GetTaxonomyRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static * @param {Object.} object Plain object - * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @returns {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} GetTaxonomyRequest */ - ExportTaxonomiesResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse) + GetTaxonomyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest) return object; - var message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse(); - if (object.taxonomies) { - if (!Array.isArray(object.taxonomies)) - throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.taxonomies: array expected"); - message.taxonomies = []; - for (var i = 0; i < object.taxonomies.length; ++i) { - if (typeof object.taxonomies[i] !== "object") - throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.taxonomies: object expected"); - message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.fromObject(object.taxonomies[i]); - } - } + var message = new $root.google.cloud.datacatalog.v1beta1.GetTaxonomyRequest(); + if (object.name != null) + message.name = String(object.name); return message; }; /** - * Creates a plain object from an ExportTaxonomiesResponse message. Also converts values to other types if specified. + * Creates a plain object from a GetTaxonomyRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static - * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} message ExportTaxonomiesResponse + * @param {google.cloud.datacatalog.v1beta1.GetTaxonomyRequest} message GetTaxonomyRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ExportTaxonomiesResponse.toObject = function toObject(message, options) { + GetTaxonomyRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.taxonomies = []; - if (message.taxonomies && message.taxonomies.length) { - object.taxonomies = []; - for (var j = 0; j < message.taxonomies.length; ++j) - object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.toObject(message.taxonomies[j], options); - } + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; return object; }; /** - * Converts this ExportTaxonomiesResponse to JSON. + * Converts this GetTaxonomyRequest to JSON. * @function toJSON - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @instance * @returns {Object.} JSON object */ - ExportTaxonomiesResponse.prototype.toJSON = function toJSON() { + GetTaxonomyRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ExportTaxonomiesResponse + * Gets the default type url for GetTaxonomyRequest * @function getTypeUrl - * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @memberof google.cloud.datacatalog.v1beta1.GetTaxonomyRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ExportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GetTaxonomyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse"; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetTaxonomyRequest"; }; - return ExportTaxonomiesResponse; + return GetTaxonomyRequest; })(); - return v1beta1; - })(); + v1beta1.CreatePolicyTagRequest = (function() { - return datacatalog; - })(); + /** + * Properties of a CreatePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ICreatePolicyTagRequest + * @property {string|null} [parent] CreatePolicyTagRequest parent + * @property {google.cloud.datacatalog.v1beta1.IPolicyTag|null} [policyTag] CreatePolicyTagRequest policyTag + */ - return cloud; - })(); + /** + * Constructs a new CreatePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a CreatePolicyTagRequest. + * @implements ICreatePolicyTagRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest=} [properties] Properties to set + */ + function CreatePolicyTagRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - google.api = (function() { + /** + * CreatePolicyTagRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @instance + */ + CreatePolicyTagRequest.prototype.parent = ""; - /** - * Namespace api. - * @memberof google - * @namespace - */ - var api = {}; + /** + * CreatePolicyTagRequest policyTag. + * @member {google.cloud.datacatalog.v1beta1.IPolicyTag|null|undefined} policyTag + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @instance + */ + CreatePolicyTagRequest.prototype.policyTag = null; - /** - * FieldBehavior enum. - * @name google.api.FieldBehavior - * @enum {number} - * @property {number} FIELD_BEHAVIOR_UNSPECIFIED=0 FIELD_BEHAVIOR_UNSPECIFIED value - * @property {number} OPTIONAL=1 OPTIONAL value - * @property {number} REQUIRED=2 REQUIRED value - * @property {number} OUTPUT_ONLY=3 OUTPUT_ONLY value - * @property {number} INPUT_ONLY=4 INPUT_ONLY value - * @property {number} IMMUTABLE=5 IMMUTABLE value - * @property {number} UNORDERED_LIST=6 UNORDERED_LIST value - * @property {number} NON_EMPTY_DEFAULT=7 NON_EMPTY_DEFAULT value - */ - api.FieldBehavior = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "FIELD_BEHAVIOR_UNSPECIFIED"] = 0; - values[valuesById[1] = "OPTIONAL"] = 1; - values[valuesById[2] = "REQUIRED"] = 2; - values[valuesById[3] = "OUTPUT_ONLY"] = 3; - values[valuesById[4] = "INPUT_ONLY"] = 4; - values[valuesById[5] = "IMMUTABLE"] = 5; - values[valuesById[6] = "UNORDERED_LIST"] = 6; - values[valuesById[7] = "NON_EMPTY_DEFAULT"] = 7; - return values; - })(); + /** + * Creates a new CreatePolicyTagRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest instance + */ + CreatePolicyTagRequest.create = function create(properties) { + return new CreatePolicyTagRequest(properties); + }; - api.Http = (function() { + /** + * Encodes the specified CreatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CreatePolicyTagRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) + $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; - /** - * Properties of a Http. - * @memberof google.api - * @interface IHttp - * @property {Array.|null} [rules] Http rules - * @property {boolean|null} [fullyDecodeReservedExpansion] Http fullyDecodeReservedExpansion - */ + /** + * Encodes the specified CreatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ICreatePolicyTagRequest} message CreatePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CreatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Constructs a new Http. - * @memberof google.api - * @classdesc Represents a Http. - * @implements IHttp - * @constructor - * @param {google.api.IHttp=} [properties] Properties to set - */ - function Http(properties) { - this.rules = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Decodes a CreatePolicyTagRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CreatePolicyTagRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.parent = reader.string(); + break; + } + case 2: { + message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Http rules. - * @member {Array.} rules - * @memberof google.api.Http - * @instance - */ - Http.prototype.rules = $util.emptyArray; + /** + * Decodes a CreatePolicyTagRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CreatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Http fullyDecodeReservedExpansion. - * @member {boolean} fullyDecodeReservedExpansion - * @memberof google.api.Http - * @instance - */ - Http.prototype.fullyDecodeReservedExpansion = false; + /** + * Verifies a CreatePolicyTagRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CreatePolicyTagRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) { + var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTag); + if (error) + return "policyTag." + error; + } + return null; + }; - /** - * Creates a new Http instance using the specified properties. - * @function create - * @memberof google.api.Http - * @static - * @param {google.api.IHttp=} [properties] Properties to set - * @returns {google.api.Http} Http instance - */ - Http.create = function create(properties) { - return new Http(properties); - }; + /** + * Creates a CreatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} CreatePolicyTagRequest + */ + CreatePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.policyTag != null) { + if (typeof object.policyTag !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest.policyTag: object expected"); + message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTag); + } + return message; + }; - /** - * Encodes the specified Http message. Does not implicitly {@link google.api.Http.verify|verify} messages. - * @function encode - * @memberof google.api.Http - * @static - * @param {google.api.IHttp} message Http message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Http.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.rules != null && message.rules.length) - for (var i = 0; i < message.rules.length; ++i) - $root.google.api.HttpRule.encode(message.rules[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.fullyDecodeReservedExpansion != null && Object.hasOwnProperty.call(message, "fullyDecodeReservedExpansion")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.fullyDecodeReservedExpansion); - return writer; - }; + /** + * Creates a plain object from a CreatePolicyTagRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest} message CreatePolicyTagRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CreatePolicyTagRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.parent = ""; + object.policyTag = null; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + object.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTag, options); + return object; + }; - /** - * Encodes the specified Http message, length delimited. Does not implicitly {@link google.api.Http.verify|verify} messages. - * @function encodeDelimited - * @memberof google.api.Http - * @static - * @param {google.api.IHttp} message Http message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Http.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Converts this CreatePolicyTagRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @instance + * @returns {Object.} JSON object + */ + CreatePolicyTagRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Decodes a Http message from the specified reader or buffer. - * @function decode - * @memberof google.api.Http - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.api.Http} Http - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Http.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.Http(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.rules && message.rules.length)) - message.rules = []; - message.rules.push($root.google.api.HttpRule.decode(reader, reader.uint32())); - break; - } - case 2: { - message.fullyDecodeReservedExpansion = reader.bool(); - break; + /** + * Gets the default type url for CreatePolicyTagRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CreatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.CreatePolicyTagRequest"; + }; - /** - * Decodes a Http message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.api.Http - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.api.Http} Http - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Http.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + return CreatePolicyTagRequest; + })(); - /** - * Verifies a Http message. - * @function verify - * @memberof google.api.Http - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Http.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.rules != null && message.hasOwnProperty("rules")) { - if (!Array.isArray(message.rules)) - return "rules: array expected"; - for (var i = 0; i < message.rules.length; ++i) { - var error = $root.google.api.HttpRule.verify(message.rules[i]); - if (error) - return "rules." + error; - } - } - if (message.fullyDecodeReservedExpansion != null && message.hasOwnProperty("fullyDecodeReservedExpansion")) - if (typeof message.fullyDecodeReservedExpansion !== "boolean") - return "fullyDecodeReservedExpansion: boolean expected"; - return null; - }; + v1beta1.DeletePolicyTagRequest = (function() { - /** - * Creates a Http message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.api.Http - * @static - * @param {Object.} object Plain object - * @returns {google.api.Http} Http - */ - Http.fromObject = function fromObject(object) { - if (object instanceof $root.google.api.Http) - return object; - var message = new $root.google.api.Http(); - if (object.rules) { - if (!Array.isArray(object.rules)) - throw TypeError(".google.api.Http.rules: array expected"); - message.rules = []; - for (var i = 0; i < object.rules.length; ++i) { - if (typeof object.rules[i] !== "object") - throw TypeError(".google.api.Http.rules: object expected"); - message.rules[i] = $root.google.api.HttpRule.fromObject(object.rules[i]); + /** + * Properties of a DeletePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IDeletePolicyTagRequest + * @property {string|null} [name] DeletePolicyTagRequest name + */ + + /** + * Constructs a new DeletePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a DeletePolicyTagRequest. + * @implements IDeletePolicyTagRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest=} [properties] Properties to set + */ + function DeletePolicyTagRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - } - if (object.fullyDecodeReservedExpansion != null) - message.fullyDecodeReservedExpansion = Boolean(object.fullyDecodeReservedExpansion); - return message; - }; - /** - * Creates a plain object from a Http message. Also converts values to other types if specified. - * @function toObject - * @memberof google.api.Http - * @static - * @param {google.api.Http} message Http - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Http.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.rules = []; - if (options.defaults) - object.fullyDecodeReservedExpansion = false; - if (message.rules && message.rules.length) { - object.rules = []; - for (var j = 0; j < message.rules.length; ++j) - object.rules[j] = $root.google.api.HttpRule.toObject(message.rules[j], options); - } - if (message.fullyDecodeReservedExpansion != null && message.hasOwnProperty("fullyDecodeReservedExpansion")) - object.fullyDecodeReservedExpansion = message.fullyDecodeReservedExpansion; - return object; - }; + /** + * DeletePolicyTagRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @instance + */ + DeletePolicyTagRequest.prototype.name = ""; - /** - * Converts this Http to JSON. - * @function toJSON - * @memberof google.api.Http - * @instance - * @returns {Object.} JSON object - */ - Http.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Creates a new DeletePolicyTagRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest instance + */ + DeletePolicyTagRequest.create = function create(properties) { + return new DeletePolicyTagRequest(properties); + }; - /** - * Gets the default type url for Http - * @function getTypeUrl - * @memberof google.api.Http - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Http.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.api.Http"; - }; + /** + * Encodes the specified DeletePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeletePolicyTagRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; - return Http; - })(); + /** + * Encodes the specified DeletePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IDeletePolicyTagRequest} message DeletePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeletePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - api.HttpRule = (function() { + /** + * Decodes a DeletePolicyTagRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeletePolicyTagRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Properties of a HttpRule. - * @memberof google.api - * @interface IHttpRule - * @property {string|null} [selector] HttpRule selector - * @property {string|null} [get] HttpRule get - * @property {string|null} [put] HttpRule put - * @property {string|null} [post] HttpRule post - * @property {string|null} ["delete"] HttpRule delete - * @property {string|null} [patch] HttpRule patch - * @property {google.api.ICustomHttpPattern|null} [custom] HttpRule custom - * @property {string|null} [body] HttpRule body - * @property {string|null} [responseBody] HttpRule responseBody - * @property {Array.|null} [additionalBindings] HttpRule additionalBindings - */ + /** + * Decodes a DeletePolicyTagRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeletePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Constructs a new HttpRule. - * @memberof google.api - * @classdesc Represents a HttpRule. - * @implements IHttpRule - * @constructor - * @param {google.api.IHttpRule=} [properties] Properties to set - */ - function HttpRule(properties) { - this.additionalBindings = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Verifies a DeletePolicyTagRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DeletePolicyTagRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; - /** - * HttpRule selector. - * @member {string} selector - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.selector = ""; + /** + * Creates a DeletePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} DeletePolicyTagRequest + */ + DeletePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; - /** - * HttpRule get. - * @member {string|null|undefined} get - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.get = null; + /** + * Creates a plain object from a DeletePolicyTagRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest} message DeletePolicyTagRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DeletePolicyTagRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; - /** - * HttpRule put. - * @member {string|null|undefined} put - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.put = null; + /** + * Converts this DeletePolicyTagRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @instance + * @returns {Object.} JSON object + */ + DeletePolicyTagRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * HttpRule post. - * @member {string|null|undefined} post - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.post = null; + /** + * Gets the default type url for DeletePolicyTagRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DeletePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.DeletePolicyTagRequest"; + }; - /** - * HttpRule delete. - * @member {string|null|undefined} delete - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype["delete"] = null; + return DeletePolicyTagRequest; + })(); - /** - * HttpRule patch. - * @member {string|null|undefined} patch - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.patch = null; + v1beta1.UpdatePolicyTagRequest = (function() { - /** - * HttpRule custom. - * @member {google.api.ICustomHttpPattern|null|undefined} custom - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.custom = null; + /** + * Properties of an UpdatePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IUpdatePolicyTagRequest + * @property {google.cloud.datacatalog.v1beta1.IPolicyTag|null} [policyTag] UpdatePolicyTagRequest policyTag + * @property {google.protobuf.IFieldMask|null} [updateMask] UpdatePolicyTagRequest updateMask + */ - /** - * HttpRule body. - * @member {string} body - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.body = ""; + /** + * Constructs a new UpdatePolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an UpdatePolicyTagRequest. + * @implements IUpdatePolicyTagRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest=} [properties] Properties to set + */ + function UpdatePolicyTagRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * HttpRule responseBody. - * @member {string} responseBody - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.responseBody = ""; + /** + * UpdatePolicyTagRequest policyTag. + * @member {google.cloud.datacatalog.v1beta1.IPolicyTag|null|undefined} policyTag + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @instance + */ + UpdatePolicyTagRequest.prototype.policyTag = null; - /** - * HttpRule additionalBindings. - * @member {Array.} additionalBindings - * @memberof google.api.HttpRule - * @instance - */ - HttpRule.prototype.additionalBindings = $util.emptyArray; + /** + * UpdatePolicyTagRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @instance + */ + UpdatePolicyTagRequest.prototype.updateMask = null; - // OneOf field names bound to virtual getters and setters - var $oneOfFields; + /** + * Creates a new UpdatePolicyTagRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest instance + */ + UpdatePolicyTagRequest.create = function create(properties) { + return new UpdatePolicyTagRequest(properties); + }; - /** - * HttpRule pattern. - * @member {"get"|"put"|"post"|"delete"|"patch"|"custom"|undefined} pattern - * @memberof google.api.HttpRule - * @instance - */ - Object.defineProperty(HttpRule.prototype, "pattern", { - get: $util.oneOfGetter($oneOfFields = ["get", "put", "post", "delete", "patch", "custom"]), - set: $util.oneOfSetter($oneOfFields) - }); + /** + * Encodes the specified UpdatePolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + UpdatePolicyTagRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.policyTag != null && Object.hasOwnProperty.call(message, "policyTag")) + $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTag, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; - /** - * Creates a new HttpRule instance using the specified properties. - * @function create - * @memberof google.api.HttpRule - * @static - * @param {google.api.IHttpRule=} [properties] Properties to set - * @returns {google.api.HttpRule} HttpRule instance - */ - HttpRule.create = function create(properties) { - return new HttpRule(properties); - }; + /** + * Encodes the specified UpdatePolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IUpdatePolicyTagRequest} message UpdatePolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + UpdatePolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Encodes the specified HttpRule message. Does not implicitly {@link google.api.HttpRule.verify|verify} messages. - * @function encode - * @memberof google.api.HttpRule - * @static - * @param {google.api.IHttpRule} message HttpRule message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - HttpRule.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.selector != null && Object.hasOwnProperty.call(message, "selector")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.selector); - if (message.get != null && Object.hasOwnProperty.call(message, "get")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.get); - if (message.put != null && Object.hasOwnProperty.call(message, "put")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.put); - if (message.post != null && Object.hasOwnProperty.call(message, "post")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.post); - if (message["delete"] != null && Object.hasOwnProperty.call(message, "delete")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message["delete"]); - if (message.patch != null && Object.hasOwnProperty.call(message, "patch")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.patch); - if (message.body != null && Object.hasOwnProperty.call(message, "body")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.body); - if (message.custom != null && Object.hasOwnProperty.call(message, "custom")) - $root.google.api.CustomHttpPattern.encode(message.custom, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.additionalBindings != null && message.additionalBindings.length) - for (var i = 0; i < message.additionalBindings.length; ++i) - $root.google.api.HttpRule.encode(message.additionalBindings[i], writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); - if (message.responseBody != null && Object.hasOwnProperty.call(message, "responseBody")) - writer.uint32(/* id 12, wireType 2 =*/98).string(message.responseBody); - return writer; - }; + /** + * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + UpdatePolicyTagRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32()); + break; + } + case 2: { + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Encodes the specified HttpRule message, length delimited. Does not implicitly {@link google.api.HttpRule.verify|verify} messages. - * @function encodeDelimited - * @memberof google.api.HttpRule - * @static - * @param {google.api.IHttpRule} message HttpRule message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - HttpRule.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Decodes an UpdatePolicyTagRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + UpdatePolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Decodes a HttpRule message from the specified reader or buffer. - * @function decode - * @memberof google.api.HttpRule - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.api.HttpRule} HttpRule - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - HttpRule.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.HttpRule(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.selector = reader.string(); - break; - } - case 2: { - message.get = reader.string(); - break; - } - case 3: { - message.put = reader.string(); - break; - } - case 4: { - message.post = reader.string(); - break; - } - case 5: { - message["delete"] = reader.string(); - break; - } - case 6: { - message.patch = reader.string(); - break; + /** + * Verifies an UpdatePolicyTagRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + UpdatePolicyTagRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) { + var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTag); + if (error) + return "policyTag." + error; } - case 8: { - message.custom = $root.google.api.CustomHttpPattern.decode(reader, reader.uint32()); - break; + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; } - case 7: { - message.body = reader.string(); - break; + return null; + }; + + /** + * Creates an UpdatePolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} UpdatePolicyTagRequest + */ + UpdatePolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest(); + if (object.policyTag != null) { + if (typeof object.policyTag !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.policyTag: object expected"); + message.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTag); } - case 12: { - message.responseBody = reader.string(); - break; + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); } - case 11: { - if (!(message.additionalBindings && message.additionalBindings.length)) - message.additionalBindings = []; - message.additionalBindings.push($root.google.api.HttpRule.decode(reader, reader.uint32())); - break; + return message; + }; + + /** + * Creates a plain object from an UpdatePolicyTagRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest} message UpdatePolicyTagRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + UpdatePolicyTagRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.policyTag = null; + object.updateMask = null; } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + if (message.policyTag != null && message.hasOwnProperty("policyTag")) + object.policyTag = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTag, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + return object; + }; - /** - * Decodes a HttpRule message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.api.HttpRule - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.api.HttpRule} HttpRule - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - HttpRule.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Converts this UpdatePolicyTagRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @instance + * @returns {Object.} JSON object + */ + UpdatePolicyTagRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Verifies a HttpRule message. - * @function verify - * @memberof google.api.HttpRule - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - HttpRule.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - var properties = {}; - if (message.selector != null && message.hasOwnProperty("selector")) + /** + * Gets the default type url for UpdatePolicyTagRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + UpdatePolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.UpdatePolicyTagRequest"; + }; + + return UpdatePolicyTagRequest; + })(); + + v1beta1.ListPolicyTagsRequest = (function() { + + /** + * Properties of a ListPolicyTagsRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IListPolicyTagsRequest + * @property {string|null} [parent] ListPolicyTagsRequest parent + * @property {number|null} [pageSize] ListPolicyTagsRequest pageSize + * @property {string|null} [pageToken] ListPolicyTagsRequest pageToken + */ + + /** + * Constructs a new ListPolicyTagsRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a ListPolicyTagsRequest. + * @implements IListPolicyTagsRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest=} [properties] Properties to set + */ + function ListPolicyTagsRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ListPolicyTagsRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @instance + */ + ListPolicyTagsRequest.prototype.parent = ""; + + /** + * ListPolicyTagsRequest pageSize. + * @member {number} pageSize + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @instance + */ + ListPolicyTagsRequest.prototype.pageSize = 0; + + /** + * ListPolicyTagsRequest pageToken. + * @member {string} pageToken + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @instance + */ + ListPolicyTagsRequest.prototype.pageToken = ""; + + /** + * Creates a new ListPolicyTagsRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest instance + */ + ListPolicyTagsRequest.create = function create(properties) { + return new ListPolicyTagsRequest(properties); + }; + + /** + * Encodes the specified ListPolicyTagsRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListPolicyTagsRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + return writer; + }; + + /** + * Encodes the specified ListPolicyTagsRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsRequest} message ListPolicyTagsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListPolicyTagsRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ListPolicyTagsRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListPolicyTagsRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.parent = reader.string(); + break; + } + case 2: { + message.pageSize = reader.int32(); + break; + } + case 3: { + message.pageToken = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ListPolicyTagsRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListPolicyTagsRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ListPolicyTagsRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ListPolicyTagsRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + return null; + }; + + /** + * Creates a ListPolicyTagsRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} ListPolicyTagsRequest + */ + ListPolicyTagsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + return message; + }; + + /** + * Creates a plain object from a ListPolicyTagsRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest} message ListPolicyTagsRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ListPolicyTagsRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.parent = ""; + object.pageSize = 0; + object.pageToken = ""; + } + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + return object; + }; + + /** + * Converts this ListPolicyTagsRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @instance + * @returns {Object.} JSON object + */ + ListPolicyTagsRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ListPolicyTagsRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ListPolicyTagsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListPolicyTagsRequest"; + }; + + return ListPolicyTagsRequest; + })(); + + v1beta1.ListPolicyTagsResponse = (function() { + + /** + * Properties of a ListPolicyTagsResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IListPolicyTagsResponse + * @property {Array.|null} [policyTags] ListPolicyTagsResponse policyTags + * @property {string|null} [nextPageToken] ListPolicyTagsResponse nextPageToken + */ + + /** + * Constructs a new ListPolicyTagsResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a ListPolicyTagsResponse. + * @implements IListPolicyTagsResponse + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse=} [properties] Properties to set + */ + function ListPolicyTagsResponse(properties) { + this.policyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ListPolicyTagsResponse policyTags. + * @member {Array.} policyTags + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @instance + */ + ListPolicyTagsResponse.prototype.policyTags = $util.emptyArray; + + /** + * ListPolicyTagsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @instance + */ + ListPolicyTagsResponse.prototype.nextPageToken = ""; + + /** + * Creates a new ListPolicyTagsResponse instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse instance + */ + ListPolicyTagsResponse.create = function create(properties) { + return new ListPolicyTagsResponse(properties); + }; + + /** + * Encodes the specified ListPolicyTagsResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListPolicyTagsResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.policyTags != null && message.policyTags.length) + for (var i = 0; i < message.policyTags.length; ++i) + $root.google.cloud.datacatalog.v1beta1.PolicyTag.encode(message.policyTags[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + return writer; + }; + + /** + * Encodes the specified ListPolicyTagsResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IListPolicyTagsResponse} message ListPolicyTagsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListPolicyTagsResponse.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ListPolicyTagsResponse message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListPolicyTagsResponse.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.policyTags && message.policyTags.length)) + message.policyTags = []; + message.policyTags.push($root.google.cloud.datacatalog.v1beta1.PolicyTag.decode(reader, reader.uint32())); + break; + } + case 2: { + message.nextPageToken = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ListPolicyTagsResponse message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListPolicyTagsResponse.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ListPolicyTagsResponse message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ListPolicyTagsResponse.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.policyTags != null && message.hasOwnProperty("policyTags")) { + if (!Array.isArray(message.policyTags)) + return "policyTags: array expected"; + for (var i = 0; i < message.policyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.PolicyTag.verify(message.policyTags[i]); + if (error) + return "policyTags." + error; + } + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; + return null; + }; + + /** + * Creates a ListPolicyTagsResponse message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} ListPolicyTagsResponse + */ + ListPolicyTagsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse(); + if (object.policyTags) { + if (!Array.isArray(object.policyTags)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.policyTags: array expected"); + message.policyTags = []; + for (var i = 0; i < object.policyTags.length; ++i) { + if (typeof object.policyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse.policyTags: object expected"); + message.policyTags[i] = $root.google.cloud.datacatalog.v1beta1.PolicyTag.fromObject(object.policyTags[i]); + } + } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); + return message; + }; + + /** + * Creates a plain object from a ListPolicyTagsResponse message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse} message ListPolicyTagsResponse + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ListPolicyTagsResponse.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.policyTags = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.policyTags && message.policyTags.length) { + object.policyTags = []; + for (var j = 0; j < message.policyTags.length; ++j) + object.policyTags[j] = $root.google.cloud.datacatalog.v1beta1.PolicyTag.toObject(message.policyTags[j], options); + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; + return object; + }; + + /** + * Converts this ListPolicyTagsResponse to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @instance + * @returns {Object.} JSON object + */ + ListPolicyTagsResponse.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ListPolicyTagsResponse + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ListPolicyTagsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ListPolicyTagsResponse"; + }; + + return ListPolicyTagsResponse; + })(); + + v1beta1.GetPolicyTagRequest = (function() { + + /** + * Properties of a GetPolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IGetPolicyTagRequest + * @property {string|null} [name] GetPolicyTagRequest name + */ + + /** + * Constructs a new GetPolicyTagRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a GetPolicyTagRequest. + * @implements IGetPolicyTagRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest=} [properties] Properties to set + */ + function GetPolicyTagRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * GetPolicyTagRequest name. + * @member {string} name + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @instance + */ + GetPolicyTagRequest.prototype.name = ""; + + /** + * Creates a new GetPolicyTagRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest instance + */ + GetPolicyTagRequest.create = function create(properties) { + return new GetPolicyTagRequest(properties); + }; + + /** + * Encodes the specified GetPolicyTagRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetPolicyTagRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetPolicyTagRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; + + /** + * Encodes the specified GetPolicyTagRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.GetPolicyTagRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IGetPolicyTagRequest} message GetPolicyTagRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetPolicyTagRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a GetPolicyTagRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetPolicyTagRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a GetPolicyTagRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetPolicyTagRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a GetPolicyTagRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GetPolicyTagRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; + + /** + * Creates a GetPolicyTagRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} GetPolicyTagRequest + */ + GetPolicyTagRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.GetPolicyTagRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; + + /** + * Creates a plain object from a GetPolicyTagRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.GetPolicyTagRequest} message GetPolicyTagRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GetPolicyTagRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; + + /** + * Converts this GetPolicyTagRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @instance + * @returns {Object.} JSON object + */ + GetPolicyTagRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for GetPolicyTagRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.GetPolicyTagRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + GetPolicyTagRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.GetPolicyTagRequest"; + }; + + return GetPolicyTagRequest; + })(); + + v1beta1.PolicyTagManagerSerialization = (function() { + + /** + * Constructs a new PolicyTagManagerSerialization service. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a PolicyTagManagerSerialization + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + */ + function PolicyTagManagerSerialization(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } + + (PolicyTagManagerSerialization.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = PolicyTagManagerSerialization; + + /** + * Creates new PolicyTagManagerSerialization service using the specified rpc implementation. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @static + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {PolicyTagManagerSerialization} RPC service. Useful where requests and/or responses are streamed. + */ + PolicyTagManagerSerialization.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); + }; + + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization|importTaxonomies}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @typedef ImportTaxonomiesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} [response] ImportTaxonomiesResponse + */ + + /** + * Calls ImportTaxonomies. + * @function importTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @instance + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization.ImportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ImportTaxonomiesResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManagerSerialization.prototype.importTaxonomies = function importTaxonomies(request, callback) { + return this.rpcCall(importTaxonomies, $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse, request, callback); + }, "name", { value: "ImportTaxonomies" }); + + /** + * Calls ImportTaxonomies. + * @function importTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @instance + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} request ImportTaxonomiesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization|exportTaxonomies}. + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @typedef ExportTaxonomiesCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} [response] ExportTaxonomiesResponse + */ + + /** + * Calls ExportTaxonomies. + * @function exportTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @instance + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object + * @param {google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization.ExportTaxonomiesCallback} callback Node-style callback called with the error, if any, and ExportTaxonomiesResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(PolicyTagManagerSerialization.prototype.exportTaxonomies = function exportTaxonomies(request, callback) { + return this.rpcCall(exportTaxonomies, $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest, $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse, request, callback); + }, "name", { value: "ExportTaxonomies" }); + + /** + * Calls ExportTaxonomies. + * @function exportTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.PolicyTagManagerSerialization + * @instance + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} request ExportTaxonomiesRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + return PolicyTagManagerSerialization; + })(); + + v1beta1.SerializedTaxonomy = (function() { + + /** + * Properties of a SerializedTaxonomy. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISerializedTaxonomy + * @property {string|null} [displayName] SerializedTaxonomy displayName + * @property {string|null} [description] SerializedTaxonomy description + * @property {Array.|null} [policyTags] SerializedTaxonomy policyTags + */ + + /** + * Constructs a new SerializedTaxonomy. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a SerializedTaxonomy. + * @implements ISerializedTaxonomy + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy=} [properties] Properties to set + */ + function SerializedTaxonomy(properties) { + this.policyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * SerializedTaxonomy displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @instance + */ + SerializedTaxonomy.prototype.displayName = ""; + + /** + * SerializedTaxonomy description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @instance + */ + SerializedTaxonomy.prototype.description = ""; + + /** + * SerializedTaxonomy policyTags. + * @member {Array.} policyTags + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @instance + */ + SerializedTaxonomy.prototype.policyTags = $util.emptyArray; + + /** + * Creates a new SerializedTaxonomy instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy instance + */ + SerializedTaxonomy.create = function create(properties) { + return new SerializedTaxonomy(properties); + }; + + /** + * Encodes the specified SerializedTaxonomy message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SerializedTaxonomy.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.description); + if (message.policyTags != null && message.policyTags.length) + for (var i = 0; i < message.policyTags.length; ++i) + $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.encode(message.policyTags[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified SerializedTaxonomy message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedTaxonomy} message SerializedTaxonomy message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SerializedTaxonomy.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a SerializedTaxonomy message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SerializedTaxonomy.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.displayName = reader.string(); + break; + } + case 2: { + message.description = reader.string(); + break; + } + case 3: { + if (!(message.policyTags && message.policyTags.length)) + message.policyTags = []; + message.policyTags.push($root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a SerializedTaxonomy message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SerializedTaxonomy.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a SerializedTaxonomy message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + SerializedTaxonomy.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.policyTags != null && message.hasOwnProperty("policyTags")) { + if (!Array.isArray(message.policyTags)) + return "policyTags: array expected"; + for (var i = 0; i < message.policyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify(message.policyTags[i]); + if (error) + return "policyTags." + error; + } + } + return null; + }; + + /** + * Creates a SerializedTaxonomy message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} SerializedTaxonomy + */ + SerializedTaxonomy.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.policyTags) { + if (!Array.isArray(object.policyTags)) + throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedTaxonomy.policyTags: array expected"); + message.policyTags = []; + for (var i = 0; i < object.policyTags.length; ++i) { + if (typeof object.policyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedTaxonomy.policyTags: object expected"); + message.policyTags[i] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.fromObject(object.policyTags[i]); + } + } + return message; + }; + + /** + * Creates a plain object from a SerializedTaxonomy message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {google.cloud.datacatalog.v1beta1.SerializedTaxonomy} message SerializedTaxonomy + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + SerializedTaxonomy.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.policyTags = []; + if (options.defaults) { + object.displayName = ""; + object.description = ""; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.policyTags && message.policyTags.length) { + object.policyTags = []; + for (var j = 0; j < message.policyTags.length; ++j) + object.policyTags[j] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.toObject(message.policyTags[j], options); + } + return object; + }; + + /** + * Converts this SerializedTaxonomy to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @instance + * @returns {Object.} JSON object + */ + SerializedTaxonomy.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for SerializedTaxonomy + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.SerializedTaxonomy + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + SerializedTaxonomy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SerializedTaxonomy"; + }; + + return SerializedTaxonomy; + })(); + + v1beta1.SerializedPolicyTag = (function() { + + /** + * Properties of a SerializedPolicyTag. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface ISerializedPolicyTag + * @property {string|null} [displayName] SerializedPolicyTag displayName + * @property {string|null} [description] SerializedPolicyTag description + * @property {Array.|null} [childPolicyTags] SerializedPolicyTag childPolicyTags + */ + + /** + * Constructs a new SerializedPolicyTag. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents a SerializedPolicyTag. + * @implements ISerializedPolicyTag + * @constructor + * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag=} [properties] Properties to set + */ + function SerializedPolicyTag(properties) { + this.childPolicyTags = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * SerializedPolicyTag displayName. + * @member {string} displayName + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @instance + */ + SerializedPolicyTag.prototype.displayName = ""; + + /** + * SerializedPolicyTag description. + * @member {string} description + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @instance + */ + SerializedPolicyTag.prototype.description = ""; + + /** + * SerializedPolicyTag childPolicyTags. + * @member {Array.} childPolicyTags + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @instance + */ + SerializedPolicyTag.prototype.childPolicyTags = $util.emptyArray; + + /** + * Creates a new SerializedPolicyTag instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag instance + */ + SerializedPolicyTag.create = function create(properties) { + return new SerializedPolicyTag(properties); + }; + + /** + * Encodes the specified SerializedPolicyTag message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SerializedPolicyTag.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.displayName != null && Object.hasOwnProperty.call(message, "displayName")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.displayName); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.childPolicyTags != null && message.childPolicyTags.length) + for (var i = 0; i < message.childPolicyTags.length; ++i) + $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.encode(message.childPolicyTags[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified SerializedPolicyTag message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {google.cloud.datacatalog.v1beta1.ISerializedPolicyTag} message SerializedPolicyTag message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SerializedPolicyTag.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a SerializedPolicyTag message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SerializedPolicyTag.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 2: { + message.displayName = reader.string(); + break; + } + case 3: { + message.description = reader.string(); + break; + } + case 4: { + if (!(message.childPolicyTags && message.childPolicyTags.length)) + message.childPolicyTags = []; + message.childPolicyTags.push($root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a SerializedPolicyTag message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SerializedPolicyTag.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a SerializedPolicyTag message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + SerializedPolicyTag.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.displayName != null && message.hasOwnProperty("displayName")) + if (!$util.isString(message.displayName)) + return "displayName: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.childPolicyTags != null && message.hasOwnProperty("childPolicyTags")) { + if (!Array.isArray(message.childPolicyTags)) + return "childPolicyTags: array expected"; + for (var i = 0; i < message.childPolicyTags.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.verify(message.childPolicyTags[i]); + if (error) + return "childPolicyTags." + error; + } + } + return null; + }; + + /** + * Creates a SerializedPolicyTag message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} SerializedPolicyTag + */ + SerializedPolicyTag.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag(); + if (object.displayName != null) + message.displayName = String(object.displayName); + if (object.description != null) + message.description = String(object.description); + if (object.childPolicyTags) { + if (!Array.isArray(object.childPolicyTags)) + throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedPolicyTag.childPolicyTags: array expected"); + message.childPolicyTags = []; + for (var i = 0; i < object.childPolicyTags.length; ++i) { + if (typeof object.childPolicyTags[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.SerializedPolicyTag.childPolicyTags: object expected"); + message.childPolicyTags[i] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.fromObject(object.childPolicyTags[i]); + } + } + return message; + }; + + /** + * Creates a plain object from a SerializedPolicyTag message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {google.cloud.datacatalog.v1beta1.SerializedPolicyTag} message SerializedPolicyTag + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + SerializedPolicyTag.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.childPolicyTags = []; + if (options.defaults) { + object.displayName = ""; + object.description = ""; + } + if (message.displayName != null && message.hasOwnProperty("displayName")) + object.displayName = message.displayName; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.childPolicyTags && message.childPolicyTags.length) { + object.childPolicyTags = []; + for (var j = 0; j < message.childPolicyTags.length; ++j) + object.childPolicyTags[j] = $root.google.cloud.datacatalog.v1beta1.SerializedPolicyTag.toObject(message.childPolicyTags[j], options); + } + return object; + }; + + /** + * Converts this SerializedPolicyTag to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @instance + * @returns {Object.} JSON object + */ + SerializedPolicyTag.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for SerializedPolicyTag + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.SerializedPolicyTag + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + SerializedPolicyTag.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.SerializedPolicyTag"; + }; + + return SerializedPolicyTag; + })(); + + v1beta1.ImportTaxonomiesRequest = (function() { + + /** + * Properties of an ImportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IImportTaxonomiesRequest + * @property {string|null} [parent] ImportTaxonomiesRequest parent + * @property {google.cloud.datacatalog.v1beta1.IInlineSource|null} [inlineSource] ImportTaxonomiesRequest inlineSource + */ + + /** + * Constructs a new ImportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an ImportTaxonomiesRequest. + * @implements IImportTaxonomiesRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest=} [properties] Properties to set + */ + function ImportTaxonomiesRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ImportTaxonomiesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @instance + */ + ImportTaxonomiesRequest.prototype.parent = ""; + + /** + * ImportTaxonomiesRequest inlineSource. + * @member {google.cloud.datacatalog.v1beta1.IInlineSource|null|undefined} inlineSource + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @instance + */ + ImportTaxonomiesRequest.prototype.inlineSource = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * ImportTaxonomiesRequest source. + * @member {"inlineSource"|undefined} source + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @instance + */ + Object.defineProperty(ImportTaxonomiesRequest.prototype, "source", { + get: $util.oneOfGetter($oneOfFields = ["inlineSource"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ImportTaxonomiesRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest instance + */ + ImportTaxonomiesRequest.create = function create(properties) { + return new ImportTaxonomiesRequest(properties); + }; + + /** + * Encodes the specified ImportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ImportTaxonomiesRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.inlineSource != null && Object.hasOwnProperty.call(message, "inlineSource")) + $root.google.cloud.datacatalog.v1beta1.InlineSource.encode(message.inlineSource, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ImportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesRequest} message ImportTaxonomiesRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ImportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ImportTaxonomiesRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.parent = reader.string(); + break; + } + case 2: { + message.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an ImportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ImportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ImportTaxonomiesRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ImportTaxonomiesRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { + properties.source = 1; + { + var error = $root.google.cloud.datacatalog.v1beta1.InlineSource.verify(message.inlineSource); + if (error) + return "inlineSource." + error; + } + } + return null; + }; + + /** + * Creates an ImportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} ImportTaxonomiesRequest + */ + ImportTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.inlineSource != null) { + if (typeof object.inlineSource !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest.inlineSource: object expected"); + message.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.fromObject(object.inlineSource); + } + return message; + }; + + /** + * Creates a plain object from an ImportTaxonomiesRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest} message ImportTaxonomiesRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ImportTaxonomiesRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.parent = ""; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.inlineSource != null && message.hasOwnProperty("inlineSource")) { + object.inlineSource = $root.google.cloud.datacatalog.v1beta1.InlineSource.toObject(message.inlineSource, options); + if (options.oneofs) + object.source = "inlineSource"; + } + return object; + }; + + /** + * Converts this ImportTaxonomiesRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @instance + * @returns {Object.} JSON object + */ + ImportTaxonomiesRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ImportTaxonomiesRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ImportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ImportTaxonomiesRequest"; + }; + + return ImportTaxonomiesRequest; + })(); + + v1beta1.InlineSource = (function() { + + /** + * Properties of an InlineSource. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IInlineSource + * @property {Array.|null} [taxonomies] InlineSource taxonomies + */ + + /** + * Constructs a new InlineSource. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an InlineSource. + * @implements IInlineSource + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IInlineSource=} [properties] Properties to set + */ + function InlineSource(properties) { + this.taxonomies = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * InlineSource taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @instance + */ + InlineSource.prototype.taxonomies = $util.emptyArray; + + /** + * Creates a new InlineSource instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {google.cloud.datacatalog.v1beta1.IInlineSource=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource instance + */ + InlineSource.create = function create(properties) { + return new InlineSource(properties); + }; + + /** + * Encodes the specified InlineSource message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.InlineSource.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {google.cloud.datacatalog.v1beta1.IInlineSource} message InlineSource message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + InlineSource.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified InlineSource message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.InlineSource.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {google.cloud.datacatalog.v1beta1.IInlineSource} message InlineSource message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + InlineSource.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an InlineSource message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + InlineSource.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.InlineSource(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an InlineSource message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + InlineSource.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an InlineSource message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + InlineSource.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } + } + return null; + }; + + /** + * Creates an InlineSource message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.InlineSource} InlineSource + */ + InlineSource.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.InlineSource) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.InlineSource(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1beta1.InlineSource.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.InlineSource.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.fromObject(object.taxonomies[i]); + } + } + return message; + }; + + /** + * Creates a plain object from an InlineSource message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {google.cloud.datacatalog.v1beta1.InlineSource} message InlineSource + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + InlineSource.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.toObject(message.taxonomies[j], options); + } + return object; + }; + + /** + * Converts this InlineSource to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @instance + * @returns {Object.} JSON object + */ + InlineSource.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for InlineSource + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.InlineSource + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + InlineSource.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.InlineSource"; + }; + + return InlineSource; + })(); + + v1beta1.ImportTaxonomiesResponse = (function() { + + /** + * Properties of an ImportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IImportTaxonomiesResponse + * @property {Array.|null} [taxonomies] ImportTaxonomiesResponse taxonomies + */ + + /** + * Constructs a new ImportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an ImportTaxonomiesResponse. + * @implements IImportTaxonomiesResponse + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse=} [properties] Properties to set + */ + function ImportTaxonomiesResponse(properties) { + this.taxonomies = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ImportTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @instance + */ + ImportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + + /** + * Creates a new ImportTaxonomiesResponse instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse instance + */ + ImportTaxonomiesResponse.create = function create(properties) { + return new ImportTaxonomiesResponse(properties); + }; + + /** + * Encodes the specified ImportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ImportTaxonomiesResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1beta1.Taxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ImportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IImportTaxonomiesResponse} message ImportTaxonomiesResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ImportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ImportTaxonomiesResponse.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.Taxonomy.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an ImportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ImportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ImportTaxonomiesResponse message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ImportTaxonomiesResponse.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.Taxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } + } + return null; + }; + + /** + * Creates an ImportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} ImportTaxonomiesResponse + */ + ImportTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.fromObject(object.taxonomies[i]); + } + } + return message; + }; + + /** + * Creates a plain object from an ImportTaxonomiesResponse message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse} message ImportTaxonomiesResponse + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ImportTaxonomiesResponse.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.Taxonomy.toObject(message.taxonomies[j], options); + } + return object; + }; + + /** + * Converts this ImportTaxonomiesResponse to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @instance + * @returns {Object.} JSON object + */ + ImportTaxonomiesResponse.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ImportTaxonomiesResponse + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ImportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ImportTaxonomiesResponse"; + }; + + return ImportTaxonomiesResponse; + })(); + + v1beta1.ExportTaxonomiesRequest = (function() { + + /** + * Properties of an ExportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IExportTaxonomiesRequest + * @property {string|null} [parent] ExportTaxonomiesRequest parent + * @property {Array.|null} [taxonomies] ExportTaxonomiesRequest taxonomies + * @property {boolean|null} [serializedTaxonomies] ExportTaxonomiesRequest serializedTaxonomies + */ + + /** + * Constructs a new ExportTaxonomiesRequest. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an ExportTaxonomiesRequest. + * @implements IExportTaxonomiesRequest + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest=} [properties] Properties to set + */ + function ExportTaxonomiesRequest(properties) { + this.taxonomies = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ExportTaxonomiesRequest parent. + * @member {string} parent + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @instance + */ + ExportTaxonomiesRequest.prototype.parent = ""; + + /** + * ExportTaxonomiesRequest taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @instance + */ + ExportTaxonomiesRequest.prototype.taxonomies = $util.emptyArray; + + /** + * ExportTaxonomiesRequest serializedTaxonomies. + * @member {boolean|null|undefined} serializedTaxonomies + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @instance + */ + ExportTaxonomiesRequest.prototype.serializedTaxonomies = null; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * ExportTaxonomiesRequest destination. + * @member {"serializedTaxonomies"|undefined} destination + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @instance + */ + Object.defineProperty(ExportTaxonomiesRequest.prototype, "destination", { + get: $util.oneOfGetter($oneOfFields = ["serializedTaxonomies"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new ExportTaxonomiesRequest instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest instance + */ + ExportTaxonomiesRequest.create = function create(properties) { + return new ExportTaxonomiesRequest(properties); + }; + + /** + * Encodes the specified ExportTaxonomiesRequest message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExportTaxonomiesRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.parent != null && Object.hasOwnProperty.call(message, "parent")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.parent); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.taxonomies[i]); + if (message.serializedTaxonomies != null && Object.hasOwnProperty.call(message, "serializedTaxonomies")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.serializedTaxonomies); + return writer; + }; + + /** + * Encodes the specified ExportTaxonomiesRequest message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesRequest} message ExportTaxonomiesRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExportTaxonomiesRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExportTaxonomiesRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.parent = reader.string(); + break; + } + case 2: { + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push(reader.string()); + break; + } + case 3: { + message.serializedTaxonomies = reader.bool(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an ExportTaxonomiesRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExportTaxonomiesRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ExportTaxonomiesRequest message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ExportTaxonomiesRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.parent != null && message.hasOwnProperty("parent")) + if (!$util.isString(message.parent)) + return "parent: string expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) + if (!$util.isString(message.taxonomies[i])) + return "taxonomies: string[] expected"; + } + if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { + properties.destination = 1; + if (typeof message.serializedTaxonomies !== "boolean") + return "serializedTaxonomies: boolean expected"; + } + return null; + }; + + /** + * Creates an ExportTaxonomiesRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} ExportTaxonomiesRequest + */ + ExportTaxonomiesRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest(); + if (object.parent != null) + message.parent = String(object.parent); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) + message.taxonomies[i] = String(object.taxonomies[i]); + } + if (object.serializedTaxonomies != null) + message.serializedTaxonomies = Boolean(object.serializedTaxonomies); + return message; + }; + + /** + * Creates a plain object from an ExportTaxonomiesRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest} message ExportTaxonomiesRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ExportTaxonomiesRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (options.defaults) + object.parent = ""; + if (message.parent != null && message.hasOwnProperty("parent")) + object.parent = message.parent; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = message.taxonomies[j]; + } + if (message.serializedTaxonomies != null && message.hasOwnProperty("serializedTaxonomies")) { + object.serializedTaxonomies = message.serializedTaxonomies; + if (options.oneofs) + object.destination = "serializedTaxonomies"; + } + return object; + }; + + /** + * Converts this ExportTaxonomiesRequest to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @instance + * @returns {Object.} JSON object + */ + ExportTaxonomiesRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ExportTaxonomiesRequest + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ExportTaxonomiesRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ExportTaxonomiesRequest"; + }; + + return ExportTaxonomiesRequest; + })(); + + v1beta1.ExportTaxonomiesResponse = (function() { + + /** + * Properties of an ExportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @interface IExportTaxonomiesResponse + * @property {Array.|null} [taxonomies] ExportTaxonomiesResponse taxonomies + */ + + /** + * Constructs a new ExportTaxonomiesResponse. + * @memberof google.cloud.datacatalog.v1beta1 + * @classdesc Represents an ExportTaxonomiesResponse. + * @implements IExportTaxonomiesResponse + * @constructor + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse=} [properties] Properties to set + */ + function ExportTaxonomiesResponse(properties) { + this.taxonomies = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ExportTaxonomiesResponse taxonomies. + * @member {Array.} taxonomies + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @instance + */ + ExportTaxonomiesResponse.prototype.taxonomies = $util.emptyArray; + + /** + * Creates a new ExportTaxonomiesResponse instance using the specified properties. + * @function create + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse=} [properties] Properties to set + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse instance + */ + ExportTaxonomiesResponse.create = function create(properties) { + return new ExportTaxonomiesResponse(properties); + }; + + /** + * Encodes the specified ExportTaxonomiesResponse message. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.verify|verify} messages. + * @function encode + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExportTaxonomiesResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.taxonomies != null && message.taxonomies.length) + for (var i = 0; i < message.taxonomies.length; ++i) + $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.encode(message.taxonomies[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ExportTaxonomiesResponse message, length delimited. Does not implicitly {@link google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.IExportTaxonomiesResponse} message ExportTaxonomiesResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExportTaxonomiesResponse.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer. + * @function decode + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExportTaxonomiesResponse.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.taxonomies && message.taxonomies.length)) + message.taxonomies = []; + message.taxonomies.push($root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an ExportTaxonomiesResponse message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExportTaxonomiesResponse.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ExportTaxonomiesResponse message. + * @function verify + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ExportTaxonomiesResponse.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.taxonomies != null && message.hasOwnProperty("taxonomies")) { + if (!Array.isArray(message.taxonomies)) + return "taxonomies: array expected"; + for (var i = 0; i < message.taxonomies.length; ++i) { + var error = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.verify(message.taxonomies[i]); + if (error) + return "taxonomies." + error; + } + } + return null; + }; + + /** + * Creates an ExportTaxonomiesResponse message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {Object.} object Plain object + * @returns {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} ExportTaxonomiesResponse + */ + ExportTaxonomiesResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse) + return object; + var message = new $root.google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse(); + if (object.taxonomies) { + if (!Array.isArray(object.taxonomies)) + throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.taxonomies: array expected"); + message.taxonomies = []; + for (var i = 0; i < object.taxonomies.length; ++i) { + if (typeof object.taxonomies[i] !== "object") + throw TypeError(".google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse.taxonomies: object expected"); + message.taxonomies[i] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.fromObject(object.taxonomies[i]); + } + } + return message; + }; + + /** + * Creates a plain object from an ExportTaxonomiesResponse message. Also converts values to other types if specified. + * @function toObject + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse} message ExportTaxonomiesResponse + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ExportTaxonomiesResponse.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.taxonomies = []; + if (message.taxonomies && message.taxonomies.length) { + object.taxonomies = []; + for (var j = 0; j < message.taxonomies.length; ++j) + object.taxonomies[j] = $root.google.cloud.datacatalog.v1beta1.SerializedTaxonomy.toObject(message.taxonomies[j], options); + } + return object; + }; + + /** + * Converts this ExportTaxonomiesResponse to JSON. + * @function toJSON + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @instance + * @returns {Object.} JSON object + */ + ExportTaxonomiesResponse.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ExportTaxonomiesResponse + * @function getTypeUrl + * @memberof google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ExportTaxonomiesResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.cloud.datacatalog.v1beta1.ExportTaxonomiesResponse"; + }; + + return ExportTaxonomiesResponse; + })(); + + return v1beta1; + })(); + + return datacatalog; + })(); + + return cloud; + })(); + + google.api = (function() { + + /** + * Namespace api. + * @memberof google + * @namespace + */ + var api = {}; + + /** + * FieldBehavior enum. + * @name google.api.FieldBehavior + * @enum {number} + * @property {number} FIELD_BEHAVIOR_UNSPECIFIED=0 FIELD_BEHAVIOR_UNSPECIFIED value + * @property {number} OPTIONAL=1 OPTIONAL value + * @property {number} REQUIRED=2 REQUIRED value + * @property {number} OUTPUT_ONLY=3 OUTPUT_ONLY value + * @property {number} INPUT_ONLY=4 INPUT_ONLY value + * @property {number} IMMUTABLE=5 IMMUTABLE value + * @property {number} UNORDERED_LIST=6 UNORDERED_LIST value + * @property {number} NON_EMPTY_DEFAULT=7 NON_EMPTY_DEFAULT value + */ + api.FieldBehavior = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "FIELD_BEHAVIOR_UNSPECIFIED"] = 0; + values[valuesById[1] = "OPTIONAL"] = 1; + values[valuesById[2] = "REQUIRED"] = 2; + values[valuesById[3] = "OUTPUT_ONLY"] = 3; + values[valuesById[4] = "INPUT_ONLY"] = 4; + values[valuesById[5] = "IMMUTABLE"] = 5; + values[valuesById[6] = "UNORDERED_LIST"] = 6; + values[valuesById[7] = "NON_EMPTY_DEFAULT"] = 7; + return values; + })(); + + api.Http = (function() { + + /** + * Properties of a Http. + * @memberof google.api + * @interface IHttp + * @property {Array.|null} [rules] Http rules + * @property {boolean|null} [fullyDecodeReservedExpansion] Http fullyDecodeReservedExpansion + */ + + /** + * Constructs a new Http. + * @memberof google.api + * @classdesc Represents a Http. + * @implements IHttp + * @constructor + * @param {google.api.IHttp=} [properties] Properties to set + */ + function Http(properties) { + this.rules = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Http rules. + * @member {Array.} rules + * @memberof google.api.Http + * @instance + */ + Http.prototype.rules = $util.emptyArray; + + /** + * Http fullyDecodeReservedExpansion. + * @member {boolean} fullyDecodeReservedExpansion + * @memberof google.api.Http + * @instance + */ + Http.prototype.fullyDecodeReservedExpansion = false; + + /** + * Creates a new Http instance using the specified properties. + * @function create + * @memberof google.api.Http + * @static + * @param {google.api.IHttp=} [properties] Properties to set + * @returns {google.api.Http} Http instance + */ + Http.create = function create(properties) { + return new Http(properties); + }; + + /** + * Encodes the specified Http message. Does not implicitly {@link google.api.Http.verify|verify} messages. + * @function encode + * @memberof google.api.Http + * @static + * @param {google.api.IHttp} message Http message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Http.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.rules != null && message.rules.length) + for (var i = 0; i < message.rules.length; ++i) + $root.google.api.HttpRule.encode(message.rules[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.fullyDecodeReservedExpansion != null && Object.hasOwnProperty.call(message, "fullyDecodeReservedExpansion")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.fullyDecodeReservedExpansion); + return writer; + }; + + /** + * Encodes the specified Http message, length delimited. Does not implicitly {@link google.api.Http.verify|verify} messages. + * @function encodeDelimited + * @memberof google.api.Http + * @static + * @param {google.api.IHttp} message Http message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Http.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Http message from the specified reader or buffer. + * @function decode + * @memberof google.api.Http + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.api.Http} Http + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Http.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.Http(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.rules && message.rules.length)) + message.rules = []; + message.rules.push($root.google.api.HttpRule.decode(reader, reader.uint32())); + break; + } + case 2: { + message.fullyDecodeReservedExpansion = reader.bool(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a Http message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.api.Http + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.api.Http} Http + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Http.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Http message. + * @function verify + * @memberof google.api.Http + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Http.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.rules != null && message.hasOwnProperty("rules")) { + if (!Array.isArray(message.rules)) + return "rules: array expected"; + for (var i = 0; i < message.rules.length; ++i) { + var error = $root.google.api.HttpRule.verify(message.rules[i]); + if (error) + return "rules." + error; + } + } + if (message.fullyDecodeReservedExpansion != null && message.hasOwnProperty("fullyDecodeReservedExpansion")) + if (typeof message.fullyDecodeReservedExpansion !== "boolean") + return "fullyDecodeReservedExpansion: boolean expected"; + return null; + }; + + /** + * Creates a Http message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.api.Http + * @static + * @param {Object.} object Plain object + * @returns {google.api.Http} Http + */ + Http.fromObject = function fromObject(object) { + if (object instanceof $root.google.api.Http) + return object; + var message = new $root.google.api.Http(); + if (object.rules) { + if (!Array.isArray(object.rules)) + throw TypeError(".google.api.Http.rules: array expected"); + message.rules = []; + for (var i = 0; i < object.rules.length; ++i) { + if (typeof object.rules[i] !== "object") + throw TypeError(".google.api.Http.rules: object expected"); + message.rules[i] = $root.google.api.HttpRule.fromObject(object.rules[i]); + } + } + if (object.fullyDecodeReservedExpansion != null) + message.fullyDecodeReservedExpansion = Boolean(object.fullyDecodeReservedExpansion); + return message; + }; + + /** + * Creates a plain object from a Http message. Also converts values to other types if specified. + * @function toObject + * @memberof google.api.Http + * @static + * @param {google.api.Http} message Http + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Http.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.rules = []; + if (options.defaults) + object.fullyDecodeReservedExpansion = false; + if (message.rules && message.rules.length) { + object.rules = []; + for (var j = 0; j < message.rules.length; ++j) + object.rules[j] = $root.google.api.HttpRule.toObject(message.rules[j], options); + } + if (message.fullyDecodeReservedExpansion != null && message.hasOwnProperty("fullyDecodeReservedExpansion")) + object.fullyDecodeReservedExpansion = message.fullyDecodeReservedExpansion; + return object; + }; + + /** + * Converts this Http to JSON. + * @function toJSON + * @memberof google.api.Http + * @instance + * @returns {Object.} JSON object + */ + Http.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Http + * @function getTypeUrl + * @memberof google.api.Http + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Http.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.api.Http"; + }; + + return Http; + })(); + + api.HttpRule = (function() { + + /** + * Properties of a HttpRule. + * @memberof google.api + * @interface IHttpRule + * @property {string|null} [selector] HttpRule selector + * @property {string|null} [get] HttpRule get + * @property {string|null} [put] HttpRule put + * @property {string|null} [post] HttpRule post + * @property {string|null} ["delete"] HttpRule delete + * @property {string|null} [patch] HttpRule patch + * @property {google.api.ICustomHttpPattern|null} [custom] HttpRule custom + * @property {string|null} [body] HttpRule body + * @property {string|null} [responseBody] HttpRule responseBody + * @property {Array.|null} [additionalBindings] HttpRule additionalBindings + */ + + /** + * Constructs a new HttpRule. + * @memberof google.api + * @classdesc Represents a HttpRule. + * @implements IHttpRule + * @constructor + * @param {google.api.IHttpRule=} [properties] Properties to set + */ + function HttpRule(properties) { + this.additionalBindings = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * HttpRule selector. + * @member {string} selector + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.selector = ""; + + /** + * HttpRule get. + * @member {string|null|undefined} get + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.get = null; + + /** + * HttpRule put. + * @member {string|null|undefined} put + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.put = null; + + /** + * HttpRule post. + * @member {string|null|undefined} post + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.post = null; + + /** + * HttpRule delete. + * @member {string|null|undefined} delete + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype["delete"] = null; + + /** + * HttpRule patch. + * @member {string|null|undefined} patch + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.patch = null; + + /** + * HttpRule custom. + * @member {google.api.ICustomHttpPattern|null|undefined} custom + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.custom = null; + + /** + * HttpRule body. + * @member {string} body + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.body = ""; + + /** + * HttpRule responseBody. + * @member {string} responseBody + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.responseBody = ""; + + /** + * HttpRule additionalBindings. + * @member {Array.} additionalBindings + * @memberof google.api.HttpRule + * @instance + */ + HttpRule.prototype.additionalBindings = $util.emptyArray; + + // OneOf field names bound to virtual getters and setters + var $oneOfFields; + + /** + * HttpRule pattern. + * @member {"get"|"put"|"post"|"delete"|"patch"|"custom"|undefined} pattern + * @memberof google.api.HttpRule + * @instance + */ + Object.defineProperty(HttpRule.prototype, "pattern", { + get: $util.oneOfGetter($oneOfFields = ["get", "put", "post", "delete", "patch", "custom"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * Creates a new HttpRule instance using the specified properties. + * @function create + * @memberof google.api.HttpRule + * @static + * @param {google.api.IHttpRule=} [properties] Properties to set + * @returns {google.api.HttpRule} HttpRule instance + */ + HttpRule.create = function create(properties) { + return new HttpRule(properties); + }; + + /** + * Encodes the specified HttpRule message. Does not implicitly {@link google.api.HttpRule.verify|verify} messages. + * @function encode + * @memberof google.api.HttpRule + * @static + * @param {google.api.IHttpRule} message HttpRule message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + HttpRule.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.selector != null && Object.hasOwnProperty.call(message, "selector")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.selector); + if (message.get != null && Object.hasOwnProperty.call(message, "get")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.get); + if (message.put != null && Object.hasOwnProperty.call(message, "put")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.put); + if (message.post != null && Object.hasOwnProperty.call(message, "post")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.post); + if (message["delete"] != null && Object.hasOwnProperty.call(message, "delete")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message["delete"]); + if (message.patch != null && Object.hasOwnProperty.call(message, "patch")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.patch); + if (message.body != null && Object.hasOwnProperty.call(message, "body")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.body); + if (message.custom != null && Object.hasOwnProperty.call(message, "custom")) + $root.google.api.CustomHttpPattern.encode(message.custom, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.additionalBindings != null && message.additionalBindings.length) + for (var i = 0; i < message.additionalBindings.length; ++i) + $root.google.api.HttpRule.encode(message.additionalBindings[i], writer.uint32(/* id 11, wireType 2 =*/90).fork()).ldelim(); + if (message.responseBody != null && Object.hasOwnProperty.call(message, "responseBody")) + writer.uint32(/* id 12, wireType 2 =*/98).string(message.responseBody); + return writer; + }; + + /** + * Encodes the specified HttpRule message, length delimited. Does not implicitly {@link google.api.HttpRule.verify|verify} messages. + * @function encodeDelimited + * @memberof google.api.HttpRule + * @static + * @param {google.api.IHttpRule} message HttpRule message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + HttpRule.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a HttpRule message from the specified reader or buffer. + * @function decode + * @memberof google.api.HttpRule + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.api.HttpRule} HttpRule + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + HttpRule.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.HttpRule(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.selector = reader.string(); + break; + } + case 2: { + message.get = reader.string(); + break; + } + case 3: { + message.put = reader.string(); + break; + } + case 4: { + message.post = reader.string(); + break; + } + case 5: { + message["delete"] = reader.string(); + break; + } + case 6: { + message.patch = reader.string(); + break; + } + case 8: { + message.custom = $root.google.api.CustomHttpPattern.decode(reader, reader.uint32()); + break; + } + case 7: { + message.body = reader.string(); + break; + } + case 12: { + message.responseBody = reader.string(); + break; + } + case 11: { + if (!(message.additionalBindings && message.additionalBindings.length)) + message.additionalBindings = []; + message.additionalBindings.push($root.google.api.HttpRule.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a HttpRule message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.api.HttpRule + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.api.HttpRule} HttpRule + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + HttpRule.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a HttpRule message. + * @function verify + * @memberof google.api.HttpRule + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + HttpRule.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.selector != null && message.hasOwnProperty("selector")) if (!$util.isString(message.selector)) return "selector: string expected"; if (message.get != null && message.hasOwnProperty("get")) { @@ -49953,220 +54468,3297 @@ if (!$util.isString(message.get)) return "get: string expected"; } - if (message.put != null && message.hasOwnProperty("put")) { - if (properties.pattern === 1) - return "pattern: multiple values"; - properties.pattern = 1; - if (!$util.isString(message.put)) - return "put: string expected"; + if (message.put != null && message.hasOwnProperty("put")) { + if (properties.pattern === 1) + return "pattern: multiple values"; + properties.pattern = 1; + if (!$util.isString(message.put)) + return "put: string expected"; + } + if (message.post != null && message.hasOwnProperty("post")) { + if (properties.pattern === 1) + return "pattern: multiple values"; + properties.pattern = 1; + if (!$util.isString(message.post)) + return "post: string expected"; + } + if (message["delete"] != null && message.hasOwnProperty("delete")) { + if (properties.pattern === 1) + return "pattern: multiple values"; + properties.pattern = 1; + if (!$util.isString(message["delete"])) + return "delete: string expected"; + } + if (message.patch != null && message.hasOwnProperty("patch")) { + if (properties.pattern === 1) + return "pattern: multiple values"; + properties.pattern = 1; + if (!$util.isString(message.patch)) + return "patch: string expected"; + } + if (message.custom != null && message.hasOwnProperty("custom")) { + if (properties.pattern === 1) + return "pattern: multiple values"; + properties.pattern = 1; + { + var error = $root.google.api.CustomHttpPattern.verify(message.custom); + if (error) + return "custom." + error; + } + } + if (message.body != null && message.hasOwnProperty("body")) + if (!$util.isString(message.body)) + return "body: string expected"; + if (message.responseBody != null && message.hasOwnProperty("responseBody")) + if (!$util.isString(message.responseBody)) + return "responseBody: string expected"; + if (message.additionalBindings != null && message.hasOwnProperty("additionalBindings")) { + if (!Array.isArray(message.additionalBindings)) + return "additionalBindings: array expected"; + for (var i = 0; i < message.additionalBindings.length; ++i) { + var error = $root.google.api.HttpRule.verify(message.additionalBindings[i]); + if (error) + return "additionalBindings." + error; + } + } + return null; + }; + + /** + * Creates a HttpRule message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.api.HttpRule + * @static + * @param {Object.} object Plain object + * @returns {google.api.HttpRule} HttpRule + */ + HttpRule.fromObject = function fromObject(object) { + if (object instanceof $root.google.api.HttpRule) + return object; + var message = new $root.google.api.HttpRule(); + if (object.selector != null) + message.selector = String(object.selector); + if (object.get != null) + message.get = String(object.get); + if (object.put != null) + message.put = String(object.put); + if (object.post != null) + message.post = String(object.post); + if (object["delete"] != null) + message["delete"] = String(object["delete"]); + if (object.patch != null) + message.patch = String(object.patch); + if (object.custom != null) { + if (typeof object.custom !== "object") + throw TypeError(".google.api.HttpRule.custom: object expected"); + message.custom = $root.google.api.CustomHttpPattern.fromObject(object.custom); + } + if (object.body != null) + message.body = String(object.body); + if (object.responseBody != null) + message.responseBody = String(object.responseBody); + if (object.additionalBindings) { + if (!Array.isArray(object.additionalBindings)) + throw TypeError(".google.api.HttpRule.additionalBindings: array expected"); + message.additionalBindings = []; + for (var i = 0; i < object.additionalBindings.length; ++i) { + if (typeof object.additionalBindings[i] !== "object") + throw TypeError(".google.api.HttpRule.additionalBindings: object expected"); + message.additionalBindings[i] = $root.google.api.HttpRule.fromObject(object.additionalBindings[i]); + } + } + return message; + }; + + /** + * Creates a plain object from a HttpRule message. Also converts values to other types if specified. + * @function toObject + * @memberof google.api.HttpRule + * @static + * @param {google.api.HttpRule} message HttpRule + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + HttpRule.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.additionalBindings = []; + if (options.defaults) { + object.selector = ""; + object.body = ""; + object.responseBody = ""; + } + if (message.selector != null && message.hasOwnProperty("selector")) + object.selector = message.selector; + if (message.get != null && message.hasOwnProperty("get")) { + object.get = message.get; + if (options.oneofs) + object.pattern = "get"; + } + if (message.put != null && message.hasOwnProperty("put")) { + object.put = message.put; + if (options.oneofs) + object.pattern = "put"; + } + if (message.post != null && message.hasOwnProperty("post")) { + object.post = message.post; + if (options.oneofs) + object.pattern = "post"; + } + if (message["delete"] != null && message.hasOwnProperty("delete")) { + object["delete"] = message["delete"]; + if (options.oneofs) + object.pattern = "delete"; + } + if (message.patch != null && message.hasOwnProperty("patch")) { + object.patch = message.patch; + if (options.oneofs) + object.pattern = "patch"; + } + if (message.body != null && message.hasOwnProperty("body")) + object.body = message.body; + if (message.custom != null && message.hasOwnProperty("custom")) { + object.custom = $root.google.api.CustomHttpPattern.toObject(message.custom, options); + if (options.oneofs) + object.pattern = "custom"; + } + if (message.additionalBindings && message.additionalBindings.length) { + object.additionalBindings = []; + for (var j = 0; j < message.additionalBindings.length; ++j) + object.additionalBindings[j] = $root.google.api.HttpRule.toObject(message.additionalBindings[j], options); + } + if (message.responseBody != null && message.hasOwnProperty("responseBody")) + object.responseBody = message.responseBody; + return object; + }; + + /** + * Converts this HttpRule to JSON. + * @function toJSON + * @memberof google.api.HttpRule + * @instance + * @returns {Object.} JSON object + */ + HttpRule.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for HttpRule + * @function getTypeUrl + * @memberof google.api.HttpRule + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + HttpRule.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.api.HttpRule"; + }; + + return HttpRule; + })(); + + api.CustomHttpPattern = (function() { + + /** + * Properties of a CustomHttpPattern. + * @memberof google.api + * @interface ICustomHttpPattern + * @property {string|null} [kind] CustomHttpPattern kind + * @property {string|null} [path] CustomHttpPattern path + */ + + /** + * Constructs a new CustomHttpPattern. + * @memberof google.api + * @classdesc Represents a CustomHttpPattern. + * @implements ICustomHttpPattern + * @constructor + * @param {google.api.ICustomHttpPattern=} [properties] Properties to set + */ + function CustomHttpPattern(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * CustomHttpPattern kind. + * @member {string} kind + * @memberof google.api.CustomHttpPattern + * @instance + */ + CustomHttpPattern.prototype.kind = ""; + + /** + * CustomHttpPattern path. + * @member {string} path + * @memberof google.api.CustomHttpPattern + * @instance + */ + CustomHttpPattern.prototype.path = ""; + + /** + * Creates a new CustomHttpPattern instance using the specified properties. + * @function create + * @memberof google.api.CustomHttpPattern + * @static + * @param {google.api.ICustomHttpPattern=} [properties] Properties to set + * @returns {google.api.CustomHttpPattern} CustomHttpPattern instance + */ + CustomHttpPattern.create = function create(properties) { + return new CustomHttpPattern(properties); + }; + + /** + * Encodes the specified CustomHttpPattern message. Does not implicitly {@link google.api.CustomHttpPattern.verify|verify} messages. + * @function encode + * @memberof google.api.CustomHttpPattern + * @static + * @param {google.api.ICustomHttpPattern} message CustomHttpPattern message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CustomHttpPattern.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.kind != null && Object.hasOwnProperty.call(message, "kind")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.kind); + if (message.path != null && Object.hasOwnProperty.call(message, "path")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.path); + return writer; + }; + + /** + * Encodes the specified CustomHttpPattern message, length delimited. Does not implicitly {@link google.api.CustomHttpPattern.verify|verify} messages. + * @function encodeDelimited + * @memberof google.api.CustomHttpPattern + * @static + * @param {google.api.ICustomHttpPattern} message CustomHttpPattern message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CustomHttpPattern.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a CustomHttpPattern message from the specified reader or buffer. + * @function decode + * @memberof google.api.CustomHttpPattern + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.api.CustomHttpPattern} CustomHttpPattern + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CustomHttpPattern.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.CustomHttpPattern(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.kind = reader.string(); + break; + } + case 2: { + message.path = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a CustomHttpPattern message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.api.CustomHttpPattern + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.api.CustomHttpPattern} CustomHttpPattern + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CustomHttpPattern.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a CustomHttpPattern message. + * @function verify + * @memberof google.api.CustomHttpPattern + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CustomHttpPattern.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.kind != null && message.hasOwnProperty("kind")) + if (!$util.isString(message.kind)) + return "kind: string expected"; + if (message.path != null && message.hasOwnProperty("path")) + if (!$util.isString(message.path)) + return "path: string expected"; + return null; + }; + + /** + * Creates a CustomHttpPattern message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.api.CustomHttpPattern + * @static + * @param {Object.} object Plain object + * @returns {google.api.CustomHttpPattern} CustomHttpPattern + */ + CustomHttpPattern.fromObject = function fromObject(object) { + if (object instanceof $root.google.api.CustomHttpPattern) + return object; + var message = new $root.google.api.CustomHttpPattern(); + if (object.kind != null) + message.kind = String(object.kind); + if (object.path != null) + message.path = String(object.path); + return message; + }; + + /** + * Creates a plain object from a CustomHttpPattern message. Also converts values to other types if specified. + * @function toObject + * @memberof google.api.CustomHttpPattern + * @static + * @param {google.api.CustomHttpPattern} message CustomHttpPattern + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CustomHttpPattern.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.kind = ""; + object.path = ""; + } + if (message.kind != null && message.hasOwnProperty("kind")) + object.kind = message.kind; + if (message.path != null && message.hasOwnProperty("path")) + object.path = message.path; + return object; + }; + + /** + * Converts this CustomHttpPattern to JSON. + * @function toJSON + * @memberof google.api.CustomHttpPattern + * @instance + * @returns {Object.} JSON object + */ + CustomHttpPattern.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for CustomHttpPattern + * @function getTypeUrl + * @memberof google.api.CustomHttpPattern + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CustomHttpPattern.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.api.CustomHttpPattern"; + }; + + return CustomHttpPattern; + })(); + + api.ResourceDescriptor = (function() { + + /** + * Properties of a ResourceDescriptor. + * @memberof google.api + * @interface IResourceDescriptor + * @property {string|null} [type] ResourceDescriptor type + * @property {Array.|null} [pattern] ResourceDescriptor pattern + * @property {string|null} [nameField] ResourceDescriptor nameField + * @property {google.api.ResourceDescriptor.History|null} [history] ResourceDescriptor history + * @property {string|null} [plural] ResourceDescriptor plural + * @property {string|null} [singular] ResourceDescriptor singular + * @property {Array.|null} [style] ResourceDescriptor style + */ + + /** + * Constructs a new ResourceDescriptor. + * @memberof google.api + * @classdesc Represents a ResourceDescriptor. + * @implements IResourceDescriptor + * @constructor + * @param {google.api.IResourceDescriptor=} [properties] Properties to set + */ + function ResourceDescriptor(properties) { + this.pattern = []; + this.style = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ResourceDescriptor type. + * @member {string} type + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.type = ""; + + /** + * ResourceDescriptor pattern. + * @member {Array.} pattern + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.pattern = $util.emptyArray; + + /** + * ResourceDescriptor nameField. + * @member {string} nameField + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.nameField = ""; + + /** + * ResourceDescriptor history. + * @member {google.api.ResourceDescriptor.History} history + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.history = 0; + + /** + * ResourceDescriptor plural. + * @member {string} plural + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.plural = ""; + + /** + * ResourceDescriptor singular. + * @member {string} singular + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.singular = ""; + + /** + * ResourceDescriptor style. + * @member {Array.} style + * @memberof google.api.ResourceDescriptor + * @instance + */ + ResourceDescriptor.prototype.style = $util.emptyArray; + + /** + * Creates a new ResourceDescriptor instance using the specified properties. + * @function create + * @memberof google.api.ResourceDescriptor + * @static + * @param {google.api.IResourceDescriptor=} [properties] Properties to set + * @returns {google.api.ResourceDescriptor} ResourceDescriptor instance + */ + ResourceDescriptor.create = function create(properties) { + return new ResourceDescriptor(properties); + }; + + /** + * Encodes the specified ResourceDescriptor message. Does not implicitly {@link google.api.ResourceDescriptor.verify|verify} messages. + * @function encode + * @memberof google.api.ResourceDescriptor + * @static + * @param {google.api.IResourceDescriptor} message ResourceDescriptor message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ResourceDescriptor.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); + if (message.pattern != null && message.pattern.length) + for (var i = 0; i < message.pattern.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.pattern[i]); + if (message.nameField != null && Object.hasOwnProperty.call(message, "nameField")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.nameField); + if (message.history != null && Object.hasOwnProperty.call(message, "history")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.history); + if (message.plural != null && Object.hasOwnProperty.call(message, "plural")) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.plural); + if (message.singular != null && Object.hasOwnProperty.call(message, "singular")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.singular); + if (message.style != null && message.style.length) { + writer.uint32(/* id 10, wireType 2 =*/82).fork(); + for (var i = 0; i < message.style.length; ++i) + writer.int32(message.style[i]); + writer.ldelim(); + } + return writer; + }; + + /** + * Encodes the specified ResourceDescriptor message, length delimited. Does not implicitly {@link google.api.ResourceDescriptor.verify|verify} messages. + * @function encodeDelimited + * @memberof google.api.ResourceDescriptor + * @static + * @param {google.api.IResourceDescriptor} message ResourceDescriptor message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ResourceDescriptor.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ResourceDescriptor message from the specified reader or buffer. + * @function decode + * @memberof google.api.ResourceDescriptor + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.api.ResourceDescriptor} ResourceDescriptor + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ResourceDescriptor.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.ResourceDescriptor(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.type = reader.string(); + break; + } + case 2: { + if (!(message.pattern && message.pattern.length)) + message.pattern = []; + message.pattern.push(reader.string()); + break; + } + case 3: { + message.nameField = reader.string(); + break; + } + case 4: { + message.history = reader.int32(); + break; + } + case 5: { + message.plural = reader.string(); + break; + } + case 6: { + message.singular = reader.string(); + break; + } + case 10: { + if (!(message.style && message.style.length)) + message.style = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.style.push(reader.int32()); + } else + message.style.push(reader.int32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ResourceDescriptor message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.api.ResourceDescriptor + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.api.ResourceDescriptor} ResourceDescriptor + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ResourceDescriptor.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ResourceDescriptor message. + * @function verify + * @memberof google.api.ResourceDescriptor + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ResourceDescriptor.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.type != null && message.hasOwnProperty("type")) + if (!$util.isString(message.type)) + return "type: string expected"; + if (message.pattern != null && message.hasOwnProperty("pattern")) { + if (!Array.isArray(message.pattern)) + return "pattern: array expected"; + for (var i = 0; i < message.pattern.length; ++i) + if (!$util.isString(message.pattern[i])) + return "pattern: string[] expected"; + } + if (message.nameField != null && message.hasOwnProperty("nameField")) + if (!$util.isString(message.nameField)) + return "nameField: string expected"; + if (message.history != null && message.hasOwnProperty("history")) + switch (message.history) { + default: + return "history: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.plural != null && message.hasOwnProperty("plural")) + if (!$util.isString(message.plural)) + return "plural: string expected"; + if (message.singular != null && message.hasOwnProperty("singular")) + if (!$util.isString(message.singular)) + return "singular: string expected"; + if (message.style != null && message.hasOwnProperty("style")) { + if (!Array.isArray(message.style)) + return "style: array expected"; + for (var i = 0; i < message.style.length; ++i) + switch (message.style[i]) { + default: + return "style: enum value[] expected"; + case 0: + case 1: + break; + } + } + return null; + }; + + /** + * Creates a ResourceDescriptor message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.api.ResourceDescriptor + * @static + * @param {Object.} object Plain object + * @returns {google.api.ResourceDescriptor} ResourceDescriptor + */ + ResourceDescriptor.fromObject = function fromObject(object) { + if (object instanceof $root.google.api.ResourceDescriptor) + return object; + var message = new $root.google.api.ResourceDescriptor(); + if (object.type != null) + message.type = String(object.type); + if (object.pattern) { + if (!Array.isArray(object.pattern)) + throw TypeError(".google.api.ResourceDescriptor.pattern: array expected"); + message.pattern = []; + for (var i = 0; i < object.pattern.length; ++i) + message.pattern[i] = String(object.pattern[i]); + } + if (object.nameField != null) + message.nameField = String(object.nameField); + switch (object.history) { + default: + if (typeof object.history === "number") { + message.history = object.history; + break; + } + break; + case "HISTORY_UNSPECIFIED": + case 0: + message.history = 0; + break; + case "ORIGINALLY_SINGLE_PATTERN": + case 1: + message.history = 1; + break; + case "FUTURE_MULTI_PATTERN": + case 2: + message.history = 2; + break; + } + if (object.plural != null) + message.plural = String(object.plural); + if (object.singular != null) + message.singular = String(object.singular); + if (object.style) { + if (!Array.isArray(object.style)) + throw TypeError(".google.api.ResourceDescriptor.style: array expected"); + message.style = []; + for (var i = 0; i < object.style.length; ++i) + switch (object.style[i]) { + default: + if (typeof object.style[i] === "number") { + message.style[i] = object.style[i]; + break; + } + case "STYLE_UNSPECIFIED": + case 0: + message.style[i] = 0; + break; + case "DECLARATIVE_FRIENDLY": + case 1: + message.style[i] = 1; + break; + } + } + return message; + }; + + /** + * Creates a plain object from a ResourceDescriptor message. Also converts values to other types if specified. + * @function toObject + * @memberof google.api.ResourceDescriptor + * @static + * @param {google.api.ResourceDescriptor} message ResourceDescriptor + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ResourceDescriptor.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.pattern = []; + object.style = []; + } + if (options.defaults) { + object.type = ""; + object.nameField = ""; + object.history = options.enums === String ? "HISTORY_UNSPECIFIED" : 0; + object.plural = ""; + object.singular = ""; + } + if (message.type != null && message.hasOwnProperty("type")) + object.type = message.type; + if (message.pattern && message.pattern.length) { + object.pattern = []; + for (var j = 0; j < message.pattern.length; ++j) + object.pattern[j] = message.pattern[j]; + } + if (message.nameField != null && message.hasOwnProperty("nameField")) + object.nameField = message.nameField; + if (message.history != null && message.hasOwnProperty("history")) + object.history = options.enums === String ? $root.google.api.ResourceDescriptor.History[message.history] === undefined ? message.history : $root.google.api.ResourceDescriptor.History[message.history] : message.history; + if (message.plural != null && message.hasOwnProperty("plural")) + object.plural = message.plural; + if (message.singular != null && message.hasOwnProperty("singular")) + object.singular = message.singular; + if (message.style && message.style.length) { + object.style = []; + for (var j = 0; j < message.style.length; ++j) + object.style[j] = options.enums === String ? $root.google.api.ResourceDescriptor.Style[message.style[j]] === undefined ? message.style[j] : $root.google.api.ResourceDescriptor.Style[message.style[j]] : message.style[j]; + } + return object; + }; + + /** + * Converts this ResourceDescriptor to JSON. + * @function toJSON + * @memberof google.api.ResourceDescriptor + * @instance + * @returns {Object.} JSON object + */ + ResourceDescriptor.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ResourceDescriptor + * @function getTypeUrl + * @memberof google.api.ResourceDescriptor + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ResourceDescriptor.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.api.ResourceDescriptor"; + }; + + /** + * History enum. + * @name google.api.ResourceDescriptor.History + * @enum {number} + * @property {number} HISTORY_UNSPECIFIED=0 HISTORY_UNSPECIFIED value + * @property {number} ORIGINALLY_SINGLE_PATTERN=1 ORIGINALLY_SINGLE_PATTERN value + * @property {number} FUTURE_MULTI_PATTERN=2 FUTURE_MULTI_PATTERN value + */ + ResourceDescriptor.History = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "HISTORY_UNSPECIFIED"] = 0; + values[valuesById[1] = "ORIGINALLY_SINGLE_PATTERN"] = 1; + values[valuesById[2] = "FUTURE_MULTI_PATTERN"] = 2; + return values; + })(); + + /** + * Style enum. + * @name google.api.ResourceDescriptor.Style + * @enum {number} + * @property {number} STYLE_UNSPECIFIED=0 STYLE_UNSPECIFIED value + * @property {number} DECLARATIVE_FRIENDLY=1 DECLARATIVE_FRIENDLY value + */ + ResourceDescriptor.Style = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "STYLE_UNSPECIFIED"] = 0; + values[valuesById[1] = "DECLARATIVE_FRIENDLY"] = 1; + return values; + })(); + + return ResourceDescriptor; + })(); + + api.ResourceReference = (function() { + + /** + * Properties of a ResourceReference. + * @memberof google.api + * @interface IResourceReference + * @property {string|null} [type] ResourceReference type + * @property {string|null} [childType] ResourceReference childType + */ + + /** + * Constructs a new ResourceReference. + * @memberof google.api + * @classdesc Represents a ResourceReference. + * @implements IResourceReference + * @constructor + * @param {google.api.IResourceReference=} [properties] Properties to set + */ + function ResourceReference(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ResourceReference type. + * @member {string} type + * @memberof google.api.ResourceReference + * @instance + */ + ResourceReference.prototype.type = ""; + + /** + * ResourceReference childType. + * @member {string} childType + * @memberof google.api.ResourceReference + * @instance + */ + ResourceReference.prototype.childType = ""; + + /** + * Creates a new ResourceReference instance using the specified properties. + * @function create + * @memberof google.api.ResourceReference + * @static + * @param {google.api.IResourceReference=} [properties] Properties to set + * @returns {google.api.ResourceReference} ResourceReference instance + */ + ResourceReference.create = function create(properties) { + return new ResourceReference(properties); + }; + + /** + * Encodes the specified ResourceReference message. Does not implicitly {@link google.api.ResourceReference.verify|verify} messages. + * @function encode + * @memberof google.api.ResourceReference + * @static + * @param {google.api.IResourceReference} message ResourceReference message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ResourceReference.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); + if (message.childType != null && Object.hasOwnProperty.call(message, "childType")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.childType); + return writer; + }; + + /** + * Encodes the specified ResourceReference message, length delimited. Does not implicitly {@link google.api.ResourceReference.verify|verify} messages. + * @function encodeDelimited + * @memberof google.api.ResourceReference + * @static + * @param {google.api.IResourceReference} message ResourceReference message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ResourceReference.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ResourceReference message from the specified reader or buffer. + * @function decode + * @memberof google.api.ResourceReference + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.api.ResourceReference} ResourceReference + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ResourceReference.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.ResourceReference(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.type = reader.string(); + break; + } + case 2: { + message.childType = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ResourceReference message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.api.ResourceReference + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.api.ResourceReference} ResourceReference + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ResourceReference.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ResourceReference message. + * @function verify + * @memberof google.api.ResourceReference + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ResourceReference.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.type != null && message.hasOwnProperty("type")) + if (!$util.isString(message.type)) + return "type: string expected"; + if (message.childType != null && message.hasOwnProperty("childType")) + if (!$util.isString(message.childType)) + return "childType: string expected"; + return null; + }; + + /** + * Creates a ResourceReference message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.api.ResourceReference + * @static + * @param {Object.} object Plain object + * @returns {google.api.ResourceReference} ResourceReference + */ + ResourceReference.fromObject = function fromObject(object) { + if (object instanceof $root.google.api.ResourceReference) + return object; + var message = new $root.google.api.ResourceReference(); + if (object.type != null) + message.type = String(object.type); + if (object.childType != null) + message.childType = String(object.childType); + return message; + }; + + /** + * Creates a plain object from a ResourceReference message. Also converts values to other types if specified. + * @function toObject + * @memberof google.api.ResourceReference + * @static + * @param {google.api.ResourceReference} message ResourceReference + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ResourceReference.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.type = ""; + object.childType = ""; + } + if (message.type != null && message.hasOwnProperty("type")) + object.type = message.type; + if (message.childType != null && message.hasOwnProperty("childType")) + object.childType = message.childType; + return object; + }; + + /** + * Converts this ResourceReference to JSON. + * @function toJSON + * @memberof google.api.ResourceReference + * @instance + * @returns {Object.} JSON object + */ + ResourceReference.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ResourceReference + * @function getTypeUrl + * @memberof google.api.ResourceReference + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ResourceReference.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.api.ResourceReference"; + }; + + return ResourceReference; + })(); + + return api; + })(); + + google.protobuf = (function() { + + /** + * Namespace protobuf. + * @memberof google + * @namespace + */ + var protobuf = {}; + + protobuf.FileDescriptorSet = (function() { + + /** + * Properties of a FileDescriptorSet. + * @memberof google.protobuf + * @interface IFileDescriptorSet + * @property {Array.|null} [file] FileDescriptorSet file + */ + + /** + * Constructs a new FileDescriptorSet. + * @memberof google.protobuf + * @classdesc Represents a FileDescriptorSet. + * @implements IFileDescriptorSet + * @constructor + * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set + */ + function FileDescriptorSet(properties) { + this.file = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * FileDescriptorSet file. + * @member {Array.} file + * @memberof google.protobuf.FileDescriptorSet + * @instance + */ + FileDescriptorSet.prototype.file = $util.emptyArray; + + /** + * Creates a new FileDescriptorSet instance using the specified properties. + * @function create + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set + * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet instance + */ + FileDescriptorSet.create = function create(properties) { + return new FileDescriptorSet(properties); + }; + + /** + * Encodes the specified FileDescriptorSet message. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. + * @function encode + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileDescriptorSet.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.file != null && message.file.length) + for (var i = 0; i < message.file.length; ++i) + $root.google.protobuf.FileDescriptorProto.encode(message.file[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified FileDescriptorSet message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileDescriptorSet.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a FileDescriptorSet message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileDescriptorSet.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileDescriptorSet(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.file && message.file.length)) + message.file = []; + message.file.push($root.google.protobuf.FileDescriptorProto.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a FileDescriptorSet message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileDescriptorSet.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a FileDescriptorSet message. + * @function verify + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + FileDescriptorSet.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.file != null && message.hasOwnProperty("file")) { + if (!Array.isArray(message.file)) + return "file: array expected"; + for (var i = 0; i < message.file.length; ++i) { + var error = $root.google.protobuf.FileDescriptorProto.verify(message.file[i]); + if (error) + return "file." + error; + } + } + return null; + }; + + /** + * Creates a FileDescriptorSet message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + */ + FileDescriptorSet.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FileDescriptorSet) + return object; + var message = new $root.google.protobuf.FileDescriptorSet(); + if (object.file) { + if (!Array.isArray(object.file)) + throw TypeError(".google.protobuf.FileDescriptorSet.file: array expected"); + message.file = []; + for (var i = 0; i < object.file.length; ++i) { + if (typeof object.file[i] !== "object") + throw TypeError(".google.protobuf.FileDescriptorSet.file: object expected"); + message.file[i] = $root.google.protobuf.FileDescriptorProto.fromObject(object.file[i]); + } + } + return message; + }; + + /** + * Creates a plain object from a FileDescriptorSet message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {google.protobuf.FileDescriptorSet} message FileDescriptorSet + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + FileDescriptorSet.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.file = []; + if (message.file && message.file.length) { + object.file = []; + for (var j = 0; j < message.file.length; ++j) + object.file[j] = $root.google.protobuf.FileDescriptorProto.toObject(message.file[j], options); + } + return object; + }; + + /** + * Converts this FileDescriptorSet to JSON. + * @function toJSON + * @memberof google.protobuf.FileDescriptorSet + * @instance + * @returns {Object.} JSON object + */ + FileDescriptorSet.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for FileDescriptorSet + * @function getTypeUrl + * @memberof google.protobuf.FileDescriptorSet + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + FileDescriptorSet.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.FileDescriptorSet"; + }; + + return FileDescriptorSet; + })(); + + protobuf.FileDescriptorProto = (function() { + + /** + * Properties of a FileDescriptorProto. + * @memberof google.protobuf + * @interface IFileDescriptorProto + * @property {string|null} [name] FileDescriptorProto name + * @property {string|null} ["package"] FileDescriptorProto package + * @property {Array.|null} [dependency] FileDescriptorProto dependency + * @property {Array.|null} [publicDependency] FileDescriptorProto publicDependency + * @property {Array.|null} [weakDependency] FileDescriptorProto weakDependency + * @property {Array.|null} [messageType] FileDescriptorProto messageType + * @property {Array.|null} [enumType] FileDescriptorProto enumType + * @property {Array.|null} [service] FileDescriptorProto service + * @property {Array.|null} [extension] FileDescriptorProto extension + * @property {google.protobuf.IFileOptions|null} [options] FileDescriptorProto options + * @property {google.protobuf.ISourceCodeInfo|null} [sourceCodeInfo] FileDescriptorProto sourceCodeInfo + * @property {string|null} [syntax] FileDescriptorProto syntax + * @property {string|null} [edition] FileDescriptorProto edition + */ + + /** + * Constructs a new FileDescriptorProto. + * @memberof google.protobuf + * @classdesc Represents a FileDescriptorProto. + * @implements IFileDescriptorProto + * @constructor + * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set + */ + function FileDescriptorProto(properties) { + this.dependency = []; + this.publicDependency = []; + this.weakDependency = []; + this.messageType = []; + this.enumType = []; + this.service = []; + this.extension = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * FileDescriptorProto name. + * @member {string} name + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.name = ""; + + /** + * FileDescriptorProto package. + * @member {string} package + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype["package"] = ""; + + /** + * FileDescriptorProto dependency. + * @member {Array.} dependency + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.dependency = $util.emptyArray; + + /** + * FileDescriptorProto publicDependency. + * @member {Array.} publicDependency + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.publicDependency = $util.emptyArray; + + /** + * FileDescriptorProto weakDependency. + * @member {Array.} weakDependency + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.weakDependency = $util.emptyArray; + + /** + * FileDescriptorProto messageType. + * @member {Array.} messageType + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.messageType = $util.emptyArray; + + /** + * FileDescriptorProto enumType. + * @member {Array.} enumType + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.enumType = $util.emptyArray; + + /** + * FileDescriptorProto service. + * @member {Array.} service + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.service = $util.emptyArray; + + /** + * FileDescriptorProto extension. + * @member {Array.} extension + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.extension = $util.emptyArray; + + /** + * FileDescriptorProto options. + * @member {google.protobuf.IFileOptions|null|undefined} options + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.options = null; + + /** + * FileDescriptorProto sourceCodeInfo. + * @member {google.protobuf.ISourceCodeInfo|null|undefined} sourceCodeInfo + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.sourceCodeInfo = null; + + /** + * FileDescriptorProto syntax. + * @member {string} syntax + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.syntax = ""; + + /** + * FileDescriptorProto edition. + * @member {string} edition + * @memberof google.protobuf.FileDescriptorProto + * @instance + */ + FileDescriptorProto.prototype.edition = ""; + + /** + * Creates a new FileDescriptorProto instance using the specified properties. + * @function create + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto instance + */ + FileDescriptorProto.create = function create(properties) { + return new FileDescriptorProto(properties); + }; + + /** + * Encodes the specified FileDescriptorProto message. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. + * @function encode + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileDescriptorProto.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message["package"] != null && Object.hasOwnProperty.call(message, "package")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message["package"]); + if (message.dependency != null && message.dependency.length) + for (var i = 0; i < message.dependency.length; ++i) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.dependency[i]); + if (message.messageType != null && message.messageType.length) + for (var i = 0; i < message.messageType.length; ++i) + $root.google.protobuf.DescriptorProto.encode(message.messageType[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.enumType != null && message.enumType.length) + for (var i = 0; i < message.enumType.length; ++i) + $root.google.protobuf.EnumDescriptorProto.encode(message.enumType[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.service != null && message.service.length) + for (var i = 0; i < message.service.length; ++i) + $root.google.protobuf.ServiceDescriptorProto.encode(message.service[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.extension != null && message.extension.length) + for (var i = 0; i < message.extension.length; ++i) + $root.google.protobuf.FieldDescriptorProto.encode(message.extension[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.FileOptions.encode(message.options, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.sourceCodeInfo != null && Object.hasOwnProperty.call(message, "sourceCodeInfo")) + $root.google.protobuf.SourceCodeInfo.encode(message.sourceCodeInfo, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + if (message.publicDependency != null && message.publicDependency.length) + for (var i = 0; i < message.publicDependency.length; ++i) + writer.uint32(/* id 10, wireType 0 =*/80).int32(message.publicDependency[i]); + if (message.weakDependency != null && message.weakDependency.length) + for (var i = 0; i < message.weakDependency.length; ++i) + writer.uint32(/* id 11, wireType 0 =*/88).int32(message.weakDependency[i]); + if (message.syntax != null && Object.hasOwnProperty.call(message, "syntax")) + writer.uint32(/* id 12, wireType 2 =*/98).string(message.syntax); + if (message.edition != null && Object.hasOwnProperty.call(message, "edition")) + writer.uint32(/* id 13, wireType 2 =*/106).string(message.edition); + return writer; + }; + + /** + * Encodes the specified FileDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a FileDescriptorProto message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileDescriptorProto.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileDescriptorProto(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + case 2: { + message["package"] = reader.string(); + break; + } + case 3: { + if (!(message.dependency && message.dependency.length)) + message.dependency = []; + message.dependency.push(reader.string()); + break; + } + case 10: { + if (!(message.publicDependency && message.publicDependency.length)) + message.publicDependency = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.publicDependency.push(reader.int32()); + } else + message.publicDependency.push(reader.int32()); + break; + } + case 11: { + if (!(message.weakDependency && message.weakDependency.length)) + message.weakDependency = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.weakDependency.push(reader.int32()); + } else + message.weakDependency.push(reader.int32()); + break; + } + case 4: { + if (!(message.messageType && message.messageType.length)) + message.messageType = []; + message.messageType.push($root.google.protobuf.DescriptorProto.decode(reader, reader.uint32())); + break; + } + case 5: { + if (!(message.enumType && message.enumType.length)) + message.enumType = []; + message.enumType.push($root.google.protobuf.EnumDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 6: { + if (!(message.service && message.service.length)) + message.service = []; + message.service.push($root.google.protobuf.ServiceDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 7: { + if (!(message.extension && message.extension.length)) + message.extension = []; + message.extension.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 8: { + message.options = $root.google.protobuf.FileOptions.decode(reader, reader.uint32()); + break; + } + case 9: { + message.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.decode(reader, reader.uint32()); + break; + } + case 12: { + message.syntax = reader.string(); + break; + } + case 13: { + message.edition = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a FileDescriptorProto message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a FileDescriptorProto message. + * @function verify + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + FileDescriptorProto.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message["package"] != null && message.hasOwnProperty("package")) + if (!$util.isString(message["package"])) + return "package: string expected"; + if (message.dependency != null && message.hasOwnProperty("dependency")) { + if (!Array.isArray(message.dependency)) + return "dependency: array expected"; + for (var i = 0; i < message.dependency.length; ++i) + if (!$util.isString(message.dependency[i])) + return "dependency: string[] expected"; + } + if (message.publicDependency != null && message.hasOwnProperty("publicDependency")) { + if (!Array.isArray(message.publicDependency)) + return "publicDependency: array expected"; + for (var i = 0; i < message.publicDependency.length; ++i) + if (!$util.isInteger(message.publicDependency[i])) + return "publicDependency: integer[] expected"; + } + if (message.weakDependency != null && message.hasOwnProperty("weakDependency")) { + if (!Array.isArray(message.weakDependency)) + return "weakDependency: array expected"; + for (var i = 0; i < message.weakDependency.length; ++i) + if (!$util.isInteger(message.weakDependency[i])) + return "weakDependency: integer[] expected"; + } + if (message.messageType != null && message.hasOwnProperty("messageType")) { + if (!Array.isArray(message.messageType)) + return "messageType: array expected"; + for (var i = 0; i < message.messageType.length; ++i) { + var error = $root.google.protobuf.DescriptorProto.verify(message.messageType[i]); + if (error) + return "messageType." + error; + } + } + if (message.enumType != null && message.hasOwnProperty("enumType")) { + if (!Array.isArray(message.enumType)) + return "enumType: array expected"; + for (var i = 0; i < message.enumType.length; ++i) { + var error = $root.google.protobuf.EnumDescriptorProto.verify(message.enumType[i]); + if (error) + return "enumType." + error; + } + } + if (message.service != null && message.hasOwnProperty("service")) { + if (!Array.isArray(message.service)) + return "service: array expected"; + for (var i = 0; i < message.service.length; ++i) { + var error = $root.google.protobuf.ServiceDescriptorProto.verify(message.service[i]); + if (error) + return "service." + error; + } + } + if (message.extension != null && message.hasOwnProperty("extension")) { + if (!Array.isArray(message.extension)) + return "extension: array expected"; + for (var i = 0; i < message.extension.length; ++i) { + var error = $root.google.protobuf.FieldDescriptorProto.verify(message.extension[i]); + if (error) + return "extension." + error; + } + } + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.FileOptions.verify(message.options); + if (error) + return "options." + error; + } + if (message.sourceCodeInfo != null && message.hasOwnProperty("sourceCodeInfo")) { + var error = $root.google.protobuf.SourceCodeInfo.verify(message.sourceCodeInfo); + if (error) + return "sourceCodeInfo." + error; + } + if (message.syntax != null && message.hasOwnProperty("syntax")) + if (!$util.isString(message.syntax)) + return "syntax: string expected"; + if (message.edition != null && message.hasOwnProperty("edition")) + if (!$util.isString(message.edition)) + return "edition: string expected"; + return null; + }; + + /** + * Creates a FileDescriptorProto message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + */ + FileDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FileDescriptorProto) + return object; + var message = new $root.google.protobuf.FileDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object["package"] != null) + message["package"] = String(object["package"]); + if (object.dependency) { + if (!Array.isArray(object.dependency)) + throw TypeError(".google.protobuf.FileDescriptorProto.dependency: array expected"); + message.dependency = []; + for (var i = 0; i < object.dependency.length; ++i) + message.dependency[i] = String(object.dependency[i]); + } + if (object.publicDependency) { + if (!Array.isArray(object.publicDependency)) + throw TypeError(".google.protobuf.FileDescriptorProto.publicDependency: array expected"); + message.publicDependency = []; + for (var i = 0; i < object.publicDependency.length; ++i) + message.publicDependency[i] = object.publicDependency[i] | 0; + } + if (object.weakDependency) { + if (!Array.isArray(object.weakDependency)) + throw TypeError(".google.protobuf.FileDescriptorProto.weakDependency: array expected"); + message.weakDependency = []; + for (var i = 0; i < object.weakDependency.length; ++i) + message.weakDependency[i] = object.weakDependency[i] | 0; + } + if (object.messageType) { + if (!Array.isArray(object.messageType)) + throw TypeError(".google.protobuf.FileDescriptorProto.messageType: array expected"); + message.messageType = []; + for (var i = 0; i < object.messageType.length; ++i) { + if (typeof object.messageType[i] !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.messageType: object expected"); + message.messageType[i] = $root.google.protobuf.DescriptorProto.fromObject(object.messageType[i]); + } + } + if (object.enumType) { + if (!Array.isArray(object.enumType)) + throw TypeError(".google.protobuf.FileDescriptorProto.enumType: array expected"); + message.enumType = []; + for (var i = 0; i < object.enumType.length; ++i) { + if (typeof object.enumType[i] !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.enumType: object expected"); + message.enumType[i] = $root.google.protobuf.EnumDescriptorProto.fromObject(object.enumType[i]); + } + } + if (object.service) { + if (!Array.isArray(object.service)) + throw TypeError(".google.protobuf.FileDescriptorProto.service: array expected"); + message.service = []; + for (var i = 0; i < object.service.length; ++i) { + if (typeof object.service[i] !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.service: object expected"); + message.service[i] = $root.google.protobuf.ServiceDescriptorProto.fromObject(object.service[i]); + } + } + if (object.extension) { + if (!Array.isArray(object.extension)) + throw TypeError(".google.protobuf.FileDescriptorProto.extension: array expected"); + message.extension = []; + for (var i = 0; i < object.extension.length; ++i) { + if (typeof object.extension[i] !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.extension: object expected"); + message.extension[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.extension[i]); + } + } + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.FileOptions.fromObject(object.options); + } + if (object.sourceCodeInfo != null) { + if (typeof object.sourceCodeInfo !== "object") + throw TypeError(".google.protobuf.FileDescriptorProto.sourceCodeInfo: object expected"); + message.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.fromObject(object.sourceCodeInfo); + } + if (object.syntax != null) + message.syntax = String(object.syntax); + if (object.edition != null) + message.edition = String(object.edition); + return message; + }; + + /** + * Creates a plain object from a FileDescriptorProto message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {google.protobuf.FileDescriptorProto} message FileDescriptorProto + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + FileDescriptorProto.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.dependency = []; + object.messageType = []; + object.enumType = []; + object.service = []; + object.extension = []; + object.publicDependency = []; + object.weakDependency = []; + } + if (options.defaults) { + object.name = ""; + object["package"] = ""; + object.options = null; + object.sourceCodeInfo = null; + object.syntax = ""; + object.edition = ""; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message["package"] != null && message.hasOwnProperty("package")) + object["package"] = message["package"]; + if (message.dependency && message.dependency.length) { + object.dependency = []; + for (var j = 0; j < message.dependency.length; ++j) + object.dependency[j] = message.dependency[j]; + } + if (message.messageType && message.messageType.length) { + object.messageType = []; + for (var j = 0; j < message.messageType.length; ++j) + object.messageType[j] = $root.google.protobuf.DescriptorProto.toObject(message.messageType[j], options); + } + if (message.enumType && message.enumType.length) { + object.enumType = []; + for (var j = 0; j < message.enumType.length; ++j) + object.enumType[j] = $root.google.protobuf.EnumDescriptorProto.toObject(message.enumType[j], options); + } + if (message.service && message.service.length) { + object.service = []; + for (var j = 0; j < message.service.length; ++j) + object.service[j] = $root.google.protobuf.ServiceDescriptorProto.toObject(message.service[j], options); + } + if (message.extension && message.extension.length) { + object.extension = []; + for (var j = 0; j < message.extension.length; ++j) + object.extension[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.extension[j], options); + } + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.FileOptions.toObject(message.options, options); + if (message.sourceCodeInfo != null && message.hasOwnProperty("sourceCodeInfo")) + object.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.toObject(message.sourceCodeInfo, options); + if (message.publicDependency && message.publicDependency.length) { + object.publicDependency = []; + for (var j = 0; j < message.publicDependency.length; ++j) + object.publicDependency[j] = message.publicDependency[j]; + } + if (message.weakDependency && message.weakDependency.length) { + object.weakDependency = []; + for (var j = 0; j < message.weakDependency.length; ++j) + object.weakDependency[j] = message.weakDependency[j]; + } + if (message.syntax != null && message.hasOwnProperty("syntax")) + object.syntax = message.syntax; + if (message.edition != null && message.hasOwnProperty("edition")) + object.edition = message.edition; + return object; + }; + + /** + * Converts this FileDescriptorProto to JSON. + * @function toJSON + * @memberof google.protobuf.FileDescriptorProto + * @instance + * @returns {Object.} JSON object + */ + FileDescriptorProto.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for FileDescriptorProto + * @function getTypeUrl + * @memberof google.protobuf.FileDescriptorProto + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + FileDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.FileDescriptorProto"; + }; + + return FileDescriptorProto; + })(); + + protobuf.DescriptorProto = (function() { + + /** + * Properties of a DescriptorProto. + * @memberof google.protobuf + * @interface IDescriptorProto + * @property {string|null} [name] DescriptorProto name + * @property {Array.|null} [field] DescriptorProto field + * @property {Array.|null} [extension] DescriptorProto extension + * @property {Array.|null} [nestedType] DescriptorProto nestedType + * @property {Array.|null} [enumType] DescriptorProto enumType + * @property {Array.|null} [extensionRange] DescriptorProto extensionRange + * @property {Array.|null} [oneofDecl] DescriptorProto oneofDecl + * @property {google.protobuf.IMessageOptions|null} [options] DescriptorProto options + * @property {Array.|null} [reservedRange] DescriptorProto reservedRange + * @property {Array.|null} [reservedName] DescriptorProto reservedName + */ + + /** + * Constructs a new DescriptorProto. + * @memberof google.protobuf + * @classdesc Represents a DescriptorProto. + * @implements IDescriptorProto + * @constructor + * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set + */ + function DescriptorProto(properties) { + this.field = []; + this.extension = []; + this.nestedType = []; + this.enumType = []; + this.extensionRange = []; + this.oneofDecl = []; + this.reservedRange = []; + this.reservedName = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * DescriptorProto name. + * @member {string} name + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.name = ""; + + /** + * DescriptorProto field. + * @member {Array.} field + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.field = $util.emptyArray; + + /** + * DescriptorProto extension. + * @member {Array.} extension + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.extension = $util.emptyArray; + + /** + * DescriptorProto nestedType. + * @member {Array.} nestedType + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.nestedType = $util.emptyArray; + + /** + * DescriptorProto enumType. + * @member {Array.} enumType + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.enumType = $util.emptyArray; + + /** + * DescriptorProto extensionRange. + * @member {Array.} extensionRange + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.extensionRange = $util.emptyArray; + + /** + * DescriptorProto oneofDecl. + * @member {Array.} oneofDecl + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.oneofDecl = $util.emptyArray; + + /** + * DescriptorProto options. + * @member {google.protobuf.IMessageOptions|null|undefined} options + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.options = null; + + /** + * DescriptorProto reservedRange. + * @member {Array.} reservedRange + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.reservedRange = $util.emptyArray; + + /** + * DescriptorProto reservedName. + * @member {Array.} reservedName + * @memberof google.protobuf.DescriptorProto + * @instance + */ + DescriptorProto.prototype.reservedName = $util.emptyArray; + + /** + * Creates a new DescriptorProto instance using the specified properties. + * @function create + * @memberof google.protobuf.DescriptorProto + * @static + * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.DescriptorProto} DescriptorProto instance + */ + DescriptorProto.create = function create(properties) { + return new DescriptorProto(properties); + }; + + /** + * Encodes the specified DescriptorProto message. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. + * @function encode + * @memberof google.protobuf.DescriptorProto + * @static + * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DescriptorProto.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.field != null && message.field.length) + for (var i = 0; i < message.field.length; ++i) + $root.google.protobuf.FieldDescriptorProto.encode(message.field[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.nestedType != null && message.nestedType.length) + for (var i = 0; i < message.nestedType.length; ++i) + $root.google.protobuf.DescriptorProto.encode(message.nestedType[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.enumType != null && message.enumType.length) + for (var i = 0; i < message.enumType.length; ++i) + $root.google.protobuf.EnumDescriptorProto.encode(message.enumType[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.extensionRange != null && message.extensionRange.length) + for (var i = 0; i < message.extensionRange.length; ++i) + $root.google.protobuf.DescriptorProto.ExtensionRange.encode(message.extensionRange[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + if (message.extension != null && message.extension.length) + for (var i = 0; i < message.extension.length; ++i) + $root.google.protobuf.FieldDescriptorProto.encode(message.extension[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.MessageOptions.encode(message.options, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.oneofDecl != null && message.oneofDecl.length) + for (var i = 0; i < message.oneofDecl.length; ++i) + $root.google.protobuf.OneofDescriptorProto.encode(message.oneofDecl[i], writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.reservedRange != null && message.reservedRange.length) + for (var i = 0; i < message.reservedRange.length; ++i) + $root.google.protobuf.DescriptorProto.ReservedRange.encode(message.reservedRange[i], writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + if (message.reservedName != null && message.reservedName.length) + for (var i = 0; i < message.reservedName.length; ++i) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.reservedName[i]); + return writer; + }; + + /** + * Encodes the specified DescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.DescriptorProto + * @static + * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a DescriptorProto message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.DescriptorProto + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.DescriptorProto} DescriptorProto + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DescriptorProto.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + case 2: { + if (!(message.field && message.field.length)) + message.field = []; + message.field.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 6: { + if (!(message.extension && message.extension.length)) + message.extension = []; + message.extension.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 3: { + if (!(message.nestedType && message.nestedType.length)) + message.nestedType = []; + message.nestedType.push($root.google.protobuf.DescriptorProto.decode(reader, reader.uint32())); + break; + } + case 4: { + if (!(message.enumType && message.enumType.length)) + message.enumType = []; + message.enumType.push($root.google.protobuf.EnumDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 5: { + if (!(message.extensionRange && message.extensionRange.length)) + message.extensionRange = []; + message.extensionRange.push($root.google.protobuf.DescriptorProto.ExtensionRange.decode(reader, reader.uint32())); + break; + } + case 8: { + if (!(message.oneofDecl && message.oneofDecl.length)) + message.oneofDecl = []; + message.oneofDecl.push($root.google.protobuf.OneofDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 7: { + message.options = $root.google.protobuf.MessageOptions.decode(reader, reader.uint32()); + break; + } + case 9: { + if (!(message.reservedRange && message.reservedRange.length)) + message.reservedRange = []; + message.reservedRange.push($root.google.protobuf.DescriptorProto.ReservedRange.decode(reader, reader.uint32())); + break; + } + case 10: { + if (!(message.reservedName && message.reservedName.length)) + message.reservedName = []; + message.reservedName.push(reader.string()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a DescriptorProto message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.DescriptorProto + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.DescriptorProto} DescriptorProto + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DescriptorProto.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a DescriptorProto message. + * @function verify + * @memberof google.protobuf.DescriptorProto + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DescriptorProto.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.field != null && message.hasOwnProperty("field")) { + if (!Array.isArray(message.field)) + return "field: array expected"; + for (var i = 0; i < message.field.length; ++i) { + var error = $root.google.protobuf.FieldDescriptorProto.verify(message.field[i]); + if (error) + return "field." + error; + } + } + if (message.extension != null && message.hasOwnProperty("extension")) { + if (!Array.isArray(message.extension)) + return "extension: array expected"; + for (var i = 0; i < message.extension.length; ++i) { + var error = $root.google.protobuf.FieldDescriptorProto.verify(message.extension[i]); + if (error) + return "extension." + error; + } + } + if (message.nestedType != null && message.hasOwnProperty("nestedType")) { + if (!Array.isArray(message.nestedType)) + return "nestedType: array expected"; + for (var i = 0; i < message.nestedType.length; ++i) { + var error = $root.google.protobuf.DescriptorProto.verify(message.nestedType[i]); + if (error) + return "nestedType." + error; + } + } + if (message.enumType != null && message.hasOwnProperty("enumType")) { + if (!Array.isArray(message.enumType)) + return "enumType: array expected"; + for (var i = 0; i < message.enumType.length; ++i) { + var error = $root.google.protobuf.EnumDescriptorProto.verify(message.enumType[i]); + if (error) + return "enumType." + error; + } + } + if (message.extensionRange != null && message.hasOwnProperty("extensionRange")) { + if (!Array.isArray(message.extensionRange)) + return "extensionRange: array expected"; + for (var i = 0; i < message.extensionRange.length; ++i) { + var error = $root.google.protobuf.DescriptorProto.ExtensionRange.verify(message.extensionRange[i]); + if (error) + return "extensionRange." + error; + } + } + if (message.oneofDecl != null && message.hasOwnProperty("oneofDecl")) { + if (!Array.isArray(message.oneofDecl)) + return "oneofDecl: array expected"; + for (var i = 0; i < message.oneofDecl.length; ++i) { + var error = $root.google.protobuf.OneofDescriptorProto.verify(message.oneofDecl[i]); + if (error) + return "oneofDecl." + error; + } + } + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.MessageOptions.verify(message.options); + if (error) + return "options." + error; + } + if (message.reservedRange != null && message.hasOwnProperty("reservedRange")) { + if (!Array.isArray(message.reservedRange)) + return "reservedRange: array expected"; + for (var i = 0; i < message.reservedRange.length; ++i) { + var error = $root.google.protobuf.DescriptorProto.ReservedRange.verify(message.reservedRange[i]); + if (error) + return "reservedRange." + error; + } + } + if (message.reservedName != null && message.hasOwnProperty("reservedName")) { + if (!Array.isArray(message.reservedName)) + return "reservedName: array expected"; + for (var i = 0; i < message.reservedName.length; ++i) + if (!$util.isString(message.reservedName[i])) + return "reservedName: string[] expected"; + } + return null; + }; + + /** + * Creates a DescriptorProto message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.DescriptorProto + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.DescriptorProto} DescriptorProto + */ + DescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.DescriptorProto) + return object; + var message = new $root.google.protobuf.DescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.field) { + if (!Array.isArray(object.field)) + throw TypeError(".google.protobuf.DescriptorProto.field: array expected"); + message.field = []; + for (var i = 0; i < object.field.length; ++i) { + if (typeof object.field[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.field: object expected"); + message.field[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.field[i]); + } + } + if (object.extension) { + if (!Array.isArray(object.extension)) + throw TypeError(".google.protobuf.DescriptorProto.extension: array expected"); + message.extension = []; + for (var i = 0; i < object.extension.length; ++i) { + if (typeof object.extension[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.extension: object expected"); + message.extension[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.extension[i]); + } + } + if (object.nestedType) { + if (!Array.isArray(object.nestedType)) + throw TypeError(".google.protobuf.DescriptorProto.nestedType: array expected"); + message.nestedType = []; + for (var i = 0; i < object.nestedType.length; ++i) { + if (typeof object.nestedType[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.nestedType: object expected"); + message.nestedType[i] = $root.google.protobuf.DescriptorProto.fromObject(object.nestedType[i]); + } + } + if (object.enumType) { + if (!Array.isArray(object.enumType)) + throw TypeError(".google.protobuf.DescriptorProto.enumType: array expected"); + message.enumType = []; + for (var i = 0; i < object.enumType.length; ++i) { + if (typeof object.enumType[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.enumType: object expected"); + message.enumType[i] = $root.google.protobuf.EnumDescriptorProto.fromObject(object.enumType[i]); + } + } + if (object.extensionRange) { + if (!Array.isArray(object.extensionRange)) + throw TypeError(".google.protobuf.DescriptorProto.extensionRange: array expected"); + message.extensionRange = []; + for (var i = 0; i < object.extensionRange.length; ++i) { + if (typeof object.extensionRange[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.extensionRange: object expected"); + message.extensionRange[i] = $root.google.protobuf.DescriptorProto.ExtensionRange.fromObject(object.extensionRange[i]); + } + } + if (object.oneofDecl) { + if (!Array.isArray(object.oneofDecl)) + throw TypeError(".google.protobuf.DescriptorProto.oneofDecl: array expected"); + message.oneofDecl = []; + for (var i = 0; i < object.oneofDecl.length; ++i) { + if (typeof object.oneofDecl[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.oneofDecl: object expected"); + message.oneofDecl[i] = $root.google.protobuf.OneofDescriptorProto.fromObject(object.oneofDecl[i]); + } + } + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.DescriptorProto.options: object expected"); + message.options = $root.google.protobuf.MessageOptions.fromObject(object.options); + } + if (object.reservedRange) { + if (!Array.isArray(object.reservedRange)) + throw TypeError(".google.protobuf.DescriptorProto.reservedRange: array expected"); + message.reservedRange = []; + for (var i = 0; i < object.reservedRange.length; ++i) { + if (typeof object.reservedRange[i] !== "object") + throw TypeError(".google.protobuf.DescriptorProto.reservedRange: object expected"); + message.reservedRange[i] = $root.google.protobuf.DescriptorProto.ReservedRange.fromObject(object.reservedRange[i]); + } + } + if (object.reservedName) { + if (!Array.isArray(object.reservedName)) + throw TypeError(".google.protobuf.DescriptorProto.reservedName: array expected"); + message.reservedName = []; + for (var i = 0; i < object.reservedName.length; ++i) + message.reservedName[i] = String(object.reservedName[i]); } - if (message.post != null && message.hasOwnProperty("post")) { - if (properties.pattern === 1) - return "pattern: multiple values"; - properties.pattern = 1; - if (!$util.isString(message.post)) - return "post: string expected"; + return message; + }; + + /** + * Creates a plain object from a DescriptorProto message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.DescriptorProto + * @static + * @param {google.protobuf.DescriptorProto} message DescriptorProto + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DescriptorProto.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.field = []; + object.nestedType = []; + object.enumType = []; + object.extensionRange = []; + object.extension = []; + object.oneofDecl = []; + object.reservedRange = []; + object.reservedName = []; } - if (message["delete"] != null && message.hasOwnProperty("delete")) { - if (properties.pattern === 1) - return "pattern: multiple values"; - properties.pattern = 1; - if (!$util.isString(message["delete"])) - return "delete: string expected"; + if (options.defaults) { + object.name = ""; + object.options = null; } - if (message.patch != null && message.hasOwnProperty("patch")) { - if (properties.pattern === 1) - return "pattern: multiple values"; - properties.pattern = 1; - if (!$util.isString(message.patch)) - return "patch: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.field && message.field.length) { + object.field = []; + for (var j = 0; j < message.field.length; ++j) + object.field[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.field[j], options); } - if (message.custom != null && message.hasOwnProperty("custom")) { - if (properties.pattern === 1) - return "pattern: multiple values"; - properties.pattern = 1; - { - var error = $root.google.api.CustomHttpPattern.verify(message.custom); + if (message.nestedType && message.nestedType.length) { + object.nestedType = []; + for (var j = 0; j < message.nestedType.length; ++j) + object.nestedType[j] = $root.google.protobuf.DescriptorProto.toObject(message.nestedType[j], options); + } + if (message.enumType && message.enumType.length) { + object.enumType = []; + for (var j = 0; j < message.enumType.length; ++j) + object.enumType[j] = $root.google.protobuf.EnumDescriptorProto.toObject(message.enumType[j], options); + } + if (message.extensionRange && message.extensionRange.length) { + object.extensionRange = []; + for (var j = 0; j < message.extensionRange.length; ++j) + object.extensionRange[j] = $root.google.protobuf.DescriptorProto.ExtensionRange.toObject(message.extensionRange[j], options); + } + if (message.extension && message.extension.length) { + object.extension = []; + for (var j = 0; j < message.extension.length; ++j) + object.extension[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.extension[j], options); + } + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.MessageOptions.toObject(message.options, options); + if (message.oneofDecl && message.oneofDecl.length) { + object.oneofDecl = []; + for (var j = 0; j < message.oneofDecl.length; ++j) + object.oneofDecl[j] = $root.google.protobuf.OneofDescriptorProto.toObject(message.oneofDecl[j], options); + } + if (message.reservedRange && message.reservedRange.length) { + object.reservedRange = []; + for (var j = 0; j < message.reservedRange.length; ++j) + object.reservedRange[j] = $root.google.protobuf.DescriptorProto.ReservedRange.toObject(message.reservedRange[j], options); + } + if (message.reservedName && message.reservedName.length) { + object.reservedName = []; + for (var j = 0; j < message.reservedName.length; ++j) + object.reservedName[j] = message.reservedName[j]; + } + return object; + }; + + /** + * Converts this DescriptorProto to JSON. + * @function toJSON + * @memberof google.protobuf.DescriptorProto + * @instance + * @returns {Object.} JSON object + */ + DescriptorProto.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for DescriptorProto + * @function getTypeUrl + * @memberof google.protobuf.DescriptorProto + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.DescriptorProto"; + }; + + DescriptorProto.ExtensionRange = (function() { + + /** + * Properties of an ExtensionRange. + * @memberof google.protobuf.DescriptorProto + * @interface IExtensionRange + * @property {number|null} [start] ExtensionRange start + * @property {number|null} [end] ExtensionRange end + * @property {google.protobuf.IExtensionRangeOptions|null} [options] ExtensionRange options + */ + + /** + * Constructs a new ExtensionRange. + * @memberof google.protobuf.DescriptorProto + * @classdesc Represents an ExtensionRange. + * @implements IExtensionRange + * @constructor + * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set + */ + function ExtensionRange(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ExtensionRange start. + * @member {number} start + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @instance + */ + ExtensionRange.prototype.start = 0; + + /** + * ExtensionRange end. + * @member {number} end + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @instance + */ + ExtensionRange.prototype.end = 0; + + /** + * ExtensionRange options. + * @member {google.protobuf.IExtensionRangeOptions|null|undefined} options + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @instance + */ + ExtensionRange.prototype.options = null; + + /** + * Creates a new ExtensionRange instance using the specified properties. + * @function create + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set + * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange instance + */ + ExtensionRange.create = function create(properties) { + return new ExtensionRange(properties); + }; + + /** + * Encodes the specified ExtensionRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. + * @function encode + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExtensionRange.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.start != null && Object.hasOwnProperty.call(message, "start")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); + if (message.end != null && Object.hasOwnProperty.call(message, "end")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.ExtensionRangeOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ExtensionRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExtensionRange.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ExtensionRange message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExtensionRange.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto.ExtensionRange(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.start = reader.int32(); + break; + } + case 2: { + message.end = reader.int32(); + break; + } + case 3: { + message.options = $root.google.protobuf.ExtensionRangeOptions.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an ExtensionRange message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExtensionRange.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ExtensionRange message. + * @function verify + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ExtensionRange.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.start != null && message.hasOwnProperty("start")) + if (!$util.isInteger(message.start)) + return "start: integer expected"; + if (message.end != null && message.hasOwnProperty("end")) + if (!$util.isInteger(message.end)) + return "end: integer expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.ExtensionRangeOptions.verify(message.options); if (error) - return "custom." + error; + return "options." + error; + } + return null; + }; + + /** + * Creates an ExtensionRange message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange + */ + ExtensionRange.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.DescriptorProto.ExtensionRange) + return object; + var message = new $root.google.protobuf.DescriptorProto.ExtensionRange(); + if (object.start != null) + message.start = object.start | 0; + if (object.end != null) + message.end = object.end | 0; + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.DescriptorProto.ExtensionRange.options: object expected"); + message.options = $root.google.protobuf.ExtensionRangeOptions.fromObject(object.options); + } + return message; + }; + + /** + * Creates a plain object from an ExtensionRange message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {google.protobuf.DescriptorProto.ExtensionRange} message ExtensionRange + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ExtensionRange.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.start = 0; + object.end = 0; + object.options = null; + } + if (message.start != null && message.hasOwnProperty("start")) + object.start = message.start; + if (message.end != null && message.hasOwnProperty("end")) + object.end = message.end; + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.ExtensionRangeOptions.toObject(message.options, options); + return object; + }; + + /** + * Converts this ExtensionRange to JSON. + * @function toJSON + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @instance + * @returns {Object.} JSON object + */ + ExtensionRange.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ExtensionRange + * @function getTypeUrl + * @memberof google.protobuf.DescriptorProto.ExtensionRange + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ExtensionRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.DescriptorProto.ExtensionRange"; + }; + + return ExtensionRange; + })(); + + DescriptorProto.ReservedRange = (function() { + + /** + * Properties of a ReservedRange. + * @memberof google.protobuf.DescriptorProto + * @interface IReservedRange + * @property {number|null} [start] ReservedRange start + * @property {number|null} [end] ReservedRange end + */ + + /** + * Constructs a new ReservedRange. + * @memberof google.protobuf.DescriptorProto + * @classdesc Represents a ReservedRange. + * @implements IReservedRange + * @constructor + * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set + */ + function ReservedRange(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ReservedRange start. + * @member {number} start + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @instance + */ + ReservedRange.prototype.start = 0; + + /** + * ReservedRange end. + * @member {number} end + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @instance + */ + ReservedRange.prototype.end = 0; + + /** + * Creates a new ReservedRange instance using the specified properties. + * @function create + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set + * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange instance + */ + ReservedRange.create = function create(properties) { + return new ReservedRange(properties); + }; + + /** + * Encodes the specified ReservedRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. + * @function encode + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ReservedRange.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.start != null && Object.hasOwnProperty.call(message, "start")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); + if (message.end != null && Object.hasOwnProperty.call(message, "end")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); + return writer; + }; + + /** + * Encodes the specified ReservedRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ReservedRange.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ReservedRange message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ReservedRange.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto.ReservedRange(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.start = reader.int32(); + break; + } + case 2: { + message.end = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a ReservedRange message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ReservedRange.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a ReservedRange message. + * @function verify + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ReservedRange.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.start != null && message.hasOwnProperty("start")) + if (!$util.isInteger(message.start)) + return "start: integer expected"; + if (message.end != null && message.hasOwnProperty("end")) + if (!$util.isInteger(message.end)) + return "end: integer expected"; + return null; + }; + + /** + * Creates a ReservedRange message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange + */ + ReservedRange.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.DescriptorProto.ReservedRange) + return object; + var message = new $root.google.protobuf.DescriptorProto.ReservedRange(); + if (object.start != null) + message.start = object.start | 0; + if (object.end != null) + message.end = object.end | 0; + return message; + }; + + /** + * Creates a plain object from a ReservedRange message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {google.protobuf.DescriptorProto.ReservedRange} message ReservedRange + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ReservedRange.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.start = 0; + object.end = 0; + } + if (message.start != null && message.hasOwnProperty("start")) + object.start = message.start; + if (message.end != null && message.hasOwnProperty("end")) + object.end = message.end; + return object; + }; + + /** + * Converts this ReservedRange to JSON. + * @function toJSON + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @instance + * @returns {Object.} JSON object + */ + ReservedRange.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for ReservedRange + * @function getTypeUrl + * @memberof google.protobuf.DescriptorProto.ReservedRange + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.DescriptorProto.ReservedRange"; + }; + + return ReservedRange; + })(); + + return DescriptorProto; + })(); + + protobuf.ExtensionRangeOptions = (function() { + + /** + * Properties of an ExtensionRangeOptions. + * @memberof google.protobuf + * @interface IExtensionRangeOptions + * @property {Array.|null} [uninterpretedOption] ExtensionRangeOptions uninterpretedOption + */ + + /** + * Constructs a new ExtensionRangeOptions. + * @memberof google.protobuf + * @classdesc Represents an ExtensionRangeOptions. + * @implements IExtensionRangeOptions + * @constructor + * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set + */ + function ExtensionRangeOptions(properties) { + this.uninterpretedOption = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * ExtensionRangeOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.ExtensionRangeOptions + * @instance + */ + ExtensionRangeOptions.prototype.uninterpretedOption = $util.emptyArray; + + /** + * Creates a new ExtensionRangeOptions instance using the specified properties. + * @function create + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set + * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions instance + */ + ExtensionRangeOptions.create = function create(properties) { + return new ExtensionRangeOptions(properties); + }; + + /** + * Encodes the specified ExtensionRangeOptions message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. + * @function encode + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExtensionRangeOptions.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified ExtensionRangeOptions message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ExtensionRangeOptions.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an ExtensionRangeOptions message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExtensionRangeOptions.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ExtensionRangeOptions(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; } } - if (message.body != null && message.hasOwnProperty("body")) - if (!$util.isString(message.body)) - return "body: string expected"; - if (message.responseBody != null && message.hasOwnProperty("responseBody")) - if (!$util.isString(message.responseBody)) - return "responseBody: string expected"; - if (message.additionalBindings != null && message.hasOwnProperty("additionalBindings")) { - if (!Array.isArray(message.additionalBindings)) - return "additionalBindings: array expected"; - for (var i = 0; i < message.additionalBindings.length; ++i) { - var error = $root.google.api.HttpRule.verify(message.additionalBindings[i]); + return message; + }; + + /** + * Decodes an ExtensionRangeOptions message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ExtensionRangeOptions.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an ExtensionRangeOptions message. + * @function verify + * @memberof google.protobuf.ExtensionRangeOptions + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ExtensionRangeOptions.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); if (error) - return "additionalBindings." + error; + return "uninterpretedOption." + error; } } return null; }; /** - * Creates a HttpRule message from a plain object. Also converts values to their respective internal types. + * Creates an ExtensionRangeOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.api.HttpRule + * @memberof google.protobuf.ExtensionRangeOptions * @static * @param {Object.} object Plain object - * @returns {google.api.HttpRule} HttpRule + * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions */ - HttpRule.fromObject = function fromObject(object) { - if (object instanceof $root.google.api.HttpRule) + ExtensionRangeOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.ExtensionRangeOptions) return object; - var message = new $root.google.api.HttpRule(); - if (object.selector != null) - message.selector = String(object.selector); - if (object.get != null) - message.get = String(object.get); - if (object.put != null) - message.put = String(object.put); - if (object.post != null) - message.post = String(object.post); - if (object["delete"] != null) - message["delete"] = String(object["delete"]); - if (object.patch != null) - message.patch = String(object.patch); - if (object.custom != null) { - if (typeof object.custom !== "object") - throw TypeError(".google.api.HttpRule.custom: object expected"); - message.custom = $root.google.api.CustomHttpPattern.fromObject(object.custom); - } - if (object.body != null) - message.body = String(object.body); - if (object.responseBody != null) - message.responseBody = String(object.responseBody); - if (object.additionalBindings) { - if (!Array.isArray(object.additionalBindings)) - throw TypeError(".google.api.HttpRule.additionalBindings: array expected"); - message.additionalBindings = []; - for (var i = 0; i < object.additionalBindings.length; ++i) { - if (typeof object.additionalBindings[i] !== "object") - throw TypeError(".google.api.HttpRule.additionalBindings: object expected"); - message.additionalBindings[i] = $root.google.api.HttpRule.fromObject(object.additionalBindings[i]); + var message = new $root.google.protobuf.ExtensionRangeOptions(); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.ExtensionRangeOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.ExtensionRangeOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); } } return message; }; /** - * Creates a plain object from a HttpRule message. Also converts values to other types if specified. + * Creates a plain object from an ExtensionRangeOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.api.HttpRule + * @memberof google.protobuf.ExtensionRangeOptions * @static - * @param {google.api.HttpRule} message HttpRule + * @param {google.protobuf.ExtensionRangeOptions} message ExtensionRangeOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - HttpRule.toObject = function toObject(message, options) { + ExtensionRangeOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.additionalBindings = []; - if (options.defaults) { - object.selector = ""; - object.body = ""; - object.responseBody = ""; - } - if (message.selector != null && message.hasOwnProperty("selector")) - object.selector = message.selector; - if (message.get != null && message.hasOwnProperty("get")) { - object.get = message.get; - if (options.oneofs) - object.pattern = "get"; - } - if (message.put != null && message.hasOwnProperty("put")) { - object.put = message.put; - if (options.oneofs) - object.pattern = "put"; - } - if (message.post != null && message.hasOwnProperty("post")) { - object.post = message.post; - if (options.oneofs) - object.pattern = "post"; - } - if (message["delete"] != null && message.hasOwnProperty("delete")) { - object["delete"] = message["delete"]; - if (options.oneofs) - object.pattern = "delete"; - } - if (message.patch != null && message.hasOwnProperty("patch")) { - object.patch = message.patch; - if (options.oneofs) - object.pattern = "patch"; - } - if (message.body != null && message.hasOwnProperty("body")) - object.body = message.body; - if (message.custom != null && message.hasOwnProperty("custom")) { - object.custom = $root.google.api.CustomHttpPattern.toObject(message.custom, options); - if (options.oneofs) - object.pattern = "custom"; - } - if (message.additionalBindings && message.additionalBindings.length) { - object.additionalBindings = []; - for (var j = 0; j < message.additionalBindings.length; ++j) - object.additionalBindings[j] = $root.google.api.HttpRule.toObject(message.additionalBindings[j], options); + object.uninterpretedOption = []; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } - if (message.responseBody != null && message.hasOwnProperty("responseBody")) - object.responseBody = message.responseBody; return object; }; /** - * Converts this HttpRule to JSON. + * Converts this ExtensionRangeOptions to JSON. * @function toJSON - * @memberof google.api.HttpRule + * @memberof google.protobuf.ExtensionRangeOptions * @instance * @returns {Object.} JSON object */ - HttpRule.prototype.toJSON = function toJSON() { + ExtensionRangeOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for HttpRule + * Gets the default type url for ExtensionRangeOptions * @function getTypeUrl - * @memberof google.api.HttpRule + * @memberof google.protobuf.ExtensionRangeOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - HttpRule.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ExtensionRangeOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.api.HttpRule"; + return typeUrlPrefix + "/google.protobuf.ExtensionRangeOptions"; }; - return HttpRule; + return ExtensionRangeOptions; })(); - api.CustomHttpPattern = (function() { + protobuf.FieldDescriptorProto = (function() { /** - * Properties of a CustomHttpPattern. - * @memberof google.api - * @interface ICustomHttpPattern - * @property {string|null} [kind] CustomHttpPattern kind - * @property {string|null} [path] CustomHttpPattern path + * Properties of a FieldDescriptorProto. + * @memberof google.protobuf + * @interface IFieldDescriptorProto + * @property {string|null} [name] FieldDescriptorProto name + * @property {number|null} [number] FieldDescriptorProto number + * @property {google.protobuf.FieldDescriptorProto.Label|null} [label] FieldDescriptorProto label + * @property {google.protobuf.FieldDescriptorProto.Type|null} [type] FieldDescriptorProto type + * @property {string|null} [typeName] FieldDescriptorProto typeName + * @property {string|null} [extendee] FieldDescriptorProto extendee + * @property {string|null} [defaultValue] FieldDescriptorProto defaultValue + * @property {number|null} [oneofIndex] FieldDescriptorProto oneofIndex + * @property {string|null} [jsonName] FieldDescriptorProto jsonName + * @property {google.protobuf.IFieldOptions|null} [options] FieldDescriptorProto options + * @property {boolean|null} [proto3Optional] FieldDescriptorProto proto3Optional */ /** - * Constructs a new CustomHttpPattern. - * @memberof google.api - * @classdesc Represents a CustomHttpPattern. - * @implements ICustomHttpPattern + * Constructs a new FieldDescriptorProto. + * @memberof google.protobuf + * @classdesc Represents a FieldDescriptorProto. + * @implements IFieldDescriptorProto * @constructor - * @param {google.api.ICustomHttpPattern=} [properties] Properties to set + * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set */ - function CustomHttpPattern(properties) { + function FieldDescriptorProto(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -50174,89 +57766,215 @@ } /** - * CustomHttpPattern kind. - * @member {string} kind - * @memberof google.api.CustomHttpPattern + * FieldDescriptorProto name. + * @member {string} name + * @memberof google.protobuf.FieldDescriptorProto * @instance */ - CustomHttpPattern.prototype.kind = ""; + FieldDescriptorProto.prototype.name = ""; /** - * CustomHttpPattern path. - * @member {string} path - * @memberof google.api.CustomHttpPattern + * FieldDescriptorProto number. + * @member {number} number + * @memberof google.protobuf.FieldDescriptorProto * @instance */ - CustomHttpPattern.prototype.path = ""; + FieldDescriptorProto.prototype.number = 0; + + /** + * FieldDescriptorProto label. + * @member {google.protobuf.FieldDescriptorProto.Label} label + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.label = 1; + + /** + * FieldDescriptorProto type. + * @member {google.protobuf.FieldDescriptorProto.Type} type + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.type = 1; + + /** + * FieldDescriptorProto typeName. + * @member {string} typeName + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.typeName = ""; + + /** + * FieldDescriptorProto extendee. + * @member {string} extendee + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.extendee = ""; + + /** + * FieldDescriptorProto defaultValue. + * @member {string} defaultValue + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.defaultValue = ""; + + /** + * FieldDescriptorProto oneofIndex. + * @member {number} oneofIndex + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.oneofIndex = 0; + + /** + * FieldDescriptorProto jsonName. + * @member {string} jsonName + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.jsonName = ""; + + /** + * FieldDescriptorProto options. + * @member {google.protobuf.IFieldOptions|null|undefined} options + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.options = null; + + /** + * FieldDescriptorProto proto3Optional. + * @member {boolean} proto3Optional + * @memberof google.protobuf.FieldDescriptorProto + * @instance + */ + FieldDescriptorProto.prototype.proto3Optional = false; /** - * Creates a new CustomHttpPattern instance using the specified properties. + * Creates a new FieldDescriptorProto instance using the specified properties. * @function create - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static - * @param {google.api.ICustomHttpPattern=} [properties] Properties to set - * @returns {google.api.CustomHttpPattern} CustomHttpPattern instance + * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto instance */ - CustomHttpPattern.create = function create(properties) { - return new CustomHttpPattern(properties); + FieldDescriptorProto.create = function create(properties) { + return new FieldDescriptorProto(properties); }; /** - * Encodes the specified CustomHttpPattern message. Does not implicitly {@link google.api.CustomHttpPattern.verify|verify} messages. + * Encodes the specified FieldDescriptorProto message. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static - * @param {google.api.ICustomHttpPattern} message CustomHttpPattern message or plain object to encode + * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CustomHttpPattern.encode = function encode(message, writer) { + FieldDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.kind != null && Object.hasOwnProperty.call(message, "kind")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.kind); - if (message.path != null && Object.hasOwnProperty.call(message, "path")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.path); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.extendee != null && Object.hasOwnProperty.call(message, "extendee")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.extendee); + if (message.number != null && Object.hasOwnProperty.call(message, "number")) + writer.uint32(/* id 3, wireType 0 =*/24).int32(message.number); + if (message.label != null && Object.hasOwnProperty.call(message, "label")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.label); + if (message.type != null && Object.hasOwnProperty.call(message, "type")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.type); + if (message.typeName != null && Object.hasOwnProperty.call(message, "typeName")) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.typeName); + if (message.defaultValue != null && Object.hasOwnProperty.call(message, "defaultValue")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.defaultValue); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.FieldOptions.encode(message.options, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.oneofIndex != null && Object.hasOwnProperty.call(message, "oneofIndex")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.oneofIndex); + if (message.jsonName != null && Object.hasOwnProperty.call(message, "jsonName")) + writer.uint32(/* id 10, wireType 2 =*/82).string(message.jsonName); + if (message.proto3Optional != null && Object.hasOwnProperty.call(message, "proto3Optional")) + writer.uint32(/* id 17, wireType 0 =*/136).bool(message.proto3Optional); return writer; }; /** - * Encodes the specified CustomHttpPattern message, length delimited. Does not implicitly {@link google.api.CustomHttpPattern.verify|verify} messages. + * Encodes the specified FieldDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static - * @param {google.api.ICustomHttpPattern} message CustomHttpPattern message or plain object to encode + * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - CustomHttpPattern.encodeDelimited = function encodeDelimited(message, writer) { + FieldDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a CustomHttpPattern message from the specified reader or buffer. + * Decodes a FieldDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.api.CustomHttpPattern} CustomHttpPattern + * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CustomHttpPattern.decode = function decode(reader, length) { + FieldDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.CustomHttpPattern(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.kind = reader.string(); + message.name = reader.string(); + break; + } + case 3: { + message.number = reader.int32(); + break; + } + case 4: { + message.label = reader.int32(); + break; + } + case 5: { + message.type = reader.int32(); + break; + } + case 6: { + message.typeName = reader.string(); break; } case 2: { - message.path = reader.string(); + message.extendee = reader.string(); + break; + } + case 7: { + message.defaultValue = reader.string(); + break; + } + case 9: { + message.oneofIndex = reader.int32(); + break; + } + case 10: { + message.jsonName = reader.string(); + break; + } + case 8: { + message.options = $root.google.protobuf.FieldOptions.decode(reader, reader.uint32()); + break; + } + case 17: { + message.proto3Optional = reader.bool(); break; } default: @@ -50268,313 +57986,484 @@ }; /** - * Decodes a CustomHttpPattern message from the specified reader or buffer, length delimited. + * Decodes a FieldDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.api.CustomHttpPattern} CustomHttpPattern + * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - CustomHttpPattern.decodeDelimited = function decodeDelimited(reader) { + FieldDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a CustomHttpPattern message. + * Verifies a FieldDescriptorProto message. * @function verify - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - CustomHttpPattern.verify = function verify(message) { + FieldDescriptorProto.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.kind != null && message.hasOwnProperty("kind")) - if (!$util.isString(message.kind)) - return "kind: string expected"; - if (message.path != null && message.hasOwnProperty("path")) - if (!$util.isString(message.path)) - return "path: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.number != null && message.hasOwnProperty("number")) + if (!$util.isInteger(message.number)) + return "number: integer expected"; + if (message.label != null && message.hasOwnProperty("label")) + switch (message.label) { + default: + return "label: enum value expected"; + case 1: + case 2: + case 3: + break; + } + if (message.type != null && message.hasOwnProperty("type")) + switch (message.type) { + default: + return "type: enum value expected"; + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + case 9: + case 10: + case 11: + case 12: + case 13: + case 14: + case 15: + case 16: + case 17: + case 18: + break; + } + if (message.typeName != null && message.hasOwnProperty("typeName")) + if (!$util.isString(message.typeName)) + return "typeName: string expected"; + if (message.extendee != null && message.hasOwnProperty("extendee")) + if (!$util.isString(message.extendee)) + return "extendee: string expected"; + if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) + if (!$util.isString(message.defaultValue)) + return "defaultValue: string expected"; + if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) + if (!$util.isInteger(message.oneofIndex)) + return "oneofIndex: integer expected"; + if (message.jsonName != null && message.hasOwnProperty("jsonName")) + if (!$util.isString(message.jsonName)) + return "jsonName: string expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.FieldOptions.verify(message.options); + if (error) + return "options." + error; + } + if (message.proto3Optional != null && message.hasOwnProperty("proto3Optional")) + if (typeof message.proto3Optional !== "boolean") + return "proto3Optional: boolean expected"; return null; }; /** - * Creates a CustomHttpPattern message from a plain object. Also converts values to their respective internal types. + * Creates a FieldDescriptorProto message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static * @param {Object.} object Plain object - * @returns {google.api.CustomHttpPattern} CustomHttpPattern + * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto */ - CustomHttpPattern.fromObject = function fromObject(object) { - if (object instanceof $root.google.api.CustomHttpPattern) + FieldDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FieldDescriptorProto) return object; - var message = new $root.google.api.CustomHttpPattern(); - if (object.kind != null) - message.kind = String(object.kind); - if (object.path != null) - message.path = String(object.path); + var message = new $root.google.protobuf.FieldDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.number != null) + message.number = object.number | 0; + switch (object.label) { + default: + if (typeof object.label === "number") { + message.label = object.label; + break; + } + break; + case "LABEL_OPTIONAL": + case 1: + message.label = 1; + break; + case "LABEL_REQUIRED": + case 2: + message.label = 2; + break; + case "LABEL_REPEATED": + case 3: + message.label = 3; + break; + } + switch (object.type) { + default: + if (typeof object.type === "number") { + message.type = object.type; + break; + } + break; + case "TYPE_DOUBLE": + case 1: + message.type = 1; + break; + case "TYPE_FLOAT": + case 2: + message.type = 2; + break; + case "TYPE_INT64": + case 3: + message.type = 3; + break; + case "TYPE_UINT64": + case 4: + message.type = 4; + break; + case "TYPE_INT32": + case 5: + message.type = 5; + break; + case "TYPE_FIXED64": + case 6: + message.type = 6; + break; + case "TYPE_FIXED32": + case 7: + message.type = 7; + break; + case "TYPE_BOOL": + case 8: + message.type = 8; + break; + case "TYPE_STRING": + case 9: + message.type = 9; + break; + case "TYPE_GROUP": + case 10: + message.type = 10; + break; + case "TYPE_MESSAGE": + case 11: + message.type = 11; + break; + case "TYPE_BYTES": + case 12: + message.type = 12; + break; + case "TYPE_UINT32": + case 13: + message.type = 13; + break; + case "TYPE_ENUM": + case 14: + message.type = 14; + break; + case "TYPE_SFIXED32": + case 15: + message.type = 15; + break; + case "TYPE_SFIXED64": + case 16: + message.type = 16; + break; + case "TYPE_SINT32": + case 17: + message.type = 17; + break; + case "TYPE_SINT64": + case 18: + message.type = 18; + break; + } + if (object.typeName != null) + message.typeName = String(object.typeName); + if (object.extendee != null) + message.extendee = String(object.extendee); + if (object.defaultValue != null) + message.defaultValue = String(object.defaultValue); + if (object.oneofIndex != null) + message.oneofIndex = object.oneofIndex | 0; + if (object.jsonName != null) + message.jsonName = String(object.jsonName); + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.FieldDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.FieldOptions.fromObject(object.options); + } + if (object.proto3Optional != null) + message.proto3Optional = Boolean(object.proto3Optional); return message; }; /** - * Creates a plain object from a CustomHttpPattern message. Also converts values to other types if specified. + * Creates a plain object from a FieldDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static - * @param {google.api.CustomHttpPattern} message CustomHttpPattern + * @param {google.protobuf.FieldDescriptorProto} message FieldDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - CustomHttpPattern.toObject = function toObject(message, options) { + FieldDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.kind = ""; - object.path = ""; + object.name = ""; + object.extendee = ""; + object.number = 0; + object.label = options.enums === String ? "LABEL_OPTIONAL" : 1; + object.type = options.enums === String ? "TYPE_DOUBLE" : 1; + object.typeName = ""; + object.defaultValue = ""; + object.options = null; + object.oneofIndex = 0; + object.jsonName = ""; + object.proto3Optional = false; } - if (message.kind != null && message.hasOwnProperty("kind")) - object.kind = message.kind; - if (message.path != null && message.hasOwnProperty("path")) - object.path = message.path; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.extendee != null && message.hasOwnProperty("extendee")) + object.extendee = message.extendee; + if (message.number != null && message.hasOwnProperty("number")) + object.number = message.number; + if (message.label != null && message.hasOwnProperty("label")) + object.label = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Label[message.label] === undefined ? message.label : $root.google.protobuf.FieldDescriptorProto.Label[message.label] : message.label; + if (message.type != null && message.hasOwnProperty("type")) + object.type = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Type[message.type] === undefined ? message.type : $root.google.protobuf.FieldDescriptorProto.Type[message.type] : message.type; + if (message.typeName != null && message.hasOwnProperty("typeName")) + object.typeName = message.typeName; + if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) + object.defaultValue = message.defaultValue; + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.FieldOptions.toObject(message.options, options); + if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) + object.oneofIndex = message.oneofIndex; + if (message.jsonName != null && message.hasOwnProperty("jsonName")) + object.jsonName = message.jsonName; + if (message.proto3Optional != null && message.hasOwnProperty("proto3Optional")) + object.proto3Optional = message.proto3Optional; return object; }; /** - * Converts this CustomHttpPattern to JSON. + * Converts this FieldDescriptorProto to JSON. * @function toJSON - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @instance * @returns {Object.} JSON object */ - CustomHttpPattern.prototype.toJSON = function toJSON() { + FieldDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for CustomHttpPattern + * Gets the default type url for FieldDescriptorProto * @function getTypeUrl - * @memberof google.api.CustomHttpPattern + * @memberof google.protobuf.FieldDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - CustomHttpPattern.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FieldDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.api.CustomHttpPattern"; + return typeUrlPrefix + "/google.protobuf.FieldDescriptorProto"; }; - return CustomHttpPattern; - })(); - - api.ResourceDescriptor = (function() { - - /** - * Properties of a ResourceDescriptor. - * @memberof google.api - * @interface IResourceDescriptor - * @property {string|null} [type] ResourceDescriptor type - * @property {Array.|null} [pattern] ResourceDescriptor pattern - * @property {string|null} [nameField] ResourceDescriptor nameField - * @property {google.api.ResourceDescriptor.History|null} [history] ResourceDescriptor history - * @property {string|null} [plural] ResourceDescriptor plural - * @property {string|null} [singular] ResourceDescriptor singular - * @property {Array.|null} [style] ResourceDescriptor style - */ - /** - * Constructs a new ResourceDescriptor. - * @memberof google.api - * @classdesc Represents a ResourceDescriptor. - * @implements IResourceDescriptor - * @constructor - * @param {google.api.IResourceDescriptor=} [properties] Properties to set + * Type enum. + * @name google.protobuf.FieldDescriptorProto.Type + * @enum {number} + * @property {number} TYPE_DOUBLE=1 TYPE_DOUBLE value + * @property {number} TYPE_FLOAT=2 TYPE_FLOAT value + * @property {number} TYPE_INT64=3 TYPE_INT64 value + * @property {number} TYPE_UINT64=4 TYPE_UINT64 value + * @property {number} TYPE_INT32=5 TYPE_INT32 value + * @property {number} TYPE_FIXED64=6 TYPE_FIXED64 value + * @property {number} TYPE_FIXED32=7 TYPE_FIXED32 value + * @property {number} TYPE_BOOL=8 TYPE_BOOL value + * @property {number} TYPE_STRING=9 TYPE_STRING value + * @property {number} TYPE_GROUP=10 TYPE_GROUP value + * @property {number} TYPE_MESSAGE=11 TYPE_MESSAGE value + * @property {number} TYPE_BYTES=12 TYPE_BYTES value + * @property {number} TYPE_UINT32=13 TYPE_UINT32 value + * @property {number} TYPE_ENUM=14 TYPE_ENUM value + * @property {number} TYPE_SFIXED32=15 TYPE_SFIXED32 value + * @property {number} TYPE_SFIXED64=16 TYPE_SFIXED64 value + * @property {number} TYPE_SINT32=17 TYPE_SINT32 value + * @property {number} TYPE_SINT64=18 TYPE_SINT64 value */ - function ResourceDescriptor(properties) { - this.pattern = []; - this.style = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + FieldDescriptorProto.Type = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[1] = "TYPE_DOUBLE"] = 1; + values[valuesById[2] = "TYPE_FLOAT"] = 2; + values[valuesById[3] = "TYPE_INT64"] = 3; + values[valuesById[4] = "TYPE_UINT64"] = 4; + values[valuesById[5] = "TYPE_INT32"] = 5; + values[valuesById[6] = "TYPE_FIXED64"] = 6; + values[valuesById[7] = "TYPE_FIXED32"] = 7; + values[valuesById[8] = "TYPE_BOOL"] = 8; + values[valuesById[9] = "TYPE_STRING"] = 9; + values[valuesById[10] = "TYPE_GROUP"] = 10; + values[valuesById[11] = "TYPE_MESSAGE"] = 11; + values[valuesById[12] = "TYPE_BYTES"] = 12; + values[valuesById[13] = "TYPE_UINT32"] = 13; + values[valuesById[14] = "TYPE_ENUM"] = 14; + values[valuesById[15] = "TYPE_SFIXED32"] = 15; + values[valuesById[16] = "TYPE_SFIXED64"] = 16; + values[valuesById[17] = "TYPE_SINT32"] = 17; + values[valuesById[18] = "TYPE_SINT64"] = 18; + return values; + })(); /** - * ResourceDescriptor type. - * @member {string} type - * @memberof google.api.ResourceDescriptor - * @instance + * Label enum. + * @name google.protobuf.FieldDescriptorProto.Label + * @enum {number} + * @property {number} LABEL_OPTIONAL=1 LABEL_OPTIONAL value + * @property {number} LABEL_REQUIRED=2 LABEL_REQUIRED value + * @property {number} LABEL_REPEATED=3 LABEL_REPEATED value */ - ResourceDescriptor.prototype.type = ""; + FieldDescriptorProto.Label = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[1] = "LABEL_OPTIONAL"] = 1; + values[valuesById[2] = "LABEL_REQUIRED"] = 2; + values[valuesById[3] = "LABEL_REPEATED"] = 3; + return values; + })(); - /** - * ResourceDescriptor pattern. - * @member {Array.} pattern - * @memberof google.api.ResourceDescriptor - * @instance - */ - ResourceDescriptor.prototype.pattern = $util.emptyArray; + return FieldDescriptorProto; + })(); - /** - * ResourceDescriptor nameField. - * @member {string} nameField - * @memberof google.api.ResourceDescriptor - * @instance - */ - ResourceDescriptor.prototype.nameField = ""; + protobuf.OneofDescriptorProto = (function() { /** - * ResourceDescriptor history. - * @member {google.api.ResourceDescriptor.History} history - * @memberof google.api.ResourceDescriptor - * @instance + * Properties of an OneofDescriptorProto. + * @memberof google.protobuf + * @interface IOneofDescriptorProto + * @property {string|null} [name] OneofDescriptorProto name + * @property {google.protobuf.IOneofOptions|null} [options] OneofDescriptorProto options */ - ResourceDescriptor.prototype.history = 0; /** - * ResourceDescriptor plural. - * @member {string} plural - * @memberof google.api.ResourceDescriptor - * @instance + * Constructs a new OneofDescriptorProto. + * @memberof google.protobuf + * @classdesc Represents an OneofDescriptorProto. + * @implements IOneofDescriptorProto + * @constructor + * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set */ - ResourceDescriptor.prototype.plural = ""; + function OneofDescriptorProto(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * ResourceDescriptor singular. - * @member {string} singular - * @memberof google.api.ResourceDescriptor + * OneofDescriptorProto name. + * @member {string} name + * @memberof google.protobuf.OneofDescriptorProto * @instance */ - ResourceDescriptor.prototype.singular = ""; + OneofDescriptorProto.prototype.name = ""; /** - * ResourceDescriptor style. - * @member {Array.} style - * @memberof google.api.ResourceDescriptor + * OneofDescriptorProto options. + * @member {google.protobuf.IOneofOptions|null|undefined} options + * @memberof google.protobuf.OneofDescriptorProto * @instance */ - ResourceDescriptor.prototype.style = $util.emptyArray; + OneofDescriptorProto.prototype.options = null; /** - * Creates a new ResourceDescriptor instance using the specified properties. + * Creates a new OneofDescriptorProto instance using the specified properties. * @function create - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static - * @param {google.api.IResourceDescriptor=} [properties] Properties to set - * @returns {google.api.ResourceDescriptor} ResourceDescriptor instance + * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto instance */ - ResourceDescriptor.create = function create(properties) { - return new ResourceDescriptor(properties); + OneofDescriptorProto.create = function create(properties) { + return new OneofDescriptorProto(properties); }; /** - * Encodes the specified ResourceDescriptor message. Does not implicitly {@link google.api.ResourceDescriptor.verify|verify} messages. + * Encodes the specified OneofDescriptorProto message. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static - * @param {google.api.IResourceDescriptor} message ResourceDescriptor message or plain object to encode + * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ResourceDescriptor.encode = function encode(message, writer) { + OneofDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); - if (message.pattern != null && message.pattern.length) - for (var i = 0; i < message.pattern.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.pattern[i]); - if (message.nameField != null && Object.hasOwnProperty.call(message, "nameField")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.nameField); - if (message.history != null && Object.hasOwnProperty.call(message, "history")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.history); - if (message.plural != null && Object.hasOwnProperty.call(message, "plural")) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.plural); - if (message.singular != null && Object.hasOwnProperty.call(message, "singular")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.singular); - if (message.style != null && message.style.length) { - writer.uint32(/* id 10, wireType 2 =*/82).fork(); - for (var i = 0; i < message.style.length; ++i) - writer.int32(message.style[i]); - writer.ldelim(); - } + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.OneofOptions.encode(message.options, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified ResourceDescriptor message, length delimited. Does not implicitly {@link google.api.ResourceDescriptor.verify|verify} messages. + * Encodes the specified OneofDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static - * @param {google.api.IResourceDescriptor} message ResourceDescriptor message or plain object to encode + * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ResourceDescriptor.encodeDelimited = function encodeDelimited(message, writer) { + OneofDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ResourceDescriptor message from the specified reader or buffer. + * Decodes an OneofDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.api.ResourceDescriptor} ResourceDescriptor + * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ResourceDescriptor.decode = function decode(reader, length) { + OneofDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.ResourceDescriptor(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.OneofDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.type = reader.string(); + message.name = reader.string(); break; } case 2: { - if (!(message.pattern && message.pattern.length)) - message.pattern = []; - message.pattern.push(reader.string()); - break; - } - case 3: { - message.nameField = reader.string(); - break; - } - case 4: { - message.history = reader.int32(); - break; - } - case 5: { - message.plural = reader.string(); - break; - } - case 6: { - message.singular = reader.string(); - break; - } - case 10: { - if (!(message.style && message.style.length)) - message.style = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.style.push(reader.int32()); - } else - message.style.push(reader.int32()); + message.options = $root.google.protobuf.OneofOptions.decode(reader, reader.uint32()); break; } default: @@ -50586,271 +58475,143 @@ }; /** - * Decodes a ResourceDescriptor message from the specified reader or buffer, length delimited. + * Decodes an OneofDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.api.ResourceDescriptor} ResourceDescriptor + * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ResourceDescriptor.decodeDelimited = function decodeDelimited(reader) { + OneofDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ResourceDescriptor message. + * Verifies an OneofDescriptorProto message. * @function verify - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ResourceDescriptor.verify = function verify(message) { + OneofDescriptorProto.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.type != null && message.hasOwnProperty("type")) - if (!$util.isString(message.type)) - return "type: string expected"; - if (message.pattern != null && message.hasOwnProperty("pattern")) { - if (!Array.isArray(message.pattern)) - return "pattern: array expected"; - for (var i = 0; i < message.pattern.length; ++i) - if (!$util.isString(message.pattern[i])) - return "pattern: string[] expected"; - } - if (message.nameField != null && message.hasOwnProperty("nameField")) - if (!$util.isString(message.nameField)) - return "nameField: string expected"; - if (message.history != null && message.hasOwnProperty("history")) - switch (message.history) { - default: - return "history: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.plural != null && message.hasOwnProperty("plural")) - if (!$util.isString(message.plural)) - return "plural: string expected"; - if (message.singular != null && message.hasOwnProperty("singular")) - if (!$util.isString(message.singular)) - return "singular: string expected"; - if (message.style != null && message.hasOwnProperty("style")) { - if (!Array.isArray(message.style)) - return "style: array expected"; - for (var i = 0; i < message.style.length; ++i) - switch (message.style[i]) { - default: - return "style: enum value[] expected"; - case 0: - case 1: - break; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.OneofOptions.verify(message.options); + if (error) + return "options." + error; } return null; }; /** - * Creates a ResourceDescriptor message from a plain object. Also converts values to their respective internal types. + * Creates an OneofDescriptorProto message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static * @param {Object.} object Plain object - * @returns {google.api.ResourceDescriptor} ResourceDescriptor + * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto */ - ResourceDescriptor.fromObject = function fromObject(object) { - if (object instanceof $root.google.api.ResourceDescriptor) + OneofDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.OneofDescriptorProto) return object; - var message = new $root.google.api.ResourceDescriptor(); - if (object.type != null) - message.type = String(object.type); - if (object.pattern) { - if (!Array.isArray(object.pattern)) - throw TypeError(".google.api.ResourceDescriptor.pattern: array expected"); - message.pattern = []; - for (var i = 0; i < object.pattern.length; ++i) - message.pattern[i] = String(object.pattern[i]); - } - if (object.nameField != null) - message.nameField = String(object.nameField); - switch (object.history) { - default: - if (typeof object.history === "number") { - message.history = object.history; - break; - } - break; - case "HISTORY_UNSPECIFIED": - case 0: - message.history = 0; - break; - case "ORIGINALLY_SINGLE_PATTERN": - case 1: - message.history = 1; - break; - case "FUTURE_MULTI_PATTERN": - case 2: - message.history = 2; - break; - } - if (object.plural != null) - message.plural = String(object.plural); - if (object.singular != null) - message.singular = String(object.singular); - if (object.style) { - if (!Array.isArray(object.style)) - throw TypeError(".google.api.ResourceDescriptor.style: array expected"); - message.style = []; - for (var i = 0; i < object.style.length; ++i) - switch (object.style[i]) { - default: - if (typeof object.style[i] === "number") { - message.style[i] = object.style[i]; - break; - } - case "STYLE_UNSPECIFIED": - case 0: - message.style[i] = 0; - break; - case "DECLARATIVE_FRIENDLY": - case 1: - message.style[i] = 1; - break; - } + var message = new $root.google.protobuf.OneofDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.OneofDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.OneofOptions.fromObject(object.options); } return message; }; /** - * Creates a plain object from a ResourceDescriptor message. Also converts values to other types if specified. + * Creates a plain object from an OneofDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static - * @param {google.api.ResourceDescriptor} message ResourceDescriptor + * @param {google.protobuf.OneofDescriptorProto} message OneofDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ResourceDescriptor.toObject = function toObject(message, options) { + OneofDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.pattern = []; - object.style = []; - } if (options.defaults) { - object.type = ""; - object.nameField = ""; - object.history = options.enums === String ? "HISTORY_UNSPECIFIED" : 0; - object.plural = ""; - object.singular = ""; - } - if (message.type != null && message.hasOwnProperty("type")) - object.type = message.type; - if (message.pattern && message.pattern.length) { - object.pattern = []; - for (var j = 0; j < message.pattern.length; ++j) - object.pattern[j] = message.pattern[j]; - } - if (message.nameField != null && message.hasOwnProperty("nameField")) - object.nameField = message.nameField; - if (message.history != null && message.hasOwnProperty("history")) - object.history = options.enums === String ? $root.google.api.ResourceDescriptor.History[message.history] === undefined ? message.history : $root.google.api.ResourceDescriptor.History[message.history] : message.history; - if (message.plural != null && message.hasOwnProperty("plural")) - object.plural = message.plural; - if (message.singular != null && message.hasOwnProperty("singular")) - object.singular = message.singular; - if (message.style && message.style.length) { - object.style = []; - for (var j = 0; j < message.style.length; ++j) - object.style[j] = options.enums === String ? $root.google.api.ResourceDescriptor.Style[message.style[j]] === undefined ? message.style[j] : $root.google.api.ResourceDescriptor.Style[message.style[j]] : message.style[j]; + object.name = ""; + object.options = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.OneofOptions.toObject(message.options, options); return object; }; /** - * Converts this ResourceDescriptor to JSON. + * Converts this OneofDescriptorProto to JSON. * @function toJSON - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @instance * @returns {Object.} JSON object */ - ResourceDescriptor.prototype.toJSON = function toJSON() { + OneofDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ResourceDescriptor + * Gets the default type url for OneofDescriptorProto * @function getTypeUrl - * @memberof google.api.ResourceDescriptor + * @memberof google.protobuf.OneofDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ResourceDescriptor.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + OneofDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.api.ResourceDescriptor"; + return typeUrlPrefix + "/google.protobuf.OneofDescriptorProto"; }; - /** - * History enum. - * @name google.api.ResourceDescriptor.History - * @enum {number} - * @property {number} HISTORY_UNSPECIFIED=0 HISTORY_UNSPECIFIED value - * @property {number} ORIGINALLY_SINGLE_PATTERN=1 ORIGINALLY_SINGLE_PATTERN value - * @property {number} FUTURE_MULTI_PATTERN=2 FUTURE_MULTI_PATTERN value - */ - ResourceDescriptor.History = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "HISTORY_UNSPECIFIED"] = 0; - values[valuesById[1] = "ORIGINALLY_SINGLE_PATTERN"] = 1; - values[valuesById[2] = "FUTURE_MULTI_PATTERN"] = 2; - return values; - })(); - - /** - * Style enum. - * @name google.api.ResourceDescriptor.Style - * @enum {number} - * @property {number} STYLE_UNSPECIFIED=0 STYLE_UNSPECIFIED value - * @property {number} DECLARATIVE_FRIENDLY=1 DECLARATIVE_FRIENDLY value - */ - ResourceDescriptor.Style = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "STYLE_UNSPECIFIED"] = 0; - values[valuesById[1] = "DECLARATIVE_FRIENDLY"] = 1; - return values; - })(); - - return ResourceDescriptor; + return OneofDescriptorProto; })(); - api.ResourceReference = (function() { + protobuf.EnumDescriptorProto = (function() { /** - * Properties of a ResourceReference. - * @memberof google.api - * @interface IResourceReference - * @property {string|null} [type] ResourceReference type - * @property {string|null} [childType] ResourceReference childType + * Properties of an EnumDescriptorProto. + * @memberof google.protobuf + * @interface IEnumDescriptorProto + * @property {string|null} [name] EnumDescriptorProto name + * @property {Array.|null} [value] EnumDescriptorProto value + * @property {google.protobuf.IEnumOptions|null} [options] EnumDescriptorProto options + * @property {Array.|null} [reservedRange] EnumDescriptorProto reservedRange + * @property {Array.|null} [reservedName] EnumDescriptorProto reservedName */ /** - * Constructs a new ResourceReference. - * @memberof google.api - * @classdesc Represents a ResourceReference. - * @implements IResourceReference + * Constructs a new EnumDescriptorProto. + * @memberof google.protobuf + * @classdesc Represents an EnumDescriptorProto. + * @implements IEnumDescriptorProto * @constructor - * @param {google.api.IResourceReference=} [properties] Properties to set + * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set */ - function ResourceReference(properties) { + function EnumDescriptorProto(properties) { + this.value = []; + this.reservedRange = []; + this.reservedName = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -50858,89 +58619,140 @@ } /** - * ResourceReference type. - * @member {string} type - * @memberof google.api.ResourceReference + * EnumDescriptorProto name. + * @member {string} name + * @memberof google.protobuf.EnumDescriptorProto * @instance */ - ResourceReference.prototype.type = ""; + EnumDescriptorProto.prototype.name = ""; /** - * ResourceReference childType. - * @member {string} childType - * @memberof google.api.ResourceReference + * EnumDescriptorProto value. + * @member {Array.} value + * @memberof google.protobuf.EnumDescriptorProto * @instance */ - ResourceReference.prototype.childType = ""; + EnumDescriptorProto.prototype.value = $util.emptyArray; /** - * Creates a new ResourceReference instance using the specified properties. + * EnumDescriptorProto options. + * @member {google.protobuf.IEnumOptions|null|undefined} options + * @memberof google.protobuf.EnumDescriptorProto + * @instance + */ + EnumDescriptorProto.prototype.options = null; + + /** + * EnumDescriptorProto reservedRange. + * @member {Array.} reservedRange + * @memberof google.protobuf.EnumDescriptorProto + * @instance + */ + EnumDescriptorProto.prototype.reservedRange = $util.emptyArray; + + /** + * EnumDescriptorProto reservedName. + * @member {Array.} reservedName + * @memberof google.protobuf.EnumDescriptorProto + * @instance + */ + EnumDescriptorProto.prototype.reservedName = $util.emptyArray; + + /** + * Creates a new EnumDescriptorProto instance using the specified properties. * @function create - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static - * @param {google.api.IResourceReference=} [properties] Properties to set - * @returns {google.api.ResourceReference} ResourceReference instance + * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto instance */ - ResourceReference.create = function create(properties) { - return new ResourceReference(properties); + EnumDescriptorProto.create = function create(properties) { + return new EnumDescriptorProto(properties); }; /** - * Encodes the specified ResourceReference message. Does not implicitly {@link google.api.ResourceReference.verify|verify} messages. + * Encodes the specified EnumDescriptorProto message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static - * @param {google.api.IResourceReference} message ResourceReference message or plain object to encode + * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ResourceReference.encode = function encode(message, writer) { + EnumDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.type); - if (message.childType != null && Object.hasOwnProperty.call(message, "childType")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.childType); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.value != null && message.value.length) + for (var i = 0; i < message.value.length; ++i) + $root.google.protobuf.EnumValueDescriptorProto.encode(message.value[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.EnumOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.reservedRange != null && message.reservedRange.length) + for (var i = 0; i < message.reservedRange.length; ++i) + $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.encode(message.reservedRange[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.reservedName != null && message.reservedName.length) + for (var i = 0; i < message.reservedName.length; ++i) + writer.uint32(/* id 5, wireType 2 =*/42).string(message.reservedName[i]); return writer; }; /** - * Encodes the specified ResourceReference message, length delimited. Does not implicitly {@link google.api.ResourceReference.verify|verify} messages. + * Encodes the specified EnumDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static - * @param {google.api.IResourceReference} message ResourceReference message or plain object to encode + * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ResourceReference.encodeDelimited = function encodeDelimited(message, writer) { + EnumDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ResourceReference message from the specified reader or buffer. + * Decodes an EnumDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.api.ResourceReference} ResourceReference + * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ResourceReference.decode = function decode(reader, length) { + EnumDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.api.ResourceReference(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.type = reader.string(); + message.name = reader.string(); break; } case 2: { - message.childType = reader.string(); + if (!(message.value && message.value.length)) + message.value = []; + message.value.push($root.google.protobuf.EnumValueDescriptorProto.decode(reader, reader.uint32())); + break; + } + case 3: { + message.options = $root.google.protobuf.EnumOptions.decode(reader, reader.uint32()); + break; + } + case 4: { + if (!(message.reservedRange && message.reservedRange.length)) + message.reservedRange = []; + message.reservedRange.push($root.google.protobuf.EnumDescriptorProto.EnumReservedRange.decode(reader, reader.uint32())); + break; + } + case 5: { + if (!(message.reservedName && message.reservedName.length)) + message.reservedName = []; + message.reservedName.push(reader.string()); break; } default: @@ -50952,144 +58764,437 @@ }; /** - * Decodes a ResourceReference message from the specified reader or buffer, length delimited. + * Decodes an EnumDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.api.ResourceReference} ResourceReference + * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ResourceReference.decodeDelimited = function decodeDelimited(reader) { + EnumDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ResourceReference message. + * Verifies an EnumDescriptorProto message. * @function verify - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ResourceReference.verify = function verify(message) { + EnumDescriptorProto.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.type != null && message.hasOwnProperty("type")) - if (!$util.isString(message.type)) - return "type: string expected"; - if (message.childType != null && message.hasOwnProperty("childType")) - if (!$util.isString(message.childType)) - return "childType: string expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.value != null && message.hasOwnProperty("value")) { + if (!Array.isArray(message.value)) + return "value: array expected"; + for (var i = 0; i < message.value.length; ++i) { + var error = $root.google.protobuf.EnumValueDescriptorProto.verify(message.value[i]); + if (error) + return "value." + error; + } + } + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.EnumOptions.verify(message.options); + if (error) + return "options." + error; + } + if (message.reservedRange != null && message.hasOwnProperty("reservedRange")) { + if (!Array.isArray(message.reservedRange)) + return "reservedRange: array expected"; + for (var i = 0; i < message.reservedRange.length; ++i) { + var error = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.verify(message.reservedRange[i]); + if (error) + return "reservedRange." + error; + } + } + if (message.reservedName != null && message.hasOwnProperty("reservedName")) { + if (!Array.isArray(message.reservedName)) + return "reservedName: array expected"; + for (var i = 0; i < message.reservedName.length; ++i) + if (!$util.isString(message.reservedName[i])) + return "reservedName: string[] expected"; + } return null; }; /** - * Creates a ResourceReference message from a plain object. Also converts values to their respective internal types. + * Creates an EnumDescriptorProto message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static * @param {Object.} object Plain object - * @returns {google.api.ResourceReference} ResourceReference + * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto */ - ResourceReference.fromObject = function fromObject(object) { - if (object instanceof $root.google.api.ResourceReference) + EnumDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.EnumDescriptorProto) return object; - var message = new $root.google.api.ResourceReference(); - if (object.type != null) - message.type = String(object.type); - if (object.childType != null) - message.childType = String(object.childType); + var message = new $root.google.protobuf.EnumDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.value) { + if (!Array.isArray(object.value)) + throw TypeError(".google.protobuf.EnumDescriptorProto.value: array expected"); + message.value = []; + for (var i = 0; i < object.value.length; ++i) { + if (typeof object.value[i] !== "object") + throw TypeError(".google.protobuf.EnumDescriptorProto.value: object expected"); + message.value[i] = $root.google.protobuf.EnumValueDescriptorProto.fromObject(object.value[i]); + } + } + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.EnumDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.EnumOptions.fromObject(object.options); + } + if (object.reservedRange) { + if (!Array.isArray(object.reservedRange)) + throw TypeError(".google.protobuf.EnumDescriptorProto.reservedRange: array expected"); + message.reservedRange = []; + for (var i = 0; i < object.reservedRange.length; ++i) { + if (typeof object.reservedRange[i] !== "object") + throw TypeError(".google.protobuf.EnumDescriptorProto.reservedRange: object expected"); + message.reservedRange[i] = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.fromObject(object.reservedRange[i]); + } + } + if (object.reservedName) { + if (!Array.isArray(object.reservedName)) + throw TypeError(".google.protobuf.EnumDescriptorProto.reservedName: array expected"); + message.reservedName = []; + for (var i = 0; i < object.reservedName.length; ++i) + message.reservedName[i] = String(object.reservedName[i]); + } return message; }; /** - * Creates a plain object from a ResourceReference message. Also converts values to other types if specified. + * Creates a plain object from an EnumDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static - * @param {google.api.ResourceReference} message ResourceReference + * @param {google.protobuf.EnumDescriptorProto} message EnumDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ResourceReference.toObject = function toObject(message, options) { + EnumDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.value = []; + object.reservedRange = []; + object.reservedName = []; + } if (options.defaults) { - object.type = ""; - object.childType = ""; + object.name = ""; + object.options = null; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.value && message.value.length) { + object.value = []; + for (var j = 0; j < message.value.length; ++j) + object.value[j] = $root.google.protobuf.EnumValueDescriptorProto.toObject(message.value[j], options); + } + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.EnumOptions.toObject(message.options, options); + if (message.reservedRange && message.reservedRange.length) { + object.reservedRange = []; + for (var j = 0; j < message.reservedRange.length; ++j) + object.reservedRange[j] = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject(message.reservedRange[j], options); + } + if (message.reservedName && message.reservedName.length) { + object.reservedName = []; + for (var j = 0; j < message.reservedName.length; ++j) + object.reservedName[j] = message.reservedName[j]; } - if (message.type != null && message.hasOwnProperty("type")) - object.type = message.type; - if (message.childType != null && message.hasOwnProperty("childType")) - object.childType = message.childType; return object; }; /** - * Converts this ResourceReference to JSON. + * Converts this EnumDescriptorProto to JSON. * @function toJSON - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @instance * @returns {Object.} JSON object */ - ResourceReference.prototype.toJSON = function toJSON() { + EnumDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ResourceReference + * Gets the default type url for EnumDescriptorProto * @function getTypeUrl - * @memberof google.api.ResourceReference + * @memberof google.protobuf.EnumDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ResourceReference.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + EnumDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.api.ResourceReference"; + return typeUrlPrefix + "/google.protobuf.EnumDescriptorProto"; }; - return ResourceReference; - })(); + EnumDescriptorProto.EnumReservedRange = (function() { - return api; - })(); + /** + * Properties of an EnumReservedRange. + * @memberof google.protobuf.EnumDescriptorProto + * @interface IEnumReservedRange + * @property {number|null} [start] EnumReservedRange start + * @property {number|null} [end] EnumReservedRange end + */ - google.protobuf = (function() { + /** + * Constructs a new EnumReservedRange. + * @memberof google.protobuf.EnumDescriptorProto + * @classdesc Represents an EnumReservedRange. + * @implements IEnumReservedRange + * @constructor + * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set + */ + function EnumReservedRange(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Namespace protobuf. - * @memberof google - * @namespace - */ - var protobuf = {}; + /** + * EnumReservedRange start. + * @member {number} start + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @instance + */ + EnumReservedRange.prototype.start = 0; - protobuf.FileDescriptorSet = (function() { + /** + * EnumReservedRange end. + * @member {number} end + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @instance + */ + EnumReservedRange.prototype.end = 0; + + /** + * Creates a new EnumReservedRange instance using the specified properties. + * @function create + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set + * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange instance + */ + EnumReservedRange.create = function create(properties) { + return new EnumReservedRange(properties); + }; + + /** + * Encodes the specified EnumReservedRange message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. + * @function encode + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumReservedRange.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.start != null && Object.hasOwnProperty.call(message, "start")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); + if (message.end != null && Object.hasOwnProperty.call(message, "end")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); + return writer; + }; + + /** + * Encodes the specified EnumReservedRange message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + EnumReservedRange.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an EnumReservedRange message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumReservedRange.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumDescriptorProto.EnumReservedRange(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.start = reader.int32(); + break; + } + case 2: { + message.end = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an EnumReservedRange message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + EnumReservedRange.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an EnumReservedRange message. + * @function verify + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + EnumReservedRange.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.start != null && message.hasOwnProperty("start")) + if (!$util.isInteger(message.start)) + return "start: integer expected"; + if (message.end != null && message.hasOwnProperty("end")) + if (!$util.isInteger(message.end)) + return "end: integer expected"; + return null; + }; + + /** + * Creates an EnumReservedRange message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange + */ + EnumReservedRange.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.EnumDescriptorProto.EnumReservedRange) + return object; + var message = new $root.google.protobuf.EnumDescriptorProto.EnumReservedRange(); + if (object.start != null) + message.start = object.start | 0; + if (object.end != null) + message.end = object.end | 0; + return message; + }; + + /** + * Creates a plain object from an EnumReservedRange message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {google.protobuf.EnumDescriptorProto.EnumReservedRange} message EnumReservedRange + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + EnumReservedRange.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.start = 0; + object.end = 0; + } + if (message.start != null && message.hasOwnProperty("start")) + object.start = message.start; + if (message.end != null && message.hasOwnProperty("end")) + object.end = message.end; + return object; + }; + + /** + * Converts this EnumReservedRange to JSON. + * @function toJSON + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @instance + * @returns {Object.} JSON object + */ + EnumReservedRange.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for EnumReservedRange + * @function getTypeUrl + * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.EnumDescriptorProto.EnumReservedRange"; + }; + + return EnumReservedRange; + })(); + + return EnumDescriptorProto; + })(); + + protobuf.EnumValueDescriptorProto = (function() { /** - * Properties of a FileDescriptorSet. + * Properties of an EnumValueDescriptorProto. * @memberof google.protobuf - * @interface IFileDescriptorSet - * @property {Array.|null} [file] FileDescriptorSet file + * @interface IEnumValueDescriptorProto + * @property {string|null} [name] EnumValueDescriptorProto name + * @property {number|null} [number] EnumValueDescriptorProto number + * @property {google.protobuf.IEnumValueOptions|null} [options] EnumValueDescriptorProto options */ /** - * Constructs a new FileDescriptorSet. + * Constructs a new EnumValueDescriptorProto. * @memberof google.protobuf - * @classdesc Represents a FileDescriptorSet. - * @implements IFileDescriptorSet + * @classdesc Represents an EnumValueDescriptorProto. + * @implements IEnumValueDescriptorProto * @constructor - * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set + * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set */ - function FileDescriptorSet(properties) { - this.file = []; + function EnumValueDescriptorProto(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -51097,78 +59202,103 @@ } /** - * FileDescriptorSet file. - * @member {Array.} file - * @memberof google.protobuf.FileDescriptorSet + * EnumValueDescriptorProto name. + * @member {string} name + * @memberof google.protobuf.EnumValueDescriptorProto * @instance */ - FileDescriptorSet.prototype.file = $util.emptyArray; + EnumValueDescriptorProto.prototype.name = ""; /** - * Creates a new FileDescriptorSet instance using the specified properties. + * EnumValueDescriptorProto number. + * @member {number} number + * @memberof google.protobuf.EnumValueDescriptorProto + * @instance + */ + EnumValueDescriptorProto.prototype.number = 0; + + /** + * EnumValueDescriptorProto options. + * @member {google.protobuf.IEnumValueOptions|null|undefined} options + * @memberof google.protobuf.EnumValueDescriptorProto + * @instance + */ + EnumValueDescriptorProto.prototype.options = null; + + /** + * Creates a new EnumValueDescriptorProto instance using the specified properties. * @function create - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorSet=} [properties] Properties to set - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet instance + * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto instance */ - FileDescriptorSet.create = function create(properties) { - return new FileDescriptorSet(properties); + EnumValueDescriptorProto.create = function create(properties) { + return new EnumValueDescriptorProto(properties); }; /** - * Encodes the specified FileDescriptorSet message. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. + * Encodes the specified EnumValueDescriptorProto message. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode + * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileDescriptorSet.encode = function encode(message, writer) { + EnumValueDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.file != null && message.file.length) - for (var i = 0; i < message.file.length; ++i) - $root.google.protobuf.FileDescriptorProto.encode(message.file[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.number != null && Object.hasOwnProperty.call(message, "number")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.number); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.protobuf.EnumValueOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified FileDescriptorSet message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorSet.verify|verify} messages. + * Encodes the specified EnumValueDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorSet} message FileDescriptorSet message or plain object to encode + * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileDescriptorSet.encodeDelimited = function encodeDelimited(message, writer) { + EnumValueDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FileDescriptorSet message from the specified reader or buffer. + * Decodes an EnumValueDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileDescriptorSet.decode = function decode(reader, length) { + EnumValueDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileDescriptorSet(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumValueDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.file && message.file.length)) - message.file = []; - message.file.push($root.google.protobuf.FileDescriptorProto.decode(reader, reader.uint32())); + message.name = reader.string(); + break; + } + case 2: { + message.number = reader.int32(); + break; + } + case 3: { + message.options = $root.google.protobuf.EnumValueOptions.decode(reader, reader.uint32()); break; } default: @@ -51180,158 +59310,147 @@ }; /** - * Decodes a FileDescriptorSet message from the specified reader or buffer, length delimited. + * Decodes an EnumValueDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileDescriptorSet.decodeDelimited = function decodeDelimited(reader) { + EnumValueDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FileDescriptorSet message. + * Verifies an EnumValueDescriptorProto message. * @function verify - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FileDescriptorSet.verify = function verify(message) { + EnumValueDescriptorProto.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.file != null && message.hasOwnProperty("file")) { - if (!Array.isArray(message.file)) - return "file: array expected"; - for (var i = 0; i < message.file.length; ++i) { - var error = $root.google.protobuf.FileDescriptorProto.verify(message.file[i]); - if (error) - return "file." + error; - } + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.number != null && message.hasOwnProperty("number")) + if (!$util.isInteger(message.number)) + return "number: integer expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.EnumValueOptions.verify(message.options); + if (error) + return "options." + error; } return null; }; /** - * Creates a FileDescriptorSet message from a plain object. Also converts values to their respective internal types. + * Creates an EnumValueDescriptorProto message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FileDescriptorSet} FileDescriptorSet + * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto */ - FileDescriptorSet.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileDescriptorSet) + EnumValueDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.EnumValueDescriptorProto) return object; - var message = new $root.google.protobuf.FileDescriptorSet(); - if (object.file) { - if (!Array.isArray(object.file)) - throw TypeError(".google.protobuf.FileDescriptorSet.file: array expected"); - message.file = []; - for (var i = 0; i < object.file.length; ++i) { - if (typeof object.file[i] !== "object") - throw TypeError(".google.protobuf.FileDescriptorSet.file: object expected"); - message.file[i] = $root.google.protobuf.FileDescriptorProto.fromObject(object.file[i]); - } + var message = new $root.google.protobuf.EnumValueDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.number != null) + message.number = object.number | 0; + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.protobuf.EnumValueDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.EnumValueOptions.fromObject(object.options); } return message; }; /** - * Creates a plain object from a FileDescriptorSet message. Also converts values to other types if specified. + * Creates a plain object from an EnumValueDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static - * @param {google.protobuf.FileDescriptorSet} message FileDescriptorSet + * @param {google.protobuf.EnumValueDescriptorProto} message EnumValueDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FileDescriptorSet.toObject = function toObject(message, options) { + EnumValueDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.file = []; - if (message.file && message.file.length) { - object.file = []; - for (var j = 0; j < message.file.length; ++j) - object.file[j] = $root.google.protobuf.FileDescriptorProto.toObject(message.file[j], options); + if (options.defaults) { + object.name = ""; + object.number = 0; + object.options = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.number != null && message.hasOwnProperty("number")) + object.number = message.number; + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.protobuf.EnumValueOptions.toObject(message.options, options); return object; }; /** - * Converts this FileDescriptorSet to JSON. + * Converts this EnumValueDescriptorProto to JSON. * @function toJSON - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @instance * @returns {Object.} JSON object */ - FileDescriptorSet.prototype.toJSON = function toJSON() { + EnumValueDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FileDescriptorSet + * Gets the default type url for EnumValueDescriptorProto * @function getTypeUrl - * @memberof google.protobuf.FileDescriptorSet + * @memberof google.protobuf.EnumValueDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FileDescriptorSet.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + EnumValueDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.FileDescriptorSet"; + return typeUrlPrefix + "/google.protobuf.EnumValueDescriptorProto"; }; - return FileDescriptorSet; + return EnumValueDescriptorProto; })(); - protobuf.FileDescriptorProto = (function() { + protobuf.ServiceDescriptorProto = (function() { /** - * Properties of a FileDescriptorProto. + * Properties of a ServiceDescriptorProto. * @memberof google.protobuf - * @interface IFileDescriptorProto - * @property {string|null} [name] FileDescriptorProto name - * @property {string|null} ["package"] FileDescriptorProto package - * @property {Array.|null} [dependency] FileDescriptorProto dependency - * @property {Array.|null} [publicDependency] FileDescriptorProto publicDependency - * @property {Array.|null} [weakDependency] FileDescriptorProto weakDependency - * @property {Array.|null} [messageType] FileDescriptorProto messageType - * @property {Array.|null} [enumType] FileDescriptorProto enumType - * @property {Array.|null} [service] FileDescriptorProto service - * @property {Array.|null} [extension] FileDescriptorProto extension - * @property {google.protobuf.IFileOptions|null} [options] FileDescriptorProto options - * @property {google.protobuf.ISourceCodeInfo|null} [sourceCodeInfo] FileDescriptorProto sourceCodeInfo - * @property {string|null} [syntax] FileDescriptorProto syntax - * @property {string|null} [edition] FileDescriptorProto edition + * @interface IServiceDescriptorProto + * @property {string|null} [name] ServiceDescriptorProto name + * @property {Array.|null} [method] ServiceDescriptorProto method + * @property {google.protobuf.IServiceOptions|null} [options] ServiceDescriptorProto options */ /** - * Constructs a new FileDescriptorProto. + * Constructs a new ServiceDescriptorProto. * @memberof google.protobuf - * @classdesc Represents a FileDescriptorProto. - * @implements IFileDescriptorProto + * @classdesc Represents a ServiceDescriptorProto. + * @implements IServiceDescriptorProto * @constructor - * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set */ - function FileDescriptorProto(properties) { - this.dependency = []; - this.publicDependency = []; - this.weakDependency = []; - this.messageType = []; - this.enumType = []; - this.service = []; - this.extension = []; + function ServiceDescriptorProto(properties) { + this.method = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -51339,197 +59458,91 @@ } /** - * FileDescriptorProto name. + * ServiceDescriptorProto name. * @member {string} name - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.name = ""; - - /** - * FileDescriptorProto package. - * @member {string} package - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype["package"] = ""; - - /** - * FileDescriptorProto dependency. - * @member {Array.} dependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.dependency = $util.emptyArray; - - /** - * FileDescriptorProto publicDependency. - * @member {Array.} publicDependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.publicDependency = $util.emptyArray; - - /** - * FileDescriptorProto weakDependency. - * @member {Array.} weakDependency - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.weakDependency = $util.emptyArray; - - /** - * FileDescriptorProto messageType. - * @member {Array.} messageType - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.messageType = $util.emptyArray; - - /** - * FileDescriptorProto enumType. - * @member {Array.} enumType - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.enumType = $util.emptyArray; - - /** - * FileDescriptorProto service. - * @member {Array.} service - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.service = $util.emptyArray; - - /** - * FileDescriptorProto extension. - * @member {Array.} extension - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.extension = $util.emptyArray; - - /** - * FileDescriptorProto options. - * @member {google.protobuf.IFileOptions|null|undefined} options - * @memberof google.protobuf.FileDescriptorProto - * @instance - */ - FileDescriptorProto.prototype.options = null; - - /** - * FileDescriptorProto sourceCodeInfo. - * @member {google.protobuf.ISourceCodeInfo|null|undefined} sourceCodeInfo - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @instance */ - FileDescriptorProto.prototype.sourceCodeInfo = null; + ServiceDescriptorProto.prototype.name = ""; /** - * FileDescriptorProto syntax. - * @member {string} syntax - * @memberof google.protobuf.FileDescriptorProto + * ServiceDescriptorProto method. + * @member {Array.} method + * @memberof google.protobuf.ServiceDescriptorProto * @instance */ - FileDescriptorProto.prototype.syntax = ""; + ServiceDescriptorProto.prototype.method = $util.emptyArray; /** - * FileDescriptorProto edition. - * @member {string} edition - * @memberof google.protobuf.FileDescriptorProto + * ServiceDescriptorProto options. + * @member {google.protobuf.IServiceOptions|null|undefined} options + * @memberof google.protobuf.ServiceDescriptorProto * @instance */ - FileDescriptorProto.prototype.edition = ""; + ServiceDescriptorProto.prototype.options = null; /** - * Creates a new FileDescriptorProto instance using the specified properties. + * Creates a new ServiceDescriptorProto instance using the specified properties. * @function create - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto instance + * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto instance */ - FileDescriptorProto.create = function create(properties) { - return new FileDescriptorProto(properties); + ServiceDescriptorProto.create = function create(properties) { + return new ServiceDescriptorProto(properties); }; /** - * Encodes the specified FileDescriptorProto message. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. + * Encodes the specified ServiceDescriptorProto message. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode + * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileDescriptorProto.encode = function encode(message, writer) { + ServiceDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message["package"] != null && Object.hasOwnProperty.call(message, "package")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message["package"]); - if (message.dependency != null && message.dependency.length) - for (var i = 0; i < message.dependency.length; ++i) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.dependency[i]); - if (message.messageType != null && message.messageType.length) - for (var i = 0; i < message.messageType.length; ++i) - $root.google.protobuf.DescriptorProto.encode(message.messageType[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.enumType != null && message.enumType.length) - for (var i = 0; i < message.enumType.length; ++i) - $root.google.protobuf.EnumDescriptorProto.encode(message.enumType[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.service != null && message.service.length) - for (var i = 0; i < message.service.length; ++i) - $root.google.protobuf.ServiceDescriptorProto.encode(message.service[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - if (message.extension != null && message.extension.length) - for (var i = 0; i < message.extension.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode(message.extension[i], writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); + if (message.method != null && message.method.length) + for (var i = 0; i < message.method.length; ++i) + $root.google.protobuf.MethodDescriptorProto.encode(message.method[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.FileOptions.encode(message.options, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.sourceCodeInfo != null && Object.hasOwnProperty.call(message, "sourceCodeInfo")) - $root.google.protobuf.SourceCodeInfo.encode(message.sourceCodeInfo, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); - if (message.publicDependency != null && message.publicDependency.length) - for (var i = 0; i < message.publicDependency.length; ++i) - writer.uint32(/* id 10, wireType 0 =*/80).int32(message.publicDependency[i]); - if (message.weakDependency != null && message.weakDependency.length) - for (var i = 0; i < message.weakDependency.length; ++i) - writer.uint32(/* id 11, wireType 0 =*/88).int32(message.weakDependency[i]); - if (message.syntax != null && Object.hasOwnProperty.call(message, "syntax")) - writer.uint32(/* id 12, wireType 2 =*/98).string(message.syntax); - if (message.edition != null && Object.hasOwnProperty.call(message, "edition")) - writer.uint32(/* id 13, wireType 2 =*/106).string(message.edition); + $root.google.protobuf.ServiceOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified FileDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FileDescriptorProto.verify|verify} messages. + * Encodes the specified ServiceDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static - * @param {google.protobuf.IFileDescriptorProto} message FileDescriptorProto message or plain object to encode + * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + ServiceDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FileDescriptorProto message from the specified reader or buffer. + * Decodes a ServiceDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileDescriptorProto.decode = function decode(reader, length) { + ServiceDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ServiceDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -51538,75 +59551,13 @@ break; } case 2: { - message["package"] = reader.string(); + if (!(message.method && message.method.length)) + message.method = []; + message.method.push($root.google.protobuf.MethodDescriptorProto.decode(reader, reader.uint32())); break; } case 3: { - if (!(message.dependency && message.dependency.length)) - message.dependency = []; - message.dependency.push(reader.string()); - break; - } - case 10: { - if (!(message.publicDependency && message.publicDependency.length)) - message.publicDependency = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.publicDependency.push(reader.int32()); - } else - message.publicDependency.push(reader.int32()); - break; - } - case 11: { - if (!(message.weakDependency && message.weakDependency.length)) - message.weakDependency = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.weakDependency.push(reader.int32()); - } else - message.weakDependency.push(reader.int32()); - break; - } - case 4: { - if (!(message.messageType && message.messageType.length)) - message.messageType = []; - message.messageType.push($root.google.protobuf.DescriptorProto.decode(reader, reader.uint32())); - break; - } - case 5: { - if (!(message.enumType && message.enumType.length)) - message.enumType = []; - message.enumType.push($root.google.protobuf.EnumDescriptorProto.decode(reader, reader.uint32())); - break; - } - case 6: { - if (!(message.service && message.service.length)) - message.service = []; - message.service.push($root.google.protobuf.ServiceDescriptorProto.decode(reader, reader.uint32())); - break; - } - case 7: { - if (!(message.extension && message.extension.length)) - message.extension = []; - message.extension.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); - break; - } - case 8: { - message.options = $root.google.protobuf.FileOptions.decode(reader, reader.uint32()); - break; - } - case 9: { - message.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.decode(reader, reader.uint32()); - break; - } - case 12: { - message.syntax = reader.string(); - break; - } - case 13: { - message.edition = reader.string(); + message.options = $root.google.protobuf.ServiceOptions.decode(reader, reader.uint32()); break; } default: @@ -51618,352 +59569,167 @@ }; /** - * Decodes a FileDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes a ServiceDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + ServiceDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FileDescriptorProto message. + * Verifies a ServiceDescriptorProto message. * @function verify - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FileDescriptorProto.verify = function verify(message) { + ServiceDescriptorProto.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.name != null && message.hasOwnProperty("name")) if (!$util.isString(message.name)) return "name: string expected"; - if (message["package"] != null && message.hasOwnProperty("package")) - if (!$util.isString(message["package"])) - return "package: string expected"; - if (message.dependency != null && message.hasOwnProperty("dependency")) { - if (!Array.isArray(message.dependency)) - return "dependency: array expected"; - for (var i = 0; i < message.dependency.length; ++i) - if (!$util.isString(message.dependency[i])) - return "dependency: string[] expected"; - } - if (message.publicDependency != null && message.hasOwnProperty("publicDependency")) { - if (!Array.isArray(message.publicDependency)) - return "publicDependency: array expected"; - for (var i = 0; i < message.publicDependency.length; ++i) - if (!$util.isInteger(message.publicDependency[i])) - return "publicDependency: integer[] expected"; - } - if (message.weakDependency != null && message.hasOwnProperty("weakDependency")) { - if (!Array.isArray(message.weakDependency)) - return "weakDependency: array expected"; - for (var i = 0; i < message.weakDependency.length; ++i) - if (!$util.isInteger(message.weakDependency[i])) - return "weakDependency: integer[] expected"; - } - if (message.messageType != null && message.hasOwnProperty("messageType")) { - if (!Array.isArray(message.messageType)) - return "messageType: array expected"; - for (var i = 0; i < message.messageType.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.verify(message.messageType[i]); - if (error) - return "messageType." + error; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (!Array.isArray(message.enumType)) - return "enumType: array expected"; - for (var i = 0; i < message.enumType.length; ++i) { - var error = $root.google.protobuf.EnumDescriptorProto.verify(message.enumType[i]); - if (error) - return "enumType." + error; - } - } - if (message.service != null && message.hasOwnProperty("service")) { - if (!Array.isArray(message.service)) - return "service: array expected"; - for (var i = 0; i < message.service.length; ++i) { - var error = $root.google.protobuf.ServiceDescriptorProto.verify(message.service[i]); - if (error) - return "service." + error; - } - } - if (message.extension != null && message.hasOwnProperty("extension")) { - if (!Array.isArray(message.extension)) - return "extension: array expected"; - for (var i = 0; i < message.extension.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify(message.extension[i]); + if (message.method != null && message.hasOwnProperty("method")) { + if (!Array.isArray(message.method)) + return "method: array expected"; + for (var i = 0; i < message.method.length; ++i) { + var error = $root.google.protobuf.MethodDescriptorProto.verify(message.method[i]); if (error) - return "extension." + error; + return "method." + error; } } if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.FileOptions.verify(message.options); + var error = $root.google.protobuf.ServiceOptions.verify(message.options); if (error) return "options." + error; } - if (message.sourceCodeInfo != null && message.hasOwnProperty("sourceCodeInfo")) { - var error = $root.google.protobuf.SourceCodeInfo.verify(message.sourceCodeInfo); - if (error) - return "sourceCodeInfo." + error; - } - if (message.syntax != null && message.hasOwnProperty("syntax")) - if (!$util.isString(message.syntax)) - return "syntax: string expected"; - if (message.edition != null && message.hasOwnProperty("edition")) - if (!$util.isString(message.edition)) - return "edition: string expected"; return null; }; /** - * Creates a FileDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates a ServiceDescriptorProto message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FileDescriptorProto} FileDescriptorProto + * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto */ - FileDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileDescriptorProto) + ServiceDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.ServiceDescriptorProto) return object; - var message = new $root.google.protobuf.FileDescriptorProto(); + var message = new $root.google.protobuf.ServiceDescriptorProto(); if (object.name != null) message.name = String(object.name); - if (object["package"] != null) - message["package"] = String(object["package"]); - if (object.dependency) { - if (!Array.isArray(object.dependency)) - throw TypeError(".google.protobuf.FileDescriptorProto.dependency: array expected"); - message.dependency = []; - for (var i = 0; i < object.dependency.length; ++i) - message.dependency[i] = String(object.dependency[i]); - } - if (object.publicDependency) { - if (!Array.isArray(object.publicDependency)) - throw TypeError(".google.protobuf.FileDescriptorProto.publicDependency: array expected"); - message.publicDependency = []; - for (var i = 0; i < object.publicDependency.length; ++i) - message.publicDependency[i] = object.publicDependency[i] | 0; - } - if (object.weakDependency) { - if (!Array.isArray(object.weakDependency)) - throw TypeError(".google.protobuf.FileDescriptorProto.weakDependency: array expected"); - message.weakDependency = []; - for (var i = 0; i < object.weakDependency.length; ++i) - message.weakDependency[i] = object.weakDependency[i] | 0; - } - if (object.messageType) { - if (!Array.isArray(object.messageType)) - throw TypeError(".google.protobuf.FileDescriptorProto.messageType: array expected"); - message.messageType = []; - for (var i = 0; i < object.messageType.length; ++i) { - if (typeof object.messageType[i] !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.messageType: object expected"); - message.messageType[i] = $root.google.protobuf.DescriptorProto.fromObject(object.messageType[i]); - } - } - if (object.enumType) { - if (!Array.isArray(object.enumType)) - throw TypeError(".google.protobuf.FileDescriptorProto.enumType: array expected"); - message.enumType = []; - for (var i = 0; i < object.enumType.length; ++i) { - if (typeof object.enumType[i] !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.enumType: object expected"); - message.enumType[i] = $root.google.protobuf.EnumDescriptorProto.fromObject(object.enumType[i]); - } - } - if (object.service) { - if (!Array.isArray(object.service)) - throw TypeError(".google.protobuf.FileDescriptorProto.service: array expected"); - message.service = []; - for (var i = 0; i < object.service.length; ++i) { - if (typeof object.service[i] !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.service: object expected"); - message.service[i] = $root.google.protobuf.ServiceDescriptorProto.fromObject(object.service[i]); - } - } - if (object.extension) { - if (!Array.isArray(object.extension)) - throw TypeError(".google.protobuf.FileDescriptorProto.extension: array expected"); - message.extension = []; - for (var i = 0; i < object.extension.length; ++i) { - if (typeof object.extension[i] !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.extension: object expected"); - message.extension[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.extension[i]); + if (object.method) { + if (!Array.isArray(object.method)) + throw TypeError(".google.protobuf.ServiceDescriptorProto.method: array expected"); + message.method = []; + for (var i = 0; i < object.method.length; ++i) { + if (typeof object.method[i] !== "object") + throw TypeError(".google.protobuf.ServiceDescriptorProto.method: object expected"); + message.method[i] = $root.google.protobuf.MethodDescriptorProto.fromObject(object.method[i]); } } if (object.options != null) { if (typeof object.options !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.FileOptions.fromObject(object.options); - } - if (object.sourceCodeInfo != null) { - if (typeof object.sourceCodeInfo !== "object") - throw TypeError(".google.protobuf.FileDescriptorProto.sourceCodeInfo: object expected"); - message.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.fromObject(object.sourceCodeInfo); + throw TypeError(".google.protobuf.ServiceDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.ServiceOptions.fromObject(object.options); } - if (object.syntax != null) - message.syntax = String(object.syntax); - if (object.edition != null) - message.edition = String(object.edition); return message; }; /** - * Creates a plain object from a FileDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from a ServiceDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static - * @param {google.protobuf.FileDescriptorProto} message FileDescriptorProto + * @param {google.protobuf.ServiceDescriptorProto} message ServiceDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FileDescriptorProto.toObject = function toObject(message, options) { + ServiceDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.dependency = []; - object.messageType = []; - object.enumType = []; - object.service = []; - object.extension = []; - object.publicDependency = []; - object.weakDependency = []; - } + if (options.arrays || options.defaults) + object.method = []; if (options.defaults) { object.name = ""; - object["package"] = ""; object.options = null; - object.sourceCodeInfo = null; - object.syntax = ""; - object.edition = ""; } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message["package"] != null && message.hasOwnProperty("package")) - object["package"] = message["package"]; - if (message.dependency && message.dependency.length) { - object.dependency = []; - for (var j = 0; j < message.dependency.length; ++j) - object.dependency[j] = message.dependency[j]; - } - if (message.messageType && message.messageType.length) { - object.messageType = []; - for (var j = 0; j < message.messageType.length; ++j) - object.messageType[j] = $root.google.protobuf.DescriptorProto.toObject(message.messageType[j], options); - } - if (message.enumType && message.enumType.length) { - object.enumType = []; - for (var j = 0; j < message.enumType.length; ++j) - object.enumType[j] = $root.google.protobuf.EnumDescriptorProto.toObject(message.enumType[j], options); - } - if (message.service && message.service.length) { - object.service = []; - for (var j = 0; j < message.service.length; ++j) - object.service[j] = $root.google.protobuf.ServiceDescriptorProto.toObject(message.service[j], options); - } - if (message.extension && message.extension.length) { - object.extension = []; - for (var j = 0; j < message.extension.length; ++j) - object.extension[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.extension[j], options); + if (message.method && message.method.length) { + object.method = []; + for (var j = 0; j < message.method.length; ++j) + object.method[j] = $root.google.protobuf.MethodDescriptorProto.toObject(message.method[j], options); } if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.FileOptions.toObject(message.options, options); - if (message.sourceCodeInfo != null && message.hasOwnProperty("sourceCodeInfo")) - object.sourceCodeInfo = $root.google.protobuf.SourceCodeInfo.toObject(message.sourceCodeInfo, options); - if (message.publicDependency && message.publicDependency.length) { - object.publicDependency = []; - for (var j = 0; j < message.publicDependency.length; ++j) - object.publicDependency[j] = message.publicDependency[j]; - } - if (message.weakDependency && message.weakDependency.length) { - object.weakDependency = []; - for (var j = 0; j < message.weakDependency.length; ++j) - object.weakDependency[j] = message.weakDependency[j]; - } - if (message.syntax != null && message.hasOwnProperty("syntax")) - object.syntax = message.syntax; - if (message.edition != null && message.hasOwnProperty("edition")) - object.edition = message.edition; + object.options = $root.google.protobuf.ServiceOptions.toObject(message.options, options); return object; }; /** - * Converts this FileDescriptorProto to JSON. + * Converts this ServiceDescriptorProto to JSON. * @function toJSON - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @instance * @returns {Object.} JSON object */ - FileDescriptorProto.prototype.toJSON = function toJSON() { + ServiceDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FileDescriptorProto + * Gets the default type url for ServiceDescriptorProto * @function getTypeUrl - * @memberof google.protobuf.FileDescriptorProto + * @memberof google.protobuf.ServiceDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FileDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ServiceDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.FileDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.ServiceDescriptorProto"; }; - return FileDescriptorProto; + return ServiceDescriptorProto; })(); - protobuf.DescriptorProto = (function() { + protobuf.MethodDescriptorProto = (function() { /** - * Properties of a DescriptorProto. + * Properties of a MethodDescriptorProto. * @memberof google.protobuf - * @interface IDescriptorProto - * @property {string|null} [name] DescriptorProto name - * @property {Array.|null} [field] DescriptorProto field - * @property {Array.|null} [extension] DescriptorProto extension - * @property {Array.|null} [nestedType] DescriptorProto nestedType - * @property {Array.|null} [enumType] DescriptorProto enumType - * @property {Array.|null} [extensionRange] DescriptorProto extensionRange - * @property {Array.|null} [oneofDecl] DescriptorProto oneofDecl - * @property {google.protobuf.IMessageOptions|null} [options] DescriptorProto options - * @property {Array.|null} [reservedRange] DescriptorProto reservedRange - * @property {Array.|null} [reservedName] DescriptorProto reservedName + * @interface IMethodDescriptorProto + * @property {string|null} [name] MethodDescriptorProto name + * @property {string|null} [inputType] MethodDescriptorProto inputType + * @property {string|null} [outputType] MethodDescriptorProto outputType + * @property {google.protobuf.IMethodOptions|null} [options] MethodDescriptorProto options + * @property {boolean|null} [clientStreaming] MethodDescriptorProto clientStreaming + * @property {boolean|null} [serverStreaming] MethodDescriptorProto serverStreaming */ /** - * Constructs a new DescriptorProto. + * Constructs a new MethodDescriptorProto. * @memberof google.protobuf - * @classdesc Represents a DescriptorProto. - * @implements IDescriptorProto + * @classdesc Represents a MethodDescriptorProto. + * @implements IMethodDescriptorProto * @constructor - * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set */ - function DescriptorProto(properties) { - this.field = []; - this.extension = []; - this.nestedType = []; - this.enumType = []; - this.extensionRange = []; - this.oneofDecl = []; - this.reservedRange = []; - this.reservedName = []; + function MethodDescriptorProto(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -51971,168 +59737,120 @@ } /** - * DescriptorProto name. + * MethodDescriptorProto name. * @member {string} name - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.name = ""; - - /** - * DescriptorProto field. - * @member {Array.} field - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.field = $util.emptyArray; - - /** - * DescriptorProto extension. - * @member {Array.} extension - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.extension = $util.emptyArray; - - /** - * DescriptorProto nestedType. - * @member {Array.} nestedType - * @memberof google.protobuf.DescriptorProto - * @instance - */ - DescriptorProto.prototype.nestedType = $util.emptyArray; - - /** - * DescriptorProto enumType. - * @member {Array.} enumType - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.enumType = $util.emptyArray; + MethodDescriptorProto.prototype.name = ""; /** - * DescriptorProto extensionRange. - * @member {Array.} extensionRange - * @memberof google.protobuf.DescriptorProto + * MethodDescriptorProto inputType. + * @member {string} inputType + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.extensionRange = $util.emptyArray; + MethodDescriptorProto.prototype.inputType = ""; /** - * DescriptorProto oneofDecl. - * @member {Array.} oneofDecl - * @memberof google.protobuf.DescriptorProto + * MethodDescriptorProto outputType. + * @member {string} outputType + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.oneofDecl = $util.emptyArray; + MethodDescriptorProto.prototype.outputType = ""; /** - * DescriptorProto options. - * @member {google.protobuf.IMessageOptions|null|undefined} options - * @memberof google.protobuf.DescriptorProto + * MethodDescriptorProto options. + * @member {google.protobuf.IMethodOptions|null|undefined} options + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.options = null; + MethodDescriptorProto.prototype.options = null; /** - * DescriptorProto reservedRange. - * @member {Array.} reservedRange - * @memberof google.protobuf.DescriptorProto + * MethodDescriptorProto clientStreaming. + * @member {boolean} clientStreaming + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.reservedRange = $util.emptyArray; + MethodDescriptorProto.prototype.clientStreaming = false; /** - * DescriptorProto reservedName. - * @member {Array.} reservedName - * @memberof google.protobuf.DescriptorProto + * MethodDescriptorProto serverStreaming. + * @member {boolean} serverStreaming + * @memberof google.protobuf.MethodDescriptorProto * @instance */ - DescriptorProto.prototype.reservedName = $util.emptyArray; + MethodDescriptorProto.prototype.serverStreaming = false; /** - * Creates a new DescriptorProto instance using the specified properties. + * Creates a new MethodDescriptorProto instance using the specified properties. * @function create - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static - * @param {google.protobuf.IDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto} DescriptorProto instance + * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set + * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto instance */ - DescriptorProto.create = function create(properties) { - return new DescriptorProto(properties); + MethodDescriptorProto.create = function create(properties) { + return new MethodDescriptorProto(properties); }; /** - * Encodes the specified DescriptorProto message. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. + * Encodes the specified MethodDescriptorProto message. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. * @function encode - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static - * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode + * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DescriptorProto.encode = function encode(message, writer) { + MethodDescriptorProto.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.name != null && Object.hasOwnProperty.call(message, "name")) writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.field != null && message.field.length) - for (var i = 0; i < message.field.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode(message.field[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.nestedType != null && message.nestedType.length) - for (var i = 0; i < message.nestedType.length; ++i) - $root.google.protobuf.DescriptorProto.encode(message.nestedType[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.enumType != null && message.enumType.length) - for (var i = 0; i < message.enumType.length; ++i) - $root.google.protobuf.EnumDescriptorProto.encode(message.enumType[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.extensionRange != null && message.extensionRange.length) - for (var i = 0; i < message.extensionRange.length; ++i) - $root.google.protobuf.DescriptorProto.ExtensionRange.encode(message.extensionRange[i], writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); - if (message.extension != null && message.extension.length) - for (var i = 0; i < message.extension.length; ++i) - $root.google.protobuf.FieldDescriptorProto.encode(message.extension[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.inputType != null && Object.hasOwnProperty.call(message, "inputType")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.inputType); + if (message.outputType != null && Object.hasOwnProperty.call(message, "outputType")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.outputType); if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.MessageOptions.encode(message.options, writer.uint32(/* id 7, wireType 2 =*/58).fork()).ldelim(); - if (message.oneofDecl != null && message.oneofDecl.length) - for (var i = 0; i < message.oneofDecl.length; ++i) - $root.google.protobuf.OneofDescriptorProto.encode(message.oneofDecl[i], writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.reservedRange != null && message.reservedRange.length) - for (var i = 0; i < message.reservedRange.length; ++i) - $root.google.protobuf.DescriptorProto.ReservedRange.encode(message.reservedRange[i], writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); - if (message.reservedName != null && message.reservedName.length) - for (var i = 0; i < message.reservedName.length; ++i) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.reservedName[i]); + $root.google.protobuf.MethodOptions.encode(message.options, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.clientStreaming != null && Object.hasOwnProperty.call(message, "clientStreaming")) + writer.uint32(/* id 5, wireType 0 =*/40).bool(message.clientStreaming); + if (message.serverStreaming != null && Object.hasOwnProperty.call(message, "serverStreaming")) + writer.uint32(/* id 6, wireType 0 =*/48).bool(message.serverStreaming); return writer; }; /** - * Encodes the specified DescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.verify|verify} messages. + * Encodes the specified MethodDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static - * @param {google.protobuf.IDescriptorProto} message DescriptorProto message or plain object to encode + * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - DescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + MethodDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a DescriptorProto message from the specified reader or buffer. + * Decodes a MethodDescriptorProto message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto} DescriptorProto + * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DescriptorProto.decode = function decode(reader, length) { + MethodDescriptorProto.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MethodDescriptorProto(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -52141,55 +59859,23 @@ break; } case 2: { - if (!(message.field && message.field.length)) - message.field = []; - message.field.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); - break; - } - case 6: { - if (!(message.extension && message.extension.length)) - message.extension = []; - message.extension.push($root.google.protobuf.FieldDescriptorProto.decode(reader, reader.uint32())); + message.inputType = reader.string(); break; } case 3: { - if (!(message.nestedType && message.nestedType.length)) - message.nestedType = []; - message.nestedType.push($root.google.protobuf.DescriptorProto.decode(reader, reader.uint32())); + message.outputType = reader.string(); break; } case 4: { - if (!(message.enumType && message.enumType.length)) - message.enumType = []; - message.enumType.push($root.google.protobuf.EnumDescriptorProto.decode(reader, reader.uint32())); + message.options = $root.google.protobuf.MethodOptions.decode(reader, reader.uint32()); break; } case 5: { - if (!(message.extensionRange && message.extensionRange.length)) - message.extensionRange = []; - message.extensionRange.push($root.google.protobuf.DescriptorProto.ExtensionRange.decode(reader, reader.uint32())); - break; - } - case 8: { - if (!(message.oneofDecl && message.oneofDecl.length)) - message.oneofDecl = []; - message.oneofDecl.push($root.google.protobuf.OneofDescriptorProto.decode(reader, reader.uint32())); - break; - } - case 7: { - message.options = $root.google.protobuf.MessageOptions.decode(reader, reader.uint32()); - break; - } - case 9: { - if (!(message.reservedRange && message.reservedRange.length)) - message.reservedRange = []; - message.reservedRange.push($root.google.protobuf.DescriptorProto.ReservedRange.decode(reader, reader.uint32())); + message.clientStreaming = reader.bool(); break; } - case 10: { - if (!(message.reservedName && message.reservedName.length)) - message.reservedName = []; - message.reservedName.push(reader.string()); + case 6: { + message.serverStreaming = reader.bool(); break; } default: @@ -52201,815 +59887,944 @@ }; /** - * Decodes a DescriptorProto message from the specified reader or buffer, length delimited. + * Decodes a MethodDescriptorProto message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto} DescriptorProto + * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - DescriptorProto.decodeDelimited = function decodeDelimited(reader) { + MethodDescriptorProto.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a DescriptorProto message. + * Verifies a MethodDescriptorProto message. * @function verify - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - DescriptorProto.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.field != null && message.hasOwnProperty("field")) { - if (!Array.isArray(message.field)) - return "field: array expected"; - for (var i = 0; i < message.field.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify(message.field[i]); - if (error) - return "field." + error; - } - } - if (message.extension != null && message.hasOwnProperty("extension")) { - if (!Array.isArray(message.extension)) - return "extension: array expected"; - for (var i = 0; i < message.extension.length; ++i) { - var error = $root.google.protobuf.FieldDescriptorProto.verify(message.extension[i]); - if (error) - return "extension." + error; - } - } - if (message.nestedType != null && message.hasOwnProperty("nestedType")) { - if (!Array.isArray(message.nestedType)) - return "nestedType: array expected"; - for (var i = 0; i < message.nestedType.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.verify(message.nestedType[i]); - if (error) - return "nestedType." + error; - } - } - if (message.enumType != null && message.hasOwnProperty("enumType")) { - if (!Array.isArray(message.enumType)) - return "enumType: array expected"; - for (var i = 0; i < message.enumType.length; ++i) { - var error = $root.google.protobuf.EnumDescriptorProto.verify(message.enumType[i]); - if (error) - return "enumType." + error; - } - } - if (message.extensionRange != null && message.hasOwnProperty("extensionRange")) { - if (!Array.isArray(message.extensionRange)) - return "extensionRange: array expected"; - for (var i = 0; i < message.extensionRange.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.ExtensionRange.verify(message.extensionRange[i]); - if (error) - return "extensionRange." + error; - } - } - if (message.oneofDecl != null && message.hasOwnProperty("oneofDecl")) { - if (!Array.isArray(message.oneofDecl)) - return "oneofDecl: array expected"; - for (var i = 0; i < message.oneofDecl.length; ++i) { - var error = $root.google.protobuf.OneofDescriptorProto.verify(message.oneofDecl[i]); - if (error) - return "oneofDecl." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.MessageOptions.verify(message.options); - if (error) - return "options." + error; - } - if (message.reservedRange != null && message.hasOwnProperty("reservedRange")) { - if (!Array.isArray(message.reservedRange)) - return "reservedRange: array expected"; - for (var i = 0; i < message.reservedRange.length; ++i) { - var error = $root.google.protobuf.DescriptorProto.ReservedRange.verify(message.reservedRange[i]); - if (error) - return "reservedRange." + error; - } - } - if (message.reservedName != null && message.hasOwnProperty("reservedName")) { - if (!Array.isArray(message.reservedName)) - return "reservedName: array expected"; - for (var i = 0; i < message.reservedName.length; ++i) - if (!$util.isString(message.reservedName[i])) - return "reservedName: string[] expected"; - } - return null; - }; - - /** - * Creates a DescriptorProto message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto} DescriptorProto - */ - DescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.DescriptorProto) - return object; - var message = new $root.google.protobuf.DescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.field) { - if (!Array.isArray(object.field)) - throw TypeError(".google.protobuf.DescriptorProto.field: array expected"); - message.field = []; - for (var i = 0; i < object.field.length; ++i) { - if (typeof object.field[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.field: object expected"); - message.field[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.field[i]); - } - } - if (object.extension) { - if (!Array.isArray(object.extension)) - throw TypeError(".google.protobuf.DescriptorProto.extension: array expected"); - message.extension = []; - for (var i = 0; i < object.extension.length; ++i) { - if (typeof object.extension[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.extension: object expected"); - message.extension[i] = $root.google.protobuf.FieldDescriptorProto.fromObject(object.extension[i]); - } - } - if (object.nestedType) { - if (!Array.isArray(object.nestedType)) - throw TypeError(".google.protobuf.DescriptorProto.nestedType: array expected"); - message.nestedType = []; - for (var i = 0; i < object.nestedType.length; ++i) { - if (typeof object.nestedType[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.nestedType: object expected"); - message.nestedType[i] = $root.google.protobuf.DescriptorProto.fromObject(object.nestedType[i]); - } - } - if (object.enumType) { - if (!Array.isArray(object.enumType)) - throw TypeError(".google.protobuf.DescriptorProto.enumType: array expected"); - message.enumType = []; - for (var i = 0; i < object.enumType.length; ++i) { - if (typeof object.enumType[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.enumType: object expected"); - message.enumType[i] = $root.google.protobuf.EnumDescriptorProto.fromObject(object.enumType[i]); - } - } - if (object.extensionRange) { - if (!Array.isArray(object.extensionRange)) - throw TypeError(".google.protobuf.DescriptorProto.extensionRange: array expected"); - message.extensionRange = []; - for (var i = 0; i < object.extensionRange.length; ++i) { - if (typeof object.extensionRange[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.extensionRange: object expected"); - message.extensionRange[i] = $root.google.protobuf.DescriptorProto.ExtensionRange.fromObject(object.extensionRange[i]); - } - } - if (object.oneofDecl) { - if (!Array.isArray(object.oneofDecl)) - throw TypeError(".google.protobuf.DescriptorProto.oneofDecl: array expected"); - message.oneofDecl = []; - for (var i = 0; i < object.oneofDecl.length; ++i) { - if (typeof object.oneofDecl[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.oneofDecl: object expected"); - message.oneofDecl[i] = $root.google.protobuf.OneofDescriptorProto.fromObject(object.oneofDecl[i]); - } + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + MethodDescriptorProto.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.inputType != null && message.hasOwnProperty("inputType")) + if (!$util.isString(message.inputType)) + return "inputType: string expected"; + if (message.outputType != null && message.hasOwnProperty("outputType")) + if (!$util.isString(message.outputType)) + return "outputType: string expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.protobuf.MethodOptions.verify(message.options); + if (error) + return "options." + error; } + if (message.clientStreaming != null && message.hasOwnProperty("clientStreaming")) + if (typeof message.clientStreaming !== "boolean") + return "clientStreaming: boolean expected"; + if (message.serverStreaming != null && message.hasOwnProperty("serverStreaming")) + if (typeof message.serverStreaming !== "boolean") + return "serverStreaming: boolean expected"; + return null; + }; + + /** + * Creates a MethodDescriptorProto message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.MethodDescriptorProto + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto + */ + MethodDescriptorProto.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.MethodDescriptorProto) + return object; + var message = new $root.google.protobuf.MethodDescriptorProto(); + if (object.name != null) + message.name = String(object.name); + if (object.inputType != null) + message.inputType = String(object.inputType); + if (object.outputType != null) + message.outputType = String(object.outputType); if (object.options != null) { if (typeof object.options !== "object") - throw TypeError(".google.protobuf.DescriptorProto.options: object expected"); - message.options = $root.google.protobuf.MessageOptions.fromObject(object.options); - } - if (object.reservedRange) { - if (!Array.isArray(object.reservedRange)) - throw TypeError(".google.protobuf.DescriptorProto.reservedRange: array expected"); - message.reservedRange = []; - for (var i = 0; i < object.reservedRange.length; ++i) { - if (typeof object.reservedRange[i] !== "object") - throw TypeError(".google.protobuf.DescriptorProto.reservedRange: object expected"); - message.reservedRange[i] = $root.google.protobuf.DescriptorProto.ReservedRange.fromObject(object.reservedRange[i]); - } - } - if (object.reservedName) { - if (!Array.isArray(object.reservedName)) - throw TypeError(".google.protobuf.DescriptorProto.reservedName: array expected"); - message.reservedName = []; - for (var i = 0; i < object.reservedName.length; ++i) - message.reservedName[i] = String(object.reservedName[i]); + throw TypeError(".google.protobuf.MethodDescriptorProto.options: object expected"); + message.options = $root.google.protobuf.MethodOptions.fromObject(object.options); } + if (object.clientStreaming != null) + message.clientStreaming = Boolean(object.clientStreaming); + if (object.serverStreaming != null) + message.serverStreaming = Boolean(object.serverStreaming); return message; }; /** - * Creates a plain object from a DescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from a MethodDescriptorProto message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static - * @param {google.protobuf.DescriptorProto} message DescriptorProto + * @param {google.protobuf.MethodDescriptorProto} message MethodDescriptorProto * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - DescriptorProto.toObject = function toObject(message, options) { + MethodDescriptorProto.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.field = []; - object.nestedType = []; - object.enumType = []; - object.extensionRange = []; - object.extension = []; - object.oneofDecl = []; - object.reservedRange = []; - object.reservedName = []; - } if (options.defaults) { object.name = ""; + object.inputType = ""; + object.outputType = ""; object.options = null; + object.clientStreaming = false; + object.serverStreaming = false; } if (message.name != null && message.hasOwnProperty("name")) object.name = message.name; - if (message.field && message.field.length) { - object.field = []; - for (var j = 0; j < message.field.length; ++j) - object.field[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.field[j], options); - } - if (message.nestedType && message.nestedType.length) { - object.nestedType = []; - for (var j = 0; j < message.nestedType.length; ++j) - object.nestedType[j] = $root.google.protobuf.DescriptorProto.toObject(message.nestedType[j], options); - } - if (message.enumType && message.enumType.length) { - object.enumType = []; - for (var j = 0; j < message.enumType.length; ++j) - object.enumType[j] = $root.google.protobuf.EnumDescriptorProto.toObject(message.enumType[j], options); - } - if (message.extensionRange && message.extensionRange.length) { - object.extensionRange = []; - for (var j = 0; j < message.extensionRange.length; ++j) - object.extensionRange[j] = $root.google.protobuf.DescriptorProto.ExtensionRange.toObject(message.extensionRange[j], options); - } - if (message.extension && message.extension.length) { - object.extension = []; - for (var j = 0; j < message.extension.length; ++j) - object.extension[j] = $root.google.protobuf.FieldDescriptorProto.toObject(message.extension[j], options); - } + if (message.inputType != null && message.hasOwnProperty("inputType")) + object.inputType = message.inputType; + if (message.outputType != null && message.hasOwnProperty("outputType")) + object.outputType = message.outputType; if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.MessageOptions.toObject(message.options, options); - if (message.oneofDecl && message.oneofDecl.length) { - object.oneofDecl = []; - for (var j = 0; j < message.oneofDecl.length; ++j) - object.oneofDecl[j] = $root.google.protobuf.OneofDescriptorProto.toObject(message.oneofDecl[j], options); - } - if (message.reservedRange && message.reservedRange.length) { - object.reservedRange = []; - for (var j = 0; j < message.reservedRange.length; ++j) - object.reservedRange[j] = $root.google.protobuf.DescriptorProto.ReservedRange.toObject(message.reservedRange[j], options); - } - if (message.reservedName && message.reservedName.length) { - object.reservedName = []; - for (var j = 0; j < message.reservedName.length; ++j) - object.reservedName[j] = message.reservedName[j]; - } + object.options = $root.google.protobuf.MethodOptions.toObject(message.options, options); + if (message.clientStreaming != null && message.hasOwnProperty("clientStreaming")) + object.clientStreaming = message.clientStreaming; + if (message.serverStreaming != null && message.hasOwnProperty("serverStreaming")) + object.serverStreaming = message.serverStreaming; return object; }; /** - * Converts this DescriptorProto to JSON. + * Converts this MethodDescriptorProto to JSON. * @function toJSON - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @instance * @returns {Object.} JSON object */ - DescriptorProto.prototype.toJSON = function toJSON() { + MethodDescriptorProto.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for DescriptorProto + * Gets the default type url for MethodDescriptorProto * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto + * @memberof google.protobuf.MethodDescriptorProto * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - DescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + MethodDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.DescriptorProto"; + return typeUrlPrefix + "/google.protobuf.MethodDescriptorProto"; }; - DescriptorProto.ExtensionRange = (function() { + return MethodDescriptorProto; + })(); - /** - * Properties of an ExtensionRange. - * @memberof google.protobuf.DescriptorProto - * @interface IExtensionRange - * @property {number|null} [start] ExtensionRange start - * @property {number|null} [end] ExtensionRange end - * @property {google.protobuf.IExtensionRangeOptions|null} [options] ExtensionRange options - */ + protobuf.FileOptions = (function() { - /** - * Constructs a new ExtensionRange. - * @memberof google.protobuf.DescriptorProto - * @classdesc Represents an ExtensionRange. - * @implements IExtensionRange - * @constructor - * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set - */ - function ExtensionRange(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Properties of a FileOptions. + * @memberof google.protobuf + * @interface IFileOptions + * @property {string|null} [javaPackage] FileOptions javaPackage + * @property {string|null} [javaOuterClassname] FileOptions javaOuterClassname + * @property {boolean|null} [javaMultipleFiles] FileOptions javaMultipleFiles + * @property {boolean|null} [javaGenerateEqualsAndHash] FileOptions javaGenerateEqualsAndHash + * @property {boolean|null} [javaStringCheckUtf8] FileOptions javaStringCheckUtf8 + * @property {google.protobuf.FileOptions.OptimizeMode|null} [optimizeFor] FileOptions optimizeFor + * @property {string|null} [goPackage] FileOptions goPackage + * @property {boolean|null} [ccGenericServices] FileOptions ccGenericServices + * @property {boolean|null} [javaGenericServices] FileOptions javaGenericServices + * @property {boolean|null} [pyGenericServices] FileOptions pyGenericServices + * @property {boolean|null} [phpGenericServices] FileOptions phpGenericServices + * @property {boolean|null} [deprecated] FileOptions deprecated + * @property {boolean|null} [ccEnableArenas] FileOptions ccEnableArenas + * @property {string|null} [objcClassPrefix] FileOptions objcClassPrefix + * @property {string|null} [csharpNamespace] FileOptions csharpNamespace + * @property {string|null} [swiftPrefix] FileOptions swiftPrefix + * @property {string|null} [phpClassPrefix] FileOptions phpClassPrefix + * @property {string|null} [phpNamespace] FileOptions phpNamespace + * @property {string|null} [phpMetadataNamespace] FileOptions phpMetadataNamespace + * @property {string|null} [rubyPackage] FileOptions rubyPackage + * @property {Array.|null} [uninterpretedOption] FileOptions uninterpretedOption + * @property {Array.|null} [".google.api.resourceDefinition"] FileOptions .google.api.resourceDefinition + */ - /** - * ExtensionRange start. - * @member {number} start - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @instance - */ - ExtensionRange.prototype.start = 0; + /** + * Constructs a new FileOptions. + * @memberof google.protobuf + * @classdesc Represents a FileOptions. + * @implements IFileOptions + * @constructor + * @param {google.protobuf.IFileOptions=} [properties] Properties to set + */ + function FileOptions(properties) { + this.uninterpretedOption = []; + this[".google.api.resourceDefinition"] = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * ExtensionRange end. - * @member {number} end - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @instance - */ - ExtensionRange.prototype.end = 0; + /** + * FileOptions javaPackage. + * @member {string} javaPackage + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaPackage = ""; - /** - * ExtensionRange options. - * @member {google.protobuf.IExtensionRangeOptions|null|undefined} options - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @instance - */ - ExtensionRange.prototype.options = null; + /** + * FileOptions javaOuterClassname. + * @member {string} javaOuterClassname + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaOuterClassname = ""; - /** - * Creates a new ExtensionRange instance using the specified properties. - * @function create - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange instance - */ - ExtensionRange.create = function create(properties) { - return new ExtensionRange(properties); - }; + /** + * FileOptions javaMultipleFiles. + * @member {boolean} javaMultipleFiles + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaMultipleFiles = false; - /** - * Encodes the specified ExtensionRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. - * @function encode - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ExtensionRange.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.start != null && Object.hasOwnProperty.call(message, "start")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.ExtensionRangeOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - return writer; - }; + /** + * FileOptions javaGenerateEqualsAndHash. + * @member {boolean} javaGenerateEqualsAndHash + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaGenerateEqualsAndHash = false; - /** - * Encodes the specified ExtensionRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ExtensionRange.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {google.protobuf.DescriptorProto.IExtensionRange} message ExtensionRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ExtensionRange.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * FileOptions javaStringCheckUtf8. + * @member {boolean} javaStringCheckUtf8 + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaStringCheckUtf8 = false; - /** - * Decodes an ExtensionRange message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ExtensionRange.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto.ExtensionRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - case 3: { - message.options = $root.google.protobuf.ExtensionRangeOptions.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * FileOptions optimizeFor. + * @member {google.protobuf.FileOptions.OptimizeMode} optimizeFor + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.optimizeFor = 1; - /** - * Decodes an ExtensionRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ExtensionRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * FileOptions goPackage. + * @member {string} goPackage + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.goPackage = ""; - /** - * Verifies an ExtensionRange message. - * @function verify - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ExtensionRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) - return "end: integer expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.ExtensionRangeOptions.verify(message.options); - if (error) - return "options." + error; - } - return null; - }; + /** + * FileOptions ccGenericServices. + * @member {boolean} ccGenericServices + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.ccGenericServices = false; - /** - * Creates an ExtensionRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto.ExtensionRange} ExtensionRange - */ - ExtensionRange.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.DescriptorProto.ExtensionRange) - return object; - var message = new $root.google.protobuf.DescriptorProto.ExtensionRange(); - if (object.start != null) - message.start = object.start | 0; - if (object.end != null) - message.end = object.end | 0; - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.DescriptorProto.ExtensionRange.options: object expected"); - message.options = $root.google.protobuf.ExtensionRangeOptions.fromObject(object.options); - } - return message; - }; + /** + * FileOptions javaGenericServices. + * @member {boolean} javaGenericServices + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.javaGenericServices = false; - /** - * Creates a plain object from an ExtensionRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {google.protobuf.DescriptorProto.ExtensionRange} message ExtensionRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ExtensionRange.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; - object.options = null; - } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.ExtensionRangeOptions.toObject(message.options, options); - return object; - }; + /** + * FileOptions pyGenericServices. + * @member {boolean} pyGenericServices + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.pyGenericServices = false; + + /** + * FileOptions phpGenericServices. + * @member {boolean} phpGenericServices + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.phpGenericServices = false; + + /** + * FileOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.deprecated = false; + + /** + * FileOptions ccEnableArenas. + * @member {boolean} ccEnableArenas + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.ccEnableArenas = true; + + /** + * FileOptions objcClassPrefix. + * @member {string} objcClassPrefix + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.objcClassPrefix = ""; - /** - * Converts this ExtensionRange to JSON. - * @function toJSON - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @instance - * @returns {Object.} JSON object - */ - ExtensionRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * FileOptions csharpNamespace. + * @member {string} csharpNamespace + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.csharpNamespace = ""; - /** - * Gets the default type url for ExtensionRange - * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto.ExtensionRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ExtensionRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.DescriptorProto.ExtensionRange"; - }; + /** + * FileOptions swiftPrefix. + * @member {string} swiftPrefix + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.swiftPrefix = ""; - return ExtensionRange; - })(); + /** + * FileOptions phpClassPrefix. + * @member {string} phpClassPrefix + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.phpClassPrefix = ""; - DescriptorProto.ReservedRange = (function() { + /** + * FileOptions phpNamespace. + * @member {string} phpNamespace + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.phpNamespace = ""; - /** - * Properties of a ReservedRange. - * @memberof google.protobuf.DescriptorProto - * @interface IReservedRange - * @property {number|null} [start] ReservedRange start - * @property {number|null} [end] ReservedRange end - */ + /** + * FileOptions phpMetadataNamespace. + * @member {string} phpMetadataNamespace + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.phpMetadataNamespace = ""; - /** - * Constructs a new ReservedRange. - * @memberof google.protobuf.DescriptorProto - * @classdesc Represents a ReservedRange. - * @implements IReservedRange - * @constructor - * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set - */ - function ReservedRange(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * FileOptions rubyPackage. + * @member {string} rubyPackage + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.rubyPackage = ""; - /** - * ReservedRange start. - * @member {number} start - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - */ - ReservedRange.prototype.start = 0; + /** + * FileOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype.uninterpretedOption = $util.emptyArray; - /** - * ReservedRange end. - * @member {number} end - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - */ - ReservedRange.prototype.end = 0; + /** + * FileOptions .google.api.resourceDefinition. + * @member {Array.} .google.api.resourceDefinition + * @memberof google.protobuf.FileOptions + * @instance + */ + FileOptions.prototype[".google.api.resourceDefinition"] = $util.emptyArray; - /** - * Creates a new ReservedRange instance using the specified properties. - * @function create - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange=} [properties] Properties to set - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange instance - */ - ReservedRange.create = function create(properties) { - return new ReservedRange(properties); - }; + /** + * Creates a new FileOptions instance using the specified properties. + * @function create + * @memberof google.protobuf.FileOptions + * @static + * @param {google.protobuf.IFileOptions=} [properties] Properties to set + * @returns {google.protobuf.FileOptions} FileOptions instance + */ + FileOptions.create = function create(properties) { + return new FileOptions(properties); + }; - /** - * Encodes the specified ReservedRange message. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @function encode - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ReservedRange.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.start != null && Object.hasOwnProperty.call(message, "start")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); - return writer; - }; + /** + * Encodes the specified FileOptions message. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. + * @function encode + * @memberof google.protobuf.FileOptions + * @static + * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileOptions.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.javaPackage != null && Object.hasOwnProperty.call(message, "javaPackage")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.javaPackage); + if (message.javaOuterClassname != null && Object.hasOwnProperty.call(message, "javaOuterClassname")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.javaOuterClassname); + if (message.optimizeFor != null && Object.hasOwnProperty.call(message, "optimizeFor")) + writer.uint32(/* id 9, wireType 0 =*/72).int32(message.optimizeFor); + if (message.javaMultipleFiles != null && Object.hasOwnProperty.call(message, "javaMultipleFiles")) + writer.uint32(/* id 10, wireType 0 =*/80).bool(message.javaMultipleFiles); + if (message.goPackage != null && Object.hasOwnProperty.call(message, "goPackage")) + writer.uint32(/* id 11, wireType 2 =*/90).string(message.goPackage); + if (message.ccGenericServices != null && Object.hasOwnProperty.call(message, "ccGenericServices")) + writer.uint32(/* id 16, wireType 0 =*/128).bool(message.ccGenericServices); + if (message.javaGenericServices != null && Object.hasOwnProperty.call(message, "javaGenericServices")) + writer.uint32(/* id 17, wireType 0 =*/136).bool(message.javaGenericServices); + if (message.pyGenericServices != null && Object.hasOwnProperty.call(message, "pyGenericServices")) + writer.uint32(/* id 18, wireType 0 =*/144).bool(message.pyGenericServices); + if (message.javaGenerateEqualsAndHash != null && Object.hasOwnProperty.call(message, "javaGenerateEqualsAndHash")) + writer.uint32(/* id 20, wireType 0 =*/160).bool(message.javaGenerateEqualsAndHash); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 23, wireType 0 =*/184).bool(message.deprecated); + if (message.javaStringCheckUtf8 != null && Object.hasOwnProperty.call(message, "javaStringCheckUtf8")) + writer.uint32(/* id 27, wireType 0 =*/216).bool(message.javaStringCheckUtf8); + if (message.ccEnableArenas != null && Object.hasOwnProperty.call(message, "ccEnableArenas")) + writer.uint32(/* id 31, wireType 0 =*/248).bool(message.ccEnableArenas); + if (message.objcClassPrefix != null && Object.hasOwnProperty.call(message, "objcClassPrefix")) + writer.uint32(/* id 36, wireType 2 =*/290).string(message.objcClassPrefix); + if (message.csharpNamespace != null && Object.hasOwnProperty.call(message, "csharpNamespace")) + writer.uint32(/* id 37, wireType 2 =*/298).string(message.csharpNamespace); + if (message.swiftPrefix != null && Object.hasOwnProperty.call(message, "swiftPrefix")) + writer.uint32(/* id 39, wireType 2 =*/314).string(message.swiftPrefix); + if (message.phpClassPrefix != null && Object.hasOwnProperty.call(message, "phpClassPrefix")) + writer.uint32(/* id 40, wireType 2 =*/322).string(message.phpClassPrefix); + if (message.phpNamespace != null && Object.hasOwnProperty.call(message, "phpNamespace")) + writer.uint32(/* id 41, wireType 2 =*/330).string(message.phpNamespace); + if (message.phpGenericServices != null && Object.hasOwnProperty.call(message, "phpGenericServices")) + writer.uint32(/* id 42, wireType 0 =*/336).bool(message.phpGenericServices); + if (message.phpMetadataNamespace != null && Object.hasOwnProperty.call(message, "phpMetadataNamespace")) + writer.uint32(/* id 44, wireType 2 =*/354).string(message.phpMetadataNamespace); + if (message.rubyPackage != null && Object.hasOwnProperty.call(message, "rubyPackage")) + writer.uint32(/* id 45, wireType 2 =*/362).string(message.rubyPackage); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message[".google.api.resourceDefinition"] != null && message[".google.api.resourceDefinition"].length) + for (var i = 0; i < message[".google.api.resourceDefinition"].length; ++i) + $root.google.api.ResourceDescriptor.encode(message[".google.api.resourceDefinition"][i], writer.uint32(/* id 1053, wireType 2 =*/8426).fork()).ldelim(); + return writer; + }; - /** - * Encodes the specified ReservedRange message, length delimited. Does not implicitly {@link google.protobuf.DescriptorProto.ReservedRange.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.IReservedRange} message ReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - ReservedRange.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified FileOptions message, length delimited. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.FileOptions + * @static + * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + FileOptions.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes a ReservedRange message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ReservedRange.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.DescriptorProto.ReservedRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); + /** + * Decodes a FileOptions message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.FileOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.FileOptions} FileOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileOptions.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileOptions(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.javaPackage = reader.string(); + break; + } + case 8: { + message.javaOuterClassname = reader.string(); + break; + } + case 10: { + message.javaMultipleFiles = reader.bool(); + break; + } + case 20: { + message.javaGenerateEqualsAndHash = reader.bool(); + break; + } + case 27: { + message.javaStringCheckUtf8 = reader.bool(); + break; + } + case 9: { + message.optimizeFor = reader.int32(); + break; + } + case 11: { + message.goPackage = reader.string(); + break; + } + case 16: { + message.ccGenericServices = reader.bool(); + break; + } + case 17: { + message.javaGenericServices = reader.bool(); + break; + } + case 18: { + message.pyGenericServices = reader.bool(); + break; + } + case 42: { + message.phpGenericServices = reader.bool(); + break; + } + case 23: { + message.deprecated = reader.bool(); + break; + } + case 31: { + message.ccEnableArenas = reader.bool(); + break; + } + case 36: { + message.objcClassPrefix = reader.string(); + break; + } + case 37: { + message.csharpNamespace = reader.string(); + break; + } + case 39: { + message.swiftPrefix = reader.string(); + break; + } + case 40: { + message.phpClassPrefix = reader.string(); + break; + } + case 41: { + message.phpNamespace = reader.string(); + break; + } + case 44: { + message.phpMetadataNamespace = reader.string(); + break; + } + case 45: { + message.rubyPackage = reader.string(); + break; + } + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } + case 1053: { + if (!(message[".google.api.resourceDefinition"] && message[".google.api.resourceDefinition"].length)) + message[".google.api.resourceDefinition"] = []; + message[".google.api.resourceDefinition"].push($root.google.api.ResourceDescriptor.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes a ReservedRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - ReservedRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a ReservedRange message. - * @function verify - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - ReservedRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) - return "end: integer expected"; - return null; - }; + } + return message; + }; - /** - * Creates a ReservedRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.DescriptorProto.ReservedRange} ReservedRange - */ - ReservedRange.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.DescriptorProto.ReservedRange) - return object; - var message = new $root.google.protobuf.DescriptorProto.ReservedRange(); - if (object.start != null) - message.start = object.start | 0; - if (object.end != null) - message.end = object.end | 0; - return message; - }; + /** + * Decodes a FileOptions message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.FileOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.FileOptions} FileOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + FileOptions.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates a plain object from a ReservedRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {google.protobuf.DescriptorProto.ReservedRange} message ReservedRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - ReservedRange.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; + /** + * Verifies a FileOptions message. + * @function verify + * @memberof google.protobuf.FileOptions + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + FileOptions.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.javaPackage != null && message.hasOwnProperty("javaPackage")) + if (!$util.isString(message.javaPackage)) + return "javaPackage: string expected"; + if (message.javaOuterClassname != null && message.hasOwnProperty("javaOuterClassname")) + if (!$util.isString(message.javaOuterClassname)) + return "javaOuterClassname: string expected"; + if (message.javaMultipleFiles != null && message.hasOwnProperty("javaMultipleFiles")) + if (typeof message.javaMultipleFiles !== "boolean") + return "javaMultipleFiles: boolean expected"; + if (message.javaGenerateEqualsAndHash != null && message.hasOwnProperty("javaGenerateEqualsAndHash")) + if (typeof message.javaGenerateEqualsAndHash !== "boolean") + return "javaGenerateEqualsAndHash: boolean expected"; + if (message.javaStringCheckUtf8 != null && message.hasOwnProperty("javaStringCheckUtf8")) + if (typeof message.javaStringCheckUtf8 !== "boolean") + return "javaStringCheckUtf8: boolean expected"; + if (message.optimizeFor != null && message.hasOwnProperty("optimizeFor")) + switch (message.optimizeFor) { + default: + return "optimizeFor: enum value expected"; + case 1: + case 2: + case 3: + break; + } + if (message.goPackage != null && message.hasOwnProperty("goPackage")) + if (!$util.isString(message.goPackage)) + return "goPackage: string expected"; + if (message.ccGenericServices != null && message.hasOwnProperty("ccGenericServices")) + if (typeof message.ccGenericServices !== "boolean") + return "ccGenericServices: boolean expected"; + if (message.javaGenericServices != null && message.hasOwnProperty("javaGenericServices")) + if (typeof message.javaGenericServices !== "boolean") + return "javaGenericServices: boolean expected"; + if (message.pyGenericServices != null && message.hasOwnProperty("pyGenericServices")) + if (typeof message.pyGenericServices !== "boolean") + return "pyGenericServices: boolean expected"; + if (message.phpGenericServices != null && message.hasOwnProperty("phpGenericServices")) + if (typeof message.phpGenericServices !== "boolean") + return "phpGenericServices: boolean expected"; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.ccEnableArenas != null && message.hasOwnProperty("ccEnableArenas")) + if (typeof message.ccEnableArenas !== "boolean") + return "ccEnableArenas: boolean expected"; + if (message.objcClassPrefix != null && message.hasOwnProperty("objcClassPrefix")) + if (!$util.isString(message.objcClassPrefix)) + return "objcClassPrefix: string expected"; + if (message.csharpNamespace != null && message.hasOwnProperty("csharpNamespace")) + if (!$util.isString(message.csharpNamespace)) + return "csharpNamespace: string expected"; + if (message.swiftPrefix != null && message.hasOwnProperty("swiftPrefix")) + if (!$util.isString(message.swiftPrefix)) + return "swiftPrefix: string expected"; + if (message.phpClassPrefix != null && message.hasOwnProperty("phpClassPrefix")) + if (!$util.isString(message.phpClassPrefix)) + return "phpClassPrefix: string expected"; + if (message.phpNamespace != null && message.hasOwnProperty("phpNamespace")) + if (!$util.isString(message.phpNamespace)) + return "phpNamespace: string expected"; + if (message.phpMetadataNamespace != null && message.hasOwnProperty("phpMetadataNamespace")) + if (!$util.isString(message.phpMetadataNamespace)) + return "phpMetadataNamespace: string expected"; + if (message.rubyPackage != null && message.hasOwnProperty("rubyPackage")) + if (!$util.isString(message.rubyPackage)) + return "rubyPackage: string expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (error) + return "uninterpretedOption." + error; } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; + } + if (message[".google.api.resourceDefinition"] != null && message.hasOwnProperty(".google.api.resourceDefinition")) { + if (!Array.isArray(message[".google.api.resourceDefinition"])) + return ".google.api.resourceDefinition: array expected"; + for (var i = 0; i < message[".google.api.resourceDefinition"].length; ++i) { + var error = $root.google.api.ResourceDescriptor.verify(message[".google.api.resourceDefinition"][i]); + if (error) + return ".google.api.resourceDefinition." + error; + } + } + return null; + }; + + /** + * Creates a FileOptions message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.FileOptions + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.FileOptions} FileOptions + */ + FileOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FileOptions) return object; - }; + var message = new $root.google.protobuf.FileOptions(); + if (object.javaPackage != null) + message.javaPackage = String(object.javaPackage); + if (object.javaOuterClassname != null) + message.javaOuterClassname = String(object.javaOuterClassname); + if (object.javaMultipleFiles != null) + message.javaMultipleFiles = Boolean(object.javaMultipleFiles); + if (object.javaGenerateEqualsAndHash != null) + message.javaGenerateEqualsAndHash = Boolean(object.javaGenerateEqualsAndHash); + if (object.javaStringCheckUtf8 != null) + message.javaStringCheckUtf8 = Boolean(object.javaStringCheckUtf8); + switch (object.optimizeFor) { + default: + if (typeof object.optimizeFor === "number") { + message.optimizeFor = object.optimizeFor; + break; + } + break; + case "SPEED": + case 1: + message.optimizeFor = 1; + break; + case "CODE_SIZE": + case 2: + message.optimizeFor = 2; + break; + case "LITE_RUNTIME": + case 3: + message.optimizeFor = 3; + break; + } + if (object.goPackage != null) + message.goPackage = String(object.goPackage); + if (object.ccGenericServices != null) + message.ccGenericServices = Boolean(object.ccGenericServices); + if (object.javaGenericServices != null) + message.javaGenericServices = Boolean(object.javaGenericServices); + if (object.pyGenericServices != null) + message.pyGenericServices = Boolean(object.pyGenericServices); + if (object.phpGenericServices != null) + message.phpGenericServices = Boolean(object.phpGenericServices); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.ccEnableArenas != null) + message.ccEnableArenas = Boolean(object.ccEnableArenas); + if (object.objcClassPrefix != null) + message.objcClassPrefix = String(object.objcClassPrefix); + if (object.csharpNamespace != null) + message.csharpNamespace = String(object.csharpNamespace); + if (object.swiftPrefix != null) + message.swiftPrefix = String(object.swiftPrefix); + if (object.phpClassPrefix != null) + message.phpClassPrefix = String(object.phpClassPrefix); + if (object.phpNamespace != null) + message.phpNamespace = String(object.phpNamespace); + if (object.phpMetadataNamespace != null) + message.phpMetadataNamespace = String(object.phpMetadataNamespace); + if (object.rubyPackage != null) + message.rubyPackage = String(object.rubyPackage); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.FileOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.FileOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + } + } + if (object[".google.api.resourceDefinition"]) { + if (!Array.isArray(object[".google.api.resourceDefinition"])) + throw TypeError(".google.protobuf.FileOptions..google.api.resourceDefinition: array expected"); + message[".google.api.resourceDefinition"] = []; + for (var i = 0; i < object[".google.api.resourceDefinition"].length; ++i) { + if (typeof object[".google.api.resourceDefinition"][i] !== "object") + throw TypeError(".google.protobuf.FileOptions..google.api.resourceDefinition: object expected"); + message[".google.api.resourceDefinition"][i] = $root.google.api.ResourceDescriptor.fromObject(object[".google.api.resourceDefinition"][i]); + } + } + return message; + }; - /** - * Converts this ReservedRange to JSON. - * @function toJSON - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @instance - * @returns {Object.} JSON object - */ - ReservedRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Creates a plain object from a FileOptions message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.FileOptions + * @static + * @param {google.protobuf.FileOptions} message FileOptions + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + FileOptions.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.uninterpretedOption = []; + object[".google.api.resourceDefinition"] = []; + } + if (options.defaults) { + object.javaPackage = ""; + object.javaOuterClassname = ""; + object.optimizeFor = options.enums === String ? "SPEED" : 1; + object.javaMultipleFiles = false; + object.goPackage = ""; + object.ccGenericServices = false; + object.javaGenericServices = false; + object.pyGenericServices = false; + object.javaGenerateEqualsAndHash = false; + object.deprecated = false; + object.javaStringCheckUtf8 = false; + object.ccEnableArenas = true; + object.objcClassPrefix = ""; + object.csharpNamespace = ""; + object.swiftPrefix = ""; + object.phpClassPrefix = ""; + object.phpNamespace = ""; + object.phpGenericServices = false; + object.phpMetadataNamespace = ""; + object.rubyPackage = ""; + } + if (message.javaPackage != null && message.hasOwnProperty("javaPackage")) + object.javaPackage = message.javaPackage; + if (message.javaOuterClassname != null && message.hasOwnProperty("javaOuterClassname")) + object.javaOuterClassname = message.javaOuterClassname; + if (message.optimizeFor != null && message.hasOwnProperty("optimizeFor")) + object.optimizeFor = options.enums === String ? $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] === undefined ? message.optimizeFor : $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] : message.optimizeFor; + if (message.javaMultipleFiles != null && message.hasOwnProperty("javaMultipleFiles")) + object.javaMultipleFiles = message.javaMultipleFiles; + if (message.goPackage != null && message.hasOwnProperty("goPackage")) + object.goPackage = message.goPackage; + if (message.ccGenericServices != null && message.hasOwnProperty("ccGenericServices")) + object.ccGenericServices = message.ccGenericServices; + if (message.javaGenericServices != null && message.hasOwnProperty("javaGenericServices")) + object.javaGenericServices = message.javaGenericServices; + if (message.pyGenericServices != null && message.hasOwnProperty("pyGenericServices")) + object.pyGenericServices = message.pyGenericServices; + if (message.javaGenerateEqualsAndHash != null && message.hasOwnProperty("javaGenerateEqualsAndHash")) + object.javaGenerateEqualsAndHash = message.javaGenerateEqualsAndHash; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.javaStringCheckUtf8 != null && message.hasOwnProperty("javaStringCheckUtf8")) + object.javaStringCheckUtf8 = message.javaStringCheckUtf8; + if (message.ccEnableArenas != null && message.hasOwnProperty("ccEnableArenas")) + object.ccEnableArenas = message.ccEnableArenas; + if (message.objcClassPrefix != null && message.hasOwnProperty("objcClassPrefix")) + object.objcClassPrefix = message.objcClassPrefix; + if (message.csharpNamespace != null && message.hasOwnProperty("csharpNamespace")) + object.csharpNamespace = message.csharpNamespace; + if (message.swiftPrefix != null && message.hasOwnProperty("swiftPrefix")) + object.swiftPrefix = message.swiftPrefix; + if (message.phpClassPrefix != null && message.hasOwnProperty("phpClassPrefix")) + object.phpClassPrefix = message.phpClassPrefix; + if (message.phpNamespace != null && message.hasOwnProperty("phpNamespace")) + object.phpNamespace = message.phpNamespace; + if (message.phpGenericServices != null && message.hasOwnProperty("phpGenericServices")) + object.phpGenericServices = message.phpGenericServices; + if (message.phpMetadataNamespace != null && message.hasOwnProperty("phpMetadataNamespace")) + object.phpMetadataNamespace = message.phpMetadataNamespace; + if (message.rubyPackage != null && message.hasOwnProperty("rubyPackage")) + object.rubyPackage = message.rubyPackage; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + } + if (message[".google.api.resourceDefinition"] && message[".google.api.resourceDefinition"].length) { + object[".google.api.resourceDefinition"] = []; + for (var j = 0; j < message[".google.api.resourceDefinition"].length; ++j) + object[".google.api.resourceDefinition"][j] = $root.google.api.ResourceDescriptor.toObject(message[".google.api.resourceDefinition"][j], options); + } + return object; + }; - /** - * Gets the default type url for ReservedRange - * @function getTypeUrl - * @memberof google.protobuf.DescriptorProto.ReservedRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - ReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.DescriptorProto.ReservedRange"; - }; + /** + * Converts this FileOptions to JSON. + * @function toJSON + * @memberof google.protobuf.FileOptions + * @instance + * @returns {Object.} JSON object + */ + FileOptions.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - return ReservedRange; + /** + * Gets the default type url for FileOptions + * @function getTypeUrl + * @memberof google.protobuf.FileOptions + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + FileOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.FileOptions"; + }; + + /** + * OptimizeMode enum. + * @name google.protobuf.FileOptions.OptimizeMode + * @enum {number} + * @property {number} SPEED=1 SPEED value + * @property {number} CODE_SIZE=2 CODE_SIZE value + * @property {number} LITE_RUNTIME=3 LITE_RUNTIME value + */ + FileOptions.OptimizeMode = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[1] = "SPEED"] = 1; + values[valuesById[2] = "CODE_SIZE"] = 2; + values[valuesById[3] = "LITE_RUNTIME"] = 3; + return values; })(); - return DescriptorProto; + return FileOptions; })(); - protobuf.ExtensionRangeOptions = (function() { + protobuf.MessageOptions = (function() { /** - * Properties of an ExtensionRangeOptions. + * Properties of a MessageOptions. * @memberof google.protobuf - * @interface IExtensionRangeOptions - * @property {Array.|null} [uninterpretedOption] ExtensionRangeOptions uninterpretedOption + * @interface IMessageOptions + * @property {boolean|null} [messageSetWireFormat] MessageOptions messageSetWireFormat + * @property {boolean|null} [noStandardDescriptorAccessor] MessageOptions noStandardDescriptorAccessor + * @property {boolean|null} [deprecated] MessageOptions deprecated + * @property {boolean|null} [mapEntry] MessageOptions mapEntry + * @property {Array.|null} [uninterpretedOption] MessageOptions uninterpretedOption + * @property {google.api.IResourceDescriptor|null} [".google.api.resource"] MessageOptions .google.api.resource */ /** - * Constructs a new ExtensionRangeOptions. + * Constructs a new MessageOptions. * @memberof google.protobuf - * @classdesc Represents an ExtensionRangeOptions. - * @implements IExtensionRangeOptions + * @classdesc Represents a MessageOptions. + * @implements IMessageOptions * @constructor - * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set + * @param {google.protobuf.IMessageOptions=} [properties] Properties to set */ - function ExtensionRangeOptions(properties) { + function MessageOptions(properties) { this.uninterpretedOption = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) @@ -53018,80 +60833,150 @@ } /** - * ExtensionRangeOptions uninterpretedOption. + * MessageOptions messageSetWireFormat. + * @member {boolean} messageSetWireFormat + * @memberof google.protobuf.MessageOptions + * @instance + */ + MessageOptions.prototype.messageSetWireFormat = false; + + /** + * MessageOptions noStandardDescriptorAccessor. + * @member {boolean} noStandardDescriptorAccessor + * @memberof google.protobuf.MessageOptions + * @instance + */ + MessageOptions.prototype.noStandardDescriptorAccessor = false; + + /** + * MessageOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.MessageOptions + * @instance + */ + MessageOptions.prototype.deprecated = false; + + /** + * MessageOptions mapEntry. + * @member {boolean} mapEntry + * @memberof google.protobuf.MessageOptions + * @instance + */ + MessageOptions.prototype.mapEntry = false; + + /** + * MessageOptions uninterpretedOption. * @member {Array.} uninterpretedOption - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @instance */ - ExtensionRangeOptions.prototype.uninterpretedOption = $util.emptyArray; + MessageOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * Creates a new ExtensionRangeOptions instance using the specified properties. + * MessageOptions .google.api.resource. + * @member {google.api.IResourceDescriptor|null|undefined} .google.api.resource + * @memberof google.protobuf.MessageOptions + * @instance + */ + MessageOptions.prototype[".google.api.resource"] = null; + + /** + * Creates a new MessageOptions instance using the specified properties. * @function create - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static - * @param {google.protobuf.IExtensionRangeOptions=} [properties] Properties to set - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions instance + * @param {google.protobuf.IMessageOptions=} [properties] Properties to set + * @returns {google.protobuf.MessageOptions} MessageOptions instance */ - ExtensionRangeOptions.create = function create(properties) { - return new ExtensionRangeOptions(properties); + MessageOptions.create = function create(properties) { + return new MessageOptions(properties); }; /** - * Encodes the specified ExtensionRangeOptions message. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. + * Encodes the specified MessageOptions message. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static - * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode + * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExtensionRangeOptions.encode = function encode(message, writer) { + MessageOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); + if (message.messageSetWireFormat != null && Object.hasOwnProperty.call(message, "messageSetWireFormat")) + writer.uint32(/* id 1, wireType 0 =*/8).bool(message.messageSetWireFormat); + if (message.noStandardDescriptorAccessor != null && Object.hasOwnProperty.call(message, "noStandardDescriptorAccessor")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.noStandardDescriptorAccessor); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); + if (message.mapEntry != null && Object.hasOwnProperty.call(message, "mapEntry")) + writer.uint32(/* id 7, wireType 0 =*/56).bool(message.mapEntry); if (message.uninterpretedOption != null && message.uninterpretedOption.length) for (var i = 0; i < message.uninterpretedOption.length; ++i) $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message[".google.api.resource"] != null && Object.hasOwnProperty.call(message, ".google.api.resource")) + $root.google.api.ResourceDescriptor.encode(message[".google.api.resource"], writer.uint32(/* id 1053, wireType 2 =*/8426).fork()).ldelim(); return writer; }; /** - * Encodes the specified ExtensionRangeOptions message, length delimited. Does not implicitly {@link google.protobuf.ExtensionRangeOptions.verify|verify} messages. + * Encodes the specified MessageOptions message, length delimited. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static - * @param {google.protobuf.IExtensionRangeOptions} message ExtensionRangeOptions message or plain object to encode + * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ExtensionRangeOptions.encodeDelimited = function encodeDelimited(message, writer) { + MessageOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer. + * Decodes a MessageOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions + * @returns {google.protobuf.MessageOptions} MessageOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExtensionRangeOptions.decode = function decode(reader, length) { + MessageOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ExtensionRangeOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MessageOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { + case 1: { + message.messageSetWireFormat = reader.bool(); + break; + } + case 2: { + message.noStandardDescriptorAccessor = reader.bool(); + break; + } + case 3: { + message.deprecated = reader.bool(); + break; + } + case 7: { + message.mapEntry = reader.bool(); + break; + } case 999: { if (!(message.uninterpretedOption && message.uninterpretedOption.length)) message.uninterpretedOption = []; message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } + case 1053: { + message[".google.api.resource"] = $root.google.api.ResourceDescriptor.decode(reader, reader.uint32()); + break; + } default: reader.skipType(tag & 7); break; @@ -53101,32 +60986,44 @@ }; /** - * Decodes an ExtensionRangeOptions message from the specified reader or buffer, length delimited. + * Decodes a MessageOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions + * @returns {google.protobuf.MessageOptions} MessageOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ExtensionRangeOptions.decodeDelimited = function decodeDelimited(reader) { + MessageOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an ExtensionRangeOptions message. + * Verifies a MessageOptions message. * @function verify - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ExtensionRangeOptions.verify = function verify(message) { + MessageOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; + if (message.messageSetWireFormat != null && message.hasOwnProperty("messageSetWireFormat")) + if (typeof message.messageSetWireFormat !== "boolean") + return "messageSetWireFormat: boolean expected"; + if (message.noStandardDescriptorAccessor != null && message.hasOwnProperty("noStandardDescriptorAccessor")) + if (typeof message.noStandardDescriptorAccessor !== "boolean") + return "noStandardDescriptorAccessor: boolean expected"; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) + if (typeof message.mapEntry !== "boolean") + return "mapEntry: boolean expected"; if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { if (!Array.isArray(message.uninterpretedOption)) return "uninterpretedOption: array expected"; @@ -53136,114 +61033,150 @@ return "uninterpretedOption." + error; } } + if (message[".google.api.resource"] != null && message.hasOwnProperty(".google.api.resource")) { + var error = $root.google.api.ResourceDescriptor.verify(message[".google.api.resource"]); + if (error) + return ".google.api.resource." + error; + } return null; }; /** - * Creates an ExtensionRangeOptions message from a plain object. Also converts values to their respective internal types. + * Creates a MessageOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.ExtensionRangeOptions} ExtensionRangeOptions + * @returns {google.protobuf.MessageOptions} MessageOptions */ - ExtensionRangeOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ExtensionRangeOptions) + MessageOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.MessageOptions) return object; - var message = new $root.google.protobuf.ExtensionRangeOptions(); + var message = new $root.google.protobuf.MessageOptions(); + if (object.messageSetWireFormat != null) + message.messageSetWireFormat = Boolean(object.messageSetWireFormat); + if (object.noStandardDescriptorAccessor != null) + message.noStandardDescriptorAccessor = Boolean(object.noStandardDescriptorAccessor); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.mapEntry != null) + message.mapEntry = Boolean(object.mapEntry); if (object.uninterpretedOption) { if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.ExtensionRangeOptions.uninterpretedOption: array expected"); + throw TypeError(".google.protobuf.MessageOptions.uninterpretedOption: array expected"); message.uninterpretedOption = []; for (var i = 0; i < object.uninterpretedOption.length; ++i) { if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.ExtensionRangeOptions.uninterpretedOption: object expected"); + throw TypeError(".google.protobuf.MessageOptions.uninterpretedOption: object expected"); message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); } } + if (object[".google.api.resource"] != null) { + if (typeof object[".google.api.resource"] !== "object") + throw TypeError(".google.protobuf.MessageOptions..google.api.resource: object expected"); + message[".google.api.resource"] = $root.google.api.ResourceDescriptor.fromObject(object[".google.api.resource"]); + } return message; }; /** - * Creates a plain object from an ExtensionRangeOptions message. Also converts values to other types if specified. + * Creates a plain object from a MessageOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static - * @param {google.protobuf.ExtensionRangeOptions} message ExtensionRangeOptions + * @param {google.protobuf.MessageOptions} message MessageOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ExtensionRangeOptions.toObject = function toObject(message, options) { + MessageOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) object.uninterpretedOption = []; + if (options.defaults) { + object.messageSetWireFormat = false; + object.noStandardDescriptorAccessor = false; + object.deprecated = false; + object.mapEntry = false; + object[".google.api.resource"] = null; + } + if (message.messageSetWireFormat != null && message.hasOwnProperty("messageSetWireFormat")) + object.messageSetWireFormat = message.messageSetWireFormat; + if (message.noStandardDescriptorAccessor != null && message.hasOwnProperty("noStandardDescriptorAccessor")) + object.noStandardDescriptorAccessor = message.noStandardDescriptorAccessor; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) + object.mapEntry = message.mapEntry; if (message.uninterpretedOption && message.uninterpretedOption.length) { object.uninterpretedOption = []; for (var j = 0; j < message.uninterpretedOption.length; ++j) object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } + if (message[".google.api.resource"] != null && message.hasOwnProperty(".google.api.resource")) + object[".google.api.resource"] = $root.google.api.ResourceDescriptor.toObject(message[".google.api.resource"], options); return object; }; /** - * Converts this ExtensionRangeOptions to JSON. + * Converts this MessageOptions to JSON. * @function toJSON - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @instance * @returns {Object.} JSON object */ - ExtensionRangeOptions.prototype.toJSON = function toJSON() { + MessageOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ExtensionRangeOptions + * Gets the default type url for MessageOptions * @function getTypeUrl - * @memberof google.protobuf.ExtensionRangeOptions + * @memberof google.protobuf.MessageOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ExtensionRangeOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + MessageOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.ExtensionRangeOptions"; + return typeUrlPrefix + "/google.protobuf.MessageOptions"; }; - return ExtensionRangeOptions; + return MessageOptions; })(); - protobuf.FieldDescriptorProto = (function() { + protobuf.FieldOptions = (function() { /** - * Properties of a FieldDescriptorProto. + * Properties of a FieldOptions. * @memberof google.protobuf - * @interface IFieldDescriptorProto - * @property {string|null} [name] FieldDescriptorProto name - * @property {number|null} [number] FieldDescriptorProto number - * @property {google.protobuf.FieldDescriptorProto.Label|null} [label] FieldDescriptorProto label - * @property {google.protobuf.FieldDescriptorProto.Type|null} [type] FieldDescriptorProto type - * @property {string|null} [typeName] FieldDescriptorProto typeName - * @property {string|null} [extendee] FieldDescriptorProto extendee - * @property {string|null} [defaultValue] FieldDescriptorProto defaultValue - * @property {number|null} [oneofIndex] FieldDescriptorProto oneofIndex - * @property {string|null} [jsonName] FieldDescriptorProto jsonName - * @property {google.protobuf.IFieldOptions|null} [options] FieldDescriptorProto options - * @property {boolean|null} [proto3Optional] FieldDescriptorProto proto3Optional + * @interface IFieldOptions + * @property {google.protobuf.FieldOptions.CType|null} [ctype] FieldOptions ctype + * @property {boolean|null} [packed] FieldOptions packed + * @property {google.protobuf.FieldOptions.JSType|null} [jstype] FieldOptions jstype + * @property {boolean|null} [lazy] FieldOptions lazy + * @property {boolean|null} [unverifiedLazy] FieldOptions unverifiedLazy + * @property {boolean|null} [deprecated] FieldOptions deprecated + * @property {boolean|null} [weak] FieldOptions weak + * @property {Array.|null} [uninterpretedOption] FieldOptions uninterpretedOption + * @property {Array.|null} [".google.api.fieldBehavior"] FieldOptions .google.api.fieldBehavior + * @property {google.api.IResourceReference|null} [".google.api.resourceReference"] FieldOptions .google.api.resourceReference */ /** - * Constructs a new FieldDescriptorProto. + * Constructs a new FieldOptions. * @memberof google.protobuf - * @classdesc Represents a FieldDescriptorProto. - * @implements IFieldDescriptorProto + * @classdesc Represents a FieldOptions. + * @implements IFieldOptions * @constructor - * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IFieldOptions=} [properties] Properties to set */ - function FieldDescriptorProto(properties) { + function FieldOptions(properties) { + this.uninterpretedOption = []; + this[".google.api.fieldBehavior"] = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -53251,215 +61184,215 @@ } /** - * FieldDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.FieldDescriptorProto - * @instance - */ - FieldDescriptorProto.prototype.name = ""; - - /** - * FieldDescriptorProto number. - * @member {number} number - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions ctype. + * @member {google.protobuf.FieldOptions.CType} ctype + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.number = 0; + FieldOptions.prototype.ctype = 0; /** - * FieldDescriptorProto label. - * @member {google.protobuf.FieldDescriptorProto.Label} label - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions packed. + * @member {boolean} packed + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.label = 1; + FieldOptions.prototype.packed = false; /** - * FieldDescriptorProto type. - * @member {google.protobuf.FieldDescriptorProto.Type} type - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions jstype. + * @member {google.protobuf.FieldOptions.JSType} jstype + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.type = 1; + FieldOptions.prototype.jstype = 0; /** - * FieldDescriptorProto typeName. - * @member {string} typeName - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions lazy. + * @member {boolean} lazy + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.typeName = ""; + FieldOptions.prototype.lazy = false; /** - * FieldDescriptorProto extendee. - * @member {string} extendee - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions unverifiedLazy. + * @member {boolean} unverifiedLazy + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.extendee = ""; + FieldOptions.prototype.unverifiedLazy = false; /** - * FieldDescriptorProto defaultValue. - * @member {string} defaultValue - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.defaultValue = ""; + FieldOptions.prototype.deprecated = false; /** - * FieldDescriptorProto oneofIndex. - * @member {number} oneofIndex - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions weak. + * @member {boolean} weak + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.oneofIndex = 0; + FieldOptions.prototype.weak = false; /** - * FieldDescriptorProto jsonName. - * @member {string} jsonName - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.jsonName = ""; + FieldOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * FieldDescriptorProto options. - * @member {google.protobuf.IFieldOptions|null|undefined} options - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions .google.api.fieldBehavior. + * @member {Array.} .google.api.fieldBehavior + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.options = null; + FieldOptions.prototype[".google.api.fieldBehavior"] = $util.emptyArray; /** - * FieldDescriptorProto proto3Optional. - * @member {boolean} proto3Optional - * @memberof google.protobuf.FieldDescriptorProto + * FieldOptions .google.api.resourceReference. + * @member {google.api.IResourceReference|null|undefined} .google.api.resourceReference + * @memberof google.protobuf.FieldOptions * @instance */ - FieldDescriptorProto.prototype.proto3Optional = false; + FieldOptions.prototype[".google.api.resourceReference"] = null; /** - * Creates a new FieldDescriptorProto instance using the specified properties. + * Creates a new FieldOptions instance using the specified properties. * @function create - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static - * @param {google.protobuf.IFieldDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto instance + * @param {google.protobuf.IFieldOptions=} [properties] Properties to set + * @returns {google.protobuf.FieldOptions} FieldOptions instance */ - FieldDescriptorProto.create = function create(properties) { - return new FieldDescriptorProto(properties); + FieldOptions.create = function create(properties) { + return new FieldOptions(properties); }; /** - * Encodes the specified FieldDescriptorProto message. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. + * Encodes the specified FieldOptions message. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static - * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode + * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldDescriptorProto.encode = function encode(message, writer) { + FieldOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.extendee != null && Object.hasOwnProperty.call(message, "extendee")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.extendee); - if (message.number != null && Object.hasOwnProperty.call(message, "number")) - writer.uint32(/* id 3, wireType 0 =*/24).int32(message.number); - if (message.label != null && Object.hasOwnProperty.call(message, "label")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.label); - if (message.type != null && Object.hasOwnProperty.call(message, "type")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.type); - if (message.typeName != null && Object.hasOwnProperty.call(message, "typeName")) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.typeName); - if (message.defaultValue != null && Object.hasOwnProperty.call(message, "defaultValue")) - writer.uint32(/* id 7, wireType 2 =*/58).string(message.defaultValue); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.FieldOptions.encode(message.options, writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); - if (message.oneofIndex != null && Object.hasOwnProperty.call(message, "oneofIndex")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.oneofIndex); - if (message.jsonName != null && Object.hasOwnProperty.call(message, "jsonName")) - writer.uint32(/* id 10, wireType 2 =*/82).string(message.jsonName); - if (message.proto3Optional != null && Object.hasOwnProperty.call(message, "proto3Optional")) - writer.uint32(/* id 17, wireType 0 =*/136).bool(message.proto3Optional); + if (message.ctype != null && Object.hasOwnProperty.call(message, "ctype")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.ctype); + if (message.packed != null && Object.hasOwnProperty.call(message, "packed")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.packed); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); + if (message.lazy != null && Object.hasOwnProperty.call(message, "lazy")) + writer.uint32(/* id 5, wireType 0 =*/40).bool(message.lazy); + if (message.jstype != null && Object.hasOwnProperty.call(message, "jstype")) + writer.uint32(/* id 6, wireType 0 =*/48).int32(message.jstype); + if (message.weak != null && Object.hasOwnProperty.call(message, "weak")) + writer.uint32(/* id 10, wireType 0 =*/80).bool(message.weak); + if (message.unverifiedLazy != null && Object.hasOwnProperty.call(message, "unverifiedLazy")) + writer.uint32(/* id 15, wireType 0 =*/120).bool(message.unverifiedLazy); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message[".google.api.fieldBehavior"] != null && message[".google.api.fieldBehavior"].length) { + writer.uint32(/* id 1052, wireType 2 =*/8418).fork(); + for (var i = 0; i < message[".google.api.fieldBehavior"].length; ++i) + writer.int32(message[".google.api.fieldBehavior"][i]); + writer.ldelim(); + } + if (message[".google.api.resourceReference"] != null && Object.hasOwnProperty.call(message, ".google.api.resourceReference")) + $root.google.api.ResourceReference.encode(message[".google.api.resourceReference"], writer.uint32(/* id 1055, wireType 2 =*/8442).fork()).ldelim(); return writer; }; /** - * Encodes the specified FieldDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.FieldDescriptorProto.verify|verify} messages. + * Encodes the specified FieldOptions message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static - * @param {google.protobuf.IFieldDescriptorProto} message FieldDescriptorProto message or plain object to encode + * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + FieldOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer. + * Decodes a FieldOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto + * @returns {google.protobuf.FieldOptions} FieldOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldDescriptorProto.decode = function decode(reader, length) { + FieldOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); + message.ctype = reader.int32(); break; } - case 3: { - message.number = reader.int32(); + case 2: { + message.packed = reader.bool(); break; } - case 4: { - message.label = reader.int32(); + case 6: { + message.jstype = reader.int32(); break; } case 5: { - message.type = reader.int32(); - break; - } - case 6: { - message.typeName = reader.string(); + message.lazy = reader.bool(); break; } - case 2: { - message.extendee = reader.string(); + case 15: { + message.unverifiedLazy = reader.bool(); break; } - case 7: { - message.defaultValue = reader.string(); + case 3: { + message.deprecated = reader.bool(); break; } - case 9: { - message.oneofIndex = reader.int32(); + case 10: { + message.weak = reader.bool(); break; } - case 10: { - message.jsonName = reader.string(); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } - case 8: { - message.options = $root.google.protobuf.FieldOptions.decode(reader, reader.uint32()); + case 1052: { + if (!(message[".google.api.fieldBehavior"] && message[".google.api.fieldBehavior"].length)) + message[".google.api.fieldBehavior"] = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message[".google.api.fieldBehavior"].push(reader.int32()); + } else + message[".google.api.fieldBehavior"].push(reader.int32()); break; } - case 17: { - message.proto3Optional = reader.bool(); + case 1055: { + message[".google.api.resourceReference"] = $root.google.api.ResourceReference.decode(reader, reader.uint32()); break; } default: @@ -53471,394 +61404,361 @@ }; /** - * Decodes a FieldDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes a FieldOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto + * @returns {google.protobuf.FieldOptions} FieldOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FieldDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + FieldOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FieldDescriptorProto message. + * Verifies a FieldOptions message. * @function verify - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FieldDescriptorProto.verify = function verify(message) { + FieldOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.number != null && message.hasOwnProperty("number")) - if (!$util.isInteger(message.number)) - return "number: integer expected"; - if (message.label != null && message.hasOwnProperty("label")) - switch (message.label) { + if (message.ctype != null && message.hasOwnProperty("ctype")) + switch (message.ctype) { default: - return "label: enum value expected"; + return "ctype: enum value expected"; + case 0: case 1: case 2: - case 3: break; } - if (message.type != null && message.hasOwnProperty("type")) - switch (message.type) { + if (message.packed != null && message.hasOwnProperty("packed")) + if (typeof message.packed !== "boolean") + return "packed: boolean expected"; + if (message.jstype != null && message.hasOwnProperty("jstype")) + switch (message.jstype) { default: - return "type: enum value expected"; + return "jstype: enum value expected"; + case 0: case 1: case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - case 8: - case 9: - case 10: - case 11: - case 12: - case 13: - case 14: - case 15: - case 16: - case 17: - case 18: break; } - if (message.typeName != null && message.hasOwnProperty("typeName")) - if (!$util.isString(message.typeName)) - return "typeName: string expected"; - if (message.extendee != null && message.hasOwnProperty("extendee")) - if (!$util.isString(message.extendee)) - return "extendee: string expected"; - if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) - if (!$util.isString(message.defaultValue)) - return "defaultValue: string expected"; - if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) - if (!$util.isInteger(message.oneofIndex)) - return "oneofIndex: integer expected"; - if (message.jsonName != null && message.hasOwnProperty("jsonName")) - if (!$util.isString(message.jsonName)) - return "jsonName: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.FieldOptions.verify(message.options); + if (message.lazy != null && message.hasOwnProperty("lazy")) + if (typeof message.lazy !== "boolean") + return "lazy: boolean expected"; + if (message.unverifiedLazy != null && message.hasOwnProperty("unverifiedLazy")) + if (typeof message.unverifiedLazy !== "boolean") + return "unverifiedLazy: boolean expected"; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.weak != null && message.hasOwnProperty("weak")) + if (typeof message.weak !== "boolean") + return "weak: boolean expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (error) + return "uninterpretedOption." + error; + } + } + if (message[".google.api.fieldBehavior"] != null && message.hasOwnProperty(".google.api.fieldBehavior")) { + if (!Array.isArray(message[".google.api.fieldBehavior"])) + return ".google.api.fieldBehavior: array expected"; + for (var i = 0; i < message[".google.api.fieldBehavior"].length; ++i) + switch (message[".google.api.fieldBehavior"][i]) { + default: + return ".google.api.fieldBehavior: enum value[] expected"; + case 0: + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + break; + } + } + if (message[".google.api.resourceReference"] != null && message.hasOwnProperty(".google.api.resourceReference")) { + var error = $root.google.api.ResourceReference.verify(message[".google.api.resourceReference"]); if (error) - return "options." + error; + return ".google.api.resourceReference." + error; } - if (message.proto3Optional != null && message.hasOwnProperty("proto3Optional")) - if (typeof message.proto3Optional !== "boolean") - return "proto3Optional: boolean expected"; return null; }; /** - * Creates a FieldDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates a FieldOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FieldDescriptorProto} FieldDescriptorProto + * @returns {google.protobuf.FieldOptions} FieldOptions */ - FieldDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FieldDescriptorProto) + FieldOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FieldOptions) return object; - var message = new $root.google.protobuf.FieldDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.number != null) - message.number = object.number | 0; - switch (object.label) { - default: - if (typeof object.label === "number") { - message.label = object.label; - break; - } - break; - case "LABEL_OPTIONAL": - case 1: - message.label = 1; - break; - case "LABEL_REQUIRED": - case 2: - message.label = 2; - break; - case "LABEL_REPEATED": - case 3: - message.label = 3; - break; - } - switch (object.type) { + var message = new $root.google.protobuf.FieldOptions(); + switch (object.ctype) { default: - if (typeof object.type === "number") { - message.type = object.type; + if (typeof object.ctype === "number") { + message.ctype = object.ctype; break; } break; - case "TYPE_DOUBLE": - case 1: - message.type = 1; - break; - case "TYPE_FLOAT": - case 2: - message.type = 2; - break; - case "TYPE_INT64": - case 3: - message.type = 3; - break; - case "TYPE_UINT64": - case 4: - message.type = 4; - break; - case "TYPE_INT32": - case 5: - message.type = 5; - break; - case "TYPE_FIXED64": - case 6: - message.type = 6; - break; - case "TYPE_FIXED32": - case 7: - message.type = 7; - break; - case "TYPE_BOOL": - case 8: - message.type = 8; - break; - case "TYPE_STRING": - case 9: - message.type = 9; - break; - case "TYPE_GROUP": - case 10: - message.type = 10; - break; - case "TYPE_MESSAGE": - case 11: - message.type = 11; - break; - case "TYPE_BYTES": - case 12: - message.type = 12; + case "STRING": + case 0: + message.ctype = 0; break; - case "TYPE_UINT32": - case 13: - message.type = 13; + case "CORD": + case 1: + message.ctype = 1; break; - case "TYPE_ENUM": - case 14: - message.type = 14; + case "STRING_PIECE": + case 2: + message.ctype = 2; break; - case "TYPE_SFIXED32": - case 15: - message.type = 15; + } + if (object.packed != null) + message.packed = Boolean(object.packed); + switch (object.jstype) { + default: + if (typeof object.jstype === "number") { + message.jstype = object.jstype; + break; + } break; - case "TYPE_SFIXED64": - case 16: - message.type = 16; + case "JS_NORMAL": + case 0: + message.jstype = 0; break; - case "TYPE_SINT32": - case 17: - message.type = 17; + case "JS_STRING": + case 1: + message.jstype = 1; break; - case "TYPE_SINT64": - case 18: - message.type = 18; + case "JS_NUMBER": + case 2: + message.jstype = 2; break; } - if (object.typeName != null) - message.typeName = String(object.typeName); - if (object.extendee != null) - message.extendee = String(object.extendee); - if (object.defaultValue != null) - message.defaultValue = String(object.defaultValue); - if (object.oneofIndex != null) - message.oneofIndex = object.oneofIndex | 0; - if (object.jsonName != null) - message.jsonName = String(object.jsonName); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.FieldDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.FieldOptions.fromObject(object.options); + if (object.lazy != null) + message.lazy = Boolean(object.lazy); + if (object.unverifiedLazy != null) + message.unverifiedLazy = Boolean(object.unverifiedLazy); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.weak != null) + message.weak = Boolean(object.weak); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.FieldOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.FieldOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + } + } + if (object[".google.api.fieldBehavior"]) { + if (!Array.isArray(object[".google.api.fieldBehavior"])) + throw TypeError(".google.protobuf.FieldOptions..google.api.fieldBehavior: array expected"); + message[".google.api.fieldBehavior"] = []; + for (var i = 0; i < object[".google.api.fieldBehavior"].length; ++i) + switch (object[".google.api.fieldBehavior"][i]) { + default: + if (typeof object[".google.api.fieldBehavior"][i] === "number") { + message[".google.api.fieldBehavior"][i] = object[".google.api.fieldBehavior"][i]; + break; + } + case "FIELD_BEHAVIOR_UNSPECIFIED": + case 0: + message[".google.api.fieldBehavior"][i] = 0; + break; + case "OPTIONAL": + case 1: + message[".google.api.fieldBehavior"][i] = 1; + break; + case "REQUIRED": + case 2: + message[".google.api.fieldBehavior"][i] = 2; + break; + case "OUTPUT_ONLY": + case 3: + message[".google.api.fieldBehavior"][i] = 3; + break; + case "INPUT_ONLY": + case 4: + message[".google.api.fieldBehavior"][i] = 4; + break; + case "IMMUTABLE": + case 5: + message[".google.api.fieldBehavior"][i] = 5; + break; + case "UNORDERED_LIST": + case 6: + message[".google.api.fieldBehavior"][i] = 6; + break; + case "NON_EMPTY_DEFAULT": + case 7: + message[".google.api.fieldBehavior"][i] = 7; + break; + } + } + if (object[".google.api.resourceReference"] != null) { + if (typeof object[".google.api.resourceReference"] !== "object") + throw TypeError(".google.protobuf.FieldOptions..google.api.resourceReference: object expected"); + message[".google.api.resourceReference"] = $root.google.api.ResourceReference.fromObject(object[".google.api.resourceReference"]); } - if (object.proto3Optional != null) - message.proto3Optional = Boolean(object.proto3Optional); return message; }; /** - * Creates a plain object from a FieldDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from a FieldOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static - * @param {google.protobuf.FieldDescriptorProto} message FieldDescriptorProto + * @param {google.protobuf.FieldOptions} message FieldOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FieldDescriptorProto.toObject = function toObject(message, options) { + FieldOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.uninterpretedOption = []; + object[".google.api.fieldBehavior"] = []; + } if (options.defaults) { - object.name = ""; - object.extendee = ""; - object.number = 0; - object.label = options.enums === String ? "LABEL_OPTIONAL" : 1; - object.type = options.enums === String ? "TYPE_DOUBLE" : 1; - object.typeName = ""; - object.defaultValue = ""; - object.options = null; - object.oneofIndex = 0; - object.jsonName = ""; - object.proto3Optional = false; + object.ctype = options.enums === String ? "STRING" : 0; + object.packed = false; + object.deprecated = false; + object.lazy = false; + object.jstype = options.enums === String ? "JS_NORMAL" : 0; + object.weak = false; + object.unverifiedLazy = false; + object[".google.api.resourceReference"] = null; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.extendee != null && message.hasOwnProperty("extendee")) - object.extendee = message.extendee; - if (message.number != null && message.hasOwnProperty("number")) - object.number = message.number; - if (message.label != null && message.hasOwnProperty("label")) - object.label = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Label[message.label] === undefined ? message.label : $root.google.protobuf.FieldDescriptorProto.Label[message.label] : message.label; - if (message.type != null && message.hasOwnProperty("type")) - object.type = options.enums === String ? $root.google.protobuf.FieldDescriptorProto.Type[message.type] === undefined ? message.type : $root.google.protobuf.FieldDescriptorProto.Type[message.type] : message.type; - if (message.typeName != null && message.hasOwnProperty("typeName")) - object.typeName = message.typeName; - if (message.defaultValue != null && message.hasOwnProperty("defaultValue")) - object.defaultValue = message.defaultValue; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.FieldOptions.toObject(message.options, options); - if (message.oneofIndex != null && message.hasOwnProperty("oneofIndex")) - object.oneofIndex = message.oneofIndex; - if (message.jsonName != null && message.hasOwnProperty("jsonName")) - object.jsonName = message.jsonName; - if (message.proto3Optional != null && message.hasOwnProperty("proto3Optional")) - object.proto3Optional = message.proto3Optional; + if (message.ctype != null && message.hasOwnProperty("ctype")) + object.ctype = options.enums === String ? $root.google.protobuf.FieldOptions.CType[message.ctype] === undefined ? message.ctype : $root.google.protobuf.FieldOptions.CType[message.ctype] : message.ctype; + if (message.packed != null && message.hasOwnProperty("packed")) + object.packed = message.packed; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.lazy != null && message.hasOwnProperty("lazy")) + object.lazy = message.lazy; + if (message.jstype != null && message.hasOwnProperty("jstype")) + object.jstype = options.enums === String ? $root.google.protobuf.FieldOptions.JSType[message.jstype] === undefined ? message.jstype : $root.google.protobuf.FieldOptions.JSType[message.jstype] : message.jstype; + if (message.weak != null && message.hasOwnProperty("weak")) + object.weak = message.weak; + if (message.unverifiedLazy != null && message.hasOwnProperty("unverifiedLazy")) + object.unverifiedLazy = message.unverifiedLazy; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + } + if (message[".google.api.fieldBehavior"] && message[".google.api.fieldBehavior"].length) { + object[".google.api.fieldBehavior"] = []; + for (var j = 0; j < message[".google.api.fieldBehavior"].length; ++j) + object[".google.api.fieldBehavior"][j] = options.enums === String ? $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] === undefined ? message[".google.api.fieldBehavior"][j] : $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] : message[".google.api.fieldBehavior"][j]; + } + if (message[".google.api.resourceReference"] != null && message.hasOwnProperty(".google.api.resourceReference")) + object[".google.api.resourceReference"] = $root.google.api.ResourceReference.toObject(message[".google.api.resourceReference"], options); return object; }; /** - * Converts this FieldDescriptorProto to JSON. + * Converts this FieldOptions to JSON. * @function toJSON - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @instance * @returns {Object.} JSON object */ - FieldDescriptorProto.prototype.toJSON = function toJSON() { + FieldOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FieldDescriptorProto + * Gets the default type url for FieldOptions * @function getTypeUrl - * @memberof google.protobuf.FieldDescriptorProto + * @memberof google.protobuf.FieldOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FieldDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FieldOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.FieldDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.FieldOptions"; }; /** - * Type enum. - * @name google.protobuf.FieldDescriptorProto.Type + * CType enum. + * @name google.protobuf.FieldOptions.CType * @enum {number} - * @property {number} TYPE_DOUBLE=1 TYPE_DOUBLE value - * @property {number} TYPE_FLOAT=2 TYPE_FLOAT value - * @property {number} TYPE_INT64=3 TYPE_INT64 value - * @property {number} TYPE_UINT64=4 TYPE_UINT64 value - * @property {number} TYPE_INT32=5 TYPE_INT32 value - * @property {number} TYPE_FIXED64=6 TYPE_FIXED64 value - * @property {number} TYPE_FIXED32=7 TYPE_FIXED32 value - * @property {number} TYPE_BOOL=8 TYPE_BOOL value - * @property {number} TYPE_STRING=9 TYPE_STRING value - * @property {number} TYPE_GROUP=10 TYPE_GROUP value - * @property {number} TYPE_MESSAGE=11 TYPE_MESSAGE value - * @property {number} TYPE_BYTES=12 TYPE_BYTES value - * @property {number} TYPE_UINT32=13 TYPE_UINT32 value - * @property {number} TYPE_ENUM=14 TYPE_ENUM value - * @property {number} TYPE_SFIXED32=15 TYPE_SFIXED32 value - * @property {number} TYPE_SFIXED64=16 TYPE_SFIXED64 value - * @property {number} TYPE_SINT32=17 TYPE_SINT32 value - * @property {number} TYPE_SINT64=18 TYPE_SINT64 value + * @property {number} STRING=0 STRING value + * @property {number} CORD=1 CORD value + * @property {number} STRING_PIECE=2 STRING_PIECE value */ - FieldDescriptorProto.Type = (function() { + FieldOptions.CType = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[1] = "TYPE_DOUBLE"] = 1; - values[valuesById[2] = "TYPE_FLOAT"] = 2; - values[valuesById[3] = "TYPE_INT64"] = 3; - values[valuesById[4] = "TYPE_UINT64"] = 4; - values[valuesById[5] = "TYPE_INT32"] = 5; - values[valuesById[6] = "TYPE_FIXED64"] = 6; - values[valuesById[7] = "TYPE_FIXED32"] = 7; - values[valuesById[8] = "TYPE_BOOL"] = 8; - values[valuesById[9] = "TYPE_STRING"] = 9; - values[valuesById[10] = "TYPE_GROUP"] = 10; - values[valuesById[11] = "TYPE_MESSAGE"] = 11; - values[valuesById[12] = "TYPE_BYTES"] = 12; - values[valuesById[13] = "TYPE_UINT32"] = 13; - values[valuesById[14] = "TYPE_ENUM"] = 14; - values[valuesById[15] = "TYPE_SFIXED32"] = 15; - values[valuesById[16] = "TYPE_SFIXED64"] = 16; - values[valuesById[17] = "TYPE_SINT32"] = 17; - values[valuesById[18] = "TYPE_SINT64"] = 18; + values[valuesById[0] = "STRING"] = 0; + values[valuesById[1] = "CORD"] = 1; + values[valuesById[2] = "STRING_PIECE"] = 2; return values; })(); /** - * Label enum. - * @name google.protobuf.FieldDescriptorProto.Label + * JSType enum. + * @name google.protobuf.FieldOptions.JSType * @enum {number} - * @property {number} LABEL_OPTIONAL=1 LABEL_OPTIONAL value - * @property {number} LABEL_REQUIRED=2 LABEL_REQUIRED value - * @property {number} LABEL_REPEATED=3 LABEL_REPEATED value + * @property {number} JS_NORMAL=0 JS_NORMAL value + * @property {number} JS_STRING=1 JS_STRING value + * @property {number} JS_NUMBER=2 JS_NUMBER value */ - FieldDescriptorProto.Label = (function() { + FieldOptions.JSType = (function() { var valuesById = {}, values = Object.create(valuesById); - values[valuesById[1] = "LABEL_OPTIONAL"] = 1; - values[valuesById[2] = "LABEL_REQUIRED"] = 2; - values[valuesById[3] = "LABEL_REPEATED"] = 3; + values[valuesById[0] = "JS_NORMAL"] = 0; + values[valuesById[1] = "JS_STRING"] = 1; + values[valuesById[2] = "JS_NUMBER"] = 2; return values; })(); - return FieldDescriptorProto; + return FieldOptions; })(); - protobuf.OneofDescriptorProto = (function() { + protobuf.OneofOptions = (function() { /** - * Properties of an OneofDescriptorProto. + * Properties of an OneofOptions. * @memberof google.protobuf - * @interface IOneofDescriptorProto - * @property {string|null} [name] OneofDescriptorProto name - * @property {google.protobuf.IOneofOptions|null} [options] OneofDescriptorProto options + * @interface IOneofOptions + * @property {Array.|null} [uninterpretedOption] OneofOptions uninterpretedOption */ /** - * Constructs a new OneofDescriptorProto. + * Constructs a new OneofOptions. * @memberof google.protobuf - * @classdesc Represents an OneofDescriptorProto. - * @implements IOneofDescriptorProto + * @classdesc Represents an OneofOptions. + * @implements IOneofOptions * @constructor - * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IOneofOptions=} [properties] Properties to set */ - function OneofDescriptorProto(properties) { + function OneofOptions(properties) { + this.uninterpretedOption = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -53866,89 +61766,78 @@ } /** - * OneofDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.OneofDescriptorProto - * @instance - */ - OneofDescriptorProto.prototype.name = ""; - - /** - * OneofDescriptorProto options. - * @member {google.protobuf.IOneofOptions|null|undefined} options - * @memberof google.protobuf.OneofDescriptorProto + * OneofOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.OneofOptions * @instance */ - OneofDescriptorProto.prototype.options = null; + OneofOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * Creates a new OneofDescriptorProto instance using the specified properties. + * Creates a new OneofOptions instance using the specified properties. * @function create - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static - * @param {google.protobuf.IOneofDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto instance + * @param {google.protobuf.IOneofOptions=} [properties] Properties to set + * @returns {google.protobuf.OneofOptions} OneofOptions instance */ - OneofDescriptorProto.create = function create(properties) { - return new OneofDescriptorProto(properties); + OneofOptions.create = function create(properties) { + return new OneofOptions(properties); }; /** - * Encodes the specified OneofDescriptorProto message. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. + * Encodes the specified OneofOptions message. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static - * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode + * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OneofDescriptorProto.encode = function encode(message, writer) { + OneofOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.OneofOptions.encode(message.options, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); return writer; }; /** - * Encodes the specified OneofDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.OneofDescriptorProto.verify|verify} messages. + * Encodes the specified OneofOptions message, length delimited. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static - * @param {google.protobuf.IOneofDescriptorProto} message OneofDescriptorProto message or plain object to encode + * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OneofDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + OneofOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer. + * Decodes an OneofOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto + * @returns {google.protobuf.OneofOptions} OneofOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OneofDescriptorProto.decode = function decode(reader, length) { + OneofOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.OneofDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.OneofOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.options = $root.google.protobuf.OneofOptions.decode(reader, reader.uint32()); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } default: @@ -53960,284 +61849,249 @@ }; /** - * Decodes an OneofDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes an OneofOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto + * @returns {google.protobuf.OneofOptions} OneofOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OneofDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + OneofOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an OneofDescriptorProto message. + * Verifies an OneofOptions message. * @function verify - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - OneofDescriptorProto.verify = function verify(message) { + OneofOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.OneofOptions.verify(message.options); - if (error) - return "options." + error; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (error) + return "uninterpretedOption." + error; + } } return null; }; /** - * Creates an OneofDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates an OneofOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.OneofDescriptorProto} OneofDescriptorProto + * @returns {google.protobuf.OneofOptions} OneofOptions */ - OneofDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.OneofDescriptorProto) + OneofOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.OneofOptions) return object; - var message = new $root.google.protobuf.OneofDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.OneofDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.OneofOptions.fromObject(object.options); + var message = new $root.google.protobuf.OneofOptions(); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.OneofOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.OneofOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + } } return message; }; /** - * Creates a plain object from an OneofDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from an OneofOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static - * @param {google.protobuf.OneofDescriptorProto} message OneofDescriptorProto + * @param {google.protobuf.OneofOptions} message OneofOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - OneofDescriptorProto.toObject = function toObject(message, options) { + OneofOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.options = null; + if (options.arrays || options.defaults) + object.uninterpretedOption = []; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.OneofOptions.toObject(message.options, options); return object; }; /** - * Converts this OneofDescriptorProto to JSON. + * Converts this OneofOptions to JSON. * @function toJSON - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @instance * @returns {Object.} JSON object */ - OneofDescriptorProto.prototype.toJSON = function toJSON() { + OneofOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for OneofDescriptorProto + * Gets the default type url for OneofOptions * @function getTypeUrl - * @memberof google.protobuf.OneofDescriptorProto + * @memberof google.protobuf.OneofOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - OneofDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + OneofOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.OneofDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.OneofOptions"; }; - return OneofDescriptorProto; + return OneofOptions; })(); - protobuf.EnumDescriptorProto = (function() { + protobuf.EnumOptions = (function() { /** - * Properties of an EnumDescriptorProto. + * Properties of an EnumOptions. * @memberof google.protobuf - * @interface IEnumDescriptorProto - * @property {string|null} [name] EnumDescriptorProto name - * @property {Array.|null} [value] EnumDescriptorProto value - * @property {google.protobuf.IEnumOptions|null} [options] EnumDescriptorProto options - * @property {Array.|null} [reservedRange] EnumDescriptorProto reservedRange - * @property {Array.|null} [reservedName] EnumDescriptorProto reservedName + * @interface IEnumOptions + * @property {boolean|null} [allowAlias] EnumOptions allowAlias + * @property {boolean|null} [deprecated] EnumOptions deprecated + * @property {Array.|null} [uninterpretedOption] EnumOptions uninterpretedOption */ /** - * Constructs a new EnumDescriptorProto. + * Constructs a new EnumOptions. * @memberof google.protobuf - * @classdesc Represents an EnumDescriptorProto. - * @implements IEnumDescriptorProto + * @classdesc Represents an EnumOptions. + * @implements IEnumOptions * @constructor - * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IEnumOptions=} [properties] Properties to set */ - function EnumDescriptorProto(properties) { - this.value = []; - this.reservedRange = []; - this.reservedName = []; + function EnumOptions(properties) { + this.uninterpretedOption = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) this[keys[i]] = properties[keys[i]]; - } - - /** - * EnumDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.name = ""; - - /** - * EnumDescriptorProto value. - * @member {Array.} value - * @memberof google.protobuf.EnumDescriptorProto - * @instance - */ - EnumDescriptorProto.prototype.value = $util.emptyArray; + } /** - * EnumDescriptorProto options. - * @member {google.protobuf.IEnumOptions|null|undefined} options - * @memberof google.protobuf.EnumDescriptorProto + * EnumOptions allowAlias. + * @member {boolean} allowAlias + * @memberof google.protobuf.EnumOptions * @instance */ - EnumDescriptorProto.prototype.options = null; + EnumOptions.prototype.allowAlias = false; /** - * EnumDescriptorProto reservedRange. - * @member {Array.} reservedRange - * @memberof google.protobuf.EnumDescriptorProto + * EnumOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.EnumOptions * @instance */ - EnumDescriptorProto.prototype.reservedRange = $util.emptyArray; + EnumOptions.prototype.deprecated = false; /** - * EnumDescriptorProto reservedName. - * @member {Array.} reservedName - * @memberof google.protobuf.EnumDescriptorProto + * EnumOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.EnumOptions * @instance */ - EnumDescriptorProto.prototype.reservedName = $util.emptyArray; + EnumOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * Creates a new EnumDescriptorProto instance using the specified properties. + * Creates a new EnumOptions instance using the specified properties. * @function create - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static - * @param {google.protobuf.IEnumDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto instance + * @param {google.protobuf.IEnumOptions=} [properties] Properties to set + * @returns {google.protobuf.EnumOptions} EnumOptions instance */ - EnumDescriptorProto.create = function create(properties) { - return new EnumDescriptorProto(properties); + EnumOptions.create = function create(properties) { + return new EnumOptions(properties); }; /** - * Encodes the specified EnumDescriptorProto message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. + * Encodes the specified EnumOptions message. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static - * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode + * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumDescriptorProto.encode = function encode(message, writer) { + EnumOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.value != null && message.value.length) - for (var i = 0; i < message.value.length; ++i) - $root.google.protobuf.EnumValueDescriptorProto.encode(message.value[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.EnumOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - if (message.reservedRange != null && message.reservedRange.length) - for (var i = 0; i < message.reservedRange.length; ++i) - $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.encode(message.reservedRange[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.reservedName != null && message.reservedName.length) - for (var i = 0; i < message.reservedName.length; ++i) - writer.uint32(/* id 5, wireType 2 =*/42).string(message.reservedName[i]); + if (message.allowAlias != null && Object.hasOwnProperty.call(message, "allowAlias")) + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.allowAlias); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); return writer; }; /** - * Encodes the specified EnumDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.verify|verify} messages. + * Encodes the specified EnumOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static - * @param {google.protobuf.IEnumDescriptorProto} message EnumDescriptorProto message or plain object to encode + * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + EnumOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer. + * Decodes an EnumOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto + * @returns {google.protobuf.EnumOptions} EnumOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumDescriptorProto.decode = function decode(reader, length) { + EnumOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); - break; - } case 2: { - if (!(message.value && message.value.length)) - message.value = []; - message.value.push($root.google.protobuf.EnumValueDescriptorProto.decode(reader, reader.uint32())); + message.allowAlias = reader.bool(); break; } case 3: { - message.options = $root.google.protobuf.EnumOptions.decode(reader, reader.uint32()); - break; - } - case 4: { - if (!(message.reservedRange && message.reservedRange.length)) - message.reservedRange = []; - message.reservedRange.push($root.google.protobuf.EnumDescriptorProto.EnumReservedRange.decode(reader, reader.uint32())); + message.deprecated = reader.bool(); break; } - case 5: { - if (!(message.reservedName && message.reservedName.length)) - message.reservedName = []; - message.reservedName.push(reader.string()); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } default: @@ -54249,437 +62103,159 @@ }; /** - * Decodes an EnumDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes an EnumOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto + * @returns {google.protobuf.EnumOptions} EnumOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + EnumOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EnumDescriptorProto message. + * Verifies an EnumOptions message. * @function verify - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EnumDescriptorProto.verify = function verify(message) { + EnumOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.value != null && message.hasOwnProperty("value")) { - if (!Array.isArray(message.value)) - return "value: array expected"; - for (var i = 0; i < message.value.length; ++i) { - var error = $root.google.protobuf.EnumValueDescriptorProto.verify(message.value[i]); - if (error) - return "value." + error; - } - } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.EnumOptions.verify(message.options); - if (error) - return "options." + error; - } - if (message.reservedRange != null && message.hasOwnProperty("reservedRange")) { - if (!Array.isArray(message.reservedRange)) - return "reservedRange: array expected"; - for (var i = 0; i < message.reservedRange.length; ++i) { - var error = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.verify(message.reservedRange[i]); + if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) + if (typeof message.allowAlias !== "boolean") + return "allowAlias: boolean expected"; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); if (error) - return "reservedRange." + error; + return "uninterpretedOption." + error; } } - if (message.reservedName != null && message.hasOwnProperty("reservedName")) { - if (!Array.isArray(message.reservedName)) - return "reservedName: array expected"; - for (var i = 0; i < message.reservedName.length; ++i) - if (!$util.isString(message.reservedName[i])) - return "reservedName: string[] expected"; - } return null; }; /** - * Creates an EnumDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates an EnumOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.EnumDescriptorProto} EnumDescriptorProto + * @returns {google.protobuf.EnumOptions} EnumOptions */ - EnumDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumDescriptorProto) + EnumOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.EnumOptions) return object; - var message = new $root.google.protobuf.EnumDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.value) { - if (!Array.isArray(object.value)) - throw TypeError(".google.protobuf.EnumDescriptorProto.value: array expected"); - message.value = []; - for (var i = 0; i < object.value.length; ++i) { - if (typeof object.value[i] !== "object") - throw TypeError(".google.protobuf.EnumDescriptorProto.value: object expected"); - message.value[i] = $root.google.protobuf.EnumValueDescriptorProto.fromObject(object.value[i]); - } - } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.EnumDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.EnumOptions.fromObject(object.options); - } - if (object.reservedRange) { - if (!Array.isArray(object.reservedRange)) - throw TypeError(".google.protobuf.EnumDescriptorProto.reservedRange: array expected"); - message.reservedRange = []; - for (var i = 0; i < object.reservedRange.length; ++i) { - if (typeof object.reservedRange[i] !== "object") - throw TypeError(".google.protobuf.EnumDescriptorProto.reservedRange: object expected"); - message.reservedRange[i] = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.fromObject(object.reservedRange[i]); + var message = new $root.google.protobuf.EnumOptions(); + if (object.allowAlias != null) + message.allowAlias = Boolean(object.allowAlias); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.EnumOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.EnumOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); } } - if (object.reservedName) { - if (!Array.isArray(object.reservedName)) - throw TypeError(".google.protobuf.EnumDescriptorProto.reservedName: array expected"); - message.reservedName = []; - for (var i = 0; i < object.reservedName.length; ++i) - message.reservedName[i] = String(object.reservedName[i]); - } return message; }; /** - * Creates a plain object from an EnumDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from an EnumOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @static - * @param {google.protobuf.EnumDescriptorProto} message EnumDescriptorProto + * @param {google.protobuf.EnumOptions} message EnumOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EnumDescriptorProto.toObject = function toObject(message, options) { + EnumOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.value = []; - object.reservedRange = []; - object.reservedName = []; - } + if (options.arrays || options.defaults) + object.uninterpretedOption = []; if (options.defaults) { - object.name = ""; - object.options = null; - } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.value && message.value.length) { - object.value = []; - for (var j = 0; j < message.value.length; ++j) - object.value[j] = $root.google.protobuf.EnumValueDescriptorProto.toObject(message.value[j], options); - } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.EnumOptions.toObject(message.options, options); - if (message.reservedRange && message.reservedRange.length) { - object.reservedRange = []; - for (var j = 0; j < message.reservedRange.length; ++j) - object.reservedRange[j] = $root.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject(message.reservedRange[j], options); + object.allowAlias = false; + object.deprecated = false; } - if (message.reservedName && message.reservedName.length) { - object.reservedName = []; - for (var j = 0; j < message.reservedName.length; ++j) - object.reservedName[j] = message.reservedName[j]; + if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) + object.allowAlias = message.allowAlias; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } return object; }; /** - * Converts this EnumDescriptorProto to JSON. + * Converts this EnumOptions to JSON. * @function toJSON - * @memberof google.protobuf.EnumDescriptorProto + * @memberof google.protobuf.EnumOptions * @instance * @returns {Object.} JSON object */ - EnumDescriptorProto.prototype.toJSON = function toJSON() { + EnumOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; - /** - * Gets the default type url for EnumDescriptorProto - * @function getTypeUrl - * @memberof google.protobuf.EnumDescriptorProto - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumDescriptorProto"; - }; - - EnumDescriptorProto.EnumReservedRange = (function() { - - /** - * Properties of an EnumReservedRange. - * @memberof google.protobuf.EnumDescriptorProto - * @interface IEnumReservedRange - * @property {number|null} [start] EnumReservedRange start - * @property {number|null} [end] EnumReservedRange end - */ - - /** - * Constructs a new EnumReservedRange. - * @memberof google.protobuf.EnumDescriptorProto - * @classdesc Represents an EnumReservedRange. - * @implements IEnumReservedRange - * @constructor - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set - */ - function EnumReservedRange(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * EnumReservedRange start. - * @member {number} start - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - */ - EnumReservedRange.prototype.start = 0; - - /** - * EnumReservedRange end. - * @member {number} end - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - */ - EnumReservedRange.prototype.end = 0; - - /** - * Creates a new EnumReservedRange instance using the specified properties. - * @function create - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange=} [properties] Properties to set - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange instance - */ - EnumReservedRange.create = function create(properties) { - return new EnumReservedRange(properties); - }; - - /** - * Encodes the specified EnumReservedRange message. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @function encode - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumReservedRange.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.start != null && Object.hasOwnProperty.call(message, "start")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.start); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.end); - return writer; - }; - - /** - * Encodes the specified EnumReservedRange message, length delimited. Does not implicitly {@link google.protobuf.EnumDescriptorProto.EnumReservedRange.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.IEnumReservedRange} message EnumReservedRange message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - EnumReservedRange.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumReservedRange.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumDescriptorProto.EnumReservedRange(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.start = reader.int32(); - break; - } - case 2: { - message.end = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes an EnumReservedRange message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - EnumReservedRange.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies an EnumReservedRange message. - * @function verify - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - EnumReservedRange.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.start != null && message.hasOwnProperty("start")) - if (!$util.isInteger(message.start)) - return "start: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) - return "end: integer expected"; - return null; - }; - - /** - * Creates an EnumReservedRange message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.EnumDescriptorProto.EnumReservedRange} EnumReservedRange - */ - EnumReservedRange.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumDescriptorProto.EnumReservedRange) - return object; - var message = new $root.google.protobuf.EnumDescriptorProto.EnumReservedRange(); - if (object.start != null) - message.start = object.start | 0; - if (object.end != null) - message.end = object.end | 0; - return message; - }; - - /** - * Creates a plain object from an EnumReservedRange message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {google.protobuf.EnumDescriptorProto.EnumReservedRange} message EnumReservedRange - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - EnumReservedRange.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.start = 0; - object.end = 0; - } - if (message.start != null && message.hasOwnProperty("start")) - object.start = message.start; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - return object; - }; - - /** - * Converts this EnumReservedRange to JSON. - * @function toJSON - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @instance - * @returns {Object.} JSON object - */ - EnumReservedRange.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for EnumReservedRange - * @function getTypeUrl - * @memberof google.protobuf.EnumDescriptorProto.EnumReservedRange - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - EnumReservedRange.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.EnumDescriptorProto.EnumReservedRange"; - }; - - return EnumReservedRange; - })(); - - return EnumDescriptorProto; + /** + * Gets the default type url for EnumOptions + * @function getTypeUrl + * @memberof google.protobuf.EnumOptions + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + EnumOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.EnumOptions"; + }; + + return EnumOptions; })(); - protobuf.EnumValueDescriptorProto = (function() { + protobuf.EnumValueOptions = (function() { /** - * Properties of an EnumValueDescriptorProto. + * Properties of an EnumValueOptions. * @memberof google.protobuf - * @interface IEnumValueDescriptorProto - * @property {string|null} [name] EnumValueDescriptorProto name - * @property {number|null} [number] EnumValueDescriptorProto number - * @property {google.protobuf.IEnumValueOptions|null} [options] EnumValueDescriptorProto options + * @interface IEnumValueOptions + * @property {boolean|null} [deprecated] EnumValueOptions deprecated + * @property {Array.|null} [uninterpretedOption] EnumValueOptions uninterpretedOption */ /** - * Constructs a new EnumValueDescriptorProto. + * Constructs a new EnumValueOptions. * @memberof google.protobuf - * @classdesc Represents an EnumValueDescriptorProto. - * @implements IEnumValueDescriptorProto + * @classdesc Represents an EnumValueOptions. + * @implements IEnumValueOptions * @constructor - * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set */ - function EnumValueDescriptorProto(properties) { + function EnumValueOptions(properties) { + this.uninterpretedOption = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -54687,103 +62263,92 @@ } /** - * EnumValueDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.EnumValueDescriptorProto - * @instance - */ - EnumValueDescriptorProto.prototype.name = ""; - - /** - * EnumValueDescriptorProto number. - * @member {number} number - * @memberof google.protobuf.EnumValueDescriptorProto + * EnumValueOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.EnumValueOptions * @instance */ - EnumValueDescriptorProto.prototype.number = 0; + EnumValueOptions.prototype.deprecated = false; /** - * EnumValueDescriptorProto options. - * @member {google.protobuf.IEnumValueOptions|null|undefined} options - * @memberof google.protobuf.EnumValueDescriptorProto + * EnumValueOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.EnumValueOptions * @instance */ - EnumValueDescriptorProto.prototype.options = null; + EnumValueOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * Creates a new EnumValueDescriptorProto instance using the specified properties. + * Creates a new EnumValueOptions instance using the specified properties. * @function create - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static - * @param {google.protobuf.IEnumValueDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto instance + * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set + * @returns {google.protobuf.EnumValueOptions} EnumValueOptions instance */ - EnumValueDescriptorProto.create = function create(properties) { - return new EnumValueDescriptorProto(properties); + EnumValueOptions.create = function create(properties) { + return new EnumValueOptions(properties); }; /** - * Encodes the specified EnumValueDescriptorProto message. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. + * Encodes the specified EnumValueOptions message. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static - * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode + * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumValueDescriptorProto.encode = function encode(message, writer) { + EnumValueOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.number != null && Object.hasOwnProperty.call(message, "number")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.number); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.EnumValueOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 1, wireType 0 =*/8).bool(message.deprecated); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); return writer; }; /** - * Encodes the specified EnumValueDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.EnumValueDescriptorProto.verify|verify} messages. + * Encodes the specified EnumValueOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static - * @param {google.protobuf.IEnumValueDescriptorProto} message EnumValueDescriptorProto message or plain object to encode + * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumValueDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + EnumValueOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer. + * Decodes an EnumValueOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto + * @returns {google.protobuf.EnumValueOptions} EnumValueOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumValueDescriptorProto.decode = function decode(reader, length) { + EnumValueOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumValueDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumValueOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.name = reader.string(); - break; - } - case 2: { - message.number = reader.int32(); + message.deprecated = reader.bool(); break; } - case 3: { - message.options = $root.google.protobuf.EnumValueOptions.decode(reader, reader.uint32()); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } default: @@ -54795,147 +62360,152 @@ }; /** - * Decodes an EnumValueDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes an EnumValueOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto + * @returns {google.protobuf.EnumValueOptions} EnumValueOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumValueDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + EnumValueOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EnumValueDescriptorProto message. + * Verifies an EnumValueOptions message. * @function verify - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EnumValueDescriptorProto.verify = function verify(message) { + EnumValueOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.number != null && message.hasOwnProperty("number")) - if (!$util.isInteger(message.number)) - return "number: integer expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.EnumValueOptions.verify(message.options); - if (error) - return "options." + error; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (error) + return "uninterpretedOption." + error; + } } return null; }; /** - * Creates an EnumValueDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates an EnumValueOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.EnumValueDescriptorProto} EnumValueDescriptorProto + * @returns {google.protobuf.EnumValueOptions} EnumValueOptions */ - EnumValueDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumValueDescriptorProto) + EnumValueOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.EnumValueOptions) return object; - var message = new $root.google.protobuf.EnumValueDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.number != null) - message.number = object.number | 0; - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.EnumValueDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.EnumValueOptions.fromObject(object.options); + var message = new $root.google.protobuf.EnumValueOptions(); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.EnumValueOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.EnumValueOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + } } return message; }; /** - * Creates a plain object from an EnumValueDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from an EnumValueOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static - * @param {google.protobuf.EnumValueDescriptorProto} message EnumValueDescriptorProto + * @param {google.protobuf.EnumValueOptions} message EnumValueOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EnumValueDescriptorProto.toObject = function toObject(message, options) { + EnumValueOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.name = ""; - object.number = 0; - object.options = null; + if (options.arrays || options.defaults) + object.uninterpretedOption = []; + if (options.defaults) + object.deprecated = false; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.number != null && message.hasOwnProperty("number")) - object.number = message.number; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.EnumValueOptions.toObject(message.options, options); return object; }; /** - * Converts this EnumValueDescriptorProto to JSON. + * Converts this EnumValueOptions to JSON. * @function toJSON - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @instance * @returns {Object.} JSON object */ - EnumValueDescriptorProto.prototype.toJSON = function toJSON() { + EnumValueOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EnumValueDescriptorProto + * Gets the default type url for EnumValueOptions * @function getTypeUrl - * @memberof google.protobuf.EnumValueDescriptorProto + * @memberof google.protobuf.EnumValueOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EnumValueDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + EnumValueOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.EnumValueDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.EnumValueOptions"; }; - return EnumValueDescriptorProto; + return EnumValueOptions; })(); - protobuf.ServiceDescriptorProto = (function() { + protobuf.ServiceOptions = (function() { /** - * Properties of a ServiceDescriptorProto. + * Properties of a ServiceOptions. * @memberof google.protobuf - * @interface IServiceDescriptorProto - * @property {string|null} [name] ServiceDescriptorProto name - * @property {Array.|null} [method] ServiceDescriptorProto method - * @property {google.protobuf.IServiceOptions|null} [options] ServiceDescriptorProto options + * @interface IServiceOptions + * @property {boolean|null} [deprecated] ServiceOptions deprecated + * @property {Array.|null} [uninterpretedOption] ServiceOptions uninterpretedOption + * @property {string|null} [".google.api.defaultHost"] ServiceOptions .google.api.defaultHost + * @property {string|null} [".google.api.oauthScopes"] ServiceOptions .google.api.oauthScopes */ /** - * Constructs a new ServiceDescriptorProto. + * Constructs a new ServiceOptions. * @memberof google.protobuf - * @classdesc Represents a ServiceDescriptorProto. - * @implements IServiceDescriptorProto + * @classdesc Represents a ServiceOptions. + * @implements IServiceOptions * @constructor - * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IServiceOptions=} [properties] Properties to set */ - function ServiceDescriptorProto(properties) { - this.method = []; + function ServiceOptions(properties) { + this.uninterpretedOption = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -54943,106 +62513,120 @@ } /** - * ServiceDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.ServiceDescriptorProto + * ServiceOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.ServiceOptions * @instance */ - ServiceDescriptorProto.prototype.name = ""; + ServiceOptions.prototype.deprecated = false; /** - * ServiceDescriptorProto method. - * @member {Array.} method - * @memberof google.protobuf.ServiceDescriptorProto + * ServiceOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.ServiceOptions * @instance */ - ServiceDescriptorProto.prototype.method = $util.emptyArray; + ServiceOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * ServiceDescriptorProto options. - * @member {google.protobuf.IServiceOptions|null|undefined} options - * @memberof google.protobuf.ServiceDescriptorProto + * ServiceOptions .google.api.defaultHost. + * @member {string} .google.api.defaultHost + * @memberof google.protobuf.ServiceOptions * @instance */ - ServiceDescriptorProto.prototype.options = null; + ServiceOptions.prototype[".google.api.defaultHost"] = ""; /** - * Creates a new ServiceDescriptorProto instance using the specified properties. + * ServiceOptions .google.api.oauthScopes. + * @member {string} .google.api.oauthScopes + * @memberof google.protobuf.ServiceOptions + * @instance + */ + ServiceOptions.prototype[".google.api.oauthScopes"] = ""; + + /** + * Creates a new ServiceOptions instance using the specified properties. * @function create - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static - * @param {google.protobuf.IServiceDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto instance + * @param {google.protobuf.IServiceOptions=} [properties] Properties to set + * @returns {google.protobuf.ServiceOptions} ServiceOptions instance */ - ServiceDescriptorProto.create = function create(properties) { - return new ServiceDescriptorProto(properties); + ServiceOptions.create = function create(properties) { + return new ServiceOptions(properties); }; /** - * Encodes the specified ServiceDescriptorProto message. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. + * Encodes the specified ServiceOptions message. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static - * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode + * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ServiceDescriptorProto.encode = function encode(message, writer) { + ServiceOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.method != null && message.method.length) - for (var i = 0; i < message.method.length; ++i) - $root.google.protobuf.MethodDescriptorProto.encode(message.method[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.ServiceOptions.encode(message.options, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 33, wireType 0 =*/264).bool(message.deprecated); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message[".google.api.defaultHost"] != null && Object.hasOwnProperty.call(message, ".google.api.defaultHost")) + writer.uint32(/* id 1049, wireType 2 =*/8394).string(message[".google.api.defaultHost"]); + if (message[".google.api.oauthScopes"] != null && Object.hasOwnProperty.call(message, ".google.api.oauthScopes")) + writer.uint32(/* id 1050, wireType 2 =*/8402).string(message[".google.api.oauthScopes"]); return writer; }; /** - * Encodes the specified ServiceDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.ServiceDescriptorProto.verify|verify} messages. + * Encodes the specified ServiceOptions message, length delimited. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static - * @param {google.protobuf.IServiceDescriptorProto} message ServiceDescriptorProto message or plain object to encode + * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ServiceDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + ServiceOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer. + * Decodes a ServiceOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto + * @returns {google.protobuf.ServiceOptions} ServiceOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ServiceDescriptorProto.decode = function decode(reader, length) { + ServiceOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ServiceDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ServiceOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); + case 33: { + message.deprecated = reader.bool(); break; } - case 2: { - if (!(message.method && message.method.length)) - message.method = []; - message.method.push($root.google.protobuf.MethodDescriptorProto.decode(reader, reader.uint32())); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } - case 3: { - message.options = $root.google.protobuf.ServiceOptions.decode(reader, reader.uint32()); + case 1049: { + message[".google.api.defaultHost"] = reader.string(); + break; + } + case 1050: { + message[".google.api.oauthScopes"] = reader.string(); break; } default: @@ -55054,167 +62638,172 @@ }; /** - * Decodes a ServiceDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes a ServiceOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto + * @returns {google.protobuf.ServiceOptions} ServiceOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ServiceDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + ServiceOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ServiceDescriptorProto message. + * Verifies a ServiceOptions message. * @function verify - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ServiceDescriptorProto.verify = function verify(message) { + ServiceOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.method != null && message.hasOwnProperty("method")) { - if (!Array.isArray(message.method)) - return "method: array expected"; - for (var i = 0; i < message.method.length; ++i) { - var error = $root.google.protobuf.MethodDescriptorProto.verify(message.method[i]); + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); if (error) - return "method." + error; + return "uninterpretedOption." + error; } } - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.ServiceOptions.verify(message.options); - if (error) - return "options." + error; - } + if (message[".google.api.defaultHost"] != null && message.hasOwnProperty(".google.api.defaultHost")) + if (!$util.isString(message[".google.api.defaultHost"])) + return ".google.api.defaultHost: string expected"; + if (message[".google.api.oauthScopes"] != null && message.hasOwnProperty(".google.api.oauthScopes")) + if (!$util.isString(message[".google.api.oauthScopes"])) + return ".google.api.oauthScopes: string expected"; return null; }; /** - * Creates a ServiceDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates a ServiceOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.ServiceDescriptorProto} ServiceDescriptorProto + * @returns {google.protobuf.ServiceOptions} ServiceOptions */ - ServiceDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ServiceDescriptorProto) + ServiceOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.ServiceOptions) return object; - var message = new $root.google.protobuf.ServiceDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.method) { - if (!Array.isArray(object.method)) - throw TypeError(".google.protobuf.ServiceDescriptorProto.method: array expected"); - message.method = []; - for (var i = 0; i < object.method.length; ++i) { - if (typeof object.method[i] !== "object") - throw TypeError(".google.protobuf.ServiceDescriptorProto.method: object expected"); - message.method[i] = $root.google.protobuf.MethodDescriptorProto.fromObject(object.method[i]); + var message = new $root.google.protobuf.ServiceOptions(); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.ServiceOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.ServiceOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); } } - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.ServiceDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.ServiceOptions.fromObject(object.options); - } + if (object[".google.api.defaultHost"] != null) + message[".google.api.defaultHost"] = String(object[".google.api.defaultHost"]); + if (object[".google.api.oauthScopes"] != null) + message[".google.api.oauthScopes"] = String(object[".google.api.oauthScopes"]); return message; }; /** - * Creates a plain object from a ServiceDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from a ServiceOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static - * @param {google.protobuf.ServiceDescriptorProto} message ServiceDescriptorProto + * @param {google.protobuf.ServiceOptions} message ServiceOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ServiceDescriptorProto.toObject = function toObject(message, options) { + ServiceOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.method = []; + object.uninterpretedOption = []; if (options.defaults) { - object.name = ""; - object.options = null; + object.deprecated = false; + object[".google.api.defaultHost"] = ""; + object[".google.api.oauthScopes"] = ""; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.method && message.method.length) { - object.method = []; - for (var j = 0; j < message.method.length; ++j) - object.method[j] = $root.google.protobuf.MethodDescriptorProto.toObject(message.method[j], options); + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); } - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.ServiceOptions.toObject(message.options, options); + if (message[".google.api.defaultHost"] != null && message.hasOwnProperty(".google.api.defaultHost")) + object[".google.api.defaultHost"] = message[".google.api.defaultHost"]; + if (message[".google.api.oauthScopes"] != null && message.hasOwnProperty(".google.api.oauthScopes")) + object[".google.api.oauthScopes"] = message[".google.api.oauthScopes"]; return object; }; /** - * Converts this ServiceDescriptorProto to JSON. + * Converts this ServiceOptions to JSON. * @function toJSON - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @instance * @returns {Object.} JSON object */ - ServiceDescriptorProto.prototype.toJSON = function toJSON() { + ServiceOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ServiceDescriptorProto + * Gets the default type url for ServiceOptions * @function getTypeUrl - * @memberof google.protobuf.ServiceDescriptorProto + * @memberof google.protobuf.ServiceOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ServiceDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + ServiceOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.ServiceDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.ServiceOptions"; }; - return ServiceDescriptorProto; + return ServiceOptions; })(); - protobuf.MethodDescriptorProto = (function() { + protobuf.MethodOptions = (function() { /** - * Properties of a MethodDescriptorProto. + * Properties of a MethodOptions. * @memberof google.protobuf - * @interface IMethodDescriptorProto - * @property {string|null} [name] MethodDescriptorProto name - * @property {string|null} [inputType] MethodDescriptorProto inputType - * @property {string|null} [outputType] MethodDescriptorProto outputType - * @property {google.protobuf.IMethodOptions|null} [options] MethodDescriptorProto options - * @property {boolean|null} [clientStreaming] MethodDescriptorProto clientStreaming - * @property {boolean|null} [serverStreaming] MethodDescriptorProto serverStreaming + * @interface IMethodOptions + * @property {boolean|null} [deprecated] MethodOptions deprecated + * @property {google.protobuf.MethodOptions.IdempotencyLevel|null} [idempotencyLevel] MethodOptions idempotencyLevel + * @property {Array.|null} [uninterpretedOption] MethodOptions uninterpretedOption + * @property {google.api.IHttpRule|null} [".google.api.http"] MethodOptions .google.api.http + * @property {Array.|null} [".google.api.methodSignature"] MethodOptions .google.api.methodSignature + * @property {google.longrunning.IOperationInfo|null} [".google.longrunning.operationInfo"] MethodOptions .google.longrunning.operationInfo */ /** - * Constructs a new MethodDescriptorProto. + * Constructs a new MethodOptions. * @memberof google.protobuf - * @classdesc Represents a MethodDescriptorProto. - * @implements IMethodDescriptorProto + * @classdesc Represents a MethodOptions. + * @implements IMethodOptions * @constructor - * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set + * @param {google.protobuf.IMethodOptions=} [properties] Properties to set */ - function MethodDescriptorProto(properties) { + function MethodOptions(properties) { + this.uninterpretedOption = []; + this[".google.api.methodSignature"] = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -55222,145 +62811,151 @@ } /** - * MethodDescriptorProto name. - * @member {string} name - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions deprecated. + * @member {boolean} deprecated + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.name = ""; + MethodOptions.prototype.deprecated = false; /** - * MethodDescriptorProto inputType. - * @member {string} inputType - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions idempotencyLevel. + * @member {google.protobuf.MethodOptions.IdempotencyLevel} idempotencyLevel + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.inputType = ""; + MethodOptions.prototype.idempotencyLevel = 0; /** - * MethodDescriptorProto outputType. - * @member {string} outputType - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions uninterpretedOption. + * @member {Array.} uninterpretedOption + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.outputType = ""; + MethodOptions.prototype.uninterpretedOption = $util.emptyArray; /** - * MethodDescriptorProto options. - * @member {google.protobuf.IMethodOptions|null|undefined} options - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions .google.api.http. + * @member {google.api.IHttpRule|null|undefined} .google.api.http + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.options = null; + MethodOptions.prototype[".google.api.http"] = null; /** - * MethodDescriptorProto clientStreaming. - * @member {boolean} clientStreaming - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions .google.api.methodSignature. + * @member {Array.} .google.api.methodSignature + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.clientStreaming = false; + MethodOptions.prototype[".google.api.methodSignature"] = $util.emptyArray; /** - * MethodDescriptorProto serverStreaming. - * @member {boolean} serverStreaming - * @memberof google.protobuf.MethodDescriptorProto + * MethodOptions .google.longrunning.operationInfo. + * @member {google.longrunning.IOperationInfo|null|undefined} .google.longrunning.operationInfo + * @memberof google.protobuf.MethodOptions * @instance */ - MethodDescriptorProto.prototype.serverStreaming = false; + MethodOptions.prototype[".google.longrunning.operationInfo"] = null; /** - * Creates a new MethodDescriptorProto instance using the specified properties. + * Creates a new MethodOptions instance using the specified properties. * @function create - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static - * @param {google.protobuf.IMethodDescriptorProto=} [properties] Properties to set - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto instance + * @param {google.protobuf.IMethodOptions=} [properties] Properties to set + * @returns {google.protobuf.MethodOptions} MethodOptions instance */ - MethodDescriptorProto.create = function create(properties) { - return new MethodDescriptorProto(properties); + MethodOptions.create = function create(properties) { + return new MethodOptions(properties); }; /** - * Encodes the specified MethodDescriptorProto message. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. + * Encodes the specified MethodOptions message. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. * @function encode - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static - * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode + * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MethodDescriptorProto.encode = function encode(message, writer) { + MethodOptions.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.name != null && Object.hasOwnProperty.call(message, "name")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); - if (message.inputType != null && Object.hasOwnProperty.call(message, "inputType")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.inputType); - if (message.outputType != null && Object.hasOwnProperty.call(message, "outputType")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.outputType); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.protobuf.MethodOptions.encode(message.options, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.clientStreaming != null && Object.hasOwnProperty.call(message, "clientStreaming")) - writer.uint32(/* id 5, wireType 0 =*/40).bool(message.clientStreaming); - if (message.serverStreaming != null && Object.hasOwnProperty.call(message, "serverStreaming")) - writer.uint32(/* id 6, wireType 0 =*/48).bool(message.serverStreaming); + if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) + writer.uint32(/* id 33, wireType 0 =*/264).bool(message.deprecated); + if (message.idempotencyLevel != null && Object.hasOwnProperty.call(message, "idempotencyLevel")) + writer.uint32(/* id 34, wireType 0 =*/272).int32(message.idempotencyLevel); + if (message.uninterpretedOption != null && message.uninterpretedOption.length) + for (var i = 0; i < message.uninterpretedOption.length; ++i) + $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message[".google.longrunning.operationInfo"] != null && Object.hasOwnProperty.call(message, ".google.longrunning.operationInfo")) + $root.google.longrunning.OperationInfo.encode(message[".google.longrunning.operationInfo"], writer.uint32(/* id 1049, wireType 2 =*/8394).fork()).ldelim(); + if (message[".google.api.methodSignature"] != null && message[".google.api.methodSignature"].length) + for (var i = 0; i < message[".google.api.methodSignature"].length; ++i) + writer.uint32(/* id 1051, wireType 2 =*/8410).string(message[".google.api.methodSignature"][i]); + if (message[".google.api.http"] != null && Object.hasOwnProperty.call(message, ".google.api.http")) + $root.google.api.HttpRule.encode(message[".google.api.http"], writer.uint32(/* id 72295728, wireType 2 =*/578365826).fork()).ldelim(); return writer; }; /** - * Encodes the specified MethodDescriptorProto message, length delimited. Does not implicitly {@link google.protobuf.MethodDescriptorProto.verify|verify} messages. + * Encodes the specified MethodOptions message, length delimited. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static - * @param {google.protobuf.IMethodDescriptorProto} message MethodDescriptorProto message or plain object to encode + * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MethodDescriptorProto.encodeDelimited = function encodeDelimited(message, writer) { + MethodOptions.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer. + * Decodes a MethodOptions message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto + * @returns {google.protobuf.MethodOptions} MethodOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MethodDescriptorProto.decode = function decode(reader, length) { + MethodOptions.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MethodDescriptorProto(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MethodOptions(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.name = reader.string(); + case 33: { + message.deprecated = reader.bool(); break; } - case 2: { - message.inputType = reader.string(); + case 34: { + message.idempotencyLevel = reader.int32(); break; } - case 3: { - message.outputType = reader.string(); + case 999: { + if (!(message.uninterpretedOption && message.uninterpretedOption.length)) + message.uninterpretedOption = []; + message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); break; } - case 4: { - message.options = $root.google.protobuf.MethodOptions.decode(reader, reader.uint32()); + case 72295728: { + message[".google.api.http"] = $root.google.api.HttpRule.decode(reader, reader.uint32()); break; } - case 5: { - message.clientStreaming = reader.bool(); + case 1051: { + if (!(message[".google.api.methodSignature"] && message[".google.api.methodSignature"].length)) + message[".google.api.methodSignature"] = []; + message[".google.api.methodSignature"].push(reader.string()); break; } - case 6: { - message.serverStreaming = reader.bool(); + case 1049: { + message[".google.longrunning.operationInfo"] = $root.google.longrunning.OperationInfo.decode(reader, reader.uint32()); break; } default: @@ -55372,567 +62967,414 @@ }; /** - * Decodes a MethodDescriptorProto message from the specified reader or buffer, length delimited. + * Decodes a MethodOptions message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto + * @returns {google.protobuf.MethodOptions} MethodOptions * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MethodDescriptorProto.decodeDelimited = function decodeDelimited(reader) { + MethodOptions.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a MethodDescriptorProto message. + * Verifies a MethodOptions message. * @function verify - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - MethodDescriptorProto.verify = function verify(message) { + MethodOptions.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) - if (!$util.isString(message.name)) - return "name: string expected"; - if (message.inputType != null && message.hasOwnProperty("inputType")) - if (!$util.isString(message.inputType)) - return "inputType: string expected"; - if (message.outputType != null && message.hasOwnProperty("outputType")) - if (!$util.isString(message.outputType)) - return "outputType: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.protobuf.MethodOptions.verify(message.options); + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + if (typeof message.deprecated !== "boolean") + return "deprecated: boolean expected"; + if (message.idempotencyLevel != null && message.hasOwnProperty("idempotencyLevel")) + switch (message.idempotencyLevel) { + default: + return "idempotencyLevel: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { + if (!Array.isArray(message.uninterpretedOption)) + return "uninterpretedOption: array expected"; + for (var i = 0; i < message.uninterpretedOption.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (error) + return "uninterpretedOption." + error; + } + } + if (message[".google.api.http"] != null && message.hasOwnProperty(".google.api.http")) { + var error = $root.google.api.HttpRule.verify(message[".google.api.http"]); if (error) - return "options." + error; + return ".google.api.http." + error; + } + if (message[".google.api.methodSignature"] != null && message.hasOwnProperty(".google.api.methodSignature")) { + if (!Array.isArray(message[".google.api.methodSignature"])) + return ".google.api.methodSignature: array expected"; + for (var i = 0; i < message[".google.api.methodSignature"].length; ++i) + if (!$util.isString(message[".google.api.methodSignature"][i])) + return ".google.api.methodSignature: string[] expected"; + } + if (message[".google.longrunning.operationInfo"] != null && message.hasOwnProperty(".google.longrunning.operationInfo")) { + var error = $root.google.longrunning.OperationInfo.verify(message[".google.longrunning.operationInfo"]); + if (error) + return ".google.longrunning.operationInfo." + error; } - if (message.clientStreaming != null && message.hasOwnProperty("clientStreaming")) - if (typeof message.clientStreaming !== "boolean") - return "clientStreaming: boolean expected"; - if (message.serverStreaming != null && message.hasOwnProperty("serverStreaming")) - if (typeof message.serverStreaming !== "boolean") - return "serverStreaming: boolean expected"; return null; }; /** - * Creates a MethodDescriptorProto message from a plain object. Also converts values to their respective internal types. + * Creates a MethodOptions message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static * @param {Object.} object Plain object - * @returns {google.protobuf.MethodDescriptorProto} MethodDescriptorProto + * @returns {google.protobuf.MethodOptions} MethodOptions */ - MethodDescriptorProto.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MethodDescriptorProto) + MethodOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.MethodOptions) return object; - var message = new $root.google.protobuf.MethodDescriptorProto(); - if (object.name != null) - message.name = String(object.name); - if (object.inputType != null) - message.inputType = String(object.inputType); - if (object.outputType != null) - message.outputType = String(object.outputType); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.protobuf.MethodDescriptorProto.options: object expected"); - message.options = $root.google.protobuf.MethodOptions.fromObject(object.options); + var message = new $root.google.protobuf.MethodOptions(); + if (object.deprecated != null) + message.deprecated = Boolean(object.deprecated); + switch (object.idempotencyLevel) { + default: + if (typeof object.idempotencyLevel === "number") { + message.idempotencyLevel = object.idempotencyLevel; + break; + } + break; + case "IDEMPOTENCY_UNKNOWN": + case 0: + message.idempotencyLevel = 0; + break; + case "NO_SIDE_EFFECTS": + case 1: + message.idempotencyLevel = 1; + break; + case "IDEMPOTENT": + case 2: + message.idempotencyLevel = 2; + break; + } + if (object.uninterpretedOption) { + if (!Array.isArray(object.uninterpretedOption)) + throw TypeError(".google.protobuf.MethodOptions.uninterpretedOption: array expected"); + message.uninterpretedOption = []; + for (var i = 0; i < object.uninterpretedOption.length; ++i) { + if (typeof object.uninterpretedOption[i] !== "object") + throw TypeError(".google.protobuf.MethodOptions.uninterpretedOption: object expected"); + message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + } + } + if (object[".google.api.http"] != null) { + if (typeof object[".google.api.http"] !== "object") + throw TypeError(".google.protobuf.MethodOptions..google.api.http: object expected"); + message[".google.api.http"] = $root.google.api.HttpRule.fromObject(object[".google.api.http"]); + } + if (object[".google.api.methodSignature"]) { + if (!Array.isArray(object[".google.api.methodSignature"])) + throw TypeError(".google.protobuf.MethodOptions..google.api.methodSignature: array expected"); + message[".google.api.methodSignature"] = []; + for (var i = 0; i < object[".google.api.methodSignature"].length; ++i) + message[".google.api.methodSignature"][i] = String(object[".google.api.methodSignature"][i]); + } + if (object[".google.longrunning.operationInfo"] != null) { + if (typeof object[".google.longrunning.operationInfo"] !== "object") + throw TypeError(".google.protobuf.MethodOptions..google.longrunning.operationInfo: object expected"); + message[".google.longrunning.operationInfo"] = $root.google.longrunning.OperationInfo.fromObject(object[".google.longrunning.operationInfo"]); } - if (object.clientStreaming != null) - message.clientStreaming = Boolean(object.clientStreaming); - if (object.serverStreaming != null) - message.serverStreaming = Boolean(object.serverStreaming); return message; }; /** - * Creates a plain object from a MethodDescriptorProto message. Also converts values to other types if specified. + * Creates a plain object from a MethodOptions message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static - * @param {google.protobuf.MethodDescriptorProto} message MethodDescriptorProto + * @param {google.protobuf.MethodOptions} message MethodOptions * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - MethodDescriptorProto.toObject = function toObject(message, options) { + MethodOptions.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) { + object.uninterpretedOption = []; + object[".google.api.methodSignature"] = []; + } if (options.defaults) { - object.name = ""; - object.inputType = ""; - object.outputType = ""; - object.options = null; - object.clientStreaming = false; - object.serverStreaming = false; + object.deprecated = false; + object.idempotencyLevel = options.enums === String ? "IDEMPOTENCY_UNKNOWN" : 0; + object[".google.longrunning.operationInfo"] = null; + object[".google.api.http"] = null; } - if (message.name != null && message.hasOwnProperty("name")) - object.name = message.name; - if (message.inputType != null && message.hasOwnProperty("inputType")) - object.inputType = message.inputType; - if (message.outputType != null && message.hasOwnProperty("outputType")) - object.outputType = message.outputType; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.protobuf.MethodOptions.toObject(message.options, options); - if (message.clientStreaming != null && message.hasOwnProperty("clientStreaming")) - object.clientStreaming = message.clientStreaming; - if (message.serverStreaming != null && message.hasOwnProperty("serverStreaming")) - object.serverStreaming = message.serverStreaming; + if (message.deprecated != null && message.hasOwnProperty("deprecated")) + object.deprecated = message.deprecated; + if (message.idempotencyLevel != null && message.hasOwnProperty("idempotencyLevel")) + object.idempotencyLevel = options.enums === String ? $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] === undefined ? message.idempotencyLevel : $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] : message.idempotencyLevel; + if (message.uninterpretedOption && message.uninterpretedOption.length) { + object.uninterpretedOption = []; + for (var j = 0; j < message.uninterpretedOption.length; ++j) + object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + } + if (message[".google.longrunning.operationInfo"] != null && message.hasOwnProperty(".google.longrunning.operationInfo")) + object[".google.longrunning.operationInfo"] = $root.google.longrunning.OperationInfo.toObject(message[".google.longrunning.operationInfo"], options); + if (message[".google.api.methodSignature"] && message[".google.api.methodSignature"].length) { + object[".google.api.methodSignature"] = []; + for (var j = 0; j < message[".google.api.methodSignature"].length; ++j) + object[".google.api.methodSignature"][j] = message[".google.api.methodSignature"][j]; + } + if (message[".google.api.http"] != null && message.hasOwnProperty(".google.api.http")) + object[".google.api.http"] = $root.google.api.HttpRule.toObject(message[".google.api.http"], options); return object; }; /** - * Converts this MethodDescriptorProto to JSON. + * Converts this MethodOptions to JSON. * @function toJSON - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @instance * @returns {Object.} JSON object */ - MethodDescriptorProto.prototype.toJSON = function toJSON() { + MethodOptions.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for MethodDescriptorProto + * Gets the default type url for MethodOptions * @function getTypeUrl - * @memberof google.protobuf.MethodDescriptorProto + * @memberof google.protobuf.MethodOptions * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - MethodDescriptorProto.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + MethodOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.MethodDescriptorProto"; + return typeUrlPrefix + "/google.protobuf.MethodOptions"; }; - return MethodDescriptorProto; - })(); - - protobuf.FileOptions = (function() { - - /** - * Properties of a FileOptions. - * @memberof google.protobuf - * @interface IFileOptions - * @property {string|null} [javaPackage] FileOptions javaPackage - * @property {string|null} [javaOuterClassname] FileOptions javaOuterClassname - * @property {boolean|null} [javaMultipleFiles] FileOptions javaMultipleFiles - * @property {boolean|null} [javaGenerateEqualsAndHash] FileOptions javaGenerateEqualsAndHash - * @property {boolean|null} [javaStringCheckUtf8] FileOptions javaStringCheckUtf8 - * @property {google.protobuf.FileOptions.OptimizeMode|null} [optimizeFor] FileOptions optimizeFor - * @property {string|null} [goPackage] FileOptions goPackage - * @property {boolean|null} [ccGenericServices] FileOptions ccGenericServices - * @property {boolean|null} [javaGenericServices] FileOptions javaGenericServices - * @property {boolean|null} [pyGenericServices] FileOptions pyGenericServices - * @property {boolean|null} [phpGenericServices] FileOptions phpGenericServices - * @property {boolean|null} [deprecated] FileOptions deprecated - * @property {boolean|null} [ccEnableArenas] FileOptions ccEnableArenas - * @property {string|null} [objcClassPrefix] FileOptions objcClassPrefix - * @property {string|null} [csharpNamespace] FileOptions csharpNamespace - * @property {string|null} [swiftPrefix] FileOptions swiftPrefix - * @property {string|null} [phpClassPrefix] FileOptions phpClassPrefix - * @property {string|null} [phpNamespace] FileOptions phpNamespace - * @property {string|null} [phpMetadataNamespace] FileOptions phpMetadataNamespace - * @property {string|null} [rubyPackage] FileOptions rubyPackage - * @property {Array.|null} [uninterpretedOption] FileOptions uninterpretedOption - * @property {Array.|null} [".google.api.resourceDefinition"] FileOptions .google.api.resourceDefinition - */ - - /** - * Constructs a new FileOptions. - * @memberof google.protobuf - * @classdesc Represents a FileOptions. - * @implements IFileOptions - * @constructor - * @param {google.protobuf.IFileOptions=} [properties] Properties to set - */ - function FileOptions(properties) { - this.uninterpretedOption = []; - this[".google.api.resourceDefinition"] = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * FileOptions javaPackage. - * @member {string} javaPackage - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaPackage = ""; - - /** - * FileOptions javaOuterClassname. - * @member {string} javaOuterClassname - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaOuterClassname = ""; - - /** - * FileOptions javaMultipleFiles. - * @member {boolean} javaMultipleFiles - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaMultipleFiles = false; - - /** - * FileOptions javaGenerateEqualsAndHash. - * @member {boolean} javaGenerateEqualsAndHash - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaGenerateEqualsAndHash = false; - - /** - * FileOptions javaStringCheckUtf8. - * @member {boolean} javaStringCheckUtf8 - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaStringCheckUtf8 = false; - - /** - * FileOptions optimizeFor. - * @member {google.protobuf.FileOptions.OptimizeMode} optimizeFor - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.optimizeFor = 1; - - /** - * FileOptions goPackage. - * @member {string} goPackage - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.goPackage = ""; - - /** - * FileOptions ccGenericServices. - * @member {boolean} ccGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.ccGenericServices = false; - - /** - * FileOptions javaGenericServices. - * @member {boolean} javaGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.javaGenericServices = false; - - /** - * FileOptions pyGenericServices. - * @member {boolean} pyGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.pyGenericServices = false; - - /** - * FileOptions phpGenericServices. - * @member {boolean} phpGenericServices - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.phpGenericServices = false; - /** - * FileOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.FileOptions - * @instance + * IdempotencyLevel enum. + * @name google.protobuf.MethodOptions.IdempotencyLevel + * @enum {number} + * @property {number} IDEMPOTENCY_UNKNOWN=0 IDEMPOTENCY_UNKNOWN value + * @property {number} NO_SIDE_EFFECTS=1 NO_SIDE_EFFECTS value + * @property {number} IDEMPOTENT=2 IDEMPOTENT value */ - FileOptions.prototype.deprecated = false; + MethodOptions.IdempotencyLevel = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "IDEMPOTENCY_UNKNOWN"] = 0; + values[valuesById[1] = "NO_SIDE_EFFECTS"] = 1; + values[valuesById[2] = "IDEMPOTENT"] = 2; + return values; + })(); - /** - * FileOptions ccEnableArenas. - * @member {boolean} ccEnableArenas - * @memberof google.protobuf.FileOptions - * @instance - */ - FileOptions.prototype.ccEnableArenas = true; + return MethodOptions; + })(); + + protobuf.UninterpretedOption = (function() { /** - * FileOptions objcClassPrefix. - * @member {string} objcClassPrefix - * @memberof google.protobuf.FileOptions - * @instance + * Properties of an UninterpretedOption. + * @memberof google.protobuf + * @interface IUninterpretedOption + * @property {Array.|null} [name] UninterpretedOption name + * @property {string|null} [identifierValue] UninterpretedOption identifierValue + * @property {number|Long|null} [positiveIntValue] UninterpretedOption positiveIntValue + * @property {number|Long|null} [negativeIntValue] UninterpretedOption negativeIntValue + * @property {number|null} [doubleValue] UninterpretedOption doubleValue + * @property {Uint8Array|null} [stringValue] UninterpretedOption stringValue + * @property {string|null} [aggregateValue] UninterpretedOption aggregateValue */ - FileOptions.prototype.objcClassPrefix = ""; /** - * FileOptions csharpNamespace. - * @member {string} csharpNamespace - * @memberof google.protobuf.FileOptions - * @instance + * Constructs a new UninterpretedOption. + * @memberof google.protobuf + * @classdesc Represents an UninterpretedOption. + * @implements IUninterpretedOption + * @constructor + * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set */ - FileOptions.prototype.csharpNamespace = ""; + function UninterpretedOption(properties) { + this.name = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * FileOptions swiftPrefix. - * @member {string} swiftPrefix - * @memberof google.protobuf.FileOptions + * UninterpretedOption name. + * @member {Array.} name + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.swiftPrefix = ""; + UninterpretedOption.prototype.name = $util.emptyArray; /** - * FileOptions phpClassPrefix. - * @member {string} phpClassPrefix - * @memberof google.protobuf.FileOptions + * UninterpretedOption identifierValue. + * @member {string} identifierValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.phpClassPrefix = ""; + UninterpretedOption.prototype.identifierValue = ""; /** - * FileOptions phpNamespace. - * @member {string} phpNamespace - * @memberof google.protobuf.FileOptions + * UninterpretedOption positiveIntValue. + * @member {number|Long} positiveIntValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.phpNamespace = ""; + UninterpretedOption.prototype.positiveIntValue = $util.Long ? $util.Long.fromBits(0,0,true) : 0; /** - * FileOptions phpMetadataNamespace. - * @member {string} phpMetadataNamespace - * @memberof google.protobuf.FileOptions + * UninterpretedOption negativeIntValue. + * @member {number|Long} negativeIntValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.phpMetadataNamespace = ""; + UninterpretedOption.prototype.negativeIntValue = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * FileOptions rubyPackage. - * @member {string} rubyPackage - * @memberof google.protobuf.FileOptions + * UninterpretedOption doubleValue. + * @member {number} doubleValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.rubyPackage = ""; + UninterpretedOption.prototype.doubleValue = 0; /** - * FileOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.FileOptions + * UninterpretedOption stringValue. + * @member {Uint8Array} stringValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype.uninterpretedOption = $util.emptyArray; + UninterpretedOption.prototype.stringValue = $util.newBuffer([]); /** - * FileOptions .google.api.resourceDefinition. - * @member {Array.} .google.api.resourceDefinition - * @memberof google.protobuf.FileOptions + * UninterpretedOption aggregateValue. + * @member {string} aggregateValue + * @memberof google.protobuf.UninterpretedOption * @instance */ - FileOptions.prototype[".google.api.resourceDefinition"] = $util.emptyArray; + UninterpretedOption.prototype.aggregateValue = ""; /** - * Creates a new FileOptions instance using the specified properties. + * Creates a new UninterpretedOption instance using the specified properties. * @function create - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static - * @param {google.protobuf.IFileOptions=} [properties] Properties to set - * @returns {google.protobuf.FileOptions} FileOptions instance + * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set + * @returns {google.protobuf.UninterpretedOption} UninterpretedOption instance */ - FileOptions.create = function create(properties) { - return new FileOptions(properties); + UninterpretedOption.create = function create(properties) { + return new UninterpretedOption(properties); }; /** - * Encodes the specified FileOptions message. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. + * Encodes the specified UninterpretedOption message. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. * @function encode - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static - * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode + * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileOptions.encode = function encode(message, writer) { + UninterpretedOption.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.javaPackage != null && Object.hasOwnProperty.call(message, "javaPackage")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.javaPackage); - if (message.javaOuterClassname != null && Object.hasOwnProperty.call(message, "javaOuterClassname")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.javaOuterClassname); - if (message.optimizeFor != null && Object.hasOwnProperty.call(message, "optimizeFor")) - writer.uint32(/* id 9, wireType 0 =*/72).int32(message.optimizeFor); - if (message.javaMultipleFiles != null && Object.hasOwnProperty.call(message, "javaMultipleFiles")) - writer.uint32(/* id 10, wireType 0 =*/80).bool(message.javaMultipleFiles); - if (message.goPackage != null && Object.hasOwnProperty.call(message, "goPackage")) - writer.uint32(/* id 11, wireType 2 =*/90).string(message.goPackage); - if (message.ccGenericServices != null && Object.hasOwnProperty.call(message, "ccGenericServices")) - writer.uint32(/* id 16, wireType 0 =*/128).bool(message.ccGenericServices); - if (message.javaGenericServices != null && Object.hasOwnProperty.call(message, "javaGenericServices")) - writer.uint32(/* id 17, wireType 0 =*/136).bool(message.javaGenericServices); - if (message.pyGenericServices != null && Object.hasOwnProperty.call(message, "pyGenericServices")) - writer.uint32(/* id 18, wireType 0 =*/144).bool(message.pyGenericServices); - if (message.javaGenerateEqualsAndHash != null && Object.hasOwnProperty.call(message, "javaGenerateEqualsAndHash")) - writer.uint32(/* id 20, wireType 0 =*/160).bool(message.javaGenerateEqualsAndHash); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 23, wireType 0 =*/184).bool(message.deprecated); - if (message.javaStringCheckUtf8 != null && Object.hasOwnProperty.call(message, "javaStringCheckUtf8")) - writer.uint32(/* id 27, wireType 0 =*/216).bool(message.javaStringCheckUtf8); - if (message.ccEnableArenas != null && Object.hasOwnProperty.call(message, "ccEnableArenas")) - writer.uint32(/* id 31, wireType 0 =*/248).bool(message.ccEnableArenas); - if (message.objcClassPrefix != null && Object.hasOwnProperty.call(message, "objcClassPrefix")) - writer.uint32(/* id 36, wireType 2 =*/290).string(message.objcClassPrefix); - if (message.csharpNamespace != null && Object.hasOwnProperty.call(message, "csharpNamespace")) - writer.uint32(/* id 37, wireType 2 =*/298).string(message.csharpNamespace); - if (message.swiftPrefix != null && Object.hasOwnProperty.call(message, "swiftPrefix")) - writer.uint32(/* id 39, wireType 2 =*/314).string(message.swiftPrefix); - if (message.phpClassPrefix != null && Object.hasOwnProperty.call(message, "phpClassPrefix")) - writer.uint32(/* id 40, wireType 2 =*/322).string(message.phpClassPrefix); - if (message.phpNamespace != null && Object.hasOwnProperty.call(message, "phpNamespace")) - writer.uint32(/* id 41, wireType 2 =*/330).string(message.phpNamespace); - if (message.phpGenericServices != null && Object.hasOwnProperty.call(message, "phpGenericServices")) - writer.uint32(/* id 42, wireType 0 =*/336).bool(message.phpGenericServices); - if (message.phpMetadataNamespace != null && Object.hasOwnProperty.call(message, "phpMetadataNamespace")) - writer.uint32(/* id 44, wireType 2 =*/354).string(message.phpMetadataNamespace); - if (message.rubyPackage != null && Object.hasOwnProperty.call(message, "rubyPackage")) - writer.uint32(/* id 45, wireType 2 =*/362).string(message.rubyPackage); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); - if (message[".google.api.resourceDefinition"] != null && message[".google.api.resourceDefinition"].length) - for (var i = 0; i < message[".google.api.resourceDefinition"].length; ++i) - $root.google.api.ResourceDescriptor.encode(message[".google.api.resourceDefinition"][i], writer.uint32(/* id 1053, wireType 2 =*/8426).fork()).ldelim(); + if (message.name != null && message.name.length) + for (var i = 0; i < message.name.length; ++i) + $root.google.protobuf.UninterpretedOption.NamePart.encode(message.name[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.identifierValue != null && Object.hasOwnProperty.call(message, "identifierValue")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.identifierValue); + if (message.positiveIntValue != null && Object.hasOwnProperty.call(message, "positiveIntValue")) + writer.uint32(/* id 4, wireType 0 =*/32).uint64(message.positiveIntValue); + if (message.negativeIntValue != null && Object.hasOwnProperty.call(message, "negativeIntValue")) + writer.uint32(/* id 5, wireType 0 =*/40).int64(message.negativeIntValue); + if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) + writer.uint32(/* id 6, wireType 1 =*/49).double(message.doubleValue); + if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) + writer.uint32(/* id 7, wireType 2 =*/58).bytes(message.stringValue); + if (message.aggregateValue != null && Object.hasOwnProperty.call(message, "aggregateValue")) + writer.uint32(/* id 8, wireType 2 =*/66).string(message.aggregateValue); return writer; }; /** - * Encodes the specified FileOptions message, length delimited. Does not implicitly {@link google.protobuf.FileOptions.verify|verify} messages. + * Encodes the specified UninterpretedOption message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static - * @param {google.protobuf.IFileOptions} message FileOptions message or plain object to encode + * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FileOptions.encodeDelimited = function encodeDelimited(message, writer) { + UninterpretedOption.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a FileOptions message from the specified reader or buffer. + * Decodes an UninterpretedOption message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FileOptions} FileOptions + * @returns {google.protobuf.UninterpretedOption} UninterpretedOption * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileOptions.decode = function decode(reader, length) { + UninterpretedOption.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FileOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.UninterpretedOption(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 1: { - message.javaPackage = reader.string(); - break; - } - case 8: { - message.javaOuterClassname = reader.string(); - break; - } - case 10: { - message.javaMultipleFiles = reader.bool(); - break; - } - case 20: { - message.javaGenerateEqualsAndHash = reader.bool(); - break; - } - case 27: { - message.javaStringCheckUtf8 = reader.bool(); - break; - } - case 9: { - message.optimizeFor = reader.int32(); - break; - } - case 11: { - message.goPackage = reader.string(); - break; - } - case 16: { - message.ccGenericServices = reader.bool(); - break; - } - case 17: { - message.javaGenericServices = reader.bool(); - break; - } - case 18: { - message.pyGenericServices = reader.bool(); - break; - } - case 42: { - message.phpGenericServices = reader.bool(); - break; - } - case 23: { - message.deprecated = reader.bool(); - break; - } - case 31: { - message.ccEnableArenas = reader.bool(); - break; - } - case 36: { - message.objcClassPrefix = reader.string(); - break; - } - case 37: { - message.csharpNamespace = reader.string(); - break; - } - case 39: { - message.swiftPrefix = reader.string(); + case 2: { + if (!(message.name && message.name.length)) + message.name = []; + message.name.push($root.google.protobuf.UninterpretedOption.NamePart.decode(reader, reader.uint32())); break; } - case 40: { - message.phpClassPrefix = reader.string(); + case 3: { + message.identifierValue = reader.string(); break; } - case 41: { - message.phpNamespace = reader.string(); + case 4: { + message.positiveIntValue = reader.uint64(); break; } - case 44: { - message.phpMetadataNamespace = reader.string(); + case 5: { + message.negativeIntValue = reader.int64(); break; } - case 45: { - message.rubyPackage = reader.string(); + case 6: { + message.doubleValue = reader.double(); break; } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); + case 7: { + message.stringValue = reader.bytes(); break; } - case 1053: { - if (!(message[".google.api.resourceDefinition"] && message[".google.api.resourceDefinition"].length)) - message[".google.api.resourceDefinition"] = []; - message[".google.api.resourceDefinition"].push($root.google.api.ResourceDescriptor.decode(reader, reader.uint32())); + case 8: { + message.aggregateValue = reader.string(); break; } default: @@ -55944,373 +63386,454 @@ }; /** - * Decodes a FileOptions message from the specified reader or buffer, length delimited. + * Decodes an UninterpretedOption message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FileOptions} FileOptions + * @returns {google.protobuf.UninterpretedOption} UninterpretedOption * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - FileOptions.decodeDelimited = function decodeDelimited(reader) { + UninterpretedOption.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a FileOptions message. + * Verifies an UninterpretedOption message. * @function verify - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - FileOptions.verify = function verify(message) { + UninterpretedOption.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.javaPackage != null && message.hasOwnProperty("javaPackage")) - if (!$util.isString(message.javaPackage)) - return "javaPackage: string expected"; - if (message.javaOuterClassname != null && message.hasOwnProperty("javaOuterClassname")) - if (!$util.isString(message.javaOuterClassname)) - return "javaOuterClassname: string expected"; - if (message.javaMultipleFiles != null && message.hasOwnProperty("javaMultipleFiles")) - if (typeof message.javaMultipleFiles !== "boolean") - return "javaMultipleFiles: boolean expected"; - if (message.javaGenerateEqualsAndHash != null && message.hasOwnProperty("javaGenerateEqualsAndHash")) - if (typeof message.javaGenerateEqualsAndHash !== "boolean") - return "javaGenerateEqualsAndHash: boolean expected"; - if (message.javaStringCheckUtf8 != null && message.hasOwnProperty("javaStringCheckUtf8")) - if (typeof message.javaStringCheckUtf8 !== "boolean") - return "javaStringCheckUtf8: boolean expected"; - if (message.optimizeFor != null && message.hasOwnProperty("optimizeFor")) - switch (message.optimizeFor) { - default: - return "optimizeFor: enum value expected"; - case 1: - case 2: - case 3: - break; - } - if (message.goPackage != null && message.hasOwnProperty("goPackage")) - if (!$util.isString(message.goPackage)) - return "goPackage: string expected"; - if (message.ccGenericServices != null && message.hasOwnProperty("ccGenericServices")) - if (typeof message.ccGenericServices !== "boolean") - return "ccGenericServices: boolean expected"; - if (message.javaGenericServices != null && message.hasOwnProperty("javaGenericServices")) - if (typeof message.javaGenericServices !== "boolean") - return "javaGenericServices: boolean expected"; - if (message.pyGenericServices != null && message.hasOwnProperty("pyGenericServices")) - if (typeof message.pyGenericServices !== "boolean") - return "pyGenericServices: boolean expected"; - if (message.phpGenericServices != null && message.hasOwnProperty("phpGenericServices")) - if (typeof message.phpGenericServices !== "boolean") - return "phpGenericServices: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.ccEnableArenas != null && message.hasOwnProperty("ccEnableArenas")) - if (typeof message.ccEnableArenas !== "boolean") - return "ccEnableArenas: boolean expected"; - if (message.objcClassPrefix != null && message.hasOwnProperty("objcClassPrefix")) - if (!$util.isString(message.objcClassPrefix)) - return "objcClassPrefix: string expected"; - if (message.csharpNamespace != null && message.hasOwnProperty("csharpNamespace")) - if (!$util.isString(message.csharpNamespace)) - return "csharpNamespace: string expected"; - if (message.swiftPrefix != null && message.hasOwnProperty("swiftPrefix")) - if (!$util.isString(message.swiftPrefix)) - return "swiftPrefix: string expected"; - if (message.phpClassPrefix != null && message.hasOwnProperty("phpClassPrefix")) - if (!$util.isString(message.phpClassPrefix)) - return "phpClassPrefix: string expected"; - if (message.phpNamespace != null && message.hasOwnProperty("phpNamespace")) - if (!$util.isString(message.phpNamespace)) - return "phpNamespace: string expected"; - if (message.phpMetadataNamespace != null && message.hasOwnProperty("phpMetadataNamespace")) - if (!$util.isString(message.phpMetadataNamespace)) - return "phpMetadataNamespace: string expected"; - if (message.rubyPackage != null && message.hasOwnProperty("rubyPackage")) - if (!$util.isString(message.rubyPackage)) - return "rubyPackage: string expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } - if (message[".google.api.resourceDefinition"] != null && message.hasOwnProperty(".google.api.resourceDefinition")) { - if (!Array.isArray(message[".google.api.resourceDefinition"])) - return ".google.api.resourceDefinition: array expected"; - for (var i = 0; i < message[".google.api.resourceDefinition"].length; ++i) { - var error = $root.google.api.ResourceDescriptor.verify(message[".google.api.resourceDefinition"][i]); + if (message.name != null && message.hasOwnProperty("name")) { + if (!Array.isArray(message.name)) + return "name: array expected"; + for (var i = 0; i < message.name.length; ++i) { + var error = $root.google.protobuf.UninterpretedOption.NamePart.verify(message.name[i]); if (error) - return ".google.api.resourceDefinition." + error; + return "name." + error; } } + if (message.identifierValue != null && message.hasOwnProperty("identifierValue")) + if (!$util.isString(message.identifierValue)) + return "identifierValue: string expected"; + if (message.positiveIntValue != null && message.hasOwnProperty("positiveIntValue")) + if (!$util.isInteger(message.positiveIntValue) && !(message.positiveIntValue && $util.isInteger(message.positiveIntValue.low) && $util.isInteger(message.positiveIntValue.high))) + return "positiveIntValue: integer|Long expected"; + if (message.negativeIntValue != null && message.hasOwnProperty("negativeIntValue")) + if (!$util.isInteger(message.negativeIntValue) && !(message.negativeIntValue && $util.isInteger(message.negativeIntValue.low) && $util.isInteger(message.negativeIntValue.high))) + return "negativeIntValue: integer|Long expected"; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) + if (typeof message.doubleValue !== "number") + return "doubleValue: number expected"; + if (message.stringValue != null && message.hasOwnProperty("stringValue")) + if (!(message.stringValue && typeof message.stringValue.length === "number" || $util.isString(message.stringValue))) + return "stringValue: buffer expected"; + if (message.aggregateValue != null && message.hasOwnProperty("aggregateValue")) + if (!$util.isString(message.aggregateValue)) + return "aggregateValue: string expected"; return null; }; /** - * Creates a FileOptions message from a plain object. Also converts values to their respective internal types. + * Creates an UninterpretedOption message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static * @param {Object.} object Plain object - * @returns {google.protobuf.FileOptions} FileOptions + * @returns {google.protobuf.UninterpretedOption} UninterpretedOption */ - FileOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FileOptions) + UninterpretedOption.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.UninterpretedOption) return object; - var message = new $root.google.protobuf.FileOptions(); - if (object.javaPackage != null) - message.javaPackage = String(object.javaPackage); - if (object.javaOuterClassname != null) - message.javaOuterClassname = String(object.javaOuterClassname); - if (object.javaMultipleFiles != null) - message.javaMultipleFiles = Boolean(object.javaMultipleFiles); - if (object.javaGenerateEqualsAndHash != null) - message.javaGenerateEqualsAndHash = Boolean(object.javaGenerateEqualsAndHash); - if (object.javaStringCheckUtf8 != null) - message.javaStringCheckUtf8 = Boolean(object.javaStringCheckUtf8); - switch (object.optimizeFor) { - default: - if (typeof object.optimizeFor === "number") { - message.optimizeFor = object.optimizeFor; - break; - } - break; - case "SPEED": - case 1: - message.optimizeFor = 1; - break; - case "CODE_SIZE": - case 2: - message.optimizeFor = 2; - break; - case "LITE_RUNTIME": - case 3: - message.optimizeFor = 3; - break; - } - if (object.goPackage != null) - message.goPackage = String(object.goPackage); - if (object.ccGenericServices != null) - message.ccGenericServices = Boolean(object.ccGenericServices); - if (object.javaGenericServices != null) - message.javaGenericServices = Boolean(object.javaGenericServices); - if (object.pyGenericServices != null) - message.pyGenericServices = Boolean(object.pyGenericServices); - if (object.phpGenericServices != null) - message.phpGenericServices = Boolean(object.phpGenericServices); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.ccEnableArenas != null) - message.ccEnableArenas = Boolean(object.ccEnableArenas); - if (object.objcClassPrefix != null) - message.objcClassPrefix = String(object.objcClassPrefix); - if (object.csharpNamespace != null) - message.csharpNamespace = String(object.csharpNamespace); - if (object.swiftPrefix != null) - message.swiftPrefix = String(object.swiftPrefix); - if (object.phpClassPrefix != null) - message.phpClassPrefix = String(object.phpClassPrefix); - if (object.phpNamespace != null) - message.phpNamespace = String(object.phpNamespace); - if (object.phpMetadataNamespace != null) - message.phpMetadataNamespace = String(object.phpMetadataNamespace); - if (object.rubyPackage != null) - message.rubyPackage = String(object.rubyPackage); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.FileOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.FileOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } - if (object[".google.api.resourceDefinition"]) { - if (!Array.isArray(object[".google.api.resourceDefinition"])) - throw TypeError(".google.protobuf.FileOptions..google.api.resourceDefinition: array expected"); - message[".google.api.resourceDefinition"] = []; - for (var i = 0; i < object[".google.api.resourceDefinition"].length; ++i) { - if (typeof object[".google.api.resourceDefinition"][i] !== "object") - throw TypeError(".google.protobuf.FileOptions..google.api.resourceDefinition: object expected"); - message[".google.api.resourceDefinition"][i] = $root.google.api.ResourceDescriptor.fromObject(object[".google.api.resourceDefinition"][i]); + var message = new $root.google.protobuf.UninterpretedOption(); + if (object.name) { + if (!Array.isArray(object.name)) + throw TypeError(".google.protobuf.UninterpretedOption.name: array expected"); + message.name = []; + for (var i = 0; i < object.name.length; ++i) { + if (typeof object.name[i] !== "object") + throw TypeError(".google.protobuf.UninterpretedOption.name: object expected"); + message.name[i] = $root.google.protobuf.UninterpretedOption.NamePart.fromObject(object.name[i]); } } + if (object.identifierValue != null) + message.identifierValue = String(object.identifierValue); + if (object.positiveIntValue != null) + if ($util.Long) + (message.positiveIntValue = $util.Long.fromValue(object.positiveIntValue)).unsigned = true; + else if (typeof object.positiveIntValue === "string") + message.positiveIntValue = parseInt(object.positiveIntValue, 10); + else if (typeof object.positiveIntValue === "number") + message.positiveIntValue = object.positiveIntValue; + else if (typeof object.positiveIntValue === "object") + message.positiveIntValue = new $util.LongBits(object.positiveIntValue.low >>> 0, object.positiveIntValue.high >>> 0).toNumber(true); + if (object.negativeIntValue != null) + if ($util.Long) + (message.negativeIntValue = $util.Long.fromValue(object.negativeIntValue)).unsigned = false; + else if (typeof object.negativeIntValue === "string") + message.negativeIntValue = parseInt(object.negativeIntValue, 10); + else if (typeof object.negativeIntValue === "number") + message.negativeIntValue = object.negativeIntValue; + else if (typeof object.negativeIntValue === "object") + message.negativeIntValue = new $util.LongBits(object.negativeIntValue.low >>> 0, object.negativeIntValue.high >>> 0).toNumber(); + if (object.doubleValue != null) + message.doubleValue = Number(object.doubleValue); + if (object.stringValue != null) + if (typeof object.stringValue === "string") + $util.base64.decode(object.stringValue, message.stringValue = $util.newBuffer($util.base64.length(object.stringValue)), 0); + else if (object.stringValue.length >= 0) + message.stringValue = object.stringValue; + if (object.aggregateValue != null) + message.aggregateValue = String(object.aggregateValue); return message; }; /** - * Creates a plain object from a FileOptions message. Also converts values to other types if specified. + * Creates a plain object from an UninterpretedOption message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static - * @param {google.protobuf.FileOptions} message FileOptions + * @param {google.protobuf.UninterpretedOption} message UninterpretedOption * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FileOptions.toObject = function toObject(message, options) { + UninterpretedOption.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.uninterpretedOption = []; - object[".google.api.resourceDefinition"] = []; - } + if (options.arrays || options.defaults) + object.name = []; if (options.defaults) { - object.javaPackage = ""; - object.javaOuterClassname = ""; - object.optimizeFor = options.enums === String ? "SPEED" : 1; - object.javaMultipleFiles = false; - object.goPackage = ""; - object.ccGenericServices = false; - object.javaGenericServices = false; - object.pyGenericServices = false; - object.javaGenerateEqualsAndHash = false; - object.deprecated = false; - object.javaStringCheckUtf8 = false; - object.ccEnableArenas = true; - object.objcClassPrefix = ""; - object.csharpNamespace = ""; - object.swiftPrefix = ""; - object.phpClassPrefix = ""; - object.phpNamespace = ""; - object.phpGenericServices = false; - object.phpMetadataNamespace = ""; - object.rubyPackage = ""; - } - if (message.javaPackage != null && message.hasOwnProperty("javaPackage")) - object.javaPackage = message.javaPackage; - if (message.javaOuterClassname != null && message.hasOwnProperty("javaOuterClassname")) - object.javaOuterClassname = message.javaOuterClassname; - if (message.optimizeFor != null && message.hasOwnProperty("optimizeFor")) - object.optimizeFor = options.enums === String ? $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] === undefined ? message.optimizeFor : $root.google.protobuf.FileOptions.OptimizeMode[message.optimizeFor] : message.optimizeFor; - if (message.javaMultipleFiles != null && message.hasOwnProperty("javaMultipleFiles")) - object.javaMultipleFiles = message.javaMultipleFiles; - if (message.goPackage != null && message.hasOwnProperty("goPackage")) - object.goPackage = message.goPackage; - if (message.ccGenericServices != null && message.hasOwnProperty("ccGenericServices")) - object.ccGenericServices = message.ccGenericServices; - if (message.javaGenericServices != null && message.hasOwnProperty("javaGenericServices")) - object.javaGenericServices = message.javaGenericServices; - if (message.pyGenericServices != null && message.hasOwnProperty("pyGenericServices")) - object.pyGenericServices = message.pyGenericServices; - if (message.javaGenerateEqualsAndHash != null && message.hasOwnProperty("javaGenerateEqualsAndHash")) - object.javaGenerateEqualsAndHash = message.javaGenerateEqualsAndHash; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.javaStringCheckUtf8 != null && message.hasOwnProperty("javaStringCheckUtf8")) - object.javaStringCheckUtf8 = message.javaStringCheckUtf8; - if (message.ccEnableArenas != null && message.hasOwnProperty("ccEnableArenas")) - object.ccEnableArenas = message.ccEnableArenas; - if (message.objcClassPrefix != null && message.hasOwnProperty("objcClassPrefix")) - object.objcClassPrefix = message.objcClassPrefix; - if (message.csharpNamespace != null && message.hasOwnProperty("csharpNamespace")) - object.csharpNamespace = message.csharpNamespace; - if (message.swiftPrefix != null && message.hasOwnProperty("swiftPrefix")) - object.swiftPrefix = message.swiftPrefix; - if (message.phpClassPrefix != null && message.hasOwnProperty("phpClassPrefix")) - object.phpClassPrefix = message.phpClassPrefix; - if (message.phpNamespace != null && message.hasOwnProperty("phpNamespace")) - object.phpNamespace = message.phpNamespace; - if (message.phpGenericServices != null && message.hasOwnProperty("phpGenericServices")) - object.phpGenericServices = message.phpGenericServices; - if (message.phpMetadataNamespace != null && message.hasOwnProperty("phpMetadataNamespace")) - object.phpMetadataNamespace = message.phpMetadataNamespace; - if (message.rubyPackage != null && message.hasOwnProperty("rubyPackage")) - object.rubyPackage = message.rubyPackage; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + object.identifierValue = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, true); + object.positiveIntValue = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.positiveIntValue = options.longs === String ? "0" : 0; + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.negativeIntValue = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.negativeIntValue = options.longs === String ? "0" : 0; + object.doubleValue = 0; + if (options.bytes === String) + object.stringValue = ""; + else { + object.stringValue = []; + if (options.bytes !== Array) + object.stringValue = $util.newBuffer(object.stringValue); + } + object.aggregateValue = ""; } - if (message[".google.api.resourceDefinition"] && message[".google.api.resourceDefinition"].length) { - object[".google.api.resourceDefinition"] = []; - for (var j = 0; j < message[".google.api.resourceDefinition"].length; ++j) - object[".google.api.resourceDefinition"][j] = $root.google.api.ResourceDescriptor.toObject(message[".google.api.resourceDefinition"][j], options); + if (message.name && message.name.length) { + object.name = []; + for (var j = 0; j < message.name.length; ++j) + object.name[j] = $root.google.protobuf.UninterpretedOption.NamePart.toObject(message.name[j], options); } + if (message.identifierValue != null && message.hasOwnProperty("identifierValue")) + object.identifierValue = message.identifierValue; + if (message.positiveIntValue != null && message.hasOwnProperty("positiveIntValue")) + if (typeof message.positiveIntValue === "number") + object.positiveIntValue = options.longs === String ? String(message.positiveIntValue) : message.positiveIntValue; + else + object.positiveIntValue = options.longs === String ? $util.Long.prototype.toString.call(message.positiveIntValue) : options.longs === Number ? new $util.LongBits(message.positiveIntValue.low >>> 0, message.positiveIntValue.high >>> 0).toNumber(true) : message.positiveIntValue; + if (message.negativeIntValue != null && message.hasOwnProperty("negativeIntValue")) + if (typeof message.negativeIntValue === "number") + object.negativeIntValue = options.longs === String ? String(message.negativeIntValue) : message.negativeIntValue; + else + object.negativeIntValue = options.longs === String ? $util.Long.prototype.toString.call(message.negativeIntValue) : options.longs === Number ? new $util.LongBits(message.negativeIntValue.low >>> 0, message.negativeIntValue.high >>> 0).toNumber() : message.negativeIntValue; + if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) + object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; + if (message.stringValue != null && message.hasOwnProperty("stringValue")) + object.stringValue = options.bytes === String ? $util.base64.encode(message.stringValue, 0, message.stringValue.length) : options.bytes === Array ? Array.prototype.slice.call(message.stringValue) : message.stringValue; + if (message.aggregateValue != null && message.hasOwnProperty("aggregateValue")) + object.aggregateValue = message.aggregateValue; return object; }; /** - * Converts this FileOptions to JSON. + * Converts this UninterpretedOption to JSON. * @function toJSON - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @instance * @returns {Object.} JSON object */ - FileOptions.prototype.toJSON = function toJSON() { + UninterpretedOption.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FileOptions + * Gets the default type url for UninterpretedOption * @function getTypeUrl - * @memberof google.protobuf.FileOptions + * @memberof google.protobuf.UninterpretedOption * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FileOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + UninterpretedOption.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.FileOptions"; + return typeUrlPrefix + "/google.protobuf.UninterpretedOption"; }; - /** - * OptimizeMode enum. - * @name google.protobuf.FileOptions.OptimizeMode - * @enum {number} - * @property {number} SPEED=1 SPEED value - * @property {number} CODE_SIZE=2 CODE_SIZE value - * @property {number} LITE_RUNTIME=3 LITE_RUNTIME value - */ - FileOptions.OptimizeMode = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[1] = "SPEED"] = 1; - values[valuesById[2] = "CODE_SIZE"] = 2; - values[valuesById[3] = "LITE_RUNTIME"] = 3; - return values; + UninterpretedOption.NamePart = (function() { + + /** + * Properties of a NamePart. + * @memberof google.protobuf.UninterpretedOption + * @interface INamePart + * @property {string} namePart NamePart namePart + * @property {boolean} isExtension NamePart isExtension + */ + + /** + * Constructs a new NamePart. + * @memberof google.protobuf.UninterpretedOption + * @classdesc Represents a NamePart. + * @implements INamePart + * @constructor + * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set + */ + function NamePart(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * NamePart namePart. + * @member {string} namePart + * @memberof google.protobuf.UninterpretedOption.NamePart + * @instance + */ + NamePart.prototype.namePart = ""; + + /** + * NamePart isExtension. + * @member {boolean} isExtension + * @memberof google.protobuf.UninterpretedOption.NamePart + * @instance + */ + NamePart.prototype.isExtension = false; + + /** + * Creates a new NamePart instance using the specified properties. + * @function create + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set + * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart instance + */ + NamePart.create = function create(properties) { + return new NamePart(properties); + }; + + /** + * Encodes the specified NamePart message. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * @function encode + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + NamePart.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + writer.uint32(/* id 1, wireType 2 =*/10).string(message.namePart); + writer.uint32(/* id 2, wireType 0 =*/16).bool(message.isExtension); + return writer; + }; + + /** + * Encodes the specified NamePart message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + NamePart.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a NamePart message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + NamePart.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.UninterpretedOption.NamePart(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.namePart = reader.string(); + break; + } + case 2: { + message.isExtension = reader.bool(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + if (!message.hasOwnProperty("namePart")) + throw $util.ProtocolError("missing required 'namePart'", { instance: message }); + if (!message.hasOwnProperty("isExtension")) + throw $util.ProtocolError("missing required 'isExtension'", { instance: message }); + return message; + }; + + /** + * Decodes a NamePart message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + NamePart.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a NamePart message. + * @function verify + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + NamePart.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (!$util.isString(message.namePart)) + return "namePart: string expected"; + if (typeof message.isExtension !== "boolean") + return "isExtension: boolean expected"; + return null; + }; + + /** + * Creates a NamePart message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + */ + NamePart.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.UninterpretedOption.NamePart) + return object; + var message = new $root.google.protobuf.UninterpretedOption.NamePart(); + if (object.namePart != null) + message.namePart = String(object.namePart); + if (object.isExtension != null) + message.isExtension = Boolean(object.isExtension); + return message; + }; + + /** + * Creates a plain object from a NamePart message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {google.protobuf.UninterpretedOption.NamePart} message NamePart + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + NamePart.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.namePart = ""; + object.isExtension = false; + } + if (message.namePart != null && message.hasOwnProperty("namePart")) + object.namePart = message.namePart; + if (message.isExtension != null && message.hasOwnProperty("isExtension")) + object.isExtension = message.isExtension; + return object; + }; + + /** + * Converts this NamePart to JSON. + * @function toJSON + * @memberof google.protobuf.UninterpretedOption.NamePart + * @instance + * @returns {Object.} JSON object + */ + NamePart.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for NamePart + * @function getTypeUrl + * @memberof google.protobuf.UninterpretedOption.NamePart + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + NamePart.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.UninterpretedOption.NamePart"; + }; + + return NamePart; })(); - return FileOptions; + return UninterpretedOption; })(); - protobuf.MessageOptions = (function() { + protobuf.SourceCodeInfo = (function() { /** - * Properties of a MessageOptions. + * Properties of a SourceCodeInfo. * @memberof google.protobuf - * @interface IMessageOptions - * @property {boolean|null} [messageSetWireFormat] MessageOptions messageSetWireFormat - * @property {boolean|null} [noStandardDescriptorAccessor] MessageOptions noStandardDescriptorAccessor - * @property {boolean|null} [deprecated] MessageOptions deprecated - * @property {boolean|null} [mapEntry] MessageOptions mapEntry - * @property {Array.|null} [uninterpretedOption] MessageOptions uninterpretedOption - * @property {google.api.IResourceDescriptor|null} [".google.api.resource"] MessageOptions .google.api.resource + * @interface ISourceCodeInfo + * @property {Array.|null} [location] SourceCodeInfo location */ /** - * Constructs a new MessageOptions. + * Constructs a new SourceCodeInfo. * @memberof google.protobuf - * @classdesc Represents a MessageOptions. - * @implements IMessageOptions + * @classdesc Represents a SourceCodeInfo. + * @implements ISourceCodeInfo * @constructor - * @param {google.protobuf.IMessageOptions=} [properties] Properties to set + * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set */ - function MessageOptions(properties) { - this.uninterpretedOption = []; + function SourceCodeInfo(properties) { + this.location = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -56318,148 +63841,78 @@ } /** - * MessageOptions messageSetWireFormat. - * @member {boolean} messageSetWireFormat - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.messageSetWireFormat = false; - - /** - * MessageOptions noStandardDescriptorAccessor. - * @member {boolean} noStandardDescriptorAccessor - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.noStandardDescriptorAccessor = false; - - /** - * MessageOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.deprecated = false; - - /** - * MessageOptions mapEntry. - * @member {boolean} mapEntry - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.mapEntry = false; - - /** - * MessageOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.MessageOptions - * @instance - */ - MessageOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * MessageOptions .google.api.resource. - * @member {google.api.IResourceDescriptor|null|undefined} .google.api.resource - * @memberof google.protobuf.MessageOptions + * SourceCodeInfo location. + * @member {Array.} location + * @memberof google.protobuf.SourceCodeInfo * @instance */ - MessageOptions.prototype[".google.api.resource"] = null; + SourceCodeInfo.prototype.location = $util.emptyArray; /** - * Creates a new MessageOptions instance using the specified properties. + * Creates a new SourceCodeInfo instance using the specified properties. * @function create - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static - * @param {google.protobuf.IMessageOptions=} [properties] Properties to set - * @returns {google.protobuf.MessageOptions} MessageOptions instance + * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set + * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo instance */ - MessageOptions.create = function create(properties) { - return new MessageOptions(properties); + SourceCodeInfo.create = function create(properties) { + return new SourceCodeInfo(properties); }; /** - * Encodes the specified MessageOptions message. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. + * Encodes the specified SourceCodeInfo message. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. * @function encode - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static - * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode + * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MessageOptions.encode = function encode(message, writer) { + SourceCodeInfo.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.messageSetWireFormat != null && Object.hasOwnProperty.call(message, "messageSetWireFormat")) - writer.uint32(/* id 1, wireType 0 =*/8).bool(message.messageSetWireFormat); - if (message.noStandardDescriptorAccessor != null && Object.hasOwnProperty.call(message, "noStandardDescriptorAccessor")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.noStandardDescriptorAccessor); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); - if (message.mapEntry != null && Object.hasOwnProperty.call(message, "mapEntry")) - writer.uint32(/* id 7, wireType 0 =*/56).bool(message.mapEntry); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); - if (message[".google.api.resource"] != null && Object.hasOwnProperty.call(message, ".google.api.resource")) - $root.google.api.ResourceDescriptor.encode(message[".google.api.resource"], writer.uint32(/* id 1053, wireType 2 =*/8426).fork()).ldelim(); + if (message.location != null && message.location.length) + for (var i = 0; i < message.location.length; ++i) + $root.google.protobuf.SourceCodeInfo.Location.encode(message.location[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); return writer; }; /** - * Encodes the specified MessageOptions message, length delimited. Does not implicitly {@link google.protobuf.MessageOptions.verify|verify} messages. + * Encodes the specified SourceCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static - * @param {google.protobuf.IMessageOptions} message MessageOptions message or plain object to encode + * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MessageOptions.encodeDelimited = function encodeDelimited(message, writer) { + SourceCodeInfo.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a MessageOptions message from the specified reader or buffer. + * Decodes a SourceCodeInfo message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MessageOptions} MessageOptions + * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MessageOptions.decode = function decode(reader, length) { + SourceCodeInfo.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MessageOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.SourceCodeInfo(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.messageSetWireFormat = reader.bool(); - break; - } - case 2: { - message.noStandardDescriptorAccessor = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 7: { - message.mapEntry = reader.bool(); - break; - } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); - break; - } - case 1053: { - message[".google.api.resource"] = $root.google.api.ResourceDescriptor.decode(reader, reader.uint32()); + if (!(message.location && message.location.length)) + message.location = []; + message.location.push($root.google.protobuf.SourceCodeInfo.Location.decode(reader, reader.uint32())); break; } default: @@ -56471,197 +63924,502 @@ }; /** - * Decodes a MessageOptions message from the specified reader or buffer, length delimited. + * Decodes a SourceCodeInfo message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MessageOptions} MessageOptions + * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MessageOptions.decodeDelimited = function decodeDelimited(reader) { + SourceCodeInfo.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a MessageOptions message. + * Verifies a SourceCodeInfo message. * @function verify - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - MessageOptions.verify = function verify(message) { + SourceCodeInfo.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.messageSetWireFormat != null && message.hasOwnProperty("messageSetWireFormat")) - if (typeof message.messageSetWireFormat !== "boolean") - return "messageSetWireFormat: boolean expected"; - if (message.noStandardDescriptorAccessor != null && message.hasOwnProperty("noStandardDescriptorAccessor")) - if (typeof message.noStandardDescriptorAccessor !== "boolean") - return "noStandardDescriptorAccessor: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) - if (typeof message.mapEntry !== "boolean") - return "mapEntry: boolean expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); + if (message.location != null && message.hasOwnProperty("location")) { + if (!Array.isArray(message.location)) + return "location: array expected"; + for (var i = 0; i < message.location.length; ++i) { + var error = $root.google.protobuf.SourceCodeInfo.Location.verify(message.location[i]); if (error) - return "uninterpretedOption." + error; + return "location." + error; } } - if (message[".google.api.resource"] != null && message.hasOwnProperty(".google.api.resource")) { - var error = $root.google.api.ResourceDescriptor.verify(message[".google.api.resource"]); - if (error) - return ".google.api.resource." + error; - } return null; }; /** - * Creates a MessageOptions message from a plain object. Also converts values to their respective internal types. + * Creates a SourceCodeInfo message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static * @param {Object.} object Plain object - * @returns {google.protobuf.MessageOptions} MessageOptions + * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo */ - MessageOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MessageOptions) + SourceCodeInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.SourceCodeInfo) return object; - var message = new $root.google.protobuf.MessageOptions(); - if (object.messageSetWireFormat != null) - message.messageSetWireFormat = Boolean(object.messageSetWireFormat); - if (object.noStandardDescriptorAccessor != null) - message.noStandardDescriptorAccessor = Boolean(object.noStandardDescriptorAccessor); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.mapEntry != null) - message.mapEntry = Boolean(object.mapEntry); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.MessageOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.MessageOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); + var message = new $root.google.protobuf.SourceCodeInfo(); + if (object.location) { + if (!Array.isArray(object.location)) + throw TypeError(".google.protobuf.SourceCodeInfo.location: array expected"); + message.location = []; + for (var i = 0; i < object.location.length; ++i) { + if (typeof object.location[i] !== "object") + throw TypeError(".google.protobuf.SourceCodeInfo.location: object expected"); + message.location[i] = $root.google.protobuf.SourceCodeInfo.Location.fromObject(object.location[i]); } } - if (object[".google.api.resource"] != null) { - if (typeof object[".google.api.resource"] !== "object") - throw TypeError(".google.protobuf.MessageOptions..google.api.resource: object expected"); - message[".google.api.resource"] = $root.google.api.ResourceDescriptor.fromObject(object[".google.api.resource"]); - } return message; }; /** - * Creates a plain object from a MessageOptions message. Also converts values to other types if specified. + * Creates a plain object from a SourceCodeInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.MessageOptions + * @memberof google.protobuf.SourceCodeInfo * @static - * @param {google.protobuf.MessageOptions} message MessageOptions + * @param {google.protobuf.SourceCodeInfo} message SourceCodeInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - MessageOptions.toObject = function toObject(message, options) { + SourceCodeInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.uninterpretedOption = []; - if (options.defaults) { - object.messageSetWireFormat = false; - object.noStandardDescriptorAccessor = false; - object.deprecated = false; - object.mapEntry = false; - object[".google.api.resource"] = null; - } - if (message.messageSetWireFormat != null && message.hasOwnProperty("messageSetWireFormat")) - object.messageSetWireFormat = message.messageSetWireFormat; - if (message.noStandardDescriptorAccessor != null && message.hasOwnProperty("noStandardDescriptorAccessor")) - object.noStandardDescriptorAccessor = message.noStandardDescriptorAccessor; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.mapEntry != null && message.hasOwnProperty("mapEntry")) - object.mapEntry = message.mapEntry; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + object.location = []; + if (message.location && message.location.length) { + object.location = []; + for (var j = 0; j < message.location.length; ++j) + object.location[j] = $root.google.protobuf.SourceCodeInfo.Location.toObject(message.location[j], options); } - if (message[".google.api.resource"] != null && message.hasOwnProperty(".google.api.resource")) - object[".google.api.resource"] = $root.google.api.ResourceDescriptor.toObject(message[".google.api.resource"], options); return object; }; - /** - * Converts this MessageOptions to JSON. - * @function toJSON - * @memberof google.protobuf.MessageOptions - * @instance - * @returns {Object.} JSON object - */ - MessageOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Converts this SourceCodeInfo to JSON. + * @function toJSON + * @memberof google.protobuf.SourceCodeInfo + * @instance + * @returns {Object.} JSON object + */ + SourceCodeInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for SourceCodeInfo + * @function getTypeUrl + * @memberof google.protobuf.SourceCodeInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + SourceCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.SourceCodeInfo"; + }; + + SourceCodeInfo.Location = (function() { + + /** + * Properties of a Location. + * @memberof google.protobuf.SourceCodeInfo + * @interface ILocation + * @property {Array.|null} [path] Location path + * @property {Array.|null} [span] Location span + * @property {string|null} [leadingComments] Location leadingComments + * @property {string|null} [trailingComments] Location trailingComments + * @property {Array.|null} [leadingDetachedComments] Location leadingDetachedComments + */ + + /** + * Constructs a new Location. + * @memberof google.protobuf.SourceCodeInfo + * @classdesc Represents a Location. + * @implements ILocation + * @constructor + * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set + */ + function Location(properties) { + this.path = []; + this.span = []; + this.leadingDetachedComments = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Location path. + * @member {Array.} path + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + */ + Location.prototype.path = $util.emptyArray; + + /** + * Location span. + * @member {Array.} span + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + */ + Location.prototype.span = $util.emptyArray; + + /** + * Location leadingComments. + * @member {string} leadingComments + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + */ + Location.prototype.leadingComments = ""; + + /** + * Location trailingComments. + * @member {string} trailingComments + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + */ + Location.prototype.trailingComments = ""; + + /** + * Location leadingDetachedComments. + * @member {Array.} leadingDetachedComments + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + */ + Location.prototype.leadingDetachedComments = $util.emptyArray; + + /** + * Creates a new Location instance using the specified properties. + * @function create + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set + * @returns {google.protobuf.SourceCodeInfo.Location} Location instance + */ + Location.create = function create(properties) { + return new Location(properties); + }; + + /** + * Encodes the specified Location message. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * @function encode + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Location.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.path != null && message.path.length) { + writer.uint32(/* id 1, wireType 2 =*/10).fork(); + for (var i = 0; i < message.path.length; ++i) + writer.int32(message.path[i]); + writer.ldelim(); + } + if (message.span != null && message.span.length) { + writer.uint32(/* id 2, wireType 2 =*/18).fork(); + for (var i = 0; i < message.span.length; ++i) + writer.int32(message.span[i]); + writer.ldelim(); + } + if (message.leadingComments != null && Object.hasOwnProperty.call(message, "leadingComments")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.leadingComments); + if (message.trailingComments != null && Object.hasOwnProperty.call(message, "trailingComments")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.trailingComments); + if (message.leadingDetachedComments != null && message.leadingDetachedComments.length) + for (var i = 0; i < message.leadingDetachedComments.length; ++i) + writer.uint32(/* id 6, wireType 2 =*/50).string(message.leadingDetachedComments[i]); + return writer; + }; + + /** + * Encodes the specified Location message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Location.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a Location message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Location.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.SourceCodeInfo.Location(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.path && message.path.length)) + message.path = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.path.push(reader.int32()); + } else + message.path.push(reader.int32()); + break; + } + case 2: { + if (!(message.span && message.span.length)) + message.span = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.span.push(reader.int32()); + } else + message.span.push(reader.int32()); + break; + } + case 3: { + message.leadingComments = reader.string(); + break; + } + case 4: { + message.trailingComments = reader.string(); + break; + } + case 6: { + if (!(message.leadingDetachedComments && message.leadingDetachedComments.length)) + message.leadingDetachedComments = []; + message.leadingDetachedComments.push(reader.string()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a Location message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Location.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a Location message. + * @function verify + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Location.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.path != null && message.hasOwnProperty("path")) { + if (!Array.isArray(message.path)) + return "path: array expected"; + for (var i = 0; i < message.path.length; ++i) + if (!$util.isInteger(message.path[i])) + return "path: integer[] expected"; + } + if (message.span != null && message.hasOwnProperty("span")) { + if (!Array.isArray(message.span)) + return "span: array expected"; + for (var i = 0; i < message.span.length; ++i) + if (!$util.isInteger(message.span[i])) + return "span: integer[] expected"; + } + if (message.leadingComments != null && message.hasOwnProperty("leadingComments")) + if (!$util.isString(message.leadingComments)) + return "leadingComments: string expected"; + if (message.trailingComments != null && message.hasOwnProperty("trailingComments")) + if (!$util.isString(message.trailingComments)) + return "trailingComments: string expected"; + if (message.leadingDetachedComments != null && message.hasOwnProperty("leadingDetachedComments")) { + if (!Array.isArray(message.leadingDetachedComments)) + return "leadingDetachedComments: array expected"; + for (var i = 0; i < message.leadingDetachedComments.length; ++i) + if (!$util.isString(message.leadingDetachedComments[i])) + return "leadingDetachedComments: string[] expected"; + } + return null; + }; + + /** + * Creates a Location message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.SourceCodeInfo.Location} Location + */ + Location.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.SourceCodeInfo.Location) + return object; + var message = new $root.google.protobuf.SourceCodeInfo.Location(); + if (object.path) { + if (!Array.isArray(object.path)) + throw TypeError(".google.protobuf.SourceCodeInfo.Location.path: array expected"); + message.path = []; + for (var i = 0; i < object.path.length; ++i) + message.path[i] = object.path[i] | 0; + } + if (object.span) { + if (!Array.isArray(object.span)) + throw TypeError(".google.protobuf.SourceCodeInfo.Location.span: array expected"); + message.span = []; + for (var i = 0; i < object.span.length; ++i) + message.span[i] = object.span[i] | 0; + } + if (object.leadingComments != null) + message.leadingComments = String(object.leadingComments); + if (object.trailingComments != null) + message.trailingComments = String(object.trailingComments); + if (object.leadingDetachedComments) { + if (!Array.isArray(object.leadingDetachedComments)) + throw TypeError(".google.protobuf.SourceCodeInfo.Location.leadingDetachedComments: array expected"); + message.leadingDetachedComments = []; + for (var i = 0; i < object.leadingDetachedComments.length; ++i) + message.leadingDetachedComments[i] = String(object.leadingDetachedComments[i]); + } + return message; + }; + + /** + * Creates a plain object from a Location message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {google.protobuf.SourceCodeInfo.Location} message Location + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Location.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) { + object.path = []; + object.span = []; + object.leadingDetachedComments = []; + } + if (options.defaults) { + object.leadingComments = ""; + object.trailingComments = ""; + } + if (message.path && message.path.length) { + object.path = []; + for (var j = 0; j < message.path.length; ++j) + object.path[j] = message.path[j]; + } + if (message.span && message.span.length) { + object.span = []; + for (var j = 0; j < message.span.length; ++j) + object.span[j] = message.span[j]; + } + if (message.leadingComments != null && message.hasOwnProperty("leadingComments")) + object.leadingComments = message.leadingComments; + if (message.trailingComments != null && message.hasOwnProperty("trailingComments")) + object.trailingComments = message.trailingComments; + if (message.leadingDetachedComments && message.leadingDetachedComments.length) { + object.leadingDetachedComments = []; + for (var j = 0; j < message.leadingDetachedComments.length; ++j) + object.leadingDetachedComments[j] = message.leadingDetachedComments[j]; + } + return object; + }; + + /** + * Converts this Location to JSON. + * @function toJSON + * @memberof google.protobuf.SourceCodeInfo.Location + * @instance + * @returns {Object.} JSON object + */ + Location.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Gets the default type url for MessageOptions - * @function getTypeUrl - * @memberof google.protobuf.MessageOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - MessageOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.MessageOptions"; - }; + /** + * Gets the default type url for Location + * @function getTypeUrl + * @memberof google.protobuf.SourceCodeInfo.Location + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Location.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.SourceCodeInfo.Location"; + }; - return MessageOptions; + return Location; + })(); + + return SourceCodeInfo; })(); - protobuf.FieldOptions = (function() { + protobuf.GeneratedCodeInfo = (function() { /** - * Properties of a FieldOptions. + * Properties of a GeneratedCodeInfo. * @memberof google.protobuf - * @interface IFieldOptions - * @property {google.protobuf.FieldOptions.CType|null} [ctype] FieldOptions ctype - * @property {boolean|null} [packed] FieldOptions packed - * @property {google.protobuf.FieldOptions.JSType|null} [jstype] FieldOptions jstype - * @property {boolean|null} [lazy] FieldOptions lazy - * @property {boolean|null} [unverifiedLazy] FieldOptions unverifiedLazy - * @property {boolean|null} [deprecated] FieldOptions deprecated - * @property {boolean|null} [weak] FieldOptions weak - * @property {Array.|null} [uninterpretedOption] FieldOptions uninterpretedOption - * @property {Array.|null} [".google.api.fieldBehavior"] FieldOptions .google.api.fieldBehavior - * @property {google.api.IResourceReference|null} [".google.api.resourceReference"] FieldOptions .google.api.resourceReference + * @interface IGeneratedCodeInfo + * @property {Array.|null} [annotation] GeneratedCodeInfo annotation */ /** - * Constructs a new FieldOptions. + * Constructs a new GeneratedCodeInfo. * @memberof google.protobuf - * @classdesc Represents a FieldOptions. - * @implements IFieldOptions + * @classdesc Represents a GeneratedCodeInfo. + * @implements IGeneratedCodeInfo * @constructor - * @param {google.protobuf.IFieldOptions=} [properties] Properties to set + * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set */ - function FieldOptions(properties) { - this.uninterpretedOption = []; - this[".google.api.fieldBehavior"] = []; + function GeneratedCodeInfo(properties) { + this.annotation = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -56669,581 +64427,584 @@ } /** - * FieldOptions ctype. - * @member {google.protobuf.FieldOptions.CType} ctype - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.ctype = 0; - - /** - * FieldOptions packed. - * @member {boolean} packed - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.packed = false; - - /** - * FieldOptions jstype. - * @member {google.protobuf.FieldOptions.JSType} jstype - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.jstype = 0; - - /** - * FieldOptions lazy. - * @member {boolean} lazy - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.lazy = false; - - /** - * FieldOptions unverifiedLazy. - * @member {boolean} unverifiedLazy - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.unverifiedLazy = false; - - /** - * FieldOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.deprecated = false; - - /** - * FieldOptions weak. - * @member {boolean} weak - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.weak = false; - - /** - * FieldOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * FieldOptions .google.api.fieldBehavior. - * @member {Array.} .google.api.fieldBehavior - * @memberof google.protobuf.FieldOptions - * @instance - */ - FieldOptions.prototype[".google.api.fieldBehavior"] = $util.emptyArray; - - /** - * FieldOptions .google.api.resourceReference. - * @member {google.api.IResourceReference|null|undefined} .google.api.resourceReference - * @memberof google.protobuf.FieldOptions + * GeneratedCodeInfo annotation. + * @member {Array.} annotation + * @memberof google.protobuf.GeneratedCodeInfo * @instance */ - FieldOptions.prototype[".google.api.resourceReference"] = null; + GeneratedCodeInfo.prototype.annotation = $util.emptyArray; /** - * Creates a new FieldOptions instance using the specified properties. + * Creates a new GeneratedCodeInfo instance using the specified properties. * @function create - * @memberof google.protobuf.FieldOptions + * @memberof google.protobuf.GeneratedCodeInfo * @static - * @param {google.protobuf.IFieldOptions=} [properties] Properties to set - * @returns {google.protobuf.FieldOptions} FieldOptions instance + * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set + * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo instance */ - FieldOptions.create = function create(properties) { - return new FieldOptions(properties); + GeneratedCodeInfo.create = function create(properties) { + return new GeneratedCodeInfo(properties); }; /** - * Encodes the specified FieldOptions message. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. + * Encodes the specified GeneratedCodeInfo message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. * @function encode - * @memberof google.protobuf.FieldOptions + * @memberof google.protobuf.GeneratedCodeInfo * @static - * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode + * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - FieldOptions.encode = function encode(message, writer) { + GeneratedCodeInfo.encode = function encode(message, writer) { if (!writer) - writer = $Writer.create(); - if (message.ctype != null && Object.hasOwnProperty.call(message, "ctype")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.ctype); - if (message.packed != null && Object.hasOwnProperty.call(message, "packed")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.packed); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); - if (message.lazy != null && Object.hasOwnProperty.call(message, "lazy")) - writer.uint32(/* id 5, wireType 0 =*/40).bool(message.lazy); - if (message.jstype != null && Object.hasOwnProperty.call(message, "jstype")) - writer.uint32(/* id 6, wireType 0 =*/48).int32(message.jstype); - if (message.weak != null && Object.hasOwnProperty.call(message, "weak")) - writer.uint32(/* id 10, wireType 0 =*/80).bool(message.weak); - if (message.unverifiedLazy != null && Object.hasOwnProperty.call(message, "unverifiedLazy")) - writer.uint32(/* id 15, wireType 0 =*/120).bool(message.unverifiedLazy); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); - if (message[".google.api.fieldBehavior"] != null && message[".google.api.fieldBehavior"].length) { - writer.uint32(/* id 1052, wireType 2 =*/8418).fork(); - for (var i = 0; i < message[".google.api.fieldBehavior"].length; ++i) - writer.int32(message[".google.api.fieldBehavior"][i]); - writer.ldelim(); - } - if (message[".google.api.resourceReference"] != null && Object.hasOwnProperty.call(message, ".google.api.resourceReference")) - $root.google.api.ResourceReference.encode(message[".google.api.resourceReference"], writer.uint32(/* id 1055, wireType 2 =*/8442).fork()).ldelim(); - return writer; - }; - - /** - * Encodes the specified FieldOptions message, length delimited. Does not implicitly {@link google.protobuf.FieldOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FieldOptions - * @static - * @param {google.protobuf.IFieldOptions} message FieldOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a FieldOptions message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FieldOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldOptions} FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldOptions.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.ctype = reader.int32(); - break; - } - case 2: { - message.packed = reader.bool(); - break; - } - case 6: { - message.jstype = reader.int32(); - break; - } - case 5: { - message.lazy = reader.bool(); - break; - } - case 15: { - message.unverifiedLazy = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 10: { - message.weak = reader.bool(); - break; - } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); - break; - } - case 1052: { - if (!(message[".google.api.fieldBehavior"] && message[".google.api.fieldBehavior"].length)) - message[".google.api.fieldBehavior"] = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message[".google.api.fieldBehavior"].push(reader.int32()); - } else - message[".google.api.fieldBehavior"].push(reader.int32()); - break; - } - case 1055: { - message[".google.api.resourceReference"] = $root.google.api.ResourceReference.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a FieldOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FieldOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldOptions} FieldOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a FieldOptions message. - * @function verify - * @memberof google.protobuf.FieldOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FieldOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.ctype != null && message.hasOwnProperty("ctype")) - switch (message.ctype) { - default: - return "ctype: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.packed != null && message.hasOwnProperty("packed")) - if (typeof message.packed !== "boolean") - return "packed: boolean expected"; - if (message.jstype != null && message.hasOwnProperty("jstype")) - switch (message.jstype) { - default: - return "jstype: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.lazy != null && message.hasOwnProperty("lazy")) - if (typeof message.lazy !== "boolean") - return "lazy: boolean expected"; - if (message.unverifiedLazy != null && message.hasOwnProperty("unverifiedLazy")) - if (typeof message.unverifiedLazy !== "boolean") - return "unverifiedLazy: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.weak != null && message.hasOwnProperty("weak")) - if (typeof message.weak !== "boolean") - return "weak: boolean expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } - if (message[".google.api.fieldBehavior"] != null && message.hasOwnProperty(".google.api.fieldBehavior")) { - if (!Array.isArray(message[".google.api.fieldBehavior"])) - return ".google.api.fieldBehavior: array expected"; - for (var i = 0; i < message[".google.api.fieldBehavior"].length; ++i) - switch (message[".google.api.fieldBehavior"][i]) { - default: - return ".google.api.fieldBehavior: enum value[] expected"; - case 0: - case 1: - case 2: - case 3: - case 4: - case 5: - case 6: - case 7: - break; - } - } - if (message[".google.api.resourceReference"] != null && message.hasOwnProperty(".google.api.resourceReference")) { - var error = $root.google.api.ResourceReference.verify(message[".google.api.resourceReference"]); - if (error) - return ".google.api.resourceReference." + error; - } - return null; - }; - - /** - * Creates a FieldOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FieldOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FieldOptions} FieldOptions - */ - FieldOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FieldOptions) - return object; - var message = new $root.google.protobuf.FieldOptions(); - switch (object.ctype) { - default: - if (typeof object.ctype === "number") { - message.ctype = object.ctype; - break; - } - break; - case "STRING": - case 0: - message.ctype = 0; - break; - case "CORD": - case 1: - message.ctype = 1; - break; - case "STRING_PIECE": - case 2: - message.ctype = 2; - break; - } - if (object.packed != null) - message.packed = Boolean(object.packed); - switch (object.jstype) { - default: - if (typeof object.jstype === "number") { - message.jstype = object.jstype; - break; - } - break; - case "JS_NORMAL": - case 0: - message.jstype = 0; - break; - case "JS_STRING": - case 1: - message.jstype = 1; - break; - case "JS_NUMBER": - case 2: - message.jstype = 2; - break; - } - if (object.lazy != null) - message.lazy = Boolean(object.lazy); - if (object.unverifiedLazy != null) - message.unverifiedLazy = Boolean(object.unverifiedLazy); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.weak != null) - message.weak = Boolean(object.weak); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.FieldOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.FieldOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } - if (object[".google.api.fieldBehavior"]) { - if (!Array.isArray(object[".google.api.fieldBehavior"])) - throw TypeError(".google.protobuf.FieldOptions..google.api.fieldBehavior: array expected"); - message[".google.api.fieldBehavior"] = []; - for (var i = 0; i < object[".google.api.fieldBehavior"].length; ++i) - switch (object[".google.api.fieldBehavior"][i]) { - default: - if (typeof object[".google.api.fieldBehavior"][i] === "number") { - message[".google.api.fieldBehavior"][i] = object[".google.api.fieldBehavior"][i]; - break; - } - case "FIELD_BEHAVIOR_UNSPECIFIED": - case 0: - message[".google.api.fieldBehavior"][i] = 0; - break; - case "OPTIONAL": - case 1: - message[".google.api.fieldBehavior"][i] = 1; - break; - case "REQUIRED": - case 2: - message[".google.api.fieldBehavior"][i] = 2; - break; - case "OUTPUT_ONLY": - case 3: - message[".google.api.fieldBehavior"][i] = 3; - break; - case "INPUT_ONLY": - case 4: - message[".google.api.fieldBehavior"][i] = 4; - break; - case "IMMUTABLE": - case 5: - message[".google.api.fieldBehavior"][i] = 5; - break; - case "UNORDERED_LIST": - case 6: - message[".google.api.fieldBehavior"][i] = 6; - break; - case "NON_EMPTY_DEFAULT": - case 7: - message[".google.api.fieldBehavior"][i] = 7; + writer = $Writer.create(); + if (message.annotation != null && message.annotation.length) + for (var i = 0; i < message.annotation.length; ++i) + $root.google.protobuf.GeneratedCodeInfo.Annotation.encode(message.annotation[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified GeneratedCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.GeneratedCodeInfo + * @static + * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GeneratedCodeInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a GeneratedCodeInfo message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.GeneratedCodeInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GeneratedCodeInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.GeneratedCodeInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.annotation && message.annotation.length)) + message.annotation = []; + message.annotation.push($root.google.protobuf.GeneratedCodeInfo.Annotation.decode(reader, reader.uint32())); break; } + default: + reader.skipType(tag & 7); + break; + } } - if (object[".google.api.resourceReference"] != null) { - if (typeof object[".google.api.resourceReference"] !== "object") - throw TypeError(".google.protobuf.FieldOptions..google.api.resourceReference: object expected"); - message[".google.api.resourceReference"] = $root.google.api.ResourceReference.fromObject(object[".google.api.resourceReference"]); + return message; + }; + + /** + * Decodes a GeneratedCodeInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.GeneratedCodeInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GeneratedCodeInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a GeneratedCodeInfo message. + * @function verify + * @memberof google.protobuf.GeneratedCodeInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GeneratedCodeInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.annotation != null && message.hasOwnProperty("annotation")) { + if (!Array.isArray(message.annotation)) + return "annotation: array expected"; + for (var i = 0; i < message.annotation.length; ++i) { + var error = $root.google.protobuf.GeneratedCodeInfo.Annotation.verify(message.annotation[i]); + if (error) + return "annotation." + error; + } + } + return null; + }; + + /** + * Creates a GeneratedCodeInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.GeneratedCodeInfo + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo + */ + GeneratedCodeInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.GeneratedCodeInfo) + return object; + var message = new $root.google.protobuf.GeneratedCodeInfo(); + if (object.annotation) { + if (!Array.isArray(object.annotation)) + throw TypeError(".google.protobuf.GeneratedCodeInfo.annotation: array expected"); + message.annotation = []; + for (var i = 0; i < object.annotation.length; ++i) { + if (typeof object.annotation[i] !== "object") + throw TypeError(".google.protobuf.GeneratedCodeInfo.annotation: object expected"); + message.annotation[i] = $root.google.protobuf.GeneratedCodeInfo.Annotation.fromObject(object.annotation[i]); + } } return message; }; /** - * Creates a plain object from a FieldOptions message. Also converts values to other types if specified. + * Creates a plain object from a GeneratedCodeInfo message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.FieldOptions + * @memberof google.protobuf.GeneratedCodeInfo * @static - * @param {google.protobuf.FieldOptions} message FieldOptions + * @param {google.protobuf.GeneratedCodeInfo} message GeneratedCodeInfo * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - FieldOptions.toObject = function toObject(message, options) { + GeneratedCodeInfo.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.uninterpretedOption = []; - object[".google.api.fieldBehavior"] = []; - } - if (options.defaults) { - object.ctype = options.enums === String ? "STRING" : 0; - object.packed = false; - object.deprecated = false; - object.lazy = false; - object.jstype = options.enums === String ? "JS_NORMAL" : 0; - object.weak = false; - object.unverifiedLazy = false; - object[".google.api.resourceReference"] = null; - } - if (message.ctype != null && message.hasOwnProperty("ctype")) - object.ctype = options.enums === String ? $root.google.protobuf.FieldOptions.CType[message.ctype] === undefined ? message.ctype : $root.google.protobuf.FieldOptions.CType[message.ctype] : message.ctype; - if (message.packed != null && message.hasOwnProperty("packed")) - object.packed = message.packed; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.lazy != null && message.hasOwnProperty("lazy")) - object.lazy = message.lazy; - if (message.jstype != null && message.hasOwnProperty("jstype")) - object.jstype = options.enums === String ? $root.google.protobuf.FieldOptions.JSType[message.jstype] === undefined ? message.jstype : $root.google.protobuf.FieldOptions.JSType[message.jstype] : message.jstype; - if (message.weak != null && message.hasOwnProperty("weak")) - object.weak = message.weak; - if (message.unverifiedLazy != null && message.hasOwnProperty("unverifiedLazy")) - object.unverifiedLazy = message.unverifiedLazy; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); - } - if (message[".google.api.fieldBehavior"] && message[".google.api.fieldBehavior"].length) { - object[".google.api.fieldBehavior"] = []; - for (var j = 0; j < message[".google.api.fieldBehavior"].length; ++j) - object[".google.api.fieldBehavior"][j] = options.enums === String ? $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] === undefined ? message[".google.api.fieldBehavior"][j] : $root.google.api.FieldBehavior[message[".google.api.fieldBehavior"][j]] : message[".google.api.fieldBehavior"][j]; + if (options.arrays || options.defaults) + object.annotation = []; + if (message.annotation && message.annotation.length) { + object.annotation = []; + for (var j = 0; j < message.annotation.length; ++j) + object.annotation[j] = $root.google.protobuf.GeneratedCodeInfo.Annotation.toObject(message.annotation[j], options); } - if (message[".google.api.resourceReference"] != null && message.hasOwnProperty(".google.api.resourceReference")) - object[".google.api.resourceReference"] = $root.google.api.ResourceReference.toObject(message[".google.api.resourceReference"], options); return object; }; /** - * Converts this FieldOptions to JSON. + * Converts this GeneratedCodeInfo to JSON. * @function toJSON - * @memberof google.protobuf.FieldOptions + * @memberof google.protobuf.GeneratedCodeInfo * @instance * @returns {Object.} JSON object */ - FieldOptions.prototype.toJSON = function toJSON() { + GeneratedCodeInfo.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for FieldOptions + * Gets the default type url for GeneratedCodeInfo * @function getTypeUrl - * @memberof google.protobuf.FieldOptions + * @memberof google.protobuf.GeneratedCodeInfo * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - FieldOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + GeneratedCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.FieldOptions"; + return typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo"; }; - /** - * CType enum. - * @name google.protobuf.FieldOptions.CType - * @enum {number} - * @property {number} STRING=0 STRING value - * @property {number} CORD=1 CORD value - * @property {number} STRING_PIECE=2 STRING_PIECE value - */ - FieldOptions.CType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "STRING"] = 0; - values[valuesById[1] = "CORD"] = 1; - values[valuesById[2] = "STRING_PIECE"] = 2; - return values; - })(); + GeneratedCodeInfo.Annotation = (function() { + + /** + * Properties of an Annotation. + * @memberof google.protobuf.GeneratedCodeInfo + * @interface IAnnotation + * @property {Array.|null} [path] Annotation path + * @property {string|null} [sourceFile] Annotation sourceFile + * @property {number|null} [begin] Annotation begin + * @property {number|null} [end] Annotation end + * @property {google.protobuf.GeneratedCodeInfo.Annotation.Semantic|null} [semantic] Annotation semantic + */ + + /** + * Constructs a new Annotation. + * @memberof google.protobuf.GeneratedCodeInfo + * @classdesc Represents an Annotation. + * @implements IAnnotation + * @constructor + * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set + */ + function Annotation(properties) { + this.path = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Annotation path. + * @member {Array.} path + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + */ + Annotation.prototype.path = $util.emptyArray; + + /** + * Annotation sourceFile. + * @member {string} sourceFile + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + */ + Annotation.prototype.sourceFile = ""; + + /** + * Annotation begin. + * @member {number} begin + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + */ + Annotation.prototype.begin = 0; + + /** + * Annotation end. + * @member {number} end + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + */ + Annotation.prototype.end = 0; + + /** + * Annotation semantic. + * @member {google.protobuf.GeneratedCodeInfo.Annotation.Semantic} semantic + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + */ + Annotation.prototype.semantic = 0; + + /** + * Creates a new Annotation instance using the specified properties. + * @function create + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set + * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation instance + */ + Annotation.create = function create(properties) { + return new Annotation(properties); + }; + + /** + * Encodes the specified Annotation message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * @function encode + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Annotation.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.path != null && message.path.length) { + writer.uint32(/* id 1, wireType 2 =*/10).fork(); + for (var i = 0; i < message.path.length; ++i) + writer.int32(message.path[i]); + writer.ldelim(); + } + if (message.sourceFile != null && Object.hasOwnProperty.call(message, "sourceFile")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.sourceFile); + if (message.begin != null && Object.hasOwnProperty.call(message, "begin")) + writer.uint32(/* id 3, wireType 0 =*/24).int32(message.begin); + if (message.end != null && Object.hasOwnProperty.call(message, "end")) + writer.uint32(/* id 4, wireType 0 =*/32).int32(message.end); + if (message.semantic != null && Object.hasOwnProperty.call(message, "semantic")) + writer.uint32(/* id 5, wireType 0 =*/40).int32(message.semantic); + return writer; + }; + + /** + * Encodes the specified Annotation message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * @function encodeDelimited + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Annotation.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an Annotation message from the specified reader or buffer. + * @function decode + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Annotation.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.GeneratedCodeInfo.Annotation(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.path && message.path.length)) + message.path = []; + if ((tag & 7) === 2) { + var end2 = reader.uint32() + reader.pos; + while (reader.pos < end2) + message.path.push(reader.int32()); + } else + message.path.push(reader.int32()); + break; + } + case 2: { + message.sourceFile = reader.string(); + break; + } + case 3: { + message.begin = reader.int32(); + break; + } + case 4: { + message.end = reader.int32(); + break; + } + case 5: { + message.semantic = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an Annotation message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Annotation.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an Annotation message. + * @function verify + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Annotation.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.path != null && message.hasOwnProperty("path")) { + if (!Array.isArray(message.path)) + return "path: array expected"; + for (var i = 0; i < message.path.length; ++i) + if (!$util.isInteger(message.path[i])) + return "path: integer[] expected"; + } + if (message.sourceFile != null && message.hasOwnProperty("sourceFile")) + if (!$util.isString(message.sourceFile)) + return "sourceFile: string expected"; + if (message.begin != null && message.hasOwnProperty("begin")) + if (!$util.isInteger(message.begin)) + return "begin: integer expected"; + if (message.end != null && message.hasOwnProperty("end")) + if (!$util.isInteger(message.end)) + return "end: integer expected"; + if (message.semantic != null && message.hasOwnProperty("semantic")) + switch (message.semantic) { + default: + return "semantic: enum value expected"; + case 0: + case 1: + case 2: + break; + } + return null; + }; + + /** + * Creates an Annotation message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + */ + Annotation.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.GeneratedCodeInfo.Annotation) + return object; + var message = new $root.google.protobuf.GeneratedCodeInfo.Annotation(); + if (object.path) { + if (!Array.isArray(object.path)) + throw TypeError(".google.protobuf.GeneratedCodeInfo.Annotation.path: array expected"); + message.path = []; + for (var i = 0; i < object.path.length; ++i) + message.path[i] = object.path[i] | 0; + } + if (object.sourceFile != null) + message.sourceFile = String(object.sourceFile); + if (object.begin != null) + message.begin = object.begin | 0; + if (object.end != null) + message.end = object.end | 0; + switch (object.semantic) { + default: + if (typeof object.semantic === "number") { + message.semantic = object.semantic; + break; + } + break; + case "NONE": + case 0: + message.semantic = 0; + break; + case "SET": + case 1: + message.semantic = 1; + break; + case "ALIAS": + case 2: + message.semantic = 2; + break; + } + return message; + }; + + /** + * Creates a plain object from an Annotation message. Also converts values to other types if specified. + * @function toObject + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {google.protobuf.GeneratedCodeInfo.Annotation} message Annotation + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Annotation.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.path = []; + if (options.defaults) { + object.sourceFile = ""; + object.begin = 0; + object.end = 0; + object.semantic = options.enums === String ? "NONE" : 0; + } + if (message.path && message.path.length) { + object.path = []; + for (var j = 0; j < message.path.length; ++j) + object.path[j] = message.path[j]; + } + if (message.sourceFile != null && message.hasOwnProperty("sourceFile")) + object.sourceFile = message.sourceFile; + if (message.begin != null && message.hasOwnProperty("begin")) + object.begin = message.begin; + if (message.end != null && message.hasOwnProperty("end")) + object.end = message.end; + if (message.semantic != null && message.hasOwnProperty("semantic")) + object.semantic = options.enums === String ? $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] === undefined ? message.semantic : $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] : message.semantic; + return object; + }; + + /** + * Converts this Annotation to JSON. + * @function toJSON + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @instance + * @returns {Object.} JSON object + */ + Annotation.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Annotation + * @function getTypeUrl + * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Annotation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo.Annotation"; + }; + + /** + * Semantic enum. + * @name google.protobuf.GeneratedCodeInfo.Annotation.Semantic + * @enum {number} + * @property {number} NONE=0 NONE value + * @property {number} SET=1 SET value + * @property {number} ALIAS=2 ALIAS value + */ + Annotation.Semantic = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "NONE"] = 0; + values[valuesById[1] = "SET"] = 1; + values[valuesById[2] = "ALIAS"] = 2; + return values; + })(); - /** - * JSType enum. - * @name google.protobuf.FieldOptions.JSType - * @enum {number} - * @property {number} JS_NORMAL=0 JS_NORMAL value - * @property {number} JS_STRING=1 JS_STRING value - * @property {number} JS_NUMBER=2 JS_NUMBER value - */ - FieldOptions.JSType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "JS_NORMAL"] = 0; - values[valuesById[1] = "JS_STRING"] = 1; - values[valuesById[2] = "JS_NUMBER"] = 2; - return values; + return Annotation; })(); - return FieldOptions; + return GeneratedCodeInfo; })(); - protobuf.OneofOptions = (function() { + protobuf.Timestamp = (function() { /** - * Properties of an OneofOptions. + * Properties of a Timestamp. * @memberof google.protobuf - * @interface IOneofOptions - * @property {Array.|null} [uninterpretedOption] OneofOptions uninterpretedOption + * @interface ITimestamp + * @property {number|Long|null} [seconds] Timestamp seconds + * @property {number|null} [nanos] Timestamp nanos */ /** - * Constructs a new OneofOptions. + * Constructs a new Timestamp. * @memberof google.protobuf - * @classdesc Represents an OneofOptions. - * @implements IOneofOptions + * @classdesc Represents a Timestamp. + * @implements ITimestamp * @constructor - * @param {google.protobuf.IOneofOptions=} [properties] Properties to set + * @param {google.protobuf.ITimestamp=} [properties] Properties to set */ - function OneofOptions(properties) { - this.uninterpretedOption = []; + function Timestamp(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -57251,78 +65012,89 @@ } /** - * OneofOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.OneofOptions + * Timestamp seconds. + * @member {number|Long} seconds + * @memberof google.protobuf.Timestamp * @instance */ - OneofOptions.prototype.uninterpretedOption = $util.emptyArray; + Timestamp.prototype.seconds = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * Creates a new OneofOptions instance using the specified properties. + * Timestamp nanos. + * @member {number} nanos + * @memberof google.protobuf.Timestamp + * @instance + */ + Timestamp.prototype.nanos = 0; + + /** + * Creates a new Timestamp instance using the specified properties. * @function create - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static - * @param {google.protobuf.IOneofOptions=} [properties] Properties to set - * @returns {google.protobuf.OneofOptions} OneofOptions instance + * @param {google.protobuf.ITimestamp=} [properties] Properties to set + * @returns {google.protobuf.Timestamp} Timestamp instance */ - OneofOptions.create = function create(properties) { - return new OneofOptions(properties); + Timestamp.create = function create(properties) { + return new Timestamp(properties); }; /** - * Encodes the specified OneofOptions message. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. + * Encodes the specified Timestamp message. Does not implicitly {@link google.protobuf.Timestamp.verify|verify} messages. * @function encode - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static - * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode + * @param {google.protobuf.ITimestamp} message Timestamp message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OneofOptions.encode = function encode(message, writer) { + Timestamp.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message.seconds != null && Object.hasOwnProperty.call(message, "seconds")) + writer.uint32(/* id 1, wireType 0 =*/8).int64(message.seconds); + if (message.nanos != null && Object.hasOwnProperty.call(message, "nanos")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.nanos); return writer; }; /** - * Encodes the specified OneofOptions message, length delimited. Does not implicitly {@link google.protobuf.OneofOptions.verify|verify} messages. + * Encodes the specified Timestamp message, length delimited. Does not implicitly {@link google.protobuf.Timestamp.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static - * @param {google.protobuf.IOneofOptions} message OneofOptions message or plain object to encode + * @param {google.protobuf.ITimestamp} message Timestamp message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - OneofOptions.encodeDelimited = function encodeDelimited(message, writer) { + Timestamp.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an OneofOptions message from the specified reader or buffer. + * Decodes a Timestamp message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.OneofOptions} OneofOptions + * @returns {google.protobuf.Timestamp} Timestamp * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OneofOptions.decode = function decode(reader, length) { + Timestamp.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.OneofOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Timestamp(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); + case 1: { + message.seconds = reader.int64(); + break; + } + case 2: { + message.nanos = reader.int32(); break; } default: @@ -57334,142 +65106,146 @@ }; /** - * Decodes an OneofOptions message from the specified reader or buffer, length delimited. + * Decodes a Timestamp message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.OneofOptions} OneofOptions + * @returns {google.protobuf.Timestamp} Timestamp * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - OneofOptions.decodeDelimited = function decodeDelimited(reader) { + Timestamp.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an OneofOptions message. + * Verifies a Timestamp message. * @function verify - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - OneofOptions.verify = function verify(message) { + Timestamp.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } + if (message.seconds != null && message.hasOwnProperty("seconds")) + if (!$util.isInteger(message.seconds) && !(message.seconds && $util.isInteger(message.seconds.low) && $util.isInteger(message.seconds.high))) + return "seconds: integer|Long expected"; + if (message.nanos != null && message.hasOwnProperty("nanos")) + if (!$util.isInteger(message.nanos)) + return "nanos: integer expected"; return null; }; /** - * Creates an OneofOptions message from a plain object. Also converts values to their respective internal types. + * Creates a Timestamp message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static * @param {Object.} object Plain object - * @returns {google.protobuf.OneofOptions} OneofOptions + * @returns {google.protobuf.Timestamp} Timestamp */ - OneofOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.OneofOptions) + Timestamp.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.Timestamp) return object; - var message = new $root.google.protobuf.OneofOptions(); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.OneofOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.OneofOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } + var message = new $root.google.protobuf.Timestamp(); + if (object.seconds != null) + if ($util.Long) + (message.seconds = $util.Long.fromValue(object.seconds)).unsigned = false; + else if (typeof object.seconds === "string") + message.seconds = parseInt(object.seconds, 10); + else if (typeof object.seconds === "number") + message.seconds = object.seconds; + else if (typeof object.seconds === "object") + message.seconds = new $util.LongBits(object.seconds.low >>> 0, object.seconds.high >>> 0).toNumber(); + if (object.nanos != null) + message.nanos = object.nanos | 0; return message; }; /** - * Creates a plain object from an OneofOptions message. Also converts values to other types if specified. + * Creates a plain object from a Timestamp message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static - * @param {google.protobuf.OneofOptions} message OneofOptions + * @param {google.protobuf.Timestamp} message Timestamp * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - OneofOptions.toObject = function toObject(message, options) { + Timestamp.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.uninterpretedOption = []; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + if (options.defaults) { + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.seconds = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.seconds = options.longs === String ? "0" : 0; + object.nanos = 0; } + if (message.seconds != null && message.hasOwnProperty("seconds")) + if (typeof message.seconds === "number") + object.seconds = options.longs === String ? String(message.seconds) : message.seconds; + else + object.seconds = options.longs === String ? $util.Long.prototype.toString.call(message.seconds) : options.longs === Number ? new $util.LongBits(message.seconds.low >>> 0, message.seconds.high >>> 0).toNumber() : message.seconds; + if (message.nanos != null && message.hasOwnProperty("nanos")) + object.nanos = message.nanos; return object; }; /** - * Converts this OneofOptions to JSON. + * Converts this Timestamp to JSON. * @function toJSON - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @instance * @returns {Object.} JSON object */ - OneofOptions.prototype.toJSON = function toJSON() { + Timestamp.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for OneofOptions + * Gets the default type url for Timestamp * @function getTypeUrl - * @memberof google.protobuf.OneofOptions + * @memberof google.protobuf.Timestamp * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - OneofOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Timestamp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.OneofOptions"; + return typeUrlPrefix + "/google.protobuf.Timestamp"; }; - return OneofOptions; + return Timestamp; })(); - protobuf.EnumOptions = (function() { + protobuf.FieldMask = (function() { /** - * Properties of an EnumOptions. + * Properties of a FieldMask. * @memberof google.protobuf - * @interface IEnumOptions - * @property {boolean|null} [allowAlias] EnumOptions allowAlias - * @property {boolean|null} [deprecated] EnumOptions deprecated - * @property {Array.|null} [uninterpretedOption] EnumOptions uninterpretedOption + * @interface IFieldMask + * @property {Array.|null} [paths] FieldMask paths */ /** - * Constructs a new EnumOptions. + * Constructs a new FieldMask. * @memberof google.protobuf - * @classdesc Represents an EnumOptions. - * @implements IEnumOptions + * @classdesc Represents a FieldMask. + * @implements IFieldMask * @constructor - * @param {google.protobuf.IEnumOptions=} [properties] Properties to set + * @param {google.protobuf.IFieldMask=} [properties] Properties to set */ - function EnumOptions(properties) { - this.uninterpretedOption = []; + function FieldMask(properties) { + this.paths = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -57477,106 +65253,78 @@ } /** - * EnumOptions allowAlias. - * @member {boolean} allowAlias - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.allowAlias = false; - - /** - * EnumOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.EnumOptions - * @instance - */ - EnumOptions.prototype.deprecated = false; - - /** - * EnumOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.EnumOptions + * FieldMask paths. + * @member {Array.} paths + * @memberof google.protobuf.FieldMask * @instance */ - EnumOptions.prototype.uninterpretedOption = $util.emptyArray; + FieldMask.prototype.paths = $util.emptyArray; /** - * Creates a new EnumOptions instance using the specified properties. + * Creates a new FieldMask instance using the specified properties. * @function create - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static - * @param {google.protobuf.IEnumOptions=} [properties] Properties to set - * @returns {google.protobuf.EnumOptions} EnumOptions instance + * @param {google.protobuf.IFieldMask=} [properties] Properties to set + * @returns {google.protobuf.FieldMask} FieldMask instance */ - EnumOptions.create = function create(properties) { - return new EnumOptions(properties); + FieldMask.create = function create(properties) { + return new FieldMask(properties); }; /** - * Encodes the specified EnumOptions message. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. + * Encodes the specified FieldMask message. Does not implicitly {@link google.protobuf.FieldMask.verify|verify} messages. * @function encode - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static - * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode + * @param {google.protobuf.IFieldMask} message FieldMask message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumOptions.encode = function encode(message, writer) { + FieldMask.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.allowAlias != null && Object.hasOwnProperty.call(message, "allowAlias")) - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.allowAlias); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 3, wireType 0 =*/24).bool(message.deprecated); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message.paths != null && message.paths.length) + for (var i = 0; i < message.paths.length; ++i) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.paths[i]); return writer; }; /** - * Encodes the specified EnumOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumOptions.verify|verify} messages. + * Encodes the specified FieldMask message, length delimited. Does not implicitly {@link google.protobuf.FieldMask.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static - * @param {google.protobuf.IEnumOptions} message EnumOptions message or plain object to encode + * @param {google.protobuf.IFieldMask} message FieldMask message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumOptions.encodeDelimited = function encodeDelimited(message, writer) { + FieldMask.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EnumOptions message from the specified reader or buffer. + * Decodes a FieldMask message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumOptions} EnumOptions + * @returns {google.protobuf.FieldMask} FieldMask * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumOptions.decode = function decode(reader, length) { + FieldMask.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldMask(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 2: { - message.allowAlias = reader.bool(); - break; - } - case 3: { - message.deprecated = reader.bool(); - break; - } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); + case 1: { + if (!(message.paths && message.paths.length)) + message.paths = []; + message.paths.push(reader.string()); break; } default: @@ -57588,159 +65336,135 @@ }; /** - * Decodes an EnumOptions message from the specified reader or buffer, length delimited. + * Decodes a FieldMask message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumOptions} EnumOptions + * @returns {google.protobuf.FieldMask} FieldMask * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumOptions.decodeDelimited = function decodeDelimited(reader) { + FieldMask.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EnumOptions message. + * Verifies a FieldMask message. * @function verify - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EnumOptions.verify = function verify(message) { + FieldMask.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) - if (typeof message.allowAlias !== "boolean") - return "allowAlias: boolean expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } + if (message.paths != null && message.hasOwnProperty("paths")) { + if (!Array.isArray(message.paths)) + return "paths: array expected"; + for (var i = 0; i < message.paths.length; ++i) + if (!$util.isString(message.paths[i])) + return "paths: string[] expected"; } return null; }; /** - * Creates an EnumOptions message from a plain object. Also converts values to their respective internal types. + * Creates a FieldMask message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static * @param {Object.} object Plain object - * @returns {google.protobuf.EnumOptions} EnumOptions + * @returns {google.protobuf.FieldMask} FieldMask */ - EnumOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumOptions) + FieldMask.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.FieldMask) return object; - var message = new $root.google.protobuf.EnumOptions(); - if (object.allowAlias != null) - message.allowAlias = Boolean(object.allowAlias); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.EnumOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.EnumOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } + var message = new $root.google.protobuf.FieldMask(); + if (object.paths) { + if (!Array.isArray(object.paths)) + throw TypeError(".google.protobuf.FieldMask.paths: array expected"); + message.paths = []; + for (var i = 0; i < object.paths.length; ++i) + message.paths[i] = String(object.paths[i]); } return message; }; /** - * Creates a plain object from an EnumOptions message. Also converts values to other types if specified. + * Creates a plain object from a FieldMask message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static - * @param {google.protobuf.EnumOptions} message EnumOptions + * @param {google.protobuf.FieldMask} message FieldMask * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EnumOptions.toObject = function toObject(message, options) { + FieldMask.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.arrays || options.defaults) - object.uninterpretedOption = []; - if (options.defaults) { - object.allowAlias = false; - object.deprecated = false; - } - if (message.allowAlias != null && message.hasOwnProperty("allowAlias")) - object.allowAlias = message.allowAlias; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + object.paths = []; + if (message.paths && message.paths.length) { + object.paths = []; + for (var j = 0; j < message.paths.length; ++j) + object.paths[j] = message.paths[j]; } return object; }; /** - * Converts this EnumOptions to JSON. + * Converts this FieldMask to JSON. * @function toJSON - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @instance * @returns {Object.} JSON object */ - EnumOptions.prototype.toJSON = function toJSON() { + FieldMask.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EnumOptions + * Gets the default type url for FieldMask * @function getTypeUrl - * @memberof google.protobuf.EnumOptions + * @memberof google.protobuf.FieldMask * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EnumOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + FieldMask.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.EnumOptions"; + return typeUrlPrefix + "/google.protobuf.FieldMask"; }; - return EnumOptions; + return FieldMask; })(); - protobuf.EnumValueOptions = (function() { + protobuf.Any = (function() { /** - * Properties of an EnumValueOptions. + * Properties of an Any. * @memberof google.protobuf - * @interface IEnumValueOptions - * @property {boolean|null} [deprecated] EnumValueOptions deprecated - * @property {Array.|null} [uninterpretedOption] EnumValueOptions uninterpretedOption + * @interface IAny + * @property {string|null} [type_url] Any type_url + * @property {Uint8Array|null} [value] Any value */ /** - * Constructs a new EnumValueOptions. + * Constructs a new Any. * @memberof google.protobuf - * @classdesc Represents an EnumValueOptions. - * @implements IEnumValueOptions + * @classdesc Represents an Any. + * @implements IAny * @constructor - * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set + * @param {google.protobuf.IAny=} [properties] Properties to set */ - function EnumValueOptions(properties) { - this.uninterpretedOption = []; + function Any(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -57748,92 +65472,89 @@ } /** - * EnumValueOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.EnumValueOptions + * Any type_url. + * @member {string} type_url + * @memberof google.protobuf.Any * @instance */ - EnumValueOptions.prototype.deprecated = false; + Any.prototype.type_url = ""; /** - * EnumValueOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.EnumValueOptions + * Any value. + * @member {Uint8Array} value + * @memberof google.protobuf.Any * @instance */ - EnumValueOptions.prototype.uninterpretedOption = $util.emptyArray; + Any.prototype.value = $util.newBuffer([]); /** - * Creates a new EnumValueOptions instance using the specified properties. + * Creates a new Any instance using the specified properties. * @function create - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static - * @param {google.protobuf.IEnumValueOptions=} [properties] Properties to set - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions instance + * @param {google.protobuf.IAny=} [properties] Properties to set + * @returns {google.protobuf.Any} Any instance */ - EnumValueOptions.create = function create(properties) { - return new EnumValueOptions(properties); + Any.create = function create(properties) { + return new Any(properties); }; /** - * Encodes the specified EnumValueOptions message. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. + * Encodes the specified Any message. Does not implicitly {@link google.protobuf.Any.verify|verify} messages. * @function encode - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static - * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode + * @param {google.protobuf.IAny} message Any message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumValueOptions.encode = function encode(message, writer) { + Any.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 1, wireType 0 =*/8).bool(message.deprecated); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); + if (message.type_url != null && Object.hasOwnProperty.call(message, "type_url")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.type_url); + if (message.value != null && Object.hasOwnProperty.call(message, "value")) + writer.uint32(/* id 2, wireType 2 =*/18).bytes(message.value); return writer; }; /** - * Encodes the specified EnumValueOptions message, length delimited. Does not implicitly {@link google.protobuf.EnumValueOptions.verify|verify} messages. + * Encodes the specified Any message, length delimited. Does not implicitly {@link google.protobuf.Any.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static - * @param {google.protobuf.IEnumValueOptions} message EnumValueOptions message or plain object to encode + * @param {google.protobuf.IAny} message Any message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - EnumValueOptions.encodeDelimited = function encodeDelimited(message, writer) { + Any.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an EnumValueOptions message from the specified reader or buffer. + * Decodes an Any message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions + * @returns {google.protobuf.Any} Any * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumValueOptions.decode = function decode(reader, length) { + Any.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.EnumValueOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Any(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.deprecated = reader.bool(); + message.type_url = reader.string(); break; } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); + case 2: { + message.value = reader.bytes(); break; } default: @@ -57845,152 +65566,141 @@ }; /** - * Decodes an EnumValueOptions message from the specified reader or buffer, length delimited. + * Decodes an Any message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions + * @returns {google.protobuf.Any} Any * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - EnumValueOptions.decodeDelimited = function decodeDelimited(reader) { + Any.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an EnumValueOptions message. + * Verifies an Any message. * @function verify - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - EnumValueOptions.verify = function verify(message) { + Any.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } + if (message.type_url != null && message.hasOwnProperty("type_url")) + if (!$util.isString(message.type_url)) + return "type_url: string expected"; + if (message.value != null && message.hasOwnProperty("value")) + if (!(message.value && typeof message.value.length === "number" || $util.isString(message.value))) + return "value: buffer expected"; return null; }; /** - * Creates an EnumValueOptions message from a plain object. Also converts values to their respective internal types. + * Creates an Any message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static * @param {Object.} object Plain object - * @returns {google.protobuf.EnumValueOptions} EnumValueOptions + * @returns {google.protobuf.Any} Any */ - EnumValueOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.EnumValueOptions) + Any.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.Any) return object; - var message = new $root.google.protobuf.EnumValueOptions(); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.EnumValueOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.EnumValueOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } + var message = new $root.google.protobuf.Any(); + if (object.type_url != null) + message.type_url = String(object.type_url); + if (object.value != null) + if (typeof object.value === "string") + $util.base64.decode(object.value, message.value = $util.newBuffer($util.base64.length(object.value)), 0); + else if (object.value.length >= 0) + message.value = object.value; return message; }; /** - * Creates a plain object from an EnumValueOptions message. Also converts values to other types if specified. + * Creates a plain object from an Any message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static - * @param {google.protobuf.EnumValueOptions} message EnumValueOptions + * @param {google.protobuf.Any} message Any * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - EnumValueOptions.toObject = function toObject(message, options) { + Any.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.uninterpretedOption = []; - if (options.defaults) - object.deprecated = false; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + if (options.defaults) { + object.type_url = ""; + if (options.bytes === String) + object.value = ""; + else { + object.value = []; + if (options.bytes !== Array) + object.value = $util.newBuffer(object.value); + } } + if (message.type_url != null && message.hasOwnProperty("type_url")) + object.type_url = message.type_url; + if (message.value != null && message.hasOwnProperty("value")) + object.value = options.bytes === String ? $util.base64.encode(message.value, 0, message.value.length) : options.bytes === Array ? Array.prototype.slice.call(message.value) : message.value; return object; }; /** - * Converts this EnumValueOptions to JSON. + * Converts this Any to JSON. * @function toJSON - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @instance * @returns {Object.} JSON object */ - EnumValueOptions.prototype.toJSON = function toJSON() { + Any.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for EnumValueOptions + * Gets the default type url for Any * @function getTypeUrl - * @memberof google.protobuf.EnumValueOptions + * @memberof google.protobuf.Any * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - EnumValueOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Any.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.EnumValueOptions"; + return typeUrlPrefix + "/google.protobuf.Any"; }; - return EnumValueOptions; + return Any; })(); - protobuf.ServiceOptions = (function() { + protobuf.Duration = (function() { /** - * Properties of a ServiceOptions. + * Properties of a Duration. * @memberof google.protobuf - * @interface IServiceOptions - * @property {boolean|null} [deprecated] ServiceOptions deprecated - * @property {Array.|null} [uninterpretedOption] ServiceOptions uninterpretedOption - * @property {string|null} [".google.api.defaultHost"] ServiceOptions .google.api.defaultHost - * @property {string|null} [".google.api.oauthScopes"] ServiceOptions .google.api.oauthScopes + * @interface IDuration + * @property {number|Long|null} [seconds] Duration seconds + * @property {number|null} [nanos] Duration nanos */ /** - * Constructs a new ServiceOptions. + * Constructs a new Duration. * @memberof google.protobuf - * @classdesc Represents a ServiceOptions. - * @implements IServiceOptions + * @classdesc Represents a Duration. + * @implements IDuration * @constructor - * @param {google.protobuf.IServiceOptions=} [properties] Properties to set + * @param {google.protobuf.IDuration=} [properties] Properties to set */ - function ServiceOptions(properties) { - this.uninterpretedOption = []; + function Duration(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -57998,120 +65708,89 @@ } /** - * ServiceOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.ServiceOptions - * @instance - */ - ServiceOptions.prototype.deprecated = false; - - /** - * ServiceOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.ServiceOptions - * @instance - */ - ServiceOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * ServiceOptions .google.api.defaultHost. - * @member {string} .google.api.defaultHost - * @memberof google.protobuf.ServiceOptions + * Duration seconds. + * @member {number|Long} seconds + * @memberof google.protobuf.Duration * @instance */ - ServiceOptions.prototype[".google.api.defaultHost"] = ""; + Duration.prototype.seconds = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * ServiceOptions .google.api.oauthScopes. - * @member {string} .google.api.oauthScopes - * @memberof google.protobuf.ServiceOptions + * Duration nanos. + * @member {number} nanos + * @memberof google.protobuf.Duration * @instance */ - ServiceOptions.prototype[".google.api.oauthScopes"] = ""; + Duration.prototype.nanos = 0; /** - * Creates a new ServiceOptions instance using the specified properties. + * Creates a new Duration instance using the specified properties. * @function create - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static - * @param {google.protobuf.IServiceOptions=} [properties] Properties to set - * @returns {google.protobuf.ServiceOptions} ServiceOptions instance + * @param {google.protobuf.IDuration=} [properties] Properties to set + * @returns {google.protobuf.Duration} Duration instance */ - ServiceOptions.create = function create(properties) { - return new ServiceOptions(properties); + Duration.create = function create(properties) { + return new Duration(properties); }; /** - * Encodes the specified ServiceOptions message. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. + * Encodes the specified Duration message. Does not implicitly {@link google.protobuf.Duration.verify|verify} messages. * @function encode - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static - * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode + * @param {google.protobuf.IDuration} message Duration message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ServiceOptions.encode = function encode(message, writer) { + Duration.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 33, wireType 0 =*/264).bool(message.deprecated); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); - if (message[".google.api.defaultHost"] != null && Object.hasOwnProperty.call(message, ".google.api.defaultHost")) - writer.uint32(/* id 1049, wireType 2 =*/8394).string(message[".google.api.defaultHost"]); - if (message[".google.api.oauthScopes"] != null && Object.hasOwnProperty.call(message, ".google.api.oauthScopes")) - writer.uint32(/* id 1050, wireType 2 =*/8402).string(message[".google.api.oauthScopes"]); + if (message.seconds != null && Object.hasOwnProperty.call(message, "seconds")) + writer.uint32(/* id 1, wireType 0 =*/8).int64(message.seconds); + if (message.nanos != null && Object.hasOwnProperty.call(message, "nanos")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.nanos); return writer; }; /** - * Encodes the specified ServiceOptions message, length delimited. Does not implicitly {@link google.protobuf.ServiceOptions.verify|verify} messages. + * Encodes the specified Duration message, length delimited. Does not implicitly {@link google.protobuf.Duration.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static - * @param {google.protobuf.IServiceOptions} message ServiceOptions message or plain object to encode + * @param {google.protobuf.IDuration} message Duration message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - ServiceOptions.encodeDelimited = function encodeDelimited(message, writer) { + Duration.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a ServiceOptions message from the specified reader or buffer. + * Decodes a Duration message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.ServiceOptions} ServiceOptions + * @returns {google.protobuf.Duration} Duration * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ServiceOptions.decode = function decode(reader, length) { + Duration.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.ServiceOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Duration(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 33: { - message.deprecated = reader.bool(); - break; - } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); - break; - } - case 1049: { - message[".google.api.defaultHost"] = reader.string(); + case 1: { + message.seconds = reader.int64(); break; } - case 1050: { - message[".google.api.oauthScopes"] = reader.string(); + case 2: { + message.nanos = reader.int32(); break; } default: @@ -58123,171 +65802,144 @@ }; /** - * Decodes a ServiceOptions message from the specified reader or buffer, length delimited. + * Decodes a Duration message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.ServiceOptions} ServiceOptions + * @returns {google.protobuf.Duration} Duration * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - ServiceOptions.decodeDelimited = function decodeDelimited(reader) { + Duration.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a ServiceOptions message. + * Verifies a Duration message. * @function verify - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - ServiceOptions.verify = function verify(message) { + Duration.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } - if (message[".google.api.defaultHost"] != null && message.hasOwnProperty(".google.api.defaultHost")) - if (!$util.isString(message[".google.api.defaultHost"])) - return ".google.api.defaultHost: string expected"; - if (message[".google.api.oauthScopes"] != null && message.hasOwnProperty(".google.api.oauthScopes")) - if (!$util.isString(message[".google.api.oauthScopes"])) - return ".google.api.oauthScopes: string expected"; + if (message.seconds != null && message.hasOwnProperty("seconds")) + if (!$util.isInteger(message.seconds) && !(message.seconds && $util.isInteger(message.seconds.low) && $util.isInteger(message.seconds.high))) + return "seconds: integer|Long expected"; + if (message.nanos != null && message.hasOwnProperty("nanos")) + if (!$util.isInteger(message.nanos)) + return "nanos: integer expected"; return null; }; /** - * Creates a ServiceOptions message from a plain object. Also converts values to their respective internal types. + * Creates a Duration message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static * @param {Object.} object Plain object - * @returns {google.protobuf.ServiceOptions} ServiceOptions + * @returns {google.protobuf.Duration} Duration */ - ServiceOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.ServiceOptions) + Duration.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.Duration) return object; - var message = new $root.google.protobuf.ServiceOptions(); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.ServiceOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.ServiceOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } - if (object[".google.api.defaultHost"] != null) - message[".google.api.defaultHost"] = String(object[".google.api.defaultHost"]); - if (object[".google.api.oauthScopes"] != null) - message[".google.api.oauthScopes"] = String(object[".google.api.oauthScopes"]); + var message = new $root.google.protobuf.Duration(); + if (object.seconds != null) + if ($util.Long) + (message.seconds = $util.Long.fromValue(object.seconds)).unsigned = false; + else if (typeof object.seconds === "string") + message.seconds = parseInt(object.seconds, 10); + else if (typeof object.seconds === "number") + message.seconds = object.seconds; + else if (typeof object.seconds === "object") + message.seconds = new $util.LongBits(object.seconds.low >>> 0, object.seconds.high >>> 0).toNumber(); + if (object.nanos != null) + message.nanos = object.nanos | 0; return message; }; /** - * Creates a plain object from a ServiceOptions message. Also converts values to other types if specified. + * Creates a plain object from a Duration message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static - * @param {google.protobuf.ServiceOptions} message ServiceOptions + * @param {google.protobuf.Duration} message Duration * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - ServiceOptions.toObject = function toObject(message, options) { + Duration.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.uninterpretedOption = []; if (options.defaults) { - object.deprecated = false; - object[".google.api.defaultHost"] = ""; - object[".google.api.oauthScopes"] = ""; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); + if ($util.Long) { + var long = new $util.Long(0, 0, false); + object.seconds = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.seconds = options.longs === String ? "0" : 0; + object.nanos = 0; } - if (message[".google.api.defaultHost"] != null && message.hasOwnProperty(".google.api.defaultHost")) - object[".google.api.defaultHost"] = message[".google.api.defaultHost"]; - if (message[".google.api.oauthScopes"] != null && message.hasOwnProperty(".google.api.oauthScopes")) - object[".google.api.oauthScopes"] = message[".google.api.oauthScopes"]; + if (message.seconds != null && message.hasOwnProperty("seconds")) + if (typeof message.seconds === "number") + object.seconds = options.longs === String ? String(message.seconds) : message.seconds; + else + object.seconds = options.longs === String ? $util.Long.prototype.toString.call(message.seconds) : options.longs === Number ? new $util.LongBits(message.seconds.low >>> 0, message.seconds.high >>> 0).toNumber() : message.seconds; + if (message.nanos != null && message.hasOwnProperty("nanos")) + object.nanos = message.nanos; return object; }; /** - * Converts this ServiceOptions to JSON. + * Converts this Duration to JSON. * @function toJSON - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @instance * @returns {Object.} JSON object */ - ServiceOptions.prototype.toJSON = function toJSON() { + Duration.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for ServiceOptions + * Gets the default type url for Duration * @function getTypeUrl - * @memberof google.protobuf.ServiceOptions + * @memberof google.protobuf.Duration * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - ServiceOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Duration.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.ServiceOptions"; + return typeUrlPrefix + "/google.protobuf.Duration"; }; - return ServiceOptions; + return Duration; })(); - protobuf.MethodOptions = (function() { + protobuf.Empty = (function() { /** - * Properties of a MethodOptions. + * Properties of an Empty. * @memberof google.protobuf - * @interface IMethodOptions - * @property {boolean|null} [deprecated] MethodOptions deprecated - * @property {google.protobuf.MethodOptions.IdempotencyLevel|null} [idempotencyLevel] MethodOptions idempotencyLevel - * @property {Array.|null} [uninterpretedOption] MethodOptions uninterpretedOption - * @property {google.api.IHttpRule|null} [".google.api.http"] MethodOptions .google.api.http - * @property {Array.|null} [".google.api.methodSignature"] MethodOptions .google.api.methodSignature + * @interface IEmpty */ /** - * Constructs a new MethodOptions. + * Constructs a new Empty. * @memberof google.protobuf - * @classdesc Represents a MethodOptions. - * @implements IMethodOptions + * @classdesc Represents an Empty. + * @implements IEmpty * @constructor - * @param {google.protobuf.IMethodOptions=} [properties] Properties to set + * @param {google.protobuf.IEmpty=} [properties] Properties to set */ - function MethodOptions(properties) { - this.uninterpretedOption = []; - this[".google.api.methodSignature"] = []; + function Empty(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -58295,139 +65947,63 @@ } /** - * MethodOptions deprecated. - * @member {boolean} deprecated - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.deprecated = false; - - /** - * MethodOptions idempotencyLevel. - * @member {google.protobuf.MethodOptions.IdempotencyLevel} idempotencyLevel - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.idempotencyLevel = 0; - - /** - * MethodOptions uninterpretedOption. - * @member {Array.} uninterpretedOption - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype.uninterpretedOption = $util.emptyArray; - - /** - * MethodOptions .google.api.http. - * @member {google.api.IHttpRule|null|undefined} .google.api.http - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype[".google.api.http"] = null; - - /** - * MethodOptions .google.api.methodSignature. - * @member {Array.} .google.api.methodSignature - * @memberof google.protobuf.MethodOptions - * @instance - */ - MethodOptions.prototype[".google.api.methodSignature"] = $util.emptyArray; - - /** - * Creates a new MethodOptions instance using the specified properties. + * Creates a new Empty instance using the specified properties. * @function create - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static - * @param {google.protobuf.IMethodOptions=} [properties] Properties to set - * @returns {google.protobuf.MethodOptions} MethodOptions instance + * @param {google.protobuf.IEmpty=} [properties] Properties to set + * @returns {google.protobuf.Empty} Empty instance */ - MethodOptions.create = function create(properties) { - return new MethodOptions(properties); + Empty.create = function create(properties) { + return new Empty(properties); }; /** - * Encodes the specified MethodOptions message. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. + * Encodes the specified Empty message. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. * @function encode - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static - * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode + * @param {google.protobuf.IEmpty} message Empty message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MethodOptions.encode = function encode(message, writer) { + Empty.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.deprecated != null && Object.hasOwnProperty.call(message, "deprecated")) - writer.uint32(/* id 33, wireType 0 =*/264).bool(message.deprecated); - if (message.idempotencyLevel != null && Object.hasOwnProperty.call(message, "idempotencyLevel")) - writer.uint32(/* id 34, wireType 0 =*/272).int32(message.idempotencyLevel); - if (message.uninterpretedOption != null && message.uninterpretedOption.length) - for (var i = 0; i < message.uninterpretedOption.length; ++i) - $root.google.protobuf.UninterpretedOption.encode(message.uninterpretedOption[i], writer.uint32(/* id 999, wireType 2 =*/7994).fork()).ldelim(); - if (message[".google.api.methodSignature"] != null && message[".google.api.methodSignature"].length) - for (var i = 0; i < message[".google.api.methodSignature"].length; ++i) - writer.uint32(/* id 1051, wireType 2 =*/8410).string(message[".google.api.methodSignature"][i]); - if (message[".google.api.http"] != null && Object.hasOwnProperty.call(message, ".google.api.http")) - $root.google.api.HttpRule.encode(message[".google.api.http"], writer.uint32(/* id 72295728, wireType 2 =*/578365826).fork()).ldelim(); return writer; }; /** - * Encodes the specified MethodOptions message, length delimited. Does not implicitly {@link google.protobuf.MethodOptions.verify|verify} messages. + * Encodes the specified Empty message, length delimited. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static - * @param {google.protobuf.IMethodOptions} message MethodOptions message or plain object to encode + * @param {google.protobuf.IEmpty} message Empty message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MethodOptions.encodeDelimited = function encodeDelimited(message, writer) { + Empty.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a MethodOptions message from the specified reader or buffer. + * Decodes an Empty message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.MethodOptions} MethodOptions + * @returns {google.protobuf.Empty} Empty * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MethodOptions.decode = function decode(reader, length) { + Empty.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.MethodOptions(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Empty(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { - case 33: { - message.deprecated = reader.bool(); - break; - } - case 34: { - message.idempotencyLevel = reader.int32(); - break; - } - case 999: { - if (!(message.uninterpretedOption && message.uninterpretedOption.length)) - message.uninterpretedOption = []; - message.uninterpretedOption.push($root.google.protobuf.UninterpretedOption.decode(reader, reader.uint32())); - break; - } - case 72295728: { - message[".google.api.http"] = $root.google.api.HttpRule.decode(reader, reader.uint32()); - break; - } - case 1051: { - if (!(message[".google.api.methodSignature"] && message[".google.api.methodSignature"].length)) - message[".google.api.methodSignature"] = []; - message[".google.api.methodSignature"].push(reader.string()); - break; - } default: reader.skipType(tag & 7); break; @@ -58437,630 +66013,758 @@ }; /** - * Decodes a MethodOptions message from the specified reader or buffer, length delimited. + * Decodes an Empty message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.MethodOptions} MethodOptions + * @returns {google.protobuf.Empty} Empty * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MethodOptions.decodeDelimited = function decodeDelimited(reader) { + Empty.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a MethodOptions message. + * Verifies an Empty message. * @function verify - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - MethodOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - if (typeof message.deprecated !== "boolean") - return "deprecated: boolean expected"; - if (message.idempotencyLevel != null && message.hasOwnProperty("idempotencyLevel")) - switch (message.idempotencyLevel) { - default: - return "idempotencyLevel: enum value expected"; - case 0: - case 1: - case 2: - break; - } - if (message.uninterpretedOption != null && message.hasOwnProperty("uninterpretedOption")) { - if (!Array.isArray(message.uninterpretedOption)) - return "uninterpretedOption: array expected"; - for (var i = 0; i < message.uninterpretedOption.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.verify(message.uninterpretedOption[i]); - if (error) - return "uninterpretedOption." + error; - } - } - if (message[".google.api.http"] != null && message.hasOwnProperty(".google.api.http")) { - var error = $root.google.api.HttpRule.verify(message[".google.api.http"]); - if (error) - return ".google.api.http." + error; - } - if (message[".google.api.methodSignature"] != null && message.hasOwnProperty(".google.api.methodSignature")) { - if (!Array.isArray(message[".google.api.methodSignature"])) - return ".google.api.methodSignature: array expected"; - for (var i = 0; i < message[".google.api.methodSignature"].length; ++i) - if (!$util.isString(message[".google.api.methodSignature"][i])) - return ".google.api.methodSignature: string[] expected"; - } - return null; - }; - - /** - * Creates a MethodOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.MethodOptions - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.MethodOptions} MethodOptions - */ - MethodOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.MethodOptions) - return object; - var message = new $root.google.protobuf.MethodOptions(); - if (object.deprecated != null) - message.deprecated = Boolean(object.deprecated); - switch (object.idempotencyLevel) { - default: - if (typeof object.idempotencyLevel === "number") { - message.idempotencyLevel = object.idempotencyLevel; - break; - } - break; - case "IDEMPOTENCY_UNKNOWN": - case 0: - message.idempotencyLevel = 0; - break; - case "NO_SIDE_EFFECTS": - case 1: - message.idempotencyLevel = 1; - break; - case "IDEMPOTENT": - case 2: - message.idempotencyLevel = 2; - break; - } - if (object.uninterpretedOption) { - if (!Array.isArray(object.uninterpretedOption)) - throw TypeError(".google.protobuf.MethodOptions.uninterpretedOption: array expected"); - message.uninterpretedOption = []; - for (var i = 0; i < object.uninterpretedOption.length; ++i) { - if (typeof object.uninterpretedOption[i] !== "object") - throw TypeError(".google.protobuf.MethodOptions.uninterpretedOption: object expected"); - message.uninterpretedOption[i] = $root.google.protobuf.UninterpretedOption.fromObject(object.uninterpretedOption[i]); - } - } - if (object[".google.api.http"] != null) { - if (typeof object[".google.api.http"] !== "object") - throw TypeError(".google.protobuf.MethodOptions..google.api.http: object expected"); - message[".google.api.http"] = $root.google.api.HttpRule.fromObject(object[".google.api.http"]); - } - if (object[".google.api.methodSignature"]) { - if (!Array.isArray(object[".google.api.methodSignature"])) - throw TypeError(".google.protobuf.MethodOptions..google.api.methodSignature: array expected"); - message[".google.api.methodSignature"] = []; - for (var i = 0; i < object[".google.api.methodSignature"].length; ++i) - message[".google.api.methodSignature"][i] = String(object[".google.api.methodSignature"][i]); - } - return message; + Empty.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + return null; }; /** - * Creates a plain object from a MethodOptions message. Also converts values to other types if specified. + * Creates an Empty message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.protobuf.Empty + * @static + * @param {Object.} object Plain object + * @returns {google.protobuf.Empty} Empty + */ + Empty.fromObject = function fromObject(object) { + if (object instanceof $root.google.protobuf.Empty) + return object; + return new $root.google.protobuf.Empty(); + }; + + /** + * Creates a plain object from an Empty message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static - * @param {google.protobuf.MethodOptions} message MethodOptions + * @param {google.protobuf.Empty} message Empty * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - MethodOptions.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.uninterpretedOption = []; - object[".google.api.methodSignature"] = []; - } - if (options.defaults) { - object.deprecated = false; - object.idempotencyLevel = options.enums === String ? "IDEMPOTENCY_UNKNOWN" : 0; - object[".google.api.http"] = null; - } - if (message.deprecated != null && message.hasOwnProperty("deprecated")) - object.deprecated = message.deprecated; - if (message.idempotencyLevel != null && message.hasOwnProperty("idempotencyLevel")) - object.idempotencyLevel = options.enums === String ? $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] === undefined ? message.idempotencyLevel : $root.google.protobuf.MethodOptions.IdempotencyLevel[message.idempotencyLevel] : message.idempotencyLevel; - if (message.uninterpretedOption && message.uninterpretedOption.length) { - object.uninterpretedOption = []; - for (var j = 0; j < message.uninterpretedOption.length; ++j) - object.uninterpretedOption[j] = $root.google.protobuf.UninterpretedOption.toObject(message.uninterpretedOption[j], options); - } - if (message[".google.api.methodSignature"] && message[".google.api.methodSignature"].length) { - object[".google.api.methodSignature"] = []; - for (var j = 0; j < message[".google.api.methodSignature"].length; ++j) - object[".google.api.methodSignature"][j] = message[".google.api.methodSignature"][j]; - } - if (message[".google.api.http"] != null && message.hasOwnProperty(".google.api.http")) - object[".google.api.http"] = $root.google.api.HttpRule.toObject(message[".google.api.http"], options); - return object; + Empty.toObject = function toObject() { + return {}; }; /** - * Converts this MethodOptions to JSON. + * Converts this Empty to JSON. * @function toJSON - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @instance * @returns {Object.} JSON object */ - MethodOptions.prototype.toJSON = function toJSON() { + Empty.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for MethodOptions + * Gets the default type url for Empty * @function getTypeUrl - * @memberof google.protobuf.MethodOptions + * @memberof google.protobuf.Empty * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - MethodOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Empty.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.MethodOptions"; + return typeUrlPrefix + "/google.protobuf.Empty"; }; + return Empty; + })(); + + return protobuf; + })(); + + google.iam = (function() { + + /** + * Namespace iam. + * @memberof google + * @namespace + */ + var iam = {}; + + iam.v1 = (function() { + /** - * IdempotencyLevel enum. - * @name google.protobuf.MethodOptions.IdempotencyLevel - * @enum {number} - * @property {number} IDEMPOTENCY_UNKNOWN=0 IDEMPOTENCY_UNKNOWN value - * @property {number} NO_SIDE_EFFECTS=1 NO_SIDE_EFFECTS value - * @property {number} IDEMPOTENT=2 IDEMPOTENT value + * Namespace v1. + * @memberof google.iam + * @namespace */ - MethodOptions.IdempotencyLevel = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "IDEMPOTENCY_UNKNOWN"] = 0; - values[valuesById[1] = "NO_SIDE_EFFECTS"] = 1; - values[valuesById[2] = "IDEMPOTENT"] = 2; - return values; + var v1 = {}; + + v1.IAMPolicy = (function() { + + /** + * Constructs a new IAMPolicy service. + * @memberof google.iam.v1 + * @classdesc Represents a IAMPolicy + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + */ + function IAMPolicy(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } + + (IAMPolicy.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = IAMPolicy; + + /** + * Creates new IAMPolicy service using the specified rpc implementation. + * @function create + * @memberof google.iam.v1.IAMPolicy + * @static + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {IAMPolicy} RPC service. Useful where requests and/or responses are streamed. + */ + IAMPolicy.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); + }; + + /** + * Callback as used by {@link google.iam.v1.IAMPolicy|setIamPolicy}. + * @memberof google.iam.v1.IAMPolicy + * @typedef SetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy + */ + + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @param {google.iam.v1.IAMPolicy.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(IAMPolicy.prototype.setIamPolicy = function setIamPolicy(request, callback) { + return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "SetIamPolicy" }); + + /** + * Calls SetIamPolicy. + * @function setIamPolicy + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.iam.v1.IAMPolicy|getIamPolicy}. + * @memberof google.iam.v1.IAMPolicy + * @typedef GetIamPolicyCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.Policy} [response] Policy + */ + + /** + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @param {google.iam.v1.IAMPolicy.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(IAMPolicy.prototype.getIamPolicy = function getIamPolicy(request, callback) { + return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); + }, "name", { value: "GetIamPolicy" }); + + /** + * Calls GetIamPolicy. + * @function getIamPolicy + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + /** + * Callback as used by {@link google.iam.v1.IAMPolicy|testIamPermissions}. + * @memberof google.iam.v1.IAMPolicy + * @typedef TestIamPermissionsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse + */ + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @param {google.iam.v1.IAMPolicy.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(IAMPolicy.prototype.testIamPermissions = function testIamPermissions(request, callback) { + return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); + }, "name", { value: "TestIamPermissions" }); + + /** + * Calls TestIamPermissions. + * @function testIamPermissions + * @memberof google.iam.v1.IAMPolicy + * @instance + * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ + + return IAMPolicy; })(); - return MethodOptions; - })(); + v1.SetIamPolicyRequest = (function() { - protobuf.UninterpretedOption = (function() { + /** + * Properties of a SetIamPolicyRequest. + * @memberof google.iam.v1 + * @interface ISetIamPolicyRequest + * @property {string|null} [resource] SetIamPolicyRequest resource + * @property {google.iam.v1.IPolicy|null} [policy] SetIamPolicyRequest policy + * @property {google.protobuf.IFieldMask|null} [updateMask] SetIamPolicyRequest updateMask + */ - /** - * Properties of an UninterpretedOption. - * @memberof google.protobuf - * @interface IUninterpretedOption - * @property {Array.|null} [name] UninterpretedOption name - * @property {string|null} [identifierValue] UninterpretedOption identifierValue - * @property {number|Long|null} [positiveIntValue] UninterpretedOption positiveIntValue - * @property {number|Long|null} [negativeIntValue] UninterpretedOption negativeIntValue - * @property {number|null} [doubleValue] UninterpretedOption doubleValue - * @property {Uint8Array|null} [stringValue] UninterpretedOption stringValue - * @property {string|null} [aggregateValue] UninterpretedOption aggregateValue - */ + /** + * Constructs a new SetIamPolicyRequest. + * @memberof google.iam.v1 + * @classdesc Represents a SetIamPolicyRequest. + * @implements ISetIamPolicyRequest + * @constructor + * @param {google.iam.v1.ISetIamPolicyRequest=} [properties] Properties to set + */ + function SetIamPolicyRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Constructs a new UninterpretedOption. - * @memberof google.protobuf - * @classdesc Represents an UninterpretedOption. - * @implements IUninterpretedOption - * @constructor - * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set - */ - function UninterpretedOption(properties) { - this.name = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * SetIamPolicyRequest resource. + * @member {string} resource + * @memberof google.iam.v1.SetIamPolicyRequest + * @instance + */ + SetIamPolicyRequest.prototype.resource = ""; - /** - * UninterpretedOption name. - * @member {Array.} name - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.name = $util.emptyArray; + /** + * SetIamPolicyRequest policy. + * @member {google.iam.v1.IPolicy|null|undefined} policy + * @memberof google.iam.v1.SetIamPolicyRequest + * @instance + */ + SetIamPolicyRequest.prototype.policy = null; + + /** + * SetIamPolicyRequest updateMask. + * @member {google.protobuf.IFieldMask|null|undefined} updateMask + * @memberof google.iam.v1.SetIamPolicyRequest + * @instance + */ + SetIamPolicyRequest.prototype.updateMask = null; + + /** + * Creates a new SetIamPolicyRequest instance using the specified properties. + * @function create + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {google.iam.v1.ISetIamPolicyRequest=} [properties] Properties to set + * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest instance + */ + SetIamPolicyRequest.create = function create(properties) { + return new SetIamPolicyRequest(properties); + }; + + /** + * Encodes the specified SetIamPolicyRequest message. Does not implicitly {@link google.iam.v1.SetIamPolicyRequest.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {google.iam.v1.ISetIamPolicyRequest} message SetIamPolicyRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SetIamPolicyRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); + if (message.policy != null && Object.hasOwnProperty.call(message, "policy")) + $root.google.iam.v1.Policy.encode(message.policy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) + $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified SetIamPolicyRequest message, length delimited. Does not implicitly {@link google.iam.v1.SetIamPolicyRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {google.iam.v1.ISetIamPolicyRequest} message SetIamPolicyRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + SetIamPolicyRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a SetIamPolicyRequest message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SetIamPolicyRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.SetIamPolicyRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.resource = reader.string(); + break; + } + case 2: { + message.policy = $root.google.iam.v1.Policy.decode(reader, reader.uint32()); + break; + } + case 3: { + message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a SetIamPolicyRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + SetIamPolicyRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a SetIamPolicyRequest message. + * @function verify + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + SetIamPolicyRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.resource != null && message.hasOwnProperty("resource")) + if (!$util.isString(message.resource)) + return "resource: string expected"; + if (message.policy != null && message.hasOwnProperty("policy")) { + var error = $root.google.iam.v1.Policy.verify(message.policy); + if (error) + return "policy." + error; + } + if (message.updateMask != null && message.hasOwnProperty("updateMask")) { + var error = $root.google.protobuf.FieldMask.verify(message.updateMask); + if (error) + return "updateMask." + error; + } + return null; + }; + + /** + * Creates a SetIamPolicyRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + */ + SetIamPolicyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.SetIamPolicyRequest) + return object; + var message = new $root.google.iam.v1.SetIamPolicyRequest(); + if (object.resource != null) + message.resource = String(object.resource); + if (object.policy != null) { + if (typeof object.policy !== "object") + throw TypeError(".google.iam.v1.SetIamPolicyRequest.policy: object expected"); + message.policy = $root.google.iam.v1.Policy.fromObject(object.policy); + } + if (object.updateMask != null) { + if (typeof object.updateMask !== "object") + throw TypeError(".google.iam.v1.SetIamPolicyRequest.updateMask: object expected"); + message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + } + return message; + }; + + /** + * Creates a plain object from a SetIamPolicyRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {google.iam.v1.SetIamPolicyRequest} message SetIamPolicyRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + SetIamPolicyRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.resource = ""; + object.policy = null; + object.updateMask = null; + } + if (message.resource != null && message.hasOwnProperty("resource")) + object.resource = message.resource; + if (message.policy != null && message.hasOwnProperty("policy")) + object.policy = $root.google.iam.v1.Policy.toObject(message.policy, options); + if (message.updateMask != null && message.hasOwnProperty("updateMask")) + object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); + return object; + }; + + /** + * Converts this SetIamPolicyRequest to JSON. + * @function toJSON + * @memberof google.iam.v1.SetIamPolicyRequest + * @instance + * @returns {Object.} JSON object + */ + SetIamPolicyRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for SetIamPolicyRequest + * @function getTypeUrl + * @memberof google.iam.v1.SetIamPolicyRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + SetIamPolicyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.SetIamPolicyRequest"; + }; - /** - * UninterpretedOption identifierValue. - * @member {string} identifierValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.identifierValue = ""; + return SetIamPolicyRequest; + })(); - /** - * UninterpretedOption positiveIntValue. - * @member {number|Long} positiveIntValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.positiveIntValue = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + v1.GetIamPolicyRequest = (function() { - /** - * UninterpretedOption negativeIntValue. - * @member {number|Long} negativeIntValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.negativeIntValue = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + /** + * Properties of a GetIamPolicyRequest. + * @memberof google.iam.v1 + * @interface IGetIamPolicyRequest + * @property {string|null} [resource] GetIamPolicyRequest resource + * @property {google.iam.v1.IGetPolicyOptions|null} [options] GetIamPolicyRequest options + */ - /** - * UninterpretedOption doubleValue. - * @member {number} doubleValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.doubleValue = 0; + /** + * Constructs a new GetIamPolicyRequest. + * @memberof google.iam.v1 + * @classdesc Represents a GetIamPolicyRequest. + * @implements IGetIamPolicyRequest + * @constructor + * @param {google.iam.v1.IGetIamPolicyRequest=} [properties] Properties to set + */ + function GetIamPolicyRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * UninterpretedOption stringValue. - * @member {Uint8Array} stringValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.stringValue = $util.newBuffer([]); + /** + * GetIamPolicyRequest resource. + * @member {string} resource + * @memberof google.iam.v1.GetIamPolicyRequest + * @instance + */ + GetIamPolicyRequest.prototype.resource = ""; - /** - * UninterpretedOption aggregateValue. - * @member {string} aggregateValue - * @memberof google.protobuf.UninterpretedOption - * @instance - */ - UninterpretedOption.prototype.aggregateValue = ""; + /** + * GetIamPolicyRequest options. + * @member {google.iam.v1.IGetPolicyOptions|null|undefined} options + * @memberof google.iam.v1.GetIamPolicyRequest + * @instance + */ + GetIamPolicyRequest.prototype.options = null; - /** - * Creates a new UninterpretedOption instance using the specified properties. - * @function create - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption=} [properties] Properties to set - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption instance - */ - UninterpretedOption.create = function create(properties) { - return new UninterpretedOption(properties); - }; + /** + * Creates a new GetIamPolicyRequest instance using the specified properties. + * @function create + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {google.iam.v1.IGetIamPolicyRequest=} [properties] Properties to set + * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest instance + */ + GetIamPolicyRequest.create = function create(properties) { + return new GetIamPolicyRequest(properties); + }; - /** - * Encodes the specified UninterpretedOption message. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @function encode - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UninterpretedOption.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.name != null && message.name.length) - for (var i = 0; i < message.name.length; ++i) - $root.google.protobuf.UninterpretedOption.NamePart.encode(message.name[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.identifierValue != null && Object.hasOwnProperty.call(message, "identifierValue")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.identifierValue); - if (message.positiveIntValue != null && Object.hasOwnProperty.call(message, "positiveIntValue")) - writer.uint32(/* id 4, wireType 0 =*/32).uint64(message.positiveIntValue); - if (message.negativeIntValue != null && Object.hasOwnProperty.call(message, "negativeIntValue")) - writer.uint32(/* id 5, wireType 0 =*/40).int64(message.negativeIntValue); - if (message.doubleValue != null && Object.hasOwnProperty.call(message, "doubleValue")) - writer.uint32(/* id 6, wireType 1 =*/49).double(message.doubleValue); - if (message.stringValue != null && Object.hasOwnProperty.call(message, "stringValue")) - writer.uint32(/* id 7, wireType 2 =*/58).bytes(message.stringValue); - if (message.aggregateValue != null && Object.hasOwnProperty.call(message, "aggregateValue")) - writer.uint32(/* id 8, wireType 2 =*/66).string(message.aggregateValue); - return writer; - }; + /** + * Encodes the specified GetIamPolicyRequest message. Does not implicitly {@link google.iam.v1.GetIamPolicyRequest.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {google.iam.v1.IGetIamPolicyRequest} message GetIamPolicyRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetIamPolicyRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); + if (message.options != null && Object.hasOwnProperty.call(message, "options")) + $root.google.iam.v1.GetPolicyOptions.encode(message.options, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; - /** - * Encodes the specified UninterpretedOption message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.IUninterpretedOption} message UninterpretedOption message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - UninterpretedOption.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified GetIamPolicyRequest message, length delimited. Does not implicitly {@link google.iam.v1.GetIamPolicyRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {google.iam.v1.IGetIamPolicyRequest} message GetIamPolicyRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetIamPolicyRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Decodes an UninterpretedOption message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UninterpretedOption.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.UninterpretedOption(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 2: { - if (!(message.name && message.name.length)) - message.name = []; - message.name.push($root.google.protobuf.UninterpretedOption.NamePart.decode(reader, reader.uint32())); - break; - } - case 3: { - message.identifierValue = reader.string(); - break; - } - case 4: { - message.positiveIntValue = reader.uint64(); - break; - } - case 5: { - message.negativeIntValue = reader.int64(); - break; - } - case 6: { - message.doubleValue = reader.double(); - break; - } - case 7: { - message.stringValue = reader.bytes(); - break; - } - case 8: { - message.aggregateValue = reader.string(); + /** + * Decodes a GetIamPolicyRequest message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetIamPolicyRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.GetIamPolicyRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.resource = reader.string(); + break; + } + case 2: { + message.options = $root.google.iam.v1.GetPolicyOptions.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); break; } - default: - reader.skipType(tag & 7); - break; } - } - return message; - }; + return message; + }; - /** - * Decodes an UninterpretedOption message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - UninterpretedOption.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Decodes a GetIamPolicyRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetIamPolicyRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Verifies an UninterpretedOption message. - * @function verify - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - UninterpretedOption.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.name != null && message.hasOwnProperty("name")) { - if (!Array.isArray(message.name)) - return "name: array expected"; - for (var i = 0; i < message.name.length; ++i) { - var error = $root.google.protobuf.UninterpretedOption.NamePart.verify(message.name[i]); + /** + * Verifies a GetIamPolicyRequest message. + * @function verify + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GetIamPolicyRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.resource != null && message.hasOwnProperty("resource")) + if (!$util.isString(message.resource)) + return "resource: string expected"; + if (message.options != null && message.hasOwnProperty("options")) { + var error = $root.google.iam.v1.GetPolicyOptions.verify(message.options); if (error) - return "name." + error; + return "options." + error; } - } - if (message.identifierValue != null && message.hasOwnProperty("identifierValue")) - if (!$util.isString(message.identifierValue)) - return "identifierValue: string expected"; - if (message.positiveIntValue != null && message.hasOwnProperty("positiveIntValue")) - if (!$util.isInteger(message.positiveIntValue) && !(message.positiveIntValue && $util.isInteger(message.positiveIntValue.low) && $util.isInteger(message.positiveIntValue.high))) - return "positiveIntValue: integer|Long expected"; - if (message.negativeIntValue != null && message.hasOwnProperty("negativeIntValue")) - if (!$util.isInteger(message.negativeIntValue) && !(message.negativeIntValue && $util.isInteger(message.negativeIntValue.low) && $util.isInteger(message.negativeIntValue.high))) - return "negativeIntValue: integer|Long expected"; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) - if (typeof message.doubleValue !== "number") - return "doubleValue: number expected"; - if (message.stringValue != null && message.hasOwnProperty("stringValue")) - if (!(message.stringValue && typeof message.stringValue.length === "number" || $util.isString(message.stringValue))) - return "stringValue: buffer expected"; - if (message.aggregateValue != null && message.hasOwnProperty("aggregateValue")) - if (!$util.isString(message.aggregateValue)) - return "aggregateValue: string expected"; - return null; - }; + return null; + }; - /** - * Creates an UninterpretedOption message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.UninterpretedOption} UninterpretedOption - */ - UninterpretedOption.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.UninterpretedOption) - return object; - var message = new $root.google.protobuf.UninterpretedOption(); - if (object.name) { - if (!Array.isArray(object.name)) - throw TypeError(".google.protobuf.UninterpretedOption.name: array expected"); - message.name = []; - for (var i = 0; i < object.name.length; ++i) { - if (typeof object.name[i] !== "object") - throw TypeError(".google.protobuf.UninterpretedOption.name: object expected"); - message.name[i] = $root.google.protobuf.UninterpretedOption.NamePart.fromObject(object.name[i]); + /** + * Creates a GetIamPolicyRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + */ + GetIamPolicyRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.GetIamPolicyRequest) + return object; + var message = new $root.google.iam.v1.GetIamPolicyRequest(); + if (object.resource != null) + message.resource = String(object.resource); + if (object.options != null) { + if (typeof object.options !== "object") + throw TypeError(".google.iam.v1.GetIamPolicyRequest.options: object expected"); + message.options = $root.google.iam.v1.GetPolicyOptions.fromObject(object.options); } - } - if (object.identifierValue != null) - message.identifierValue = String(object.identifierValue); - if (object.positiveIntValue != null) - if ($util.Long) - (message.positiveIntValue = $util.Long.fromValue(object.positiveIntValue)).unsigned = true; - else if (typeof object.positiveIntValue === "string") - message.positiveIntValue = parseInt(object.positiveIntValue, 10); - else if (typeof object.positiveIntValue === "number") - message.positiveIntValue = object.positiveIntValue; - else if (typeof object.positiveIntValue === "object") - message.positiveIntValue = new $util.LongBits(object.positiveIntValue.low >>> 0, object.positiveIntValue.high >>> 0).toNumber(true); - if (object.negativeIntValue != null) - if ($util.Long) - (message.negativeIntValue = $util.Long.fromValue(object.negativeIntValue)).unsigned = false; - else if (typeof object.negativeIntValue === "string") - message.negativeIntValue = parseInt(object.negativeIntValue, 10); - else if (typeof object.negativeIntValue === "number") - message.negativeIntValue = object.negativeIntValue; - else if (typeof object.negativeIntValue === "object") - message.negativeIntValue = new $util.LongBits(object.negativeIntValue.low >>> 0, object.negativeIntValue.high >>> 0).toNumber(); - if (object.doubleValue != null) - message.doubleValue = Number(object.doubleValue); - if (object.stringValue != null) - if (typeof object.stringValue === "string") - $util.base64.decode(object.stringValue, message.stringValue = $util.newBuffer($util.base64.length(object.stringValue)), 0); - else if (object.stringValue.length >= 0) - message.stringValue = object.stringValue; - if (object.aggregateValue != null) - message.aggregateValue = String(object.aggregateValue); - return message; - }; + return message; + }; - /** - * Creates a plain object from an UninterpretedOption message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {google.protobuf.UninterpretedOption} message UninterpretedOption - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - UninterpretedOption.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.name = []; - if (options.defaults) { - object.identifierValue = ""; - if ($util.Long) { - var long = new $util.Long(0, 0, true); - object.positiveIntValue = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.positiveIntValue = options.longs === String ? "0" : 0; - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.negativeIntValue = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.negativeIntValue = options.longs === String ? "0" : 0; - object.doubleValue = 0; - if (options.bytes === String) - object.stringValue = ""; - else { - object.stringValue = []; - if (options.bytes !== Array) - object.stringValue = $util.newBuffer(object.stringValue); + /** + * Creates a plain object from a GetIamPolicyRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {google.iam.v1.GetIamPolicyRequest} message GetIamPolicyRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GetIamPolicyRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.resource = ""; + object.options = null; } - object.aggregateValue = ""; - } - if (message.name && message.name.length) { - object.name = []; - for (var j = 0; j < message.name.length; ++j) - object.name[j] = $root.google.protobuf.UninterpretedOption.NamePart.toObject(message.name[j], options); - } - if (message.identifierValue != null && message.hasOwnProperty("identifierValue")) - object.identifierValue = message.identifierValue; - if (message.positiveIntValue != null && message.hasOwnProperty("positiveIntValue")) - if (typeof message.positiveIntValue === "number") - object.positiveIntValue = options.longs === String ? String(message.positiveIntValue) : message.positiveIntValue; - else - object.positiveIntValue = options.longs === String ? $util.Long.prototype.toString.call(message.positiveIntValue) : options.longs === Number ? new $util.LongBits(message.positiveIntValue.low >>> 0, message.positiveIntValue.high >>> 0).toNumber(true) : message.positiveIntValue; - if (message.negativeIntValue != null && message.hasOwnProperty("negativeIntValue")) - if (typeof message.negativeIntValue === "number") - object.negativeIntValue = options.longs === String ? String(message.negativeIntValue) : message.negativeIntValue; - else - object.negativeIntValue = options.longs === String ? $util.Long.prototype.toString.call(message.negativeIntValue) : options.longs === Number ? new $util.LongBits(message.negativeIntValue.low >>> 0, message.negativeIntValue.high >>> 0).toNumber() : message.negativeIntValue; - if (message.doubleValue != null && message.hasOwnProperty("doubleValue")) - object.doubleValue = options.json && !isFinite(message.doubleValue) ? String(message.doubleValue) : message.doubleValue; - if (message.stringValue != null && message.hasOwnProperty("stringValue")) - object.stringValue = options.bytes === String ? $util.base64.encode(message.stringValue, 0, message.stringValue.length) : options.bytes === Array ? Array.prototype.slice.call(message.stringValue) : message.stringValue; - if (message.aggregateValue != null && message.hasOwnProperty("aggregateValue")) - object.aggregateValue = message.aggregateValue; - return object; - }; + if (message.resource != null && message.hasOwnProperty("resource")) + object.resource = message.resource; + if (message.options != null && message.hasOwnProperty("options")) + object.options = $root.google.iam.v1.GetPolicyOptions.toObject(message.options, options); + return object; + }; + + /** + * Converts this GetIamPolicyRequest to JSON. + * @function toJSON + * @memberof google.iam.v1.GetIamPolicyRequest + * @instance + * @returns {Object.} JSON object + */ + GetIamPolicyRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Converts this UninterpretedOption to JSON. - * @function toJSON - * @memberof google.protobuf.UninterpretedOption - * @instance - * @returns {Object.} JSON object - */ - UninterpretedOption.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Gets the default type url for GetIamPolicyRequest + * @function getTypeUrl + * @memberof google.iam.v1.GetIamPolicyRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + GetIamPolicyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.GetIamPolicyRequest"; + }; - /** - * Gets the default type url for UninterpretedOption - * @function getTypeUrl - * @memberof google.protobuf.UninterpretedOption - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - UninterpretedOption.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.UninterpretedOption"; - }; + return GetIamPolicyRequest; + })(); - UninterpretedOption.NamePart = (function() { + v1.TestIamPermissionsRequest = (function() { /** - * Properties of a NamePart. - * @memberof google.protobuf.UninterpretedOption - * @interface INamePart - * @property {string} namePart NamePart namePart - * @property {boolean} isExtension NamePart isExtension + * Properties of a TestIamPermissionsRequest. + * @memberof google.iam.v1 + * @interface ITestIamPermissionsRequest + * @property {string|null} [resource] TestIamPermissionsRequest resource + * @property {Array.|null} [permissions] TestIamPermissionsRequest permissions */ /** - * Constructs a new NamePart. - * @memberof google.protobuf.UninterpretedOption - * @classdesc Represents a NamePart. - * @implements INamePart + * Constructs a new TestIamPermissionsRequest. + * @memberof google.iam.v1 + * @classdesc Represents a TestIamPermissionsRequest. + * @implements ITestIamPermissionsRequest * @constructor - * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set + * @param {google.iam.v1.ITestIamPermissionsRequest=} [properties] Properties to set */ - function NamePart(properties) { + function TestIamPermissionsRequest(properties) { + this.permissions = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -59068,87 +66772,92 @@ } /** - * NamePart namePart. - * @member {string} namePart - * @memberof google.protobuf.UninterpretedOption.NamePart + * TestIamPermissionsRequest resource. + * @member {string} resource + * @memberof google.iam.v1.TestIamPermissionsRequest * @instance */ - NamePart.prototype.namePart = ""; + TestIamPermissionsRequest.prototype.resource = ""; /** - * NamePart isExtension. - * @member {boolean} isExtension - * @memberof google.protobuf.UninterpretedOption.NamePart + * TestIamPermissionsRequest permissions. + * @member {Array.} permissions + * @memberof google.iam.v1.TestIamPermissionsRequest * @instance */ - NamePart.prototype.isExtension = false; + TestIamPermissionsRequest.prototype.permissions = $util.emptyArray; /** - * Creates a new NamePart instance using the specified properties. + * Creates a new TestIamPermissionsRequest instance using the specified properties. * @function create - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static - * @param {google.protobuf.UninterpretedOption.INamePart=} [properties] Properties to set - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart instance + * @param {google.iam.v1.ITestIamPermissionsRequest=} [properties] Properties to set + * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest instance */ - NamePart.create = function create(properties) { - return new NamePart(properties); + TestIamPermissionsRequest.create = function create(properties) { + return new TestIamPermissionsRequest(properties); }; /** - * Encodes the specified NamePart message. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * Encodes the specified TestIamPermissionsRequest message. Does not implicitly {@link google.iam.v1.TestIamPermissionsRequest.verify|verify} messages. * @function encode - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static - * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {google.iam.v1.ITestIamPermissionsRequest} message TestIamPermissionsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NamePart.encode = function encode(message, writer) { + TestIamPermissionsRequest.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - writer.uint32(/* id 1, wireType 2 =*/10).string(message.namePart); - writer.uint32(/* id 2, wireType 0 =*/16).bool(message.isExtension); + if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); + if (message.permissions != null && message.permissions.length) + for (var i = 0; i < message.permissions.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.permissions[i]); return writer; }; /** - * Encodes the specified NamePart message, length delimited. Does not implicitly {@link google.protobuf.UninterpretedOption.NamePart.verify|verify} messages. + * Encodes the specified TestIamPermissionsRequest message, length delimited. Does not implicitly {@link google.iam.v1.TestIamPermissionsRequest.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static - * @param {google.protobuf.UninterpretedOption.INamePart} message NamePart message or plain object to encode + * @param {google.iam.v1.ITestIamPermissionsRequest} message TestIamPermissionsRequest message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - NamePart.encodeDelimited = function encodeDelimited(message, writer) { + TestIamPermissionsRequest.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a NamePart message from the specified reader or buffer. + * Decodes a TestIamPermissionsRequest message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NamePart.decode = function decode(reader, length) { + TestIamPermissionsRequest.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.UninterpretedOption.NamePart(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.TestIamPermissionsRequest(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.namePart = reader.string(); + message.resource = reader.string(); break; } case 2: { - message.isExtension = reader.bool(); + if (!(message.permissions && message.permissions.length)) + message.permissions = []; + message.permissions.push(reader.string()); break; } default: @@ -59156,525 +66865,227 @@ break; } } - if (!message.hasOwnProperty("namePart")) - throw $util.ProtocolError("missing required 'namePart'", { instance: message }); - if (!message.hasOwnProperty("isExtension")) - throw $util.ProtocolError("missing required 'isExtension'", { instance: message }); return message; }; /** - * Decodes a NamePart message from the specified reader or buffer, length delimited. + * Decodes a TestIamPermissionsRequest message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - NamePart.decodeDelimited = function decodeDelimited(reader) { + TestIamPermissionsRequest.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a NamePart message. + * Verifies a TestIamPermissionsRequest message. * @function verify - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - NamePart.verify = function verify(message) { + TestIamPermissionsRequest.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (!$util.isString(message.namePart)) - return "namePart: string expected"; - if (typeof message.isExtension !== "boolean") - return "isExtension: boolean expected"; + if (message.resource != null && message.hasOwnProperty("resource")) + if (!$util.isString(message.resource)) + return "resource: string expected"; + if (message.permissions != null && message.hasOwnProperty("permissions")) { + if (!Array.isArray(message.permissions)) + return "permissions: array expected"; + for (var i = 0; i < message.permissions.length; ++i) + if (!$util.isString(message.permissions[i])) + return "permissions: string[] expected"; + } return null; }; /** - * Creates a NamePart message from a plain object. Also converts values to their respective internal types. + * Creates a TestIamPermissionsRequest message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static * @param {Object.} object Plain object - * @returns {google.protobuf.UninterpretedOption.NamePart} NamePart + * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest */ - NamePart.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.UninterpretedOption.NamePart) + TestIamPermissionsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.TestIamPermissionsRequest) return object; - var message = new $root.google.protobuf.UninterpretedOption.NamePart(); - if (object.namePart != null) - message.namePart = String(object.namePart); - if (object.isExtension != null) - message.isExtension = Boolean(object.isExtension); + var message = new $root.google.iam.v1.TestIamPermissionsRequest(); + if (object.resource != null) + message.resource = String(object.resource); + if (object.permissions) { + if (!Array.isArray(object.permissions)) + throw TypeError(".google.iam.v1.TestIamPermissionsRequest.permissions: array expected"); + message.permissions = []; + for (var i = 0; i < object.permissions.length; ++i) + message.permissions[i] = String(object.permissions[i]); + } return message; }; /** - * Creates a plain object from a NamePart message. Also converts values to other types if specified. + * Creates a plain object from a TestIamPermissionsRequest message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static - * @param {google.protobuf.UninterpretedOption.NamePart} message NamePart + * @param {google.iam.v1.TestIamPermissionsRequest} message TestIamPermissionsRequest * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - NamePart.toObject = function toObject(message, options) { + TestIamPermissionsRequest.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.namePart = ""; - object.isExtension = false; + if (options.arrays || options.defaults) + object.permissions = []; + if (options.defaults) + object.resource = ""; + if (message.resource != null && message.hasOwnProperty("resource")) + object.resource = message.resource; + if (message.permissions && message.permissions.length) { + object.permissions = []; + for (var j = 0; j < message.permissions.length; ++j) + object.permissions[j] = message.permissions[j]; } - if (message.namePart != null && message.hasOwnProperty("namePart")) - object.namePart = message.namePart; - if (message.isExtension != null && message.hasOwnProperty("isExtension")) - object.isExtension = message.isExtension; return object; }; /** - * Converts this NamePart to JSON. + * Converts this TestIamPermissionsRequest to JSON. * @function toJSON - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @instance * @returns {Object.} JSON object */ - NamePart.prototype.toJSON = function toJSON() { + TestIamPermissionsRequest.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for NamePart + * Gets the default type url for TestIamPermissionsRequest * @function getTypeUrl - * @memberof google.protobuf.UninterpretedOption.NamePart + * @memberof google.iam.v1.TestIamPermissionsRequest * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - NamePart.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.UninterpretedOption.NamePart"; - }; - - return NamePart; - })(); - - return UninterpretedOption; - })(); - - protobuf.SourceCodeInfo = (function() { - - /** - * Properties of a SourceCodeInfo. - * @memberof google.protobuf - * @interface ISourceCodeInfo - * @property {Array.|null} [location] SourceCodeInfo location - */ - - /** - * Constructs a new SourceCodeInfo. - * @memberof google.protobuf - * @classdesc Represents a SourceCodeInfo. - * @implements ISourceCodeInfo - * @constructor - * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set - */ - function SourceCodeInfo(properties) { - this.location = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * SourceCodeInfo location. - * @member {Array.} location - * @memberof google.protobuf.SourceCodeInfo - * @instance - */ - SourceCodeInfo.prototype.location = $util.emptyArray; - - /** - * Creates a new SourceCodeInfo instance using the specified properties. - * @function create - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo=} [properties] Properties to set - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo instance - */ - SourceCodeInfo.create = function create(properties) { - return new SourceCodeInfo(properties); - }; - - /** - * Encodes the specified SourceCodeInfo message. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @function encode - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SourceCodeInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.location != null && message.location.length) - for (var i = 0; i < message.location.length; ++i) - $root.google.protobuf.SourceCodeInfo.Location.encode(message.location[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - return writer; - }; - - /** - * Encodes the specified SourceCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.ISourceCodeInfo} message SourceCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - SourceCodeInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SourceCodeInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.SourceCodeInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.location && message.location.length)) - message.location = []; - message.location.push($root.google.protobuf.SourceCodeInfo.Location.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a SourceCodeInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - SourceCodeInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a SourceCodeInfo message. - * @function verify - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - SourceCodeInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.location != null && message.hasOwnProperty("location")) { - if (!Array.isArray(message.location)) - return "location: array expected"; - for (var i = 0; i < message.location.length; ++i) { - var error = $root.google.protobuf.SourceCodeInfo.Location.verify(message.location[i]); - if (error) - return "location." + error; - } - } - return null; - }; - - /** - * Creates a SourceCodeInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.SourceCodeInfo} SourceCodeInfo - */ - SourceCodeInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.SourceCodeInfo) - return object; - var message = new $root.google.protobuf.SourceCodeInfo(); - if (object.location) { - if (!Array.isArray(object.location)) - throw TypeError(".google.protobuf.SourceCodeInfo.location: array expected"); - message.location = []; - for (var i = 0; i < object.location.length; ++i) { - if (typeof object.location[i] !== "object") - throw TypeError(".google.protobuf.SourceCodeInfo.location: object expected"); - message.location[i] = $root.google.protobuf.SourceCodeInfo.Location.fromObject(object.location[i]); - } - } - return message; - }; - - /** - * Creates a plain object from a SourceCodeInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {google.protobuf.SourceCodeInfo} message SourceCodeInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - SourceCodeInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.location = []; - if (message.location && message.location.length) { - object.location = []; - for (var j = 0; j < message.location.length; ++j) - object.location[j] = $root.google.protobuf.SourceCodeInfo.Location.toObject(message.location[j], options); - } - return object; - }; - - /** - * Converts this SourceCodeInfo to JSON. - * @function toJSON - * @memberof google.protobuf.SourceCodeInfo - * @instance - * @returns {Object.} JSON object - */ - SourceCodeInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for SourceCodeInfo - * @function getTypeUrl - * @memberof google.protobuf.SourceCodeInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - SourceCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.SourceCodeInfo"; - }; - - SourceCodeInfo.Location = (function() { - - /** - * Properties of a Location. - * @memberof google.protobuf.SourceCodeInfo - * @interface ILocation - * @property {Array.|null} [path] Location path - * @property {Array.|null} [span] Location span - * @property {string|null} [leadingComments] Location leadingComments - * @property {string|null} [trailingComments] Location trailingComments - * @property {Array.|null} [leadingDetachedComments] Location leadingDetachedComments - */ - - /** - * Constructs a new Location. - * @memberof google.protobuf.SourceCodeInfo - * @classdesc Represents a Location. - * @implements ILocation - * @constructor - * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set - */ - function Location(properties) { - this.path = []; - this.span = []; - this.leadingDetachedComments = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * Location path. - * @member {Array.} path - * @memberof google.protobuf.SourceCodeInfo.Location - * @instance - */ - Location.prototype.path = $util.emptyArray; - - /** - * Location span. - * @member {Array.} span - * @memberof google.protobuf.SourceCodeInfo.Location - * @instance + * @returns {string} The default type url */ - Location.prototype.span = $util.emptyArray; + TestIamPermissionsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.TestIamPermissionsRequest"; + }; + + return TestIamPermissionsRequest; + })(); + + v1.TestIamPermissionsResponse = (function() { /** - * Location leadingComments. - * @member {string} leadingComments - * @memberof google.protobuf.SourceCodeInfo.Location - * @instance + * Properties of a TestIamPermissionsResponse. + * @memberof google.iam.v1 + * @interface ITestIamPermissionsResponse + * @property {Array.|null} [permissions] TestIamPermissionsResponse permissions */ - Location.prototype.leadingComments = ""; /** - * Location trailingComments. - * @member {string} trailingComments - * @memberof google.protobuf.SourceCodeInfo.Location - * @instance + * Constructs a new TestIamPermissionsResponse. + * @memberof google.iam.v1 + * @classdesc Represents a TestIamPermissionsResponse. + * @implements ITestIamPermissionsResponse + * @constructor + * @param {google.iam.v1.ITestIamPermissionsResponse=} [properties] Properties to set */ - Location.prototype.trailingComments = ""; + function TestIamPermissionsResponse(properties) { + this.permissions = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } /** - * Location leadingDetachedComments. - * @member {Array.} leadingDetachedComments - * @memberof google.protobuf.SourceCodeInfo.Location + * TestIamPermissionsResponse permissions. + * @member {Array.} permissions + * @memberof google.iam.v1.TestIamPermissionsResponse * @instance */ - Location.prototype.leadingDetachedComments = $util.emptyArray; + TestIamPermissionsResponse.prototype.permissions = $util.emptyArray; /** - * Creates a new Location instance using the specified properties. + * Creates a new TestIamPermissionsResponse instance using the specified properties. * @function create - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static - * @param {google.protobuf.SourceCodeInfo.ILocation=} [properties] Properties to set - * @returns {google.protobuf.SourceCodeInfo.Location} Location instance + * @param {google.iam.v1.ITestIamPermissionsResponse=} [properties] Properties to set + * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse instance */ - Location.create = function create(properties) { - return new Location(properties); + TestIamPermissionsResponse.create = function create(properties) { + return new TestIamPermissionsResponse(properties); }; /** - * Encodes the specified Location message. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * Encodes the specified TestIamPermissionsResponse message. Does not implicitly {@link google.iam.v1.TestIamPermissionsResponse.verify|verify} messages. * @function encode - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static - * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {google.iam.v1.ITestIamPermissionsResponse} message TestIamPermissionsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Location.encode = function encode(message, writer) { + TestIamPermissionsResponse.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.path != null && message.path.length) { - writer.uint32(/* id 1, wireType 2 =*/10).fork(); - for (var i = 0; i < message.path.length; ++i) - writer.int32(message.path[i]); - writer.ldelim(); - } - if (message.span != null && message.span.length) { - writer.uint32(/* id 2, wireType 2 =*/18).fork(); - for (var i = 0; i < message.span.length; ++i) - writer.int32(message.span[i]); - writer.ldelim(); - } - if (message.leadingComments != null && Object.hasOwnProperty.call(message, "leadingComments")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.leadingComments); - if (message.trailingComments != null && Object.hasOwnProperty.call(message, "trailingComments")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.trailingComments); - if (message.leadingDetachedComments != null && message.leadingDetachedComments.length) - for (var i = 0; i < message.leadingDetachedComments.length; ++i) - writer.uint32(/* id 6, wireType 2 =*/50).string(message.leadingDetachedComments[i]); + if (message.permissions != null && message.permissions.length) + for (var i = 0; i < message.permissions.length; ++i) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.permissions[i]); return writer; }; /** - * Encodes the specified Location message, length delimited. Does not implicitly {@link google.protobuf.SourceCodeInfo.Location.verify|verify} messages. + * Encodes the specified TestIamPermissionsResponse message, length delimited. Does not implicitly {@link google.iam.v1.TestIamPermissionsResponse.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static - * @param {google.protobuf.SourceCodeInfo.ILocation} message Location message or plain object to encode + * @param {google.iam.v1.ITestIamPermissionsResponse} message TestIamPermissionsResponse message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Location.encodeDelimited = function encodeDelimited(message, writer) { + TestIamPermissionsResponse.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Location message from the specified reader or buffer. + * Decodes a TestIamPermissionsResponse message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Location.decode = function decode(reader, length) { + TestIamPermissionsResponse.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.SourceCodeInfo.Location(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.TestIamPermissionsResponse(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.path && message.path.length)) - message.path = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.path.push(reader.int32()); - } else - message.path.push(reader.int32()); - break; - } - case 2: { - if (!(message.span && message.span.length)) - message.span = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.span.push(reader.int32()); - } else - message.span.push(reader.int32()); - break; - } - case 3: { - message.leadingComments = reader.string(); - break; - } - case 4: { - message.trailingComments = reader.string(); - break; - } - case 6: { - if (!(message.leadingDetachedComments && message.leadingDetachedComments.length)) - message.leadingDetachedComments = []; - message.leadingDetachedComments.push(reader.string()); + if (!(message.permissions && message.permissions.length)) + message.permissions = []; + message.permissions.push(reader.string()); break; } default: @@ -59686,422 +67097,342 @@ }; /** - * Decodes a Location message from the specified reader or buffer, length delimited. + * Decodes a TestIamPermissionsResponse message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Location.decodeDelimited = function decodeDelimited(reader) { + TestIamPermissionsResponse.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Location message. + * Verifies a TestIamPermissionsResponse message. * @function verify - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Location.verify = function verify(message) { + TestIamPermissionsResponse.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.path != null && message.hasOwnProperty("path")) { - if (!Array.isArray(message.path)) - return "path: array expected"; - for (var i = 0; i < message.path.length; ++i) - if (!$util.isInteger(message.path[i])) - return "path: integer[] expected"; - } - if (message.span != null && message.hasOwnProperty("span")) { - if (!Array.isArray(message.span)) - return "span: array expected"; - for (var i = 0; i < message.span.length; ++i) - if (!$util.isInteger(message.span[i])) - return "span: integer[] expected"; - } - if (message.leadingComments != null && message.hasOwnProperty("leadingComments")) - if (!$util.isString(message.leadingComments)) - return "leadingComments: string expected"; - if (message.trailingComments != null && message.hasOwnProperty("trailingComments")) - if (!$util.isString(message.trailingComments)) - return "trailingComments: string expected"; - if (message.leadingDetachedComments != null && message.hasOwnProperty("leadingDetachedComments")) { - if (!Array.isArray(message.leadingDetachedComments)) - return "leadingDetachedComments: array expected"; - for (var i = 0; i < message.leadingDetachedComments.length; ++i) - if (!$util.isString(message.leadingDetachedComments[i])) - return "leadingDetachedComments: string[] expected"; + if (message.permissions != null && message.hasOwnProperty("permissions")) { + if (!Array.isArray(message.permissions)) + return "permissions: array expected"; + for (var i = 0; i < message.permissions.length; ++i) + if (!$util.isString(message.permissions[i])) + return "permissions: string[] expected"; } return null; }; /** - * Creates a Location message from a plain object. Also converts values to their respective internal types. + * Creates a TestIamPermissionsResponse message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static * @param {Object.} object Plain object - * @returns {google.protobuf.SourceCodeInfo.Location} Location + * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse */ - Location.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.SourceCodeInfo.Location) + TestIamPermissionsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.TestIamPermissionsResponse) return object; - var message = new $root.google.protobuf.SourceCodeInfo.Location(); - if (object.path) { - if (!Array.isArray(object.path)) - throw TypeError(".google.protobuf.SourceCodeInfo.Location.path: array expected"); - message.path = []; - for (var i = 0; i < object.path.length; ++i) - message.path[i] = object.path[i] | 0; - } - if (object.span) { - if (!Array.isArray(object.span)) - throw TypeError(".google.protobuf.SourceCodeInfo.Location.span: array expected"); - message.span = []; - for (var i = 0; i < object.span.length; ++i) - message.span[i] = object.span[i] | 0; - } - if (object.leadingComments != null) - message.leadingComments = String(object.leadingComments); - if (object.trailingComments != null) - message.trailingComments = String(object.trailingComments); - if (object.leadingDetachedComments) { - if (!Array.isArray(object.leadingDetachedComments)) - throw TypeError(".google.protobuf.SourceCodeInfo.Location.leadingDetachedComments: array expected"); - message.leadingDetachedComments = []; - for (var i = 0; i < object.leadingDetachedComments.length; ++i) - message.leadingDetachedComments[i] = String(object.leadingDetachedComments[i]); + var message = new $root.google.iam.v1.TestIamPermissionsResponse(); + if (object.permissions) { + if (!Array.isArray(object.permissions)) + throw TypeError(".google.iam.v1.TestIamPermissionsResponse.permissions: array expected"); + message.permissions = []; + for (var i = 0; i < object.permissions.length; ++i) + message.permissions[i] = String(object.permissions[i]); } return message; }; /** - * Creates a plain object from a Location message. Also converts values to other types if specified. + * Creates a plain object from a TestIamPermissionsResponse message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static - * @param {google.protobuf.SourceCodeInfo.Location} message Location + * @param {google.iam.v1.TestIamPermissionsResponse} message TestIamPermissionsResponse * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Location.toObject = function toObject(message, options) { + TestIamPermissionsResponse.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) { - object.path = []; - object.span = []; - object.leadingDetachedComments = []; - } - if (options.defaults) { - object.leadingComments = ""; - object.trailingComments = ""; - } - if (message.path && message.path.length) { - object.path = []; - for (var j = 0; j < message.path.length; ++j) - object.path[j] = message.path[j]; - } - if (message.span && message.span.length) { - object.span = []; - for (var j = 0; j < message.span.length; ++j) - object.span[j] = message.span[j]; - } - if (message.leadingComments != null && message.hasOwnProperty("leadingComments")) - object.leadingComments = message.leadingComments; - if (message.trailingComments != null && message.hasOwnProperty("trailingComments")) - object.trailingComments = message.trailingComments; - if (message.leadingDetachedComments && message.leadingDetachedComments.length) { - object.leadingDetachedComments = []; - for (var j = 0; j < message.leadingDetachedComments.length; ++j) - object.leadingDetachedComments[j] = message.leadingDetachedComments[j]; + if (options.arrays || options.defaults) + object.permissions = []; + if (message.permissions && message.permissions.length) { + object.permissions = []; + for (var j = 0; j < message.permissions.length; ++j) + object.permissions[j] = message.permissions[j]; } return object; }; /** - * Converts this Location to JSON. + * Converts this TestIamPermissionsResponse to JSON. * @function toJSON - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @instance * @returns {Object.} JSON object */ - Location.prototype.toJSON = function toJSON() { + TestIamPermissionsResponse.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Location + * Gets the default type url for TestIamPermissionsResponse * @function getTypeUrl - * @memberof google.protobuf.SourceCodeInfo.Location + * @memberof google.iam.v1.TestIamPermissionsResponse * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Location.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + TestIamPermissionsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.SourceCodeInfo.Location"; + return typeUrlPrefix + "/google.iam.v1.TestIamPermissionsResponse"; }; - return Location; + return TestIamPermissionsResponse; })(); - return SourceCodeInfo; - })(); - - protobuf.GeneratedCodeInfo = (function() { - - /** - * Properties of a GeneratedCodeInfo. - * @memberof google.protobuf - * @interface IGeneratedCodeInfo - * @property {Array.|null} [annotation] GeneratedCodeInfo annotation - */ - - /** - * Constructs a new GeneratedCodeInfo. - * @memberof google.protobuf - * @classdesc Represents a GeneratedCodeInfo. - * @implements IGeneratedCodeInfo - * @constructor - * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set - */ - function GeneratedCodeInfo(properties) { - this.annotation = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + v1.GetPolicyOptions = (function() { - /** - * GeneratedCodeInfo annotation. - * @member {Array.} annotation - * @memberof google.protobuf.GeneratedCodeInfo - * @instance - */ - GeneratedCodeInfo.prototype.annotation = $util.emptyArray; + /** + * Properties of a GetPolicyOptions. + * @memberof google.iam.v1 + * @interface IGetPolicyOptions + * @property {number|null} [requestedPolicyVersion] GetPolicyOptions requestedPolicyVersion + */ - /** - * Creates a new GeneratedCodeInfo instance using the specified properties. - * @function create - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo=} [properties] Properties to set - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo instance - */ - GeneratedCodeInfo.create = function create(properties) { - return new GeneratedCodeInfo(properties); - }; + /** + * Constructs a new GetPolicyOptions. + * @memberof google.iam.v1 + * @classdesc Represents a GetPolicyOptions. + * @implements IGetPolicyOptions + * @constructor + * @param {google.iam.v1.IGetPolicyOptions=} [properties] Properties to set + */ + function GetPolicyOptions(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified GeneratedCodeInfo message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @function encode - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GeneratedCodeInfo.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.annotation != null && message.annotation.length) - for (var i = 0; i < message.annotation.length; ++i) - $root.google.protobuf.GeneratedCodeInfo.Annotation.encode(message.annotation[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - return writer; - }; + /** + * GetPolicyOptions requestedPolicyVersion. + * @member {number} requestedPolicyVersion + * @memberof google.iam.v1.GetPolicyOptions + * @instance + */ + GetPolicyOptions.prototype.requestedPolicyVersion = 0; - /** - * Encodes the specified GeneratedCodeInfo message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.IGeneratedCodeInfo} message GeneratedCodeInfo message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GeneratedCodeInfo.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Creates a new GetPolicyOptions instance using the specified properties. + * @function create + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {google.iam.v1.IGetPolicyOptions=} [properties] Properties to set + * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions instance + */ + GetPolicyOptions.create = function create(properties) { + return new GetPolicyOptions(properties); + }; - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GeneratedCodeInfo.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.GeneratedCodeInfo(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.annotation && message.annotation.length)) - message.annotation = []; - message.annotation.push($root.google.protobuf.GeneratedCodeInfo.Annotation.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Encodes the specified GetPolicyOptions message. Does not implicitly {@link google.iam.v1.GetPolicyOptions.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {google.iam.v1.IGetPolicyOptions} message GetPolicyOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetPolicyOptions.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.requestedPolicyVersion != null && Object.hasOwnProperty.call(message, "requestedPolicyVersion")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.requestedPolicyVersion); + return writer; + }; - /** - * Decodes a GeneratedCodeInfo message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GeneratedCodeInfo.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified GetPolicyOptions message, length delimited. Does not implicitly {@link google.iam.v1.GetPolicyOptions.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {google.iam.v1.IGetPolicyOptions} message GetPolicyOptions message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetPolicyOptions.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Verifies a GeneratedCodeInfo message. - * @function verify - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - GeneratedCodeInfo.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.annotation != null && message.hasOwnProperty("annotation")) { - if (!Array.isArray(message.annotation)) - return "annotation: array expected"; - for (var i = 0; i < message.annotation.length; ++i) { - var error = $root.google.protobuf.GeneratedCodeInfo.Annotation.verify(message.annotation[i]); - if (error) - return "annotation." + error; + /** + * Decodes a GetPolicyOptions message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetPolicyOptions.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.GetPolicyOptions(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.requestedPolicyVersion = reader.int32(); + break; + } + default: + reader.skipType(tag & 7); + break; + } } - } - return null; - }; + return message; + }; - /** - * Creates a GeneratedCodeInfo message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.GeneratedCodeInfo} GeneratedCodeInfo - */ - GeneratedCodeInfo.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.GeneratedCodeInfo) + /** + * Decodes a GetPolicyOptions message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetPolicyOptions.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a GetPolicyOptions message. + * @function verify + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GetPolicyOptions.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.requestedPolicyVersion != null && message.hasOwnProperty("requestedPolicyVersion")) + if (!$util.isInteger(message.requestedPolicyVersion)) + return "requestedPolicyVersion: integer expected"; + return null; + }; + + /** + * Creates a GetPolicyOptions message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions + */ + GetPolicyOptions.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.GetPolicyOptions) + return object; + var message = new $root.google.iam.v1.GetPolicyOptions(); + if (object.requestedPolicyVersion != null) + message.requestedPolicyVersion = object.requestedPolicyVersion | 0; + return message; + }; + + /** + * Creates a plain object from a GetPolicyOptions message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {google.iam.v1.GetPolicyOptions} message GetPolicyOptions + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GetPolicyOptions.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.requestedPolicyVersion = 0; + if (message.requestedPolicyVersion != null && message.hasOwnProperty("requestedPolicyVersion")) + object.requestedPolicyVersion = message.requestedPolicyVersion; return object; - var message = new $root.google.protobuf.GeneratedCodeInfo(); - if (object.annotation) { - if (!Array.isArray(object.annotation)) - throw TypeError(".google.protobuf.GeneratedCodeInfo.annotation: array expected"); - message.annotation = []; - for (var i = 0; i < object.annotation.length; ++i) { - if (typeof object.annotation[i] !== "object") - throw TypeError(".google.protobuf.GeneratedCodeInfo.annotation: object expected"); - message.annotation[i] = $root.google.protobuf.GeneratedCodeInfo.Annotation.fromObject(object.annotation[i]); - } - } - return message; - }; + }; - /** - * Creates a plain object from a GeneratedCodeInfo message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {google.protobuf.GeneratedCodeInfo} message GeneratedCodeInfo - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - GeneratedCodeInfo.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.annotation = []; - if (message.annotation && message.annotation.length) { - object.annotation = []; - for (var j = 0; j < message.annotation.length; ++j) - object.annotation[j] = $root.google.protobuf.GeneratedCodeInfo.Annotation.toObject(message.annotation[j], options); - } - return object; - }; + /** + * Converts this GetPolicyOptions to JSON. + * @function toJSON + * @memberof google.iam.v1.GetPolicyOptions + * @instance + * @returns {Object.} JSON object + */ + GetPolicyOptions.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Converts this GeneratedCodeInfo to JSON. - * @function toJSON - * @memberof google.protobuf.GeneratedCodeInfo - * @instance - * @returns {Object.} JSON object - */ - GeneratedCodeInfo.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Gets the default type url for GetPolicyOptions + * @function getTypeUrl + * @memberof google.iam.v1.GetPolicyOptions + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + GetPolicyOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.GetPolicyOptions"; + }; - /** - * Gets the default type url for GeneratedCodeInfo - * @function getTypeUrl - * @memberof google.protobuf.GeneratedCodeInfo - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - GeneratedCodeInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo"; - }; + return GetPolicyOptions; + })(); - GeneratedCodeInfo.Annotation = (function() { + v1.Policy = (function() { /** - * Properties of an Annotation. - * @memberof google.protobuf.GeneratedCodeInfo - * @interface IAnnotation - * @property {Array.|null} [path] Annotation path - * @property {string|null} [sourceFile] Annotation sourceFile - * @property {number|null} [begin] Annotation begin - * @property {number|null} [end] Annotation end - * @property {google.protobuf.GeneratedCodeInfo.Annotation.Semantic|null} [semantic] Annotation semantic + * Properties of a Policy. + * @memberof google.iam.v1 + * @interface IPolicy + * @property {number|null} [version] Policy version + * @property {Array.|null} [bindings] Policy bindings + * @property {Array.|null} [auditConfigs] Policy auditConfigs + * @property {Uint8Array|null} [etag] Policy etag */ /** - * Constructs a new Annotation. - * @memberof google.protobuf.GeneratedCodeInfo - * @classdesc Represents an Annotation. - * @implements IAnnotation + * Constructs a new Policy. + * @memberof google.iam.v1 + * @classdesc Represents a Policy. + * @implements IPolicy * @constructor - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set + * @param {google.iam.v1.IPolicy=} [properties] Properties to set */ - function Annotation(properties) { - this.path = []; + function Policy(properties) { + this.bindings = []; + this.auditConfigs = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -60109,142 +67440,123 @@ } /** - * Annotation path. - * @member {Array.} path - * @memberof google.protobuf.GeneratedCodeInfo.Annotation - * @instance - */ - Annotation.prototype.path = $util.emptyArray; - - /** - * Annotation sourceFile. - * @member {string} sourceFile - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * Policy version. + * @member {number} version + * @memberof google.iam.v1.Policy * @instance */ - Annotation.prototype.sourceFile = ""; + Policy.prototype.version = 0; /** - * Annotation begin. - * @member {number} begin - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * Policy bindings. + * @member {Array.} bindings + * @memberof google.iam.v1.Policy * @instance */ - Annotation.prototype.begin = 0; + Policy.prototype.bindings = $util.emptyArray; /** - * Annotation end. - * @member {number} end - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * Policy auditConfigs. + * @member {Array.} auditConfigs + * @memberof google.iam.v1.Policy * @instance */ - Annotation.prototype.end = 0; + Policy.prototype.auditConfigs = $util.emptyArray; /** - * Annotation semantic. - * @member {google.protobuf.GeneratedCodeInfo.Annotation.Semantic} semantic - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * Policy etag. + * @member {Uint8Array} etag + * @memberof google.iam.v1.Policy * @instance */ - Annotation.prototype.semantic = 0; + Policy.prototype.etag = $util.newBuffer([]); /** - * Creates a new Annotation instance using the specified properties. + * Creates a new Policy instance using the specified properties. * @function create - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation=} [properties] Properties to set - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation instance + * @param {google.iam.v1.IPolicy=} [properties] Properties to set + * @returns {google.iam.v1.Policy} Policy instance */ - Annotation.create = function create(properties) { - return new Annotation(properties); + Policy.create = function create(properties) { + return new Policy(properties); }; /** - * Encodes the specified Annotation message. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * Encodes the specified Policy message. Does not implicitly {@link google.iam.v1.Policy.verify|verify} messages. * @function encode - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {google.iam.v1.IPolicy} message Policy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Annotation.encode = function encode(message, writer) { + Policy.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.path != null && message.path.length) { - writer.uint32(/* id 1, wireType 2 =*/10).fork(); - for (var i = 0; i < message.path.length; ++i) - writer.int32(message.path[i]); - writer.ldelim(); - } - if (message.sourceFile != null && Object.hasOwnProperty.call(message, "sourceFile")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.sourceFile); - if (message.begin != null && Object.hasOwnProperty.call(message, "begin")) - writer.uint32(/* id 3, wireType 0 =*/24).int32(message.begin); - if (message.end != null && Object.hasOwnProperty.call(message, "end")) - writer.uint32(/* id 4, wireType 0 =*/32).int32(message.end); - if (message.semantic != null && Object.hasOwnProperty.call(message, "semantic")) - writer.uint32(/* id 5, wireType 0 =*/40).int32(message.semantic); + if (message.version != null && Object.hasOwnProperty.call(message, "version")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.version); + if (message.etag != null && Object.hasOwnProperty.call(message, "etag")) + writer.uint32(/* id 3, wireType 2 =*/26).bytes(message.etag); + if (message.bindings != null && message.bindings.length) + for (var i = 0; i < message.bindings.length; ++i) + $root.google.iam.v1.Binding.encode(message.bindings[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.auditConfigs != null && message.auditConfigs.length) + for (var i = 0; i < message.auditConfigs.length; ++i) + $root.google.iam.v1.AuditConfig.encode(message.auditConfigs[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); return writer; }; /** - * Encodes the specified Annotation message, length delimited. Does not implicitly {@link google.protobuf.GeneratedCodeInfo.Annotation.verify|verify} messages. + * Encodes the specified Policy message, length delimited. Does not implicitly {@link google.iam.v1.Policy.verify|verify} messages. * @function encodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static - * @param {google.protobuf.GeneratedCodeInfo.IAnnotation} message Annotation message or plain object to encode + * @param {google.iam.v1.IPolicy} message Policy message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Annotation.encodeDelimited = function encodeDelimited(message, writer) { + Policy.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an Annotation message from the specified reader or buffer. + * Decodes a Policy message from the specified reader or buffer. * @function decode - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {google.iam.v1.Policy} Policy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Annotation.decode = function decode(reader, length) { + Policy.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.GeneratedCodeInfo.Annotation(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.Policy(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - if (!(message.path && message.path.length)) - message.path = []; - if ((tag & 7) === 2) { - var end2 = reader.uint32() + reader.pos; - while (reader.pos < end2) - message.path.push(reader.int32()); - } else - message.path.push(reader.int32()); - break; - } - case 2: { - message.sourceFile = reader.string(); + message.version = reader.int32(); break; } - case 3: { - message.begin = reader.int32(); + case 4: { + if (!(message.bindings && message.bindings.length)) + message.bindings = []; + message.bindings.push($root.google.iam.v1.Binding.decode(reader, reader.uint32())); break; } - case 4: { - message.end = reader.int32(); + case 6: { + if (!(message.auditConfigs && message.auditConfigs.length)) + message.auditConfigs = []; + message.auditConfigs.push($root.google.iam.v1.AuditConfig.decode(reader, reader.uint32())); break; } - case 5: { - message.semantic = reader.int32(); + case 3: { + message.etag = reader.bytes(); break; } default: @@ -60256,1003 +67568,1005 @@ }; /** - * Decodes an Annotation message from the specified reader or buffer, length delimited. + * Decodes a Policy message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {google.iam.v1.Policy} Policy * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Annotation.decodeDelimited = function decodeDelimited(reader) { + Policy.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an Annotation message. + * Verifies a Policy message. * @function verify - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Annotation.verify = function verify(message) { + Policy.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.path != null && message.hasOwnProperty("path")) { - if (!Array.isArray(message.path)) - return "path: array expected"; - for (var i = 0; i < message.path.length; ++i) - if (!$util.isInteger(message.path[i])) - return "path: integer[] expected"; + if (message.version != null && message.hasOwnProperty("version")) + if (!$util.isInteger(message.version)) + return "version: integer expected"; + if (message.bindings != null && message.hasOwnProperty("bindings")) { + if (!Array.isArray(message.bindings)) + return "bindings: array expected"; + for (var i = 0; i < message.bindings.length; ++i) { + var error = $root.google.iam.v1.Binding.verify(message.bindings[i]); + if (error) + return "bindings." + error; + } } - if (message.sourceFile != null && message.hasOwnProperty("sourceFile")) - if (!$util.isString(message.sourceFile)) - return "sourceFile: string expected"; - if (message.begin != null && message.hasOwnProperty("begin")) - if (!$util.isInteger(message.begin)) - return "begin: integer expected"; - if (message.end != null && message.hasOwnProperty("end")) - if (!$util.isInteger(message.end)) - return "end: integer expected"; - if (message.semantic != null && message.hasOwnProperty("semantic")) - switch (message.semantic) { - default: - return "semantic: enum value expected"; - case 0: - case 1: - case 2: - break; + if (message.auditConfigs != null && message.hasOwnProperty("auditConfigs")) { + if (!Array.isArray(message.auditConfigs)) + return "auditConfigs: array expected"; + for (var i = 0; i < message.auditConfigs.length; ++i) { + var error = $root.google.iam.v1.AuditConfig.verify(message.auditConfigs[i]); + if (error) + return "auditConfigs." + error; } + } + if (message.etag != null && message.hasOwnProperty("etag")) + if (!(message.etag && typeof message.etag.length === "number" || $util.isString(message.etag))) + return "etag: buffer expected"; return null; }; /** - * Creates an Annotation message from a plain object. Also converts values to their respective internal types. + * Creates a Policy message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static * @param {Object.} object Plain object - * @returns {google.protobuf.GeneratedCodeInfo.Annotation} Annotation + * @returns {google.iam.v1.Policy} Policy */ - Annotation.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.GeneratedCodeInfo.Annotation) + Policy.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.Policy) return object; - var message = new $root.google.protobuf.GeneratedCodeInfo.Annotation(); - if (object.path) { - if (!Array.isArray(object.path)) - throw TypeError(".google.protobuf.GeneratedCodeInfo.Annotation.path: array expected"); - message.path = []; - for (var i = 0; i < object.path.length; ++i) - message.path[i] = object.path[i] | 0; + var message = new $root.google.iam.v1.Policy(); + if (object.version != null) + message.version = object.version | 0; + if (object.bindings) { + if (!Array.isArray(object.bindings)) + throw TypeError(".google.iam.v1.Policy.bindings: array expected"); + message.bindings = []; + for (var i = 0; i < object.bindings.length; ++i) { + if (typeof object.bindings[i] !== "object") + throw TypeError(".google.iam.v1.Policy.bindings: object expected"); + message.bindings[i] = $root.google.iam.v1.Binding.fromObject(object.bindings[i]); + } } - if (object.sourceFile != null) - message.sourceFile = String(object.sourceFile); - if (object.begin != null) - message.begin = object.begin | 0; - if (object.end != null) - message.end = object.end | 0; - switch (object.semantic) { - default: - if (typeof object.semantic === "number") { - message.semantic = object.semantic; - break; + if (object.auditConfigs) { + if (!Array.isArray(object.auditConfigs)) + throw TypeError(".google.iam.v1.Policy.auditConfigs: array expected"); + message.auditConfigs = []; + for (var i = 0; i < object.auditConfigs.length; ++i) { + if (typeof object.auditConfigs[i] !== "object") + throw TypeError(".google.iam.v1.Policy.auditConfigs: object expected"); + message.auditConfigs[i] = $root.google.iam.v1.AuditConfig.fromObject(object.auditConfigs[i]); } - break; - case "NONE": - case 0: - message.semantic = 0; - break; - case "SET": - case 1: - message.semantic = 1; - break; - case "ALIAS": - case 2: - message.semantic = 2; - break; } + if (object.etag != null) + if (typeof object.etag === "string") + $util.base64.decode(object.etag, message.etag = $util.newBuffer($util.base64.length(object.etag)), 0); + else if (object.etag.length >= 0) + message.etag = object.etag; return message; }; /** - * Creates a plain object from an Annotation message. Also converts values to other types if specified. + * Creates a plain object from a Policy message. Also converts values to other types if specified. * @function toObject - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static - * @param {google.protobuf.GeneratedCodeInfo.Annotation} message Annotation + * @param {google.iam.v1.Policy} message Policy * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Annotation.toObject = function toObject(message, options) { + Policy.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.path = []; + if (options.arrays || options.defaults) { + object.bindings = []; + object.auditConfigs = []; + } if (options.defaults) { - object.sourceFile = ""; - object.begin = 0; - object.end = 0; - object.semantic = options.enums === String ? "NONE" : 0; + object.version = 0; + if (options.bytes === String) + object.etag = ""; + else { + object.etag = []; + if (options.bytes !== Array) + object.etag = $util.newBuffer(object.etag); + } } - if (message.path && message.path.length) { - object.path = []; - for (var j = 0; j < message.path.length; ++j) - object.path[j] = message.path[j]; + if (message.version != null && message.hasOwnProperty("version")) + object.version = message.version; + if (message.etag != null && message.hasOwnProperty("etag")) + object.etag = options.bytes === String ? $util.base64.encode(message.etag, 0, message.etag.length) : options.bytes === Array ? Array.prototype.slice.call(message.etag) : message.etag; + if (message.bindings && message.bindings.length) { + object.bindings = []; + for (var j = 0; j < message.bindings.length; ++j) + object.bindings[j] = $root.google.iam.v1.Binding.toObject(message.bindings[j], options); + } + if (message.auditConfigs && message.auditConfigs.length) { + object.auditConfigs = []; + for (var j = 0; j < message.auditConfigs.length; ++j) + object.auditConfigs[j] = $root.google.iam.v1.AuditConfig.toObject(message.auditConfigs[j], options); } - if (message.sourceFile != null && message.hasOwnProperty("sourceFile")) - object.sourceFile = message.sourceFile; - if (message.begin != null && message.hasOwnProperty("begin")) - object.begin = message.begin; - if (message.end != null && message.hasOwnProperty("end")) - object.end = message.end; - if (message.semantic != null && message.hasOwnProperty("semantic")) - object.semantic = options.enums === String ? $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] === undefined ? message.semantic : $root.google.protobuf.GeneratedCodeInfo.Annotation.Semantic[message.semantic] : message.semantic; return object; }; /** - * Converts this Annotation to JSON. + * Converts this Policy to JSON. * @function toJSON - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @instance * @returns {Object.} JSON object */ - Annotation.prototype.toJSON = function toJSON() { + Policy.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Annotation + * Gets the default type url for Policy * @function getTypeUrl - * @memberof google.protobuf.GeneratedCodeInfo.Annotation + * @memberof google.iam.v1.Policy * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Annotation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Policy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.protobuf.GeneratedCodeInfo.Annotation"; + return typeUrlPrefix + "/google.iam.v1.Policy"; }; - /** - * Semantic enum. - * @name google.protobuf.GeneratedCodeInfo.Annotation.Semantic - * @enum {number} - * @property {number} NONE=0 NONE value - * @property {number} SET=1 SET value - * @property {number} ALIAS=2 ALIAS value - */ - Annotation.Semantic = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "NONE"] = 0; - values[valuesById[1] = "SET"] = 1; - values[valuesById[2] = "ALIAS"] = 2; - return values; - })(); - - return Annotation; + return Policy; })(); - return GeneratedCodeInfo; - })(); - - protobuf.Timestamp = (function() { - - /** - * Properties of a Timestamp. - * @memberof google.protobuf - * @interface ITimestamp - * @property {number|Long|null} [seconds] Timestamp seconds - * @property {number|null} [nanos] Timestamp nanos - */ - - /** - * Constructs a new Timestamp. - * @memberof google.protobuf - * @classdesc Represents a Timestamp. - * @implements ITimestamp - * @constructor - * @param {google.protobuf.ITimestamp=} [properties] Properties to set - */ - function Timestamp(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * Timestamp seconds. - * @member {number|Long} seconds - * @memberof google.protobuf.Timestamp - * @instance - */ - Timestamp.prototype.seconds = $util.Long ? $util.Long.fromBits(0,0,false) : 0; - - /** - * Timestamp nanos. - * @member {number} nanos - * @memberof google.protobuf.Timestamp - * @instance - */ - Timestamp.prototype.nanos = 0; - - /** - * Creates a new Timestamp instance using the specified properties. - * @function create - * @memberof google.protobuf.Timestamp - * @static - * @param {google.protobuf.ITimestamp=} [properties] Properties to set - * @returns {google.protobuf.Timestamp} Timestamp instance - */ - Timestamp.create = function create(properties) { - return new Timestamp(properties); - }; - - /** - * Encodes the specified Timestamp message. Does not implicitly {@link google.protobuf.Timestamp.verify|verify} messages. - * @function encode - * @memberof google.protobuf.Timestamp - * @static - * @param {google.protobuf.ITimestamp} message Timestamp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Timestamp.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.seconds != null && Object.hasOwnProperty.call(message, "seconds")) - writer.uint32(/* id 1, wireType 0 =*/8).int64(message.seconds); - if (message.nanos != null && Object.hasOwnProperty.call(message, "nanos")) - writer.uint32(/* id 2, wireType 0 =*/16).int32(message.nanos); - return writer; - }; - - /** - * Encodes the specified Timestamp message, length delimited. Does not implicitly {@link google.protobuf.Timestamp.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.Timestamp - * @static - * @param {google.protobuf.ITimestamp} message Timestamp message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Timestamp.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; - - /** - * Decodes a Timestamp message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.Timestamp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.Timestamp} Timestamp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Timestamp.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Timestamp(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.seconds = reader.int64(); - break; - } - case 2: { - message.nanos = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; - - /** - * Decodes a Timestamp message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.Timestamp - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.Timestamp} Timestamp - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Timestamp.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; - - /** - * Verifies a Timestamp message. - * @function verify - * @memberof google.protobuf.Timestamp - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Timestamp.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.seconds != null && message.hasOwnProperty("seconds")) - if (!$util.isInteger(message.seconds) && !(message.seconds && $util.isInteger(message.seconds.low) && $util.isInteger(message.seconds.high))) - return "seconds: integer|Long expected"; - if (message.nanos != null && message.hasOwnProperty("nanos")) - if (!$util.isInteger(message.nanos)) - return "nanos: integer expected"; - return null; - }; - - /** - * Creates a Timestamp message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.Timestamp - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.Timestamp} Timestamp - */ - Timestamp.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.Timestamp) - return object; - var message = new $root.google.protobuf.Timestamp(); - if (object.seconds != null) - if ($util.Long) - (message.seconds = $util.Long.fromValue(object.seconds)).unsigned = false; - else if (typeof object.seconds === "string") - message.seconds = parseInt(object.seconds, 10); - else if (typeof object.seconds === "number") - message.seconds = object.seconds; - else if (typeof object.seconds === "object") - message.seconds = new $util.LongBits(object.seconds.low >>> 0, object.seconds.high >>> 0).toNumber(); - if (object.nanos != null) - message.nanos = object.nanos | 0; - return message; - }; - - /** - * Creates a plain object from a Timestamp message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.Timestamp - * @static - * @param {google.protobuf.Timestamp} message Timestamp - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Timestamp.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - if ($util.Long) { - var long = new $util.Long(0, 0, false); - object.seconds = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.seconds = options.longs === String ? "0" : 0; - object.nanos = 0; - } - if (message.seconds != null && message.hasOwnProperty("seconds")) - if (typeof message.seconds === "number") - object.seconds = options.longs === String ? String(message.seconds) : message.seconds; - else - object.seconds = options.longs === String ? $util.Long.prototype.toString.call(message.seconds) : options.longs === Number ? new $util.LongBits(message.seconds.low >>> 0, message.seconds.high >>> 0).toNumber() : message.seconds; - if (message.nanos != null && message.hasOwnProperty("nanos")) - object.nanos = message.nanos; - return object; - }; + v1.Binding = (function() { - /** - * Converts this Timestamp to JSON. - * @function toJSON - * @memberof google.protobuf.Timestamp - * @instance - * @returns {Object.} JSON object - */ - Timestamp.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Properties of a Binding. + * @memberof google.iam.v1 + * @interface IBinding + * @property {string|null} [role] Binding role + * @property {Array.|null} [members] Binding members + * @property {google.type.IExpr|null} [condition] Binding condition + */ - /** - * Gets the default type url for Timestamp - * @function getTypeUrl - * @memberof google.protobuf.Timestamp - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Timestamp.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + /** + * Constructs a new Binding. + * @memberof google.iam.v1 + * @classdesc Represents a Binding. + * @implements IBinding + * @constructor + * @param {google.iam.v1.IBinding=} [properties] Properties to set + */ + function Binding(properties) { + this.members = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - return typeUrlPrefix + "/google.protobuf.Timestamp"; - }; - - return Timestamp; - })(); - - protobuf.FieldMask = (function() { - - /** - * Properties of a FieldMask. - * @memberof google.protobuf - * @interface IFieldMask - * @property {Array.|null} [paths] FieldMask paths - */ - - /** - * Constructs a new FieldMask. - * @memberof google.protobuf - * @classdesc Represents a FieldMask. - * @implements IFieldMask - * @constructor - * @param {google.protobuf.IFieldMask=} [properties] Properties to set - */ - function FieldMask(properties) { - this.paths = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } - - /** - * FieldMask paths. - * @member {Array.} paths - * @memberof google.protobuf.FieldMask - * @instance - */ - FieldMask.prototype.paths = $util.emptyArray; - - /** - * Creates a new FieldMask instance using the specified properties. - * @function create - * @memberof google.protobuf.FieldMask - * @static - * @param {google.protobuf.IFieldMask=} [properties] Properties to set - * @returns {google.protobuf.FieldMask} FieldMask instance - */ - FieldMask.create = function create(properties) { - return new FieldMask(properties); - }; - /** - * Encodes the specified FieldMask message. Does not implicitly {@link google.protobuf.FieldMask.verify|verify} messages. - * @function encode - * @memberof google.protobuf.FieldMask - * @static - * @param {google.protobuf.IFieldMask} message FieldMask message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldMask.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.paths != null && message.paths.length) - for (var i = 0; i < message.paths.length; ++i) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.paths[i]); - return writer; - }; + /** + * Binding role. + * @member {string} role + * @memberof google.iam.v1.Binding + * @instance + */ + Binding.prototype.role = ""; - /** - * Encodes the specified FieldMask message, length delimited. Does not implicitly {@link google.protobuf.FieldMask.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.FieldMask - * @static - * @param {google.protobuf.IFieldMask} message FieldMask message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - FieldMask.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Binding members. + * @member {Array.} members + * @memberof google.iam.v1.Binding + * @instance + */ + Binding.prototype.members = $util.emptyArray; - /** - * Decodes a FieldMask message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.FieldMask - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.FieldMask} FieldMask - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldMask.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.FieldMask(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.paths && message.paths.length)) - message.paths = []; - message.paths.push(reader.string()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Binding condition. + * @member {google.type.IExpr|null|undefined} condition + * @memberof google.iam.v1.Binding + * @instance + */ + Binding.prototype.condition = null; - /** - * Decodes a FieldMask message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.FieldMask - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.FieldMask} FieldMask - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - FieldMask.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Creates a new Binding instance using the specified properties. + * @function create + * @memberof google.iam.v1.Binding + * @static + * @param {google.iam.v1.IBinding=} [properties] Properties to set + * @returns {google.iam.v1.Binding} Binding instance + */ + Binding.create = function create(properties) { + return new Binding(properties); + }; - /** - * Verifies a FieldMask message. - * @function verify - * @memberof google.protobuf.FieldMask - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - FieldMask.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.paths != null && message.hasOwnProperty("paths")) { - if (!Array.isArray(message.paths)) - return "paths: array expected"; - for (var i = 0; i < message.paths.length; ++i) - if (!$util.isString(message.paths[i])) - return "paths: string[] expected"; - } - return null; - }; + /** + * Encodes the specified Binding message. Does not implicitly {@link google.iam.v1.Binding.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.Binding + * @static + * @param {google.iam.v1.IBinding} message Binding message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Binding.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.role != null && Object.hasOwnProperty.call(message, "role")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.role); + if (message.members != null && message.members.length) + for (var i = 0; i < message.members.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.members[i]); + if (message.condition != null && Object.hasOwnProperty.call(message, "condition")) + $root.google.type.Expr.encode(message.condition, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; - /** - * Creates a FieldMask message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.FieldMask - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.FieldMask} FieldMask - */ - FieldMask.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.FieldMask) - return object; - var message = new $root.google.protobuf.FieldMask(); - if (object.paths) { - if (!Array.isArray(object.paths)) - throw TypeError(".google.protobuf.FieldMask.paths: array expected"); - message.paths = []; - for (var i = 0; i < object.paths.length; ++i) - message.paths[i] = String(object.paths[i]); - } - return message; - }; + /** + * Encodes the specified Binding message, length delimited. Does not implicitly {@link google.iam.v1.Binding.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.Binding + * @static + * @param {google.iam.v1.IBinding} message Binding message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Binding.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Creates a plain object from a FieldMask message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.FieldMask - * @static - * @param {google.protobuf.FieldMask} message FieldMask - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - FieldMask.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.paths = []; - if (message.paths && message.paths.length) { - object.paths = []; - for (var j = 0; j < message.paths.length; ++j) - object.paths[j] = message.paths[j]; - } - return object; - }; + /** + * Decodes a Binding message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.Binding + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.Binding} Binding + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Binding.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.Binding(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.role = reader.string(); + break; + } + case 2: { + if (!(message.members && message.members.length)) + message.members = []; + message.members.push(reader.string()); + break; + } + case 3: { + message.condition = $root.google.type.Expr.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Converts this FieldMask to JSON. - * @function toJSON - * @memberof google.protobuf.FieldMask - * @instance - * @returns {Object.} JSON object - */ - FieldMask.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Decodes a Binding message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.Binding + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.Binding} Binding + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Binding.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Gets the default type url for FieldMask - * @function getTypeUrl - * @memberof google.protobuf.FieldMask - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - FieldMask.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.FieldMask"; - }; + /** + * Verifies a Binding message. + * @function verify + * @memberof google.iam.v1.Binding + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Binding.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.role != null && message.hasOwnProperty("role")) + if (!$util.isString(message.role)) + return "role: string expected"; + if (message.members != null && message.hasOwnProperty("members")) { + if (!Array.isArray(message.members)) + return "members: array expected"; + for (var i = 0; i < message.members.length; ++i) + if (!$util.isString(message.members[i])) + return "members: string[] expected"; + } + if (message.condition != null && message.hasOwnProperty("condition")) { + var error = $root.google.type.Expr.verify(message.condition); + if (error) + return "condition." + error; + } + return null; + }; - return FieldMask; - })(); + /** + * Creates a Binding message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.Binding + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.Binding} Binding + */ + Binding.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.Binding) + return object; + var message = new $root.google.iam.v1.Binding(); + if (object.role != null) + message.role = String(object.role); + if (object.members) { + if (!Array.isArray(object.members)) + throw TypeError(".google.iam.v1.Binding.members: array expected"); + message.members = []; + for (var i = 0; i < object.members.length; ++i) + message.members[i] = String(object.members[i]); + } + if (object.condition != null) { + if (typeof object.condition !== "object") + throw TypeError(".google.iam.v1.Binding.condition: object expected"); + message.condition = $root.google.type.Expr.fromObject(object.condition); + } + return message; + }; - protobuf.Empty = (function() { + /** + * Creates a plain object from a Binding message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.Binding + * @static + * @param {google.iam.v1.Binding} message Binding + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Binding.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.members = []; + if (options.defaults) { + object.role = ""; + object.condition = null; + } + if (message.role != null && message.hasOwnProperty("role")) + object.role = message.role; + if (message.members && message.members.length) { + object.members = []; + for (var j = 0; j < message.members.length; ++j) + object.members[j] = message.members[j]; + } + if (message.condition != null && message.hasOwnProperty("condition")) + object.condition = $root.google.type.Expr.toObject(message.condition, options); + return object; + }; - /** - * Properties of an Empty. - * @memberof google.protobuf - * @interface IEmpty - */ + /** + * Converts this Binding to JSON. + * @function toJSON + * @memberof google.iam.v1.Binding + * @instance + * @returns {Object.} JSON object + */ + Binding.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new Empty. - * @memberof google.protobuf - * @classdesc Represents an Empty. - * @implements IEmpty - * @constructor - * @param {google.protobuf.IEmpty=} [properties] Properties to set - */ - function Empty(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Gets the default type url for Binding + * @function getTypeUrl + * @memberof google.iam.v1.Binding + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Binding.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.Binding"; + }; - /** - * Creates a new Empty instance using the specified properties. - * @function create - * @memberof google.protobuf.Empty - * @static - * @param {google.protobuf.IEmpty=} [properties] Properties to set - * @returns {google.protobuf.Empty} Empty instance - */ - Empty.create = function create(properties) { - return new Empty(properties); - }; + return Binding; + })(); - /** - * Encodes the specified Empty message. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. - * @function encode - * @memberof google.protobuf.Empty - * @static - * @param {google.protobuf.IEmpty} message Empty message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Empty.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - return writer; - }; + v1.AuditConfig = (function() { - /** - * Encodes the specified Empty message, length delimited. Does not implicitly {@link google.protobuf.Empty.verify|verify} messages. - * @function encodeDelimited - * @memberof google.protobuf.Empty - * @static - * @param {google.protobuf.IEmpty} message Empty message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Empty.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Properties of an AuditConfig. + * @memberof google.iam.v1 + * @interface IAuditConfig + * @property {string|null} [service] AuditConfig service + * @property {Array.|null} [auditLogConfigs] AuditConfig auditLogConfigs + */ - /** - * Decodes an Empty message from the specified reader or buffer. - * @function decode - * @memberof google.protobuf.Empty - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.protobuf.Empty} Empty - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Empty.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.protobuf.Empty(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - default: - reader.skipType(tag & 7); - break; - } + /** + * Constructs a new AuditConfig. + * @memberof google.iam.v1 + * @classdesc Represents an AuditConfig. + * @implements IAuditConfig + * @constructor + * @param {google.iam.v1.IAuditConfig=} [properties] Properties to set + */ + function AuditConfig(properties) { + this.auditLogConfigs = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - return message; - }; - /** - * Decodes an Empty message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.protobuf.Empty - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.protobuf.Empty} Empty - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Empty.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * AuditConfig service. + * @member {string} service + * @memberof google.iam.v1.AuditConfig + * @instance + */ + AuditConfig.prototype.service = ""; - /** - * Verifies an Empty message. - * @function verify - * @memberof google.protobuf.Empty - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Empty.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - return null; - }; + /** + * AuditConfig auditLogConfigs. + * @member {Array.} auditLogConfigs + * @memberof google.iam.v1.AuditConfig + * @instance + */ + AuditConfig.prototype.auditLogConfigs = $util.emptyArray; - /** - * Creates an Empty message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.protobuf.Empty - * @static - * @param {Object.} object Plain object - * @returns {google.protobuf.Empty} Empty - */ - Empty.fromObject = function fromObject(object) { - if (object instanceof $root.google.protobuf.Empty) - return object; - return new $root.google.protobuf.Empty(); - }; + /** + * Creates a new AuditConfig instance using the specified properties. + * @function create + * @memberof google.iam.v1.AuditConfig + * @static + * @param {google.iam.v1.IAuditConfig=} [properties] Properties to set + * @returns {google.iam.v1.AuditConfig} AuditConfig instance + */ + AuditConfig.create = function create(properties) { + return new AuditConfig(properties); + }; - /** - * Creates a plain object from an Empty message. Also converts values to other types if specified. - * @function toObject - * @memberof google.protobuf.Empty - * @static - * @param {google.protobuf.Empty} message Empty - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Empty.toObject = function toObject() { - return {}; - }; + /** + * Encodes the specified AuditConfig message. Does not implicitly {@link google.iam.v1.AuditConfig.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.AuditConfig + * @static + * @param {google.iam.v1.IAuditConfig} message AuditConfig message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AuditConfig.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.service != null && Object.hasOwnProperty.call(message, "service")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.service); + if (message.auditLogConfigs != null && message.auditLogConfigs.length) + for (var i = 0; i < message.auditLogConfigs.length; ++i) + $root.google.iam.v1.AuditLogConfig.encode(message.auditLogConfigs[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + return writer; + }; - /** - * Converts this Empty to JSON. - * @function toJSON - * @memberof google.protobuf.Empty - * @instance - * @returns {Object.} JSON object - */ - Empty.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Encodes the specified AuditConfig message, length delimited. Does not implicitly {@link google.iam.v1.AuditConfig.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.AuditConfig + * @static + * @param {google.iam.v1.IAuditConfig} message AuditConfig message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + AuditConfig.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Gets the default type url for Empty - * @function getTypeUrl - * @memberof google.protobuf.Empty - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Empty.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.protobuf.Empty"; - }; + /** + * Decodes an AuditConfig message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.AuditConfig + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.AuditConfig} AuditConfig + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AuditConfig.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditConfig(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.service = reader.string(); + break; + } + case 3: { + if (!(message.auditLogConfigs && message.auditLogConfigs.length)) + message.auditLogConfigs = []; + message.auditLogConfigs.push($root.google.iam.v1.AuditLogConfig.decode(reader, reader.uint32())); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an AuditConfig message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.AuditConfig + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.AuditConfig} AuditConfig + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + AuditConfig.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - return Empty; - })(); + /** + * Verifies an AuditConfig message. + * @function verify + * @memberof google.iam.v1.AuditConfig + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + AuditConfig.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.service != null && message.hasOwnProperty("service")) + if (!$util.isString(message.service)) + return "service: string expected"; + if (message.auditLogConfigs != null && message.hasOwnProperty("auditLogConfigs")) { + if (!Array.isArray(message.auditLogConfigs)) + return "auditLogConfigs: array expected"; + for (var i = 0; i < message.auditLogConfigs.length; ++i) { + var error = $root.google.iam.v1.AuditLogConfig.verify(message.auditLogConfigs[i]); + if (error) + return "auditLogConfigs." + error; + } + } + return null; + }; - return protobuf; - })(); + /** + * Creates an AuditConfig message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.AuditConfig + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.AuditConfig} AuditConfig + */ + AuditConfig.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.AuditConfig) + return object; + var message = new $root.google.iam.v1.AuditConfig(); + if (object.service != null) + message.service = String(object.service); + if (object.auditLogConfigs) { + if (!Array.isArray(object.auditLogConfigs)) + throw TypeError(".google.iam.v1.AuditConfig.auditLogConfigs: array expected"); + message.auditLogConfigs = []; + for (var i = 0; i < object.auditLogConfigs.length; ++i) { + if (typeof object.auditLogConfigs[i] !== "object") + throw TypeError(".google.iam.v1.AuditConfig.auditLogConfigs: object expected"); + message.auditLogConfigs[i] = $root.google.iam.v1.AuditLogConfig.fromObject(object.auditLogConfigs[i]); + } + } + return message; + }; - google.iam = (function() { + /** + * Creates a plain object from an AuditConfig message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.AuditConfig + * @static + * @param {google.iam.v1.AuditConfig} message AuditConfig + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + AuditConfig.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.auditLogConfigs = []; + if (options.defaults) + object.service = ""; + if (message.service != null && message.hasOwnProperty("service")) + object.service = message.service; + if (message.auditLogConfigs && message.auditLogConfigs.length) { + object.auditLogConfigs = []; + for (var j = 0; j < message.auditLogConfigs.length; ++j) + object.auditLogConfigs[j] = $root.google.iam.v1.AuditLogConfig.toObject(message.auditLogConfigs[j], options); + } + return object; + }; - /** - * Namespace iam. - * @memberof google - * @namespace - */ - var iam = {}; + /** + * Converts this AuditConfig to JSON. + * @function toJSON + * @memberof google.iam.v1.AuditConfig + * @instance + * @returns {Object.} JSON object + */ + AuditConfig.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - iam.v1 = (function() { + /** + * Gets the default type url for AuditConfig + * @function getTypeUrl + * @memberof google.iam.v1.AuditConfig + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + AuditConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.AuditConfig"; + }; - /** - * Namespace v1. - * @memberof google.iam - * @namespace - */ - var v1 = {}; + return AuditConfig; + })(); - v1.IAMPolicy = (function() { + v1.AuditLogConfig = (function() { /** - * Constructs a new IAMPolicy service. + * Properties of an AuditLogConfig. * @memberof google.iam.v1 - * @classdesc Represents a IAMPolicy - * @extends $protobuf.rpc.Service + * @interface IAuditLogConfig + * @property {google.iam.v1.AuditLogConfig.LogType|null} [logType] AuditLogConfig logType + * @property {Array.|null} [exemptedMembers] AuditLogConfig exemptedMembers + */ + + /** + * Constructs a new AuditLogConfig. + * @memberof google.iam.v1 + * @classdesc Represents an AuditLogConfig. + * @implements IAuditLogConfig * @constructor - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @param {google.iam.v1.IAuditLogConfig=} [properties] Properties to set */ - function IAMPolicy(rpcImpl, requestDelimited, responseDelimited) { - $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + function AuditLogConfig(properties) { + this.exemptedMembers = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; } - (IAMPolicy.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = IAMPolicy; + /** + * AuditLogConfig logType. + * @member {google.iam.v1.AuditLogConfig.LogType} logType + * @memberof google.iam.v1.AuditLogConfig + * @instance + */ + AuditLogConfig.prototype.logType = 0; /** - * Creates new IAMPolicy service using the specified rpc implementation. + * AuditLogConfig exemptedMembers. + * @member {Array.} exemptedMembers + * @memberof google.iam.v1.AuditLogConfig + * @instance + */ + AuditLogConfig.prototype.exemptedMembers = $util.emptyArray; + + /** + * Creates a new AuditLogConfig instance using the specified properties. * @function create - * @memberof google.iam.v1.IAMPolicy + * @memberof google.iam.v1.AuditLogConfig * @static - * @param {$protobuf.RPCImpl} rpcImpl RPC implementation - * @param {boolean} [requestDelimited=false] Whether requests are length-delimited - * @param {boolean} [responseDelimited=false] Whether responses are length-delimited - * @returns {IAMPolicy} RPC service. Useful where requests and/or responses are streamed. + * @param {google.iam.v1.IAuditLogConfig=} [properties] Properties to set + * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig instance */ - IAMPolicy.create = function create(rpcImpl, requestDelimited, responseDelimited) { - return new this(rpcImpl, requestDelimited, responseDelimited); + AuditLogConfig.create = function create(properties) { + return new AuditLogConfig(properties); }; /** - * Callback as used by {@link google.iam.v1.IAMPolicy|setIamPolicy}. - * @memberof google.iam.v1.IAMPolicy - * @typedef SetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy + * Encodes the specified AuditLogConfig message. Does not implicitly {@link google.iam.v1.AuditLogConfig.verify|verify} messages. + * @function encode + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {google.iam.v1.IAuditLogConfig} message AuditLogConfig message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ + AuditLogConfig.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.logType != null && Object.hasOwnProperty.call(message, "logType")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.logType); + if (message.exemptedMembers != null && message.exemptedMembers.length) + for (var i = 0; i < message.exemptedMembers.length; ++i) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.exemptedMembers[i]); + return writer; + }; /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.iam.v1.IAMPolicy - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @param {google.iam.v1.IAMPolicy.SetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 + * Encodes the specified AuditLogConfig message, length delimited. Does not implicitly {@link google.iam.v1.AuditLogConfig.verify|verify} messages. + * @function encodeDelimited + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {google.iam.v1.IAuditLogConfig} message AuditLogConfig message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer */ - Object.defineProperty(IAMPolicy.prototype.setIamPolicy = function setIamPolicy(request, callback) { - return this.rpcCall(setIamPolicy, $root.google.iam.v1.SetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "SetIamPolicy" }); + AuditLogConfig.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; /** - * Calls SetIamPolicy. - * @function setIamPolicy - * @memberof google.iam.v1.IAMPolicy - * @instance - * @param {google.iam.v1.ISetIamPolicyRequest} request SetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Decodes an AuditLogConfig message from the specified reader or buffer. + * @function decode + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + AuditLogConfig.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditLogConfig(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.logType = reader.int32(); + break; + } + case 2: { + if (!(message.exemptedMembers && message.exemptedMembers.length)) + message.exemptedMembers = []; + message.exemptedMembers.push(reader.string()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; /** - * Callback as used by {@link google.iam.v1.IAMPolicy|getIamPolicy}. - * @memberof google.iam.v1.IAMPolicy - * @typedef GetIamPolicyCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.Policy} [response] Policy + * Decodes an AuditLogConfig message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing */ + AuditLogConfig.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.iam.v1.IAMPolicy - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @param {google.iam.v1.IAMPolicy.GetIamPolicyCallback} callback Node-style callback called with the error, if any, and Policy - * @returns {undefined} - * @variation 1 + * Verifies an AuditLogConfig message. + * @function verify + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Object.defineProperty(IAMPolicy.prototype.getIamPolicy = function getIamPolicy(request, callback) { - return this.rpcCall(getIamPolicy, $root.google.iam.v1.GetIamPolicyRequest, $root.google.iam.v1.Policy, request, callback); - }, "name", { value: "GetIamPolicy" }); + AuditLogConfig.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.logType != null && message.hasOwnProperty("logType")) + switch (message.logType) { + default: + return "logType: enum value expected"; + case 0: + case 1: + case 2: + case 3: + break; + } + if (message.exemptedMembers != null && message.hasOwnProperty("exemptedMembers")) { + if (!Array.isArray(message.exemptedMembers)) + return "exemptedMembers: array expected"; + for (var i = 0; i < message.exemptedMembers.length; ++i) + if (!$util.isString(message.exemptedMembers[i])) + return "exemptedMembers: string[] expected"; + } + return null; + }; /** - * Calls GetIamPolicy. - * @function getIamPolicy - * @memberof google.iam.v1.IAMPolicy - * @instance - * @param {google.iam.v1.IGetIamPolicyRequest} request GetIamPolicyRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Creates an AuditLogConfig message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {Object.} object Plain object + * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig */ + AuditLogConfig.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.AuditLogConfig) + return object; + var message = new $root.google.iam.v1.AuditLogConfig(); + switch (object.logType) { + default: + if (typeof object.logType === "number") { + message.logType = object.logType; + break; + } + break; + case "LOG_TYPE_UNSPECIFIED": + case 0: + message.logType = 0; + break; + case "ADMIN_READ": + case 1: + message.logType = 1; + break; + case "DATA_WRITE": + case 2: + message.logType = 2; + break; + case "DATA_READ": + case 3: + message.logType = 3; + break; + } + if (object.exemptedMembers) { + if (!Array.isArray(object.exemptedMembers)) + throw TypeError(".google.iam.v1.AuditLogConfig.exemptedMembers: array expected"); + message.exemptedMembers = []; + for (var i = 0; i < object.exemptedMembers.length; ++i) + message.exemptedMembers[i] = String(object.exemptedMembers[i]); + } + return message; + }; /** - * Callback as used by {@link google.iam.v1.IAMPolicy|testIamPermissions}. - * @memberof google.iam.v1.IAMPolicy - * @typedef TestIamPermissionsCallback - * @type {function} - * @param {Error|null} error Error, if any - * @param {google.iam.v1.TestIamPermissionsResponse} [response] TestIamPermissionsResponse + * Creates a plain object from an AuditLogConfig message. Also converts values to other types if specified. + * @function toObject + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {google.iam.v1.AuditLogConfig} message AuditLogConfig + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object */ + AuditLogConfig.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.exemptedMembers = []; + if (options.defaults) + object.logType = options.enums === String ? "LOG_TYPE_UNSPECIFIED" : 0; + if (message.logType != null && message.hasOwnProperty("logType")) + object.logType = options.enums === String ? $root.google.iam.v1.AuditLogConfig.LogType[message.logType] === undefined ? message.logType : $root.google.iam.v1.AuditLogConfig.LogType[message.logType] : message.logType; + if (message.exemptedMembers && message.exemptedMembers.length) { + object.exemptedMembers = []; + for (var j = 0; j < message.exemptedMembers.length; ++j) + object.exemptedMembers[j] = message.exemptedMembers[j]; + } + return object; + }; /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.iam.v1.IAMPolicy + * Converts this AuditLogConfig to JSON. + * @function toJSON + * @memberof google.iam.v1.AuditLogConfig * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @param {google.iam.v1.IAMPolicy.TestIamPermissionsCallback} callback Node-style callback called with the error, if any, and TestIamPermissionsResponse - * @returns {undefined} - * @variation 1 + * @returns {Object.} JSON object */ - Object.defineProperty(IAMPolicy.prototype.testIamPermissions = function testIamPermissions(request, callback) { - return this.rpcCall(testIamPermissions, $root.google.iam.v1.TestIamPermissionsRequest, $root.google.iam.v1.TestIamPermissionsResponse, request, callback); - }, "name", { value: "TestIamPermissions" }); + AuditLogConfig.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; /** - * Calls TestIamPermissions. - * @function testIamPermissions - * @memberof google.iam.v1.IAMPolicy - * @instance - * @param {google.iam.v1.ITestIamPermissionsRequest} request TestIamPermissionsRequest message or plain object - * @returns {Promise} Promise - * @variation 2 + * Gets the default type url for AuditLogConfig + * @function getTypeUrl + * @memberof google.iam.v1.AuditLogConfig + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url */ + AuditLogConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.AuditLogConfig"; + }; - return IAMPolicy; + /** + * LogType enum. + * @name google.iam.v1.AuditLogConfig.LogType + * @enum {number} + * @property {number} LOG_TYPE_UNSPECIFIED=0 LOG_TYPE_UNSPECIFIED value + * @property {number} ADMIN_READ=1 ADMIN_READ value + * @property {number} DATA_WRITE=2 DATA_WRITE value + * @property {number} DATA_READ=3 DATA_READ value + */ + AuditLogConfig.LogType = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "LOG_TYPE_UNSPECIFIED"] = 0; + values[valuesById[1] = "ADMIN_READ"] = 1; + values[valuesById[2] = "DATA_WRITE"] = 2; + values[valuesById[3] = "DATA_READ"] = 3; + return values; + })(); + + return AuditLogConfig; })(); - v1.SetIamPolicyRequest = (function() { + v1.PolicyDelta = (function() { /** - * Properties of a SetIamPolicyRequest. + * Properties of a PolicyDelta. * @memberof google.iam.v1 - * @interface ISetIamPolicyRequest - * @property {string|null} [resource] SetIamPolicyRequest resource - * @property {google.iam.v1.IPolicy|null} [policy] SetIamPolicyRequest policy - * @property {google.protobuf.IFieldMask|null} [updateMask] SetIamPolicyRequest updateMask + * @interface IPolicyDelta + * @property {Array.|null} [bindingDeltas] PolicyDelta bindingDeltas + * @property {Array.|null} [auditConfigDeltas] PolicyDelta auditConfigDeltas */ /** - * Constructs a new SetIamPolicyRequest. + * Constructs a new PolicyDelta. * @memberof google.iam.v1 - * @classdesc Represents a SetIamPolicyRequest. - * @implements ISetIamPolicyRequest + * @classdesc Represents a PolicyDelta. + * @implements IPolicyDelta * @constructor - * @param {google.iam.v1.ISetIamPolicyRequest=} [properties] Properties to set + * @param {google.iam.v1.IPolicyDelta=} [properties] Properties to set */ - function SetIamPolicyRequest(properties) { + function PolicyDelta(properties) { + this.bindingDeltas = []; + this.auditConfigDeltas = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -61260,103 +68574,95 @@ } /** - * SetIamPolicyRequest resource. - * @member {string} resource - * @memberof google.iam.v1.SetIamPolicyRequest - * @instance - */ - SetIamPolicyRequest.prototype.resource = ""; - - /** - * SetIamPolicyRequest policy. - * @member {google.iam.v1.IPolicy|null|undefined} policy - * @memberof google.iam.v1.SetIamPolicyRequest + * PolicyDelta bindingDeltas. + * @member {Array.} bindingDeltas + * @memberof google.iam.v1.PolicyDelta * @instance */ - SetIamPolicyRequest.prototype.policy = null; + PolicyDelta.prototype.bindingDeltas = $util.emptyArray; /** - * SetIamPolicyRequest updateMask. - * @member {google.protobuf.IFieldMask|null|undefined} updateMask - * @memberof google.iam.v1.SetIamPolicyRequest + * PolicyDelta auditConfigDeltas. + * @member {Array.} auditConfigDeltas + * @memberof google.iam.v1.PolicyDelta * @instance */ - SetIamPolicyRequest.prototype.updateMask = null; + PolicyDelta.prototype.auditConfigDeltas = $util.emptyArray; /** - * Creates a new SetIamPolicyRequest instance using the specified properties. + * Creates a new PolicyDelta instance using the specified properties. * @function create - * @memberof google.iam.v1.SetIamPolicyRequest - * @static - * @param {google.iam.v1.ISetIamPolicyRequest=} [properties] Properties to set - * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest instance + * @memberof google.iam.v1.PolicyDelta + * @static + * @param {google.iam.v1.IPolicyDelta=} [properties] Properties to set + * @returns {google.iam.v1.PolicyDelta} PolicyDelta instance */ - SetIamPolicyRequest.create = function create(properties) { - return new SetIamPolicyRequest(properties); + PolicyDelta.create = function create(properties) { + return new PolicyDelta(properties); }; /** - * Encodes the specified SetIamPolicyRequest message. Does not implicitly {@link google.iam.v1.SetIamPolicyRequest.verify|verify} messages. + * Encodes the specified PolicyDelta message. Does not implicitly {@link google.iam.v1.PolicyDelta.verify|verify} messages. * @function encode - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static - * @param {google.iam.v1.ISetIamPolicyRequest} message SetIamPolicyRequest message or plain object to encode + * @param {google.iam.v1.IPolicyDelta} message PolicyDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SetIamPolicyRequest.encode = function encode(message, writer) { + PolicyDelta.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); - if (message.policy != null && Object.hasOwnProperty.call(message, "policy")) - $root.google.iam.v1.Policy.encode(message.policy, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - if (message.updateMask != null && Object.hasOwnProperty.call(message, "updateMask")) - $root.google.protobuf.FieldMask.encode(message.updateMask, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); + if (message.bindingDeltas != null && message.bindingDeltas.length) + for (var i = 0; i < message.bindingDeltas.length; ++i) + $root.google.iam.v1.BindingDelta.encode(message.bindingDeltas[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.auditConfigDeltas != null && message.auditConfigDeltas.length) + for (var i = 0; i < message.auditConfigDeltas.length; ++i) + $root.google.iam.v1.AuditConfigDelta.encode(message.auditConfigDeltas[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); return writer; }; /** - * Encodes the specified SetIamPolicyRequest message, length delimited. Does not implicitly {@link google.iam.v1.SetIamPolicyRequest.verify|verify} messages. + * Encodes the specified PolicyDelta message, length delimited. Does not implicitly {@link google.iam.v1.PolicyDelta.verify|verify} messages. * @function encodeDelimited - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static - * @param {google.iam.v1.ISetIamPolicyRequest} message SetIamPolicyRequest message or plain object to encode + * @param {google.iam.v1.IPolicyDelta} message PolicyDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - SetIamPolicyRequest.encodeDelimited = function encodeDelimited(message, writer) { + PolicyDelta.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a SetIamPolicyRequest message from the specified reader or buffer. + * Decodes a PolicyDelta message from the specified reader or buffer. * @function decode - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + * @returns {google.iam.v1.PolicyDelta} PolicyDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SetIamPolicyRequest.decode = function decode(reader, length) { + PolicyDelta.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.SetIamPolicyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.PolicyDelta(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.resource = reader.string(); + if (!(message.bindingDeltas && message.bindingDeltas.length)) + message.bindingDeltas = []; + message.bindingDeltas.push($root.google.iam.v1.BindingDelta.decode(reader, reader.uint32())); break; } case 2: { - message.policy = $root.google.iam.v1.Policy.decode(reader, reader.uint32()); - break; - } - case 3: { - message.updateMask = $root.google.protobuf.FieldMask.decode(reader, reader.uint32()); + if (!(message.auditConfigDeltas && message.auditConfigDeltas.length)) + message.auditConfigDeltas = []; + message.auditConfigDeltas.push($root.google.iam.v1.AuditConfigDelta.decode(reader, reader.uint32())); break; } default: @@ -61368,150 +68674,168 @@ }; /** - * Decodes a SetIamPolicyRequest message from the specified reader or buffer, length delimited. + * Decodes a PolicyDelta message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + * @returns {google.iam.v1.PolicyDelta} PolicyDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - SetIamPolicyRequest.decodeDelimited = function decodeDelimited(reader) { + PolicyDelta.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a SetIamPolicyRequest message. + * Verifies a PolicyDelta message. * @function verify - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - SetIamPolicyRequest.verify = function verify(message) { + PolicyDelta.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.resource != null && message.hasOwnProperty("resource")) - if (!$util.isString(message.resource)) - return "resource: string expected"; - if (message.policy != null && message.hasOwnProperty("policy")) { - var error = $root.google.iam.v1.Policy.verify(message.policy); - if (error) - return "policy." + error; + if (message.bindingDeltas != null && message.hasOwnProperty("bindingDeltas")) { + if (!Array.isArray(message.bindingDeltas)) + return "bindingDeltas: array expected"; + for (var i = 0; i < message.bindingDeltas.length; ++i) { + var error = $root.google.iam.v1.BindingDelta.verify(message.bindingDeltas[i]); + if (error) + return "bindingDeltas." + error; + } } - if (message.updateMask != null && message.hasOwnProperty("updateMask")) { - var error = $root.google.protobuf.FieldMask.verify(message.updateMask); - if (error) - return "updateMask." + error; + if (message.auditConfigDeltas != null && message.hasOwnProperty("auditConfigDeltas")) { + if (!Array.isArray(message.auditConfigDeltas)) + return "auditConfigDeltas: array expected"; + for (var i = 0; i < message.auditConfigDeltas.length; ++i) { + var error = $root.google.iam.v1.AuditConfigDelta.verify(message.auditConfigDeltas[i]); + if (error) + return "auditConfigDeltas." + error; + } } return null; }; /** - * Creates a SetIamPolicyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a PolicyDelta message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static * @param {Object.} object Plain object - * @returns {google.iam.v1.SetIamPolicyRequest} SetIamPolicyRequest + * @returns {google.iam.v1.PolicyDelta} PolicyDelta */ - SetIamPolicyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.SetIamPolicyRequest) + PolicyDelta.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.PolicyDelta) return object; - var message = new $root.google.iam.v1.SetIamPolicyRequest(); - if (object.resource != null) - message.resource = String(object.resource); - if (object.policy != null) { - if (typeof object.policy !== "object") - throw TypeError(".google.iam.v1.SetIamPolicyRequest.policy: object expected"); - message.policy = $root.google.iam.v1.Policy.fromObject(object.policy); + var message = new $root.google.iam.v1.PolicyDelta(); + if (object.bindingDeltas) { + if (!Array.isArray(object.bindingDeltas)) + throw TypeError(".google.iam.v1.PolicyDelta.bindingDeltas: array expected"); + message.bindingDeltas = []; + for (var i = 0; i < object.bindingDeltas.length; ++i) { + if (typeof object.bindingDeltas[i] !== "object") + throw TypeError(".google.iam.v1.PolicyDelta.bindingDeltas: object expected"); + message.bindingDeltas[i] = $root.google.iam.v1.BindingDelta.fromObject(object.bindingDeltas[i]); + } } - if (object.updateMask != null) { - if (typeof object.updateMask !== "object") - throw TypeError(".google.iam.v1.SetIamPolicyRequest.updateMask: object expected"); - message.updateMask = $root.google.protobuf.FieldMask.fromObject(object.updateMask); + if (object.auditConfigDeltas) { + if (!Array.isArray(object.auditConfigDeltas)) + throw TypeError(".google.iam.v1.PolicyDelta.auditConfigDeltas: array expected"); + message.auditConfigDeltas = []; + for (var i = 0; i < object.auditConfigDeltas.length; ++i) { + if (typeof object.auditConfigDeltas[i] !== "object") + throw TypeError(".google.iam.v1.PolicyDelta.auditConfigDeltas: object expected"); + message.auditConfigDeltas[i] = $root.google.iam.v1.AuditConfigDelta.fromObject(object.auditConfigDeltas[i]); + } } return message; }; /** - * Creates a plain object from a SetIamPolicyRequest message. Also converts values to other types if specified. + * Creates a plain object from a PolicyDelta message. Also converts values to other types if specified. * @function toObject - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static - * @param {google.iam.v1.SetIamPolicyRequest} message SetIamPolicyRequest + * @param {google.iam.v1.PolicyDelta} message PolicyDelta * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - SetIamPolicyRequest.toObject = function toObject(message, options) { + PolicyDelta.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.defaults) { - object.resource = ""; - object.policy = null; - object.updateMask = null; + if (options.arrays || options.defaults) { + object.bindingDeltas = []; + object.auditConfigDeltas = []; + } + if (message.bindingDeltas && message.bindingDeltas.length) { + object.bindingDeltas = []; + for (var j = 0; j < message.bindingDeltas.length; ++j) + object.bindingDeltas[j] = $root.google.iam.v1.BindingDelta.toObject(message.bindingDeltas[j], options); + } + if (message.auditConfigDeltas && message.auditConfigDeltas.length) { + object.auditConfigDeltas = []; + for (var j = 0; j < message.auditConfigDeltas.length; ++j) + object.auditConfigDeltas[j] = $root.google.iam.v1.AuditConfigDelta.toObject(message.auditConfigDeltas[j], options); } - if (message.resource != null && message.hasOwnProperty("resource")) - object.resource = message.resource; - if (message.policy != null && message.hasOwnProperty("policy")) - object.policy = $root.google.iam.v1.Policy.toObject(message.policy, options); - if (message.updateMask != null && message.hasOwnProperty("updateMask")) - object.updateMask = $root.google.protobuf.FieldMask.toObject(message.updateMask, options); return object; }; /** - * Converts this SetIamPolicyRequest to JSON. + * Converts this PolicyDelta to JSON. * @function toJSON - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @instance * @returns {Object.} JSON object */ - SetIamPolicyRequest.prototype.toJSON = function toJSON() { + PolicyDelta.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for SetIamPolicyRequest + * Gets the default type url for PolicyDelta * @function getTypeUrl - * @memberof google.iam.v1.SetIamPolicyRequest + * @memberof google.iam.v1.PolicyDelta * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - SetIamPolicyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + PolicyDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.iam.v1.SetIamPolicyRequest"; + return typeUrlPrefix + "/google.iam.v1.PolicyDelta"; }; - return SetIamPolicyRequest; + return PolicyDelta; })(); - v1.GetIamPolicyRequest = (function() { + v1.BindingDelta = (function() { /** - * Properties of a GetIamPolicyRequest. + * Properties of a BindingDelta. * @memberof google.iam.v1 - * @interface IGetIamPolicyRequest - * @property {string|null} [resource] GetIamPolicyRequest resource - * @property {google.iam.v1.IGetPolicyOptions|null} [options] GetIamPolicyRequest options + * @interface IBindingDelta + * @property {google.iam.v1.BindingDelta.Action|null} [action] BindingDelta action + * @property {string|null} [role] BindingDelta role + * @property {string|null} [member] BindingDelta member + * @property {google.type.IExpr|null} [condition] BindingDelta condition */ /** - * Constructs a new GetIamPolicyRequest. + * Constructs a new BindingDelta. * @memberof google.iam.v1 - * @classdesc Represents a GetIamPolicyRequest. - * @implements IGetIamPolicyRequest + * @classdesc Represents a BindingDelta. + * @implements IBindingDelta * @constructor - * @param {google.iam.v1.IGetIamPolicyRequest=} [properties] Properties to set + * @param {google.iam.v1.IBindingDelta=} [properties] Properties to set */ - function GetIamPolicyRequest(properties) { + function BindingDelta(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -61519,89 +68843,117 @@ } /** - * GetIamPolicyRequest resource. - * @member {string} resource - * @memberof google.iam.v1.GetIamPolicyRequest + * BindingDelta action. + * @member {google.iam.v1.BindingDelta.Action} action + * @memberof google.iam.v1.BindingDelta * @instance */ - GetIamPolicyRequest.prototype.resource = ""; + BindingDelta.prototype.action = 0; /** - * GetIamPolicyRequest options. - * @member {google.iam.v1.IGetPolicyOptions|null|undefined} options - * @memberof google.iam.v1.GetIamPolicyRequest + * BindingDelta role. + * @member {string} role + * @memberof google.iam.v1.BindingDelta * @instance */ - GetIamPolicyRequest.prototype.options = null; + BindingDelta.prototype.role = ""; /** - * Creates a new GetIamPolicyRequest instance using the specified properties. + * BindingDelta member. + * @member {string} member + * @memberof google.iam.v1.BindingDelta + * @instance + */ + BindingDelta.prototype.member = ""; + + /** + * BindingDelta condition. + * @member {google.type.IExpr|null|undefined} condition + * @memberof google.iam.v1.BindingDelta + * @instance + */ + BindingDelta.prototype.condition = null; + + /** + * Creates a new BindingDelta instance using the specified properties. * @function create - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static - * @param {google.iam.v1.IGetIamPolicyRequest=} [properties] Properties to set - * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest instance + * @param {google.iam.v1.IBindingDelta=} [properties] Properties to set + * @returns {google.iam.v1.BindingDelta} BindingDelta instance */ - GetIamPolicyRequest.create = function create(properties) { - return new GetIamPolicyRequest(properties); + BindingDelta.create = function create(properties) { + return new BindingDelta(properties); }; /** - * Encodes the specified GetIamPolicyRequest message. Does not implicitly {@link google.iam.v1.GetIamPolicyRequest.verify|verify} messages. + * Encodes the specified BindingDelta message. Does not implicitly {@link google.iam.v1.BindingDelta.verify|verify} messages. * @function encode - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static - * @param {google.iam.v1.IGetIamPolicyRequest} message GetIamPolicyRequest message or plain object to encode + * @param {google.iam.v1.IBindingDelta} message BindingDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetIamPolicyRequest.encode = function encode(message, writer) { + BindingDelta.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); - if (message.options != null && Object.hasOwnProperty.call(message, "options")) - $root.google.iam.v1.GetPolicyOptions.encode(message.options, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.action != null && Object.hasOwnProperty.call(message, "action")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.action); + if (message.role != null && Object.hasOwnProperty.call(message, "role")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.role); + if (message.member != null && Object.hasOwnProperty.call(message, "member")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.member); + if (message.condition != null && Object.hasOwnProperty.call(message, "condition")) + $root.google.type.Expr.encode(message.condition, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); return writer; }; /** - * Encodes the specified GetIamPolicyRequest message, length delimited. Does not implicitly {@link google.iam.v1.GetIamPolicyRequest.verify|verify} messages. + * Encodes the specified BindingDelta message, length delimited. Does not implicitly {@link google.iam.v1.BindingDelta.verify|verify} messages. * @function encodeDelimited - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static - * @param {google.iam.v1.IGetIamPolicyRequest} message GetIamPolicyRequest message or plain object to encode + * @param {google.iam.v1.IBindingDelta} message BindingDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - GetIamPolicyRequest.encodeDelimited = function encodeDelimited(message, writer) { + BindingDelta.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a GetIamPolicyRequest message from the specified reader or buffer. + * Decodes a BindingDelta message from the specified reader or buffer. * @function decode - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + * @returns {google.iam.v1.BindingDelta} BindingDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetIamPolicyRequest.decode = function decode(reader, length) { + BindingDelta.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.GetIamPolicyRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.BindingDelta(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.resource = reader.string(); + message.action = reader.int32(); break; } case 2: { - message.options = $root.google.iam.v1.GetPolicyOptions.decode(reader, reader.uint32()); + message.role = reader.string(); + break; + } + case 3: { + message.member = reader.string(); + break; + } + case 4: { + message.condition = $root.google.type.Expr.decode(reader, reader.uint32()); break; } default: @@ -61613,138 +68965,195 @@ }; /** - * Decodes a GetIamPolicyRequest message from the specified reader or buffer, length delimited. + * Decodes a BindingDelta message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + * @returns {google.iam.v1.BindingDelta} BindingDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - GetIamPolicyRequest.decodeDelimited = function decodeDelimited(reader) { + BindingDelta.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a GetIamPolicyRequest message. + * Verifies a BindingDelta message. * @function verify - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - GetIamPolicyRequest.verify = function verify(message) { + BindingDelta.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.resource != null && message.hasOwnProperty("resource")) - if (!$util.isString(message.resource)) - return "resource: string expected"; - if (message.options != null && message.hasOwnProperty("options")) { - var error = $root.google.iam.v1.GetPolicyOptions.verify(message.options); + if (message.action != null && message.hasOwnProperty("action")) + switch (message.action) { + default: + return "action: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.role != null && message.hasOwnProperty("role")) + if (!$util.isString(message.role)) + return "role: string expected"; + if (message.member != null && message.hasOwnProperty("member")) + if (!$util.isString(message.member)) + return "member: string expected"; + if (message.condition != null && message.hasOwnProperty("condition")) { + var error = $root.google.type.Expr.verify(message.condition); if (error) - return "options." + error; + return "condition." + error; } return null; }; /** - * Creates a GetIamPolicyRequest message from a plain object. Also converts values to their respective internal types. + * Creates a BindingDelta message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static * @param {Object.} object Plain object - * @returns {google.iam.v1.GetIamPolicyRequest} GetIamPolicyRequest + * @returns {google.iam.v1.BindingDelta} BindingDelta */ - GetIamPolicyRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.GetIamPolicyRequest) + BindingDelta.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.BindingDelta) return object; - var message = new $root.google.iam.v1.GetIamPolicyRequest(); - if (object.resource != null) - message.resource = String(object.resource); - if (object.options != null) { - if (typeof object.options !== "object") - throw TypeError(".google.iam.v1.GetIamPolicyRequest.options: object expected"); - message.options = $root.google.iam.v1.GetPolicyOptions.fromObject(object.options); + var message = new $root.google.iam.v1.BindingDelta(); + switch (object.action) { + default: + if (typeof object.action === "number") { + message.action = object.action; + break; + } + break; + case "ACTION_UNSPECIFIED": + case 0: + message.action = 0; + break; + case "ADD": + case 1: + message.action = 1; + break; + case "REMOVE": + case 2: + message.action = 2; + break; + } + if (object.role != null) + message.role = String(object.role); + if (object.member != null) + message.member = String(object.member); + if (object.condition != null) { + if (typeof object.condition !== "object") + throw TypeError(".google.iam.v1.BindingDelta.condition: object expected"); + message.condition = $root.google.type.Expr.fromObject(object.condition); } return message; }; /** - * Creates a plain object from a GetIamPolicyRequest message. Also converts values to other types if specified. + * Creates a plain object from a BindingDelta message. Also converts values to other types if specified. * @function toObject - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static - * @param {google.iam.v1.GetIamPolicyRequest} message GetIamPolicyRequest + * @param {google.iam.v1.BindingDelta} message BindingDelta * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - GetIamPolicyRequest.toObject = function toObject(message, options) { + BindingDelta.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; if (options.defaults) { - object.resource = ""; - object.options = null; + object.action = options.enums === String ? "ACTION_UNSPECIFIED" : 0; + object.role = ""; + object.member = ""; + object.condition = null; } - if (message.resource != null && message.hasOwnProperty("resource")) - object.resource = message.resource; - if (message.options != null && message.hasOwnProperty("options")) - object.options = $root.google.iam.v1.GetPolicyOptions.toObject(message.options, options); + if (message.action != null && message.hasOwnProperty("action")) + object.action = options.enums === String ? $root.google.iam.v1.BindingDelta.Action[message.action] === undefined ? message.action : $root.google.iam.v1.BindingDelta.Action[message.action] : message.action; + if (message.role != null && message.hasOwnProperty("role")) + object.role = message.role; + if (message.member != null && message.hasOwnProperty("member")) + object.member = message.member; + if (message.condition != null && message.hasOwnProperty("condition")) + object.condition = $root.google.type.Expr.toObject(message.condition, options); return object; }; /** - * Converts this GetIamPolicyRequest to JSON. + * Converts this BindingDelta to JSON. * @function toJSON - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @instance * @returns {Object.} JSON object */ - GetIamPolicyRequest.prototype.toJSON = function toJSON() { + BindingDelta.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for GetIamPolicyRequest + * Gets the default type url for BindingDelta * @function getTypeUrl - * @memberof google.iam.v1.GetIamPolicyRequest + * @memberof google.iam.v1.BindingDelta * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - GetIamPolicyRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + BindingDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.iam.v1.GetIamPolicyRequest"; + return typeUrlPrefix + "/google.iam.v1.BindingDelta"; }; - return GetIamPolicyRequest; + /** + * Action enum. + * @name google.iam.v1.BindingDelta.Action + * @enum {number} + * @property {number} ACTION_UNSPECIFIED=0 ACTION_UNSPECIFIED value + * @property {number} ADD=1 ADD value + * @property {number} REMOVE=2 REMOVE value + */ + BindingDelta.Action = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "ACTION_UNSPECIFIED"] = 0; + values[valuesById[1] = "ADD"] = 1; + values[valuesById[2] = "REMOVE"] = 2; + return values; + })(); + + return BindingDelta; })(); - v1.TestIamPermissionsRequest = (function() { + v1.AuditConfigDelta = (function() { /** - * Properties of a TestIamPermissionsRequest. + * Properties of an AuditConfigDelta. * @memberof google.iam.v1 - * @interface ITestIamPermissionsRequest - * @property {string|null} [resource] TestIamPermissionsRequest resource - * @property {Array.|null} [permissions] TestIamPermissionsRequest permissions + * @interface IAuditConfigDelta + * @property {google.iam.v1.AuditConfigDelta.Action|null} [action] AuditConfigDelta action + * @property {string|null} [service] AuditConfigDelta service + * @property {string|null} [exemptedMember] AuditConfigDelta exemptedMember + * @property {string|null} [logType] AuditConfigDelta logType */ /** - * Constructs a new TestIamPermissionsRequest. + * Constructs a new AuditConfigDelta. * @memberof google.iam.v1 - * @classdesc Represents a TestIamPermissionsRequest. - * @implements ITestIamPermissionsRequest + * @classdesc Represents an AuditConfigDelta. + * @implements IAuditConfigDelta * @constructor - * @param {google.iam.v1.ITestIamPermissionsRequest=} [properties] Properties to set + * @param {google.iam.v1.IAuditConfigDelta=} [properties] Properties to set */ - function TestIamPermissionsRequest(properties) { - this.permissions = []; + function AuditConfigDelta(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -61752,92 +69161,117 @@ } /** - * TestIamPermissionsRequest resource. - * @member {string} resource - * @memberof google.iam.v1.TestIamPermissionsRequest + * AuditConfigDelta action. + * @member {google.iam.v1.AuditConfigDelta.Action} action + * @memberof google.iam.v1.AuditConfigDelta * @instance */ - TestIamPermissionsRequest.prototype.resource = ""; + AuditConfigDelta.prototype.action = 0; /** - * TestIamPermissionsRequest permissions. - * @member {Array.} permissions - * @memberof google.iam.v1.TestIamPermissionsRequest + * AuditConfigDelta service. + * @member {string} service + * @memberof google.iam.v1.AuditConfigDelta * @instance */ - TestIamPermissionsRequest.prototype.permissions = $util.emptyArray; + AuditConfigDelta.prototype.service = ""; /** - * Creates a new TestIamPermissionsRequest instance using the specified properties. + * AuditConfigDelta exemptedMember. + * @member {string} exemptedMember + * @memberof google.iam.v1.AuditConfigDelta + * @instance + */ + AuditConfigDelta.prototype.exemptedMember = ""; + + /** + * AuditConfigDelta logType. + * @member {string} logType + * @memberof google.iam.v1.AuditConfigDelta + * @instance + */ + AuditConfigDelta.prototype.logType = ""; + + /** + * Creates a new AuditConfigDelta instance using the specified properties. * @function create - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static - * @param {google.iam.v1.ITestIamPermissionsRequest=} [properties] Properties to set - * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest instance + * @param {google.iam.v1.IAuditConfigDelta=} [properties] Properties to set + * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta instance */ - TestIamPermissionsRequest.create = function create(properties) { - return new TestIamPermissionsRequest(properties); + AuditConfigDelta.create = function create(properties) { + return new AuditConfigDelta(properties); }; /** - * Encodes the specified TestIamPermissionsRequest message. Does not implicitly {@link google.iam.v1.TestIamPermissionsRequest.verify|verify} messages. + * Encodes the specified AuditConfigDelta message. Does not implicitly {@link google.iam.v1.AuditConfigDelta.verify|verify} messages. * @function encode - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static - * @param {google.iam.v1.ITestIamPermissionsRequest} message TestIamPermissionsRequest message or plain object to encode + * @param {google.iam.v1.IAuditConfigDelta} message AuditConfigDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TestIamPermissionsRequest.encode = function encode(message, writer) { + AuditConfigDelta.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.resource != null && Object.hasOwnProperty.call(message, "resource")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.resource); - if (message.permissions != null && message.permissions.length) - for (var i = 0; i < message.permissions.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.permissions[i]); + if (message.action != null && Object.hasOwnProperty.call(message, "action")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.action); + if (message.service != null && Object.hasOwnProperty.call(message, "service")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.service); + if (message.exemptedMember != null && Object.hasOwnProperty.call(message, "exemptedMember")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.exemptedMember); + if (message.logType != null && Object.hasOwnProperty.call(message, "logType")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.logType); return writer; }; /** - * Encodes the specified TestIamPermissionsRequest message, length delimited. Does not implicitly {@link google.iam.v1.TestIamPermissionsRequest.verify|verify} messages. + * Encodes the specified AuditConfigDelta message, length delimited. Does not implicitly {@link google.iam.v1.AuditConfigDelta.verify|verify} messages. * @function encodeDelimited - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static - * @param {google.iam.v1.ITestIamPermissionsRequest} message TestIamPermissionsRequest message or plain object to encode + * @param {google.iam.v1.IAuditConfigDelta} message AuditConfigDelta message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - TestIamPermissionsRequest.encodeDelimited = function encodeDelimited(message, writer) { + AuditConfigDelta.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a TestIamPermissionsRequest message from the specified reader or buffer. + * Decodes an AuditConfigDelta message from the specified reader or buffer. * @function decode - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest + * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TestIamPermissionsRequest.decode = function decode(reader, length) { + AuditConfigDelta.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.TestIamPermissionsRequest(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditConfigDelta(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.resource = reader.string(); + message.action = reader.int32(); break; } case 2: { - if (!(message.permissions && message.permissions.length)) - message.permissions = []; - message.permissions.push(reader.string()); + message.service = reader.string(); + break; + } + case 3: { + message.exemptedMember = reader.string(); + break; + } + case 4: { + message.logType = reader.string(); break; } default: @@ -61849,2619 +69283,2629 @@ }; /** - * Decodes a TestIamPermissionsRequest message from the specified reader or buffer, length delimited. + * Decodes an AuditConfigDelta message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest + * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - TestIamPermissionsRequest.decodeDelimited = function decodeDelimited(reader) { + AuditConfigDelta.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a TestIamPermissionsRequest message. + * Verifies an AuditConfigDelta message. * @function verify - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - TestIamPermissionsRequest.verify = function verify(message) { + AuditConfigDelta.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.resource != null && message.hasOwnProperty("resource")) - if (!$util.isString(message.resource)) - return "resource: string expected"; - if (message.permissions != null && message.hasOwnProperty("permissions")) { - if (!Array.isArray(message.permissions)) - return "permissions: array expected"; - for (var i = 0; i < message.permissions.length; ++i) - if (!$util.isString(message.permissions[i])) - return "permissions: string[] expected"; - } + if (message.action != null && message.hasOwnProperty("action")) + switch (message.action) { + default: + return "action: enum value expected"; + case 0: + case 1: + case 2: + break; + } + if (message.service != null && message.hasOwnProperty("service")) + if (!$util.isString(message.service)) + return "service: string expected"; + if (message.exemptedMember != null && message.hasOwnProperty("exemptedMember")) + if (!$util.isString(message.exemptedMember)) + return "exemptedMember: string expected"; + if (message.logType != null && message.hasOwnProperty("logType")) + if (!$util.isString(message.logType)) + return "logType: string expected"; return null; }; /** - * Creates a TestIamPermissionsRequest message from a plain object. Also converts values to their respective internal types. + * Creates an AuditConfigDelta message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static * @param {Object.} object Plain object - * @returns {google.iam.v1.TestIamPermissionsRequest} TestIamPermissionsRequest + * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta */ - TestIamPermissionsRequest.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.TestIamPermissionsRequest) + AuditConfigDelta.fromObject = function fromObject(object) { + if (object instanceof $root.google.iam.v1.AuditConfigDelta) return object; - var message = new $root.google.iam.v1.TestIamPermissionsRequest(); - if (object.resource != null) - message.resource = String(object.resource); - if (object.permissions) { - if (!Array.isArray(object.permissions)) - throw TypeError(".google.iam.v1.TestIamPermissionsRequest.permissions: array expected"); - message.permissions = []; - for (var i = 0; i < object.permissions.length; ++i) - message.permissions[i] = String(object.permissions[i]); + var message = new $root.google.iam.v1.AuditConfigDelta(); + switch (object.action) { + default: + if (typeof object.action === "number") { + message.action = object.action; + break; + } + break; + case "ACTION_UNSPECIFIED": + case 0: + message.action = 0; + break; + case "ADD": + case 1: + message.action = 1; + break; + case "REMOVE": + case 2: + message.action = 2; + break; } + if (object.service != null) + message.service = String(object.service); + if (object.exemptedMember != null) + message.exemptedMember = String(object.exemptedMember); + if (object.logType != null) + message.logType = String(object.logType); return message; }; /** - * Creates a plain object from a TestIamPermissionsRequest message. Also converts values to other types if specified. + * Creates a plain object from an AuditConfigDelta message. Also converts values to other types if specified. * @function toObject - * @memberof google.iam.v1.TestIamPermissionsRequest + * @memberof google.iam.v1.AuditConfigDelta * @static - * @param {google.iam.v1.TestIamPermissionsRequest} message TestIamPermissionsRequest + * @param {google.iam.v1.AuditConfigDelta} message AuditConfigDelta * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - TestIamPermissionsRequest.toObject = function toObject(message, options) { + AuditConfigDelta.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; - if (options.arrays || options.defaults) - object.permissions = []; - if (options.defaults) - object.resource = ""; - if (message.resource != null && message.hasOwnProperty("resource")) - object.resource = message.resource; - if (message.permissions && message.permissions.length) { - object.permissions = []; - for (var j = 0; j < message.permissions.length; ++j) - object.permissions[j] = message.permissions[j]; + if (options.defaults) { + object.action = options.enums === String ? "ACTION_UNSPECIFIED" : 0; + object.service = ""; + object.exemptedMember = ""; + object.logType = ""; } + if (message.action != null && message.hasOwnProperty("action")) + object.action = options.enums === String ? $root.google.iam.v1.AuditConfigDelta.Action[message.action] === undefined ? message.action : $root.google.iam.v1.AuditConfigDelta.Action[message.action] : message.action; + if (message.service != null && message.hasOwnProperty("service")) + object.service = message.service; + if (message.exemptedMember != null && message.hasOwnProperty("exemptedMember")) + object.exemptedMember = message.exemptedMember; + if (message.logType != null && message.hasOwnProperty("logType")) + object.logType = message.logType; return object; }; - /** - * Converts this TestIamPermissionsRequest to JSON. - * @function toJSON - * @memberof google.iam.v1.TestIamPermissionsRequest - * @instance - * @returns {Object.} JSON object - */ - TestIamPermissionsRequest.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Converts this AuditConfigDelta to JSON. + * @function toJSON + * @memberof google.iam.v1.AuditConfigDelta + * @instance + * @returns {Object.} JSON object + */ + AuditConfigDelta.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for AuditConfigDelta + * @function getTypeUrl + * @memberof google.iam.v1.AuditConfigDelta + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + AuditConfigDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.iam.v1.AuditConfigDelta"; + }; + + /** + * Action enum. + * @name google.iam.v1.AuditConfigDelta.Action + * @enum {number} + * @property {number} ACTION_UNSPECIFIED=0 ACTION_UNSPECIFIED value + * @property {number} ADD=1 ADD value + * @property {number} REMOVE=2 REMOVE value + */ + AuditConfigDelta.Action = (function() { + var valuesById = {}, values = Object.create(valuesById); + values[valuesById[0] = "ACTION_UNSPECIFIED"] = 0; + values[valuesById[1] = "ADD"] = 1; + values[valuesById[2] = "REMOVE"] = 2; + return values; + })(); + + return AuditConfigDelta; + })(); + + return v1; + })(); + + return iam; + })(); + + google.type = (function() { + + /** + * Namespace type. + * @memberof google + * @namespace + */ + var type = {}; + + type.Expr = (function() { + + /** + * Properties of an Expr. + * @memberof google.type + * @interface IExpr + * @property {string|null} [expression] Expr expression + * @property {string|null} [title] Expr title + * @property {string|null} [description] Expr description + * @property {string|null} [location] Expr location + */ + + /** + * Constructs a new Expr. + * @memberof google.type + * @classdesc Represents an Expr. + * @implements IExpr + * @constructor + * @param {google.type.IExpr=} [properties] Properties to set + */ + function Expr(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * Expr expression. + * @member {string} expression + * @memberof google.type.Expr + * @instance + */ + Expr.prototype.expression = ""; + + /** + * Expr title. + * @member {string} title + * @memberof google.type.Expr + * @instance + */ + Expr.prototype.title = ""; + + /** + * Expr description. + * @member {string} description + * @memberof google.type.Expr + * @instance + */ + Expr.prototype.description = ""; + + /** + * Expr location. + * @member {string} location + * @memberof google.type.Expr + * @instance + */ + Expr.prototype.location = ""; + + /** + * Creates a new Expr instance using the specified properties. + * @function create + * @memberof google.type.Expr + * @static + * @param {google.type.IExpr=} [properties] Properties to set + * @returns {google.type.Expr} Expr instance + */ + Expr.create = function create(properties) { + return new Expr(properties); + }; + + /** + * Encodes the specified Expr message. Does not implicitly {@link google.type.Expr.verify|verify} messages. + * @function encode + * @memberof google.type.Expr + * @static + * @param {google.type.IExpr} message Expr message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Expr.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.expression != null && Object.hasOwnProperty.call(message, "expression")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.expression); + if (message.title != null && Object.hasOwnProperty.call(message, "title")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.title); + if (message.description != null && Object.hasOwnProperty.call(message, "description")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); + if (message.location != null && Object.hasOwnProperty.call(message, "location")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.location); + return writer; + }; + + /** + * Encodes the specified Expr message, length delimited. Does not implicitly {@link google.type.Expr.verify|verify} messages. + * @function encodeDelimited + * @memberof google.type.Expr + * @static + * @param {google.type.IExpr} message Expr message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Expr.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an Expr message from the specified reader or buffer. + * @function decode + * @memberof google.type.Expr + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.type.Expr} Expr + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Expr.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.type.Expr(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.expression = reader.string(); + break; + } + case 2: { + message.title = reader.string(); + break; + } + case 3: { + message.description = reader.string(); + break; + } + case 4: { + message.location = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes an Expr message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.type.Expr + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.type.Expr} Expr + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Expr.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies an Expr message. + * @function verify + * @memberof google.type.Expr + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Expr.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.expression != null && message.hasOwnProperty("expression")) + if (!$util.isString(message.expression)) + return "expression: string expected"; + if (message.title != null && message.hasOwnProperty("title")) + if (!$util.isString(message.title)) + return "title: string expected"; + if (message.description != null && message.hasOwnProperty("description")) + if (!$util.isString(message.description)) + return "description: string expected"; + if (message.location != null && message.hasOwnProperty("location")) + if (!$util.isString(message.location)) + return "location: string expected"; + return null; + }; + + /** + * Creates an Expr message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.type.Expr + * @static + * @param {Object.} object Plain object + * @returns {google.type.Expr} Expr + */ + Expr.fromObject = function fromObject(object) { + if (object instanceof $root.google.type.Expr) + return object; + var message = new $root.google.type.Expr(); + if (object.expression != null) + message.expression = String(object.expression); + if (object.title != null) + message.title = String(object.title); + if (object.description != null) + message.description = String(object.description); + if (object.location != null) + message.location = String(object.location); + return message; + }; + + /** + * Creates a plain object from an Expr message. Also converts values to other types if specified. + * @function toObject + * @memberof google.type.Expr + * @static + * @param {google.type.Expr} message Expr + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Expr.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.expression = ""; + object.title = ""; + object.description = ""; + object.location = ""; + } + if (message.expression != null && message.hasOwnProperty("expression")) + object.expression = message.expression; + if (message.title != null && message.hasOwnProperty("title")) + object.title = message.title; + if (message.description != null && message.hasOwnProperty("description")) + object.description = message.description; + if (message.location != null && message.hasOwnProperty("location")) + object.location = message.location; + return object; + }; + + /** + * Converts this Expr to JSON. + * @function toJSON + * @memberof google.type.Expr + * @instance + * @returns {Object.} JSON object + */ + Expr.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + /** + * Gets the default type url for Expr + * @function getTypeUrl + * @memberof google.type.Expr + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Expr.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.type.Expr"; + }; + + return Expr; + })(); + + return type; + })(); + + google.longrunning = (function() { + + /** + * Namespace longrunning. + * @memberof google + * @namespace + */ + var longrunning = {}; + + longrunning.Operations = (function() { + + /** + * Constructs a new Operations service. + * @memberof google.longrunning + * @classdesc Represents an Operations + * @extends $protobuf.rpc.Service + * @constructor + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + */ + function Operations(rpcImpl, requestDelimited, responseDelimited) { + $protobuf.rpc.Service.call(this, rpcImpl, requestDelimited, responseDelimited); + } - /** - * Gets the default type url for TestIamPermissionsRequest - * @function getTypeUrl - * @memberof google.iam.v1.TestIamPermissionsRequest - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - TestIamPermissionsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.TestIamPermissionsRequest"; - }; + (Operations.prototype = Object.create($protobuf.rpc.Service.prototype)).constructor = Operations; - return TestIamPermissionsRequest; - })(); + /** + * Creates new Operations service using the specified rpc implementation. + * @function create + * @memberof google.longrunning.Operations + * @static + * @param {$protobuf.RPCImpl} rpcImpl RPC implementation + * @param {boolean} [requestDelimited=false] Whether requests are length-delimited + * @param {boolean} [responseDelimited=false] Whether responses are length-delimited + * @returns {Operations} RPC service. Useful where requests and/or responses are streamed. + */ + Operations.create = function create(rpcImpl, requestDelimited, responseDelimited) { + return new this(rpcImpl, requestDelimited, responseDelimited); + }; - v1.TestIamPermissionsResponse = (function() { + /** + * Callback as used by {@link google.longrunning.Operations|listOperations}. + * @memberof google.longrunning.Operations + * @typedef ListOperationsCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.ListOperationsResponse} [response] ListOperationsResponse + */ - /** - * Properties of a TestIamPermissionsResponse. - * @memberof google.iam.v1 - * @interface ITestIamPermissionsResponse - * @property {Array.|null} [permissions] TestIamPermissionsResponse permissions - */ + /** + * Calls ListOperations. + * @function listOperations + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IListOperationsRequest} request ListOperationsRequest message or plain object + * @param {google.longrunning.Operations.ListOperationsCallback} callback Node-style callback called with the error, if any, and ListOperationsResponse + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(Operations.prototype.listOperations = function listOperations(request, callback) { + return this.rpcCall(listOperations, $root.google.longrunning.ListOperationsRequest, $root.google.longrunning.ListOperationsResponse, request, callback); + }, "name", { value: "ListOperations" }); - /** - * Constructs a new TestIamPermissionsResponse. - * @memberof google.iam.v1 - * @classdesc Represents a TestIamPermissionsResponse. - * @implements ITestIamPermissionsResponse - * @constructor - * @param {google.iam.v1.ITestIamPermissionsResponse=} [properties] Properties to set - */ - function TestIamPermissionsResponse(properties) { - this.permissions = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Calls ListOperations. + * @function listOperations + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IListOperationsRequest} request ListOperationsRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - /** - * TestIamPermissionsResponse permissions. - * @member {Array.} permissions - * @memberof google.iam.v1.TestIamPermissionsResponse - * @instance - */ - TestIamPermissionsResponse.prototype.permissions = $util.emptyArray; + /** + * Callback as used by {@link google.longrunning.Operations|getOperation}. + * @memberof google.longrunning.Operations + * @typedef GetOperationCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation + */ - /** - * Creates a new TestIamPermissionsResponse instance using the specified properties. - * @function create - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {google.iam.v1.ITestIamPermissionsResponse=} [properties] Properties to set - * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse instance - */ - TestIamPermissionsResponse.create = function create(properties) { - return new TestIamPermissionsResponse(properties); - }; + /** + * Calls GetOperation. + * @function getOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IGetOperationRequest} request GetOperationRequest message or plain object + * @param {google.longrunning.Operations.GetOperationCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(Operations.prototype.getOperation = function getOperation(request, callback) { + return this.rpcCall(getOperation, $root.google.longrunning.GetOperationRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "GetOperation" }); - /** - * Encodes the specified TestIamPermissionsResponse message. Does not implicitly {@link google.iam.v1.TestIamPermissionsResponse.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {google.iam.v1.ITestIamPermissionsResponse} message TestIamPermissionsResponse message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - TestIamPermissionsResponse.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.permissions != null && message.permissions.length) - for (var i = 0; i < message.permissions.length; ++i) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.permissions[i]); - return writer; - }; + /** + * Calls GetOperation. + * @function getOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IGetOperationRequest} request GetOperationRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - /** - * Encodes the specified TestIamPermissionsResponse message, length delimited. Does not implicitly {@link google.iam.v1.TestIamPermissionsResponse.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {google.iam.v1.ITestIamPermissionsResponse} message TestIamPermissionsResponse message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - TestIamPermissionsResponse.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Callback as used by {@link google.longrunning.Operations|deleteOperation}. + * @memberof google.longrunning.Operations + * @typedef DeleteOperationCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty + */ - /** - * Decodes a TestIamPermissionsResponse message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - TestIamPermissionsResponse.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.TestIamPermissionsResponse(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.permissions && message.permissions.length)) - message.permissions = []; - message.permissions.push(reader.string()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Calls DeleteOperation. + * @function deleteOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IDeleteOperationRequest} request DeleteOperationRequest message or plain object + * @param {google.longrunning.Operations.DeleteOperationCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(Operations.prototype.deleteOperation = function deleteOperation(request, callback) { + return this.rpcCall(deleteOperation, $root.google.longrunning.DeleteOperationRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "DeleteOperation" }); - /** - * Decodes a TestIamPermissionsResponse message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - TestIamPermissionsResponse.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Calls DeleteOperation. + * @function deleteOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IDeleteOperationRequest} request DeleteOperationRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - /** - * Verifies a TestIamPermissionsResponse message. - * @function verify - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - TestIamPermissionsResponse.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.permissions != null && message.hasOwnProperty("permissions")) { - if (!Array.isArray(message.permissions)) - return "permissions: array expected"; - for (var i = 0; i < message.permissions.length; ++i) - if (!$util.isString(message.permissions[i])) - return "permissions: string[] expected"; - } - return null; - }; + /** + * Callback as used by {@link google.longrunning.Operations|cancelOperation}. + * @memberof google.longrunning.Operations + * @typedef CancelOperationCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.protobuf.Empty} [response] Empty + */ - /** - * Creates a TestIamPermissionsResponse message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.TestIamPermissionsResponse} TestIamPermissionsResponse - */ - TestIamPermissionsResponse.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.TestIamPermissionsResponse) - return object; - var message = new $root.google.iam.v1.TestIamPermissionsResponse(); - if (object.permissions) { - if (!Array.isArray(object.permissions)) - throw TypeError(".google.iam.v1.TestIamPermissionsResponse.permissions: array expected"); - message.permissions = []; - for (var i = 0; i < object.permissions.length; ++i) - message.permissions[i] = String(object.permissions[i]); - } - return message; - }; + /** + * Calls CancelOperation. + * @function cancelOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.ICancelOperationRequest} request CancelOperationRequest message or plain object + * @param {google.longrunning.Operations.CancelOperationCallback} callback Node-style callback called with the error, if any, and Empty + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(Operations.prototype.cancelOperation = function cancelOperation(request, callback) { + return this.rpcCall(cancelOperation, $root.google.longrunning.CancelOperationRequest, $root.google.protobuf.Empty, request, callback); + }, "name", { value: "CancelOperation" }); - /** - * Creates a plain object from a TestIamPermissionsResponse message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {google.iam.v1.TestIamPermissionsResponse} message TestIamPermissionsResponse - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - TestIamPermissionsResponse.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.permissions = []; - if (message.permissions && message.permissions.length) { - object.permissions = []; - for (var j = 0; j < message.permissions.length; ++j) - object.permissions[j] = message.permissions[j]; - } - return object; - }; + /** + * Calls CancelOperation. + * @function cancelOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.ICancelOperationRequest} request CancelOperationRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - /** - * Converts this TestIamPermissionsResponse to JSON. - * @function toJSON - * @memberof google.iam.v1.TestIamPermissionsResponse - * @instance - * @returns {Object.} JSON object - */ - TestIamPermissionsResponse.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Callback as used by {@link google.longrunning.Operations|waitOperation}. + * @memberof google.longrunning.Operations + * @typedef WaitOperationCallback + * @type {function} + * @param {Error|null} error Error, if any + * @param {google.longrunning.Operation} [response] Operation + */ - /** - * Gets the default type url for TestIamPermissionsResponse - * @function getTypeUrl - * @memberof google.iam.v1.TestIamPermissionsResponse - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - TestIamPermissionsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.TestIamPermissionsResponse"; - }; + /** + * Calls WaitOperation. + * @function waitOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IWaitOperationRequest} request WaitOperationRequest message or plain object + * @param {google.longrunning.Operations.WaitOperationCallback} callback Node-style callback called with the error, if any, and Operation + * @returns {undefined} + * @variation 1 + */ + Object.defineProperty(Operations.prototype.waitOperation = function waitOperation(request, callback) { + return this.rpcCall(waitOperation, $root.google.longrunning.WaitOperationRequest, $root.google.longrunning.Operation, request, callback); + }, "name", { value: "WaitOperation" }); - return TestIamPermissionsResponse; - })(); + /** + * Calls WaitOperation. + * @function waitOperation + * @memberof google.longrunning.Operations + * @instance + * @param {google.longrunning.IWaitOperationRequest} request WaitOperationRequest message or plain object + * @returns {Promise} Promise + * @variation 2 + */ - v1.GetPolicyOptions = (function() { + return Operations; + })(); - /** - * Properties of a GetPolicyOptions. - * @memberof google.iam.v1 - * @interface IGetPolicyOptions - * @property {number|null} [requestedPolicyVersion] GetPolicyOptions requestedPolicyVersion - */ + longrunning.Operation = (function() { - /** - * Constructs a new GetPolicyOptions. - * @memberof google.iam.v1 - * @classdesc Represents a GetPolicyOptions. - * @implements IGetPolicyOptions - * @constructor - * @param {google.iam.v1.IGetPolicyOptions=} [properties] Properties to set - */ - function GetPolicyOptions(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Properties of an Operation. + * @memberof google.longrunning + * @interface IOperation + * @property {string|null} [name] Operation name + * @property {google.protobuf.IAny|null} [metadata] Operation metadata + * @property {boolean|null} [done] Operation done + * @property {google.rpc.IStatus|null} [error] Operation error + * @property {google.protobuf.IAny|null} [response] Operation response + */ - /** - * GetPolicyOptions requestedPolicyVersion. - * @member {number} requestedPolicyVersion - * @memberof google.iam.v1.GetPolicyOptions - * @instance - */ - GetPolicyOptions.prototype.requestedPolicyVersion = 0; + /** + * Constructs a new Operation. + * @memberof google.longrunning + * @classdesc Represents an Operation. + * @implements IOperation + * @constructor + * @param {google.longrunning.IOperation=} [properties] Properties to set + */ + function Operation(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new GetPolicyOptions instance using the specified properties. - * @function create - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {google.iam.v1.IGetPolicyOptions=} [properties] Properties to set - * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions instance - */ - GetPolicyOptions.create = function create(properties) { - return new GetPolicyOptions(properties); - }; + /** + * Operation name. + * @member {string} name + * @memberof google.longrunning.Operation + * @instance + */ + Operation.prototype.name = ""; - /** - * Encodes the specified GetPolicyOptions message. Does not implicitly {@link google.iam.v1.GetPolicyOptions.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {google.iam.v1.IGetPolicyOptions} message GetPolicyOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GetPolicyOptions.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.requestedPolicyVersion != null && Object.hasOwnProperty.call(message, "requestedPolicyVersion")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.requestedPolicyVersion); - return writer; - }; + /** + * Operation metadata. + * @member {google.protobuf.IAny|null|undefined} metadata + * @memberof google.longrunning.Operation + * @instance + */ + Operation.prototype.metadata = null; - /** - * Encodes the specified GetPolicyOptions message, length delimited. Does not implicitly {@link google.iam.v1.GetPolicyOptions.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {google.iam.v1.IGetPolicyOptions} message GetPolicyOptions message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - GetPolicyOptions.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Operation done. + * @member {boolean} done + * @memberof google.longrunning.Operation + * @instance + */ + Operation.prototype.done = false; - /** - * Decodes a GetPolicyOptions message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GetPolicyOptions.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.GetPolicyOptions(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.requestedPolicyVersion = reader.int32(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Operation error. + * @member {google.rpc.IStatus|null|undefined} error + * @memberof google.longrunning.Operation + * @instance + */ + Operation.prototype.error = null; - /** - * Decodes a GetPolicyOptions message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - GetPolicyOptions.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Operation response. + * @member {google.protobuf.IAny|null|undefined} response + * @memberof google.longrunning.Operation + * @instance + */ + Operation.prototype.response = null; - /** - * Verifies a GetPolicyOptions message. - * @function verify - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - GetPolicyOptions.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.requestedPolicyVersion != null && message.hasOwnProperty("requestedPolicyVersion")) - if (!$util.isInteger(message.requestedPolicyVersion)) - return "requestedPolicyVersion: integer expected"; - return null; - }; + // OneOf field names bound to virtual getters and setters + var $oneOfFields; - /** - * Creates a GetPolicyOptions message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.GetPolicyOptions} GetPolicyOptions - */ - GetPolicyOptions.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.GetPolicyOptions) - return object; - var message = new $root.google.iam.v1.GetPolicyOptions(); - if (object.requestedPolicyVersion != null) - message.requestedPolicyVersion = object.requestedPolicyVersion | 0; - return message; - }; + /** + * Operation result. + * @member {"error"|"response"|undefined} result + * @memberof google.longrunning.Operation + * @instance + */ + Object.defineProperty(Operation.prototype, "result", { + get: $util.oneOfGetter($oneOfFields = ["error", "response"]), + set: $util.oneOfSetter($oneOfFields) + }); - /** - * Creates a plain object from a GetPolicyOptions message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {google.iam.v1.GetPolicyOptions} message GetPolicyOptions - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - GetPolicyOptions.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) - object.requestedPolicyVersion = 0; - if (message.requestedPolicyVersion != null && message.hasOwnProperty("requestedPolicyVersion")) - object.requestedPolicyVersion = message.requestedPolicyVersion; - return object; - }; + /** + * Creates a new Operation instance using the specified properties. + * @function create + * @memberof google.longrunning.Operation + * @static + * @param {google.longrunning.IOperation=} [properties] Properties to set + * @returns {google.longrunning.Operation} Operation instance + */ + Operation.create = function create(properties) { + return new Operation(properties); + }; + + /** + * Encodes the specified Operation message. Does not implicitly {@link google.longrunning.Operation.verify|verify} messages. + * @function encode + * @memberof google.longrunning.Operation + * @static + * @param {google.longrunning.IOperation} message Operation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Operation.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.metadata != null && Object.hasOwnProperty.call(message, "metadata")) + $root.google.protobuf.Any.encode(message.metadata, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + if (message.done != null && Object.hasOwnProperty.call(message, "done")) + writer.uint32(/* id 3, wireType 0 =*/24).bool(message.done); + if (message.error != null && Object.hasOwnProperty.call(message, "error")) + $root.google.rpc.Status.encode(message.error, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); + if (message.response != null && Object.hasOwnProperty.call(message, "response")) + $root.google.protobuf.Any.encode(message.response, writer.uint32(/* id 5, wireType 2 =*/42).fork()).ldelim(); + return writer; + }; + + /** + * Encodes the specified Operation message, length delimited. Does not implicitly {@link google.longrunning.Operation.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.Operation + * @static + * @param {google.longrunning.IOperation} message Operation message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + Operation.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an Operation message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.Operation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.Operation} Operation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Operation.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.Operation(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; + } + case 2: { + message.metadata = $root.google.protobuf.Any.decode(reader, reader.uint32()); + break; + } + case 3: { + message.done = reader.bool(); + break; + } + case 4: { + message.error = $root.google.rpc.Status.decode(reader, reader.uint32()); + break; + } + case 5: { + message.response = $root.google.protobuf.Any.decode(reader, reader.uint32()); + break; + } + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; - /** - * Converts this GetPolicyOptions to JSON. - * @function toJSON - * @memberof google.iam.v1.GetPolicyOptions - * @instance - * @returns {Object.} JSON object - */ - GetPolicyOptions.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Decodes an Operation message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.Operation + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.Operation} Operation + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + Operation.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Gets the default type url for GetPolicyOptions - * @function getTypeUrl - * @memberof google.iam.v1.GetPolicyOptions - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - GetPolicyOptions.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + /** + * Verifies an Operation message. + * @function verify + * @memberof google.longrunning.Operation + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + Operation.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + var properties = {}; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.metadata != null && message.hasOwnProperty("metadata")) { + var error = $root.google.protobuf.Any.verify(message.metadata); + if (error) + return "metadata." + error; + } + if (message.done != null && message.hasOwnProperty("done")) + if (typeof message.done !== "boolean") + return "done: boolean expected"; + if (message.error != null && message.hasOwnProperty("error")) { + properties.result = 1; + { + var error = $root.google.rpc.Status.verify(message.error); + if (error) + return "error." + error; } - return typeUrlPrefix + "/google.iam.v1.GetPolicyOptions"; - }; + } + if (message.response != null && message.hasOwnProperty("response")) { + if (properties.result === 1) + return "result: multiple values"; + properties.result = 1; + { + var error = $root.google.protobuf.Any.verify(message.response); + if (error) + return "response." + error; + } + } + return null; + }; - return GetPolicyOptions; - })(); + /** + * Creates an Operation message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.Operation + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.Operation} Operation + */ + Operation.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.Operation) + return object; + var message = new $root.google.longrunning.Operation(); + if (object.name != null) + message.name = String(object.name); + if (object.metadata != null) { + if (typeof object.metadata !== "object") + throw TypeError(".google.longrunning.Operation.metadata: object expected"); + message.metadata = $root.google.protobuf.Any.fromObject(object.metadata); + } + if (object.done != null) + message.done = Boolean(object.done); + if (object.error != null) { + if (typeof object.error !== "object") + throw TypeError(".google.longrunning.Operation.error: object expected"); + message.error = $root.google.rpc.Status.fromObject(object.error); + } + if (object.response != null) { + if (typeof object.response !== "object") + throw TypeError(".google.longrunning.Operation.response: object expected"); + message.response = $root.google.protobuf.Any.fromObject(object.response); + } + return message; + }; - v1.Policy = (function() { + /** + * Creates a plain object from an Operation message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.Operation + * @static + * @param {google.longrunning.Operation} message Operation + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + Operation.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.name = ""; + object.metadata = null; + object.done = false; + } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.metadata != null && message.hasOwnProperty("metadata")) + object.metadata = $root.google.protobuf.Any.toObject(message.metadata, options); + if (message.done != null && message.hasOwnProperty("done")) + object.done = message.done; + if (message.error != null && message.hasOwnProperty("error")) { + object.error = $root.google.rpc.Status.toObject(message.error, options); + if (options.oneofs) + object.result = "error"; + } + if (message.response != null && message.hasOwnProperty("response")) { + object.response = $root.google.protobuf.Any.toObject(message.response, options); + if (options.oneofs) + object.result = "response"; + } + return object; + }; - /** - * Properties of a Policy. - * @memberof google.iam.v1 - * @interface IPolicy - * @property {number|null} [version] Policy version - * @property {Array.|null} [bindings] Policy bindings - * @property {Array.|null} [auditConfigs] Policy auditConfigs - * @property {Uint8Array|null} [etag] Policy etag - */ + /** + * Converts this Operation to JSON. + * @function toJSON + * @memberof google.longrunning.Operation + * @instance + * @returns {Object.} JSON object + */ + Operation.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new Policy. - * @memberof google.iam.v1 - * @classdesc Represents a Policy. - * @implements IPolicy - * @constructor - * @param {google.iam.v1.IPolicy=} [properties] Properties to set - */ - function Policy(properties) { - this.bindings = []; - this.auditConfigs = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Gets the default type url for Operation + * @function getTypeUrl + * @memberof google.longrunning.Operation + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + Operation.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } + return typeUrlPrefix + "/google.longrunning.Operation"; + }; - /** - * Policy version. - * @member {number} version - * @memberof google.iam.v1.Policy - * @instance - */ - Policy.prototype.version = 0; + return Operation; + })(); - /** - * Policy bindings. - * @member {Array.} bindings - * @memberof google.iam.v1.Policy - * @instance - */ - Policy.prototype.bindings = $util.emptyArray; + longrunning.GetOperationRequest = (function() { - /** - * Policy auditConfigs. - * @member {Array.} auditConfigs - * @memberof google.iam.v1.Policy - * @instance - */ - Policy.prototype.auditConfigs = $util.emptyArray; + /** + * Properties of a GetOperationRequest. + * @memberof google.longrunning + * @interface IGetOperationRequest + * @property {string|null} [name] GetOperationRequest name + */ - /** - * Policy etag. - * @member {Uint8Array} etag - * @memberof google.iam.v1.Policy - * @instance - */ - Policy.prototype.etag = $util.newBuffer([]); + /** + * Constructs a new GetOperationRequest. + * @memberof google.longrunning + * @classdesc Represents a GetOperationRequest. + * @implements IGetOperationRequest + * @constructor + * @param {google.longrunning.IGetOperationRequest=} [properties] Properties to set + */ + function GetOperationRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new Policy instance using the specified properties. - * @function create - * @memberof google.iam.v1.Policy - * @static - * @param {google.iam.v1.IPolicy=} [properties] Properties to set - * @returns {google.iam.v1.Policy} Policy instance - */ - Policy.create = function create(properties) { - return new Policy(properties); - }; + /** + * GetOperationRequest name. + * @member {string} name + * @memberof google.longrunning.GetOperationRequest + * @instance + */ + GetOperationRequest.prototype.name = ""; - /** - * Encodes the specified Policy message. Does not implicitly {@link google.iam.v1.Policy.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.Policy - * @static - * @param {google.iam.v1.IPolicy} message Policy message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Policy.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.version != null && Object.hasOwnProperty.call(message, "version")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.version); - if (message.etag != null && Object.hasOwnProperty.call(message, "etag")) - writer.uint32(/* id 3, wireType 2 =*/26).bytes(message.etag); - if (message.bindings != null && message.bindings.length) - for (var i = 0; i < message.bindings.length; ++i) - $root.google.iam.v1.Binding.encode(message.bindings[i], writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - if (message.auditConfigs != null && message.auditConfigs.length) - for (var i = 0; i < message.auditConfigs.length; ++i) - $root.google.iam.v1.AuditConfig.encode(message.auditConfigs[i], writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); - return writer; - }; + /** + * Creates a new GetOperationRequest instance using the specified properties. + * @function create + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {google.longrunning.IGetOperationRequest=} [properties] Properties to set + * @returns {google.longrunning.GetOperationRequest} GetOperationRequest instance + */ + GetOperationRequest.create = function create(properties) { + return new GetOperationRequest(properties); + }; - /** - * Encodes the specified Policy message, length delimited. Does not implicitly {@link google.iam.v1.Policy.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.Policy - * @static - * @param {google.iam.v1.IPolicy} message Policy message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Policy.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified GetOperationRequest message. Does not implicitly {@link google.longrunning.GetOperationRequest.verify|verify} messages. + * @function encode + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {google.longrunning.IGetOperationRequest} message GetOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetOperationRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; - /** - * Decodes a Policy message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.Policy - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.Policy} Policy - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Policy.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.Policy(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.version = reader.int32(); - break; - } - case 4: { - if (!(message.bindings && message.bindings.length)) - message.bindings = []; - message.bindings.push($root.google.iam.v1.Binding.decode(reader, reader.uint32())); - break; - } - case 6: { - if (!(message.auditConfigs && message.auditConfigs.length)) - message.auditConfigs = []; - message.auditConfigs.push($root.google.iam.v1.AuditConfig.decode(reader, reader.uint32())); - break; - } - case 3: { - message.etag = reader.bytes(); - break; - } - default: - reader.skipType(tag & 7); + /** + * Encodes the specified GetOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.GetOperationRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {google.longrunning.IGetOperationRequest} message GetOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + GetOperationRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a GetOperationRequest message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.GetOperationRequest} GetOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetOperationRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.GetOperationRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes a Policy message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.Policy - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.Policy} Policy - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Policy.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + } + return message; + }; - /** - * Verifies a Policy message. - * @function verify - * @memberof google.iam.v1.Policy - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Policy.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.version != null && message.hasOwnProperty("version")) - if (!$util.isInteger(message.version)) - return "version: integer expected"; - if (message.bindings != null && message.hasOwnProperty("bindings")) { - if (!Array.isArray(message.bindings)) - return "bindings: array expected"; - for (var i = 0; i < message.bindings.length; ++i) { - var error = $root.google.iam.v1.Binding.verify(message.bindings[i]); - if (error) - return "bindings." + error; - } - } - if (message.auditConfigs != null && message.hasOwnProperty("auditConfigs")) { - if (!Array.isArray(message.auditConfigs)) - return "auditConfigs: array expected"; - for (var i = 0; i < message.auditConfigs.length; ++i) { - var error = $root.google.iam.v1.AuditConfig.verify(message.auditConfigs[i]); - if (error) - return "auditConfigs." + error; - } - } - if (message.etag != null && message.hasOwnProperty("etag")) - if (!(message.etag && typeof message.etag.length === "number" || $util.isString(message.etag))) - return "etag: buffer expected"; - return null; - }; + /** + * Decodes a GetOperationRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.GetOperationRequest} GetOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + GetOperationRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates a Policy message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.Policy - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.Policy} Policy - */ - Policy.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.Policy) - return object; - var message = new $root.google.iam.v1.Policy(); - if (object.version != null) - message.version = object.version | 0; - if (object.bindings) { - if (!Array.isArray(object.bindings)) - throw TypeError(".google.iam.v1.Policy.bindings: array expected"); - message.bindings = []; - for (var i = 0; i < object.bindings.length; ++i) { - if (typeof object.bindings[i] !== "object") - throw TypeError(".google.iam.v1.Policy.bindings: object expected"); - message.bindings[i] = $root.google.iam.v1.Binding.fromObject(object.bindings[i]); - } - } - if (object.auditConfigs) { - if (!Array.isArray(object.auditConfigs)) - throw TypeError(".google.iam.v1.Policy.auditConfigs: array expected"); - message.auditConfigs = []; - for (var i = 0; i < object.auditConfigs.length; ++i) { - if (typeof object.auditConfigs[i] !== "object") - throw TypeError(".google.iam.v1.Policy.auditConfigs: object expected"); - message.auditConfigs[i] = $root.google.iam.v1.AuditConfig.fromObject(object.auditConfigs[i]); - } - } - if (object.etag != null) - if (typeof object.etag === "string") - $util.base64.decode(object.etag, message.etag = $util.newBuffer($util.base64.length(object.etag)), 0); - else if (object.etag.length >= 0) - message.etag = object.etag; - return message; - }; + /** + * Verifies a GetOperationRequest message. + * @function verify + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + GetOperationRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; - /** - * Creates a plain object from a Policy message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.Policy - * @static - * @param {google.iam.v1.Policy} message Policy - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Policy.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.bindings = []; - object.auditConfigs = []; - } - if (options.defaults) { - object.version = 0; - if (options.bytes === String) - object.etag = ""; - else { - object.etag = []; - if (options.bytes !== Array) - object.etag = $util.newBuffer(object.etag); - } - } - if (message.version != null && message.hasOwnProperty("version")) - object.version = message.version; - if (message.etag != null && message.hasOwnProperty("etag")) - object.etag = options.bytes === String ? $util.base64.encode(message.etag, 0, message.etag.length) : options.bytes === Array ? Array.prototype.slice.call(message.etag) : message.etag; - if (message.bindings && message.bindings.length) { - object.bindings = []; - for (var j = 0; j < message.bindings.length; ++j) - object.bindings[j] = $root.google.iam.v1.Binding.toObject(message.bindings[j], options); - } - if (message.auditConfigs && message.auditConfigs.length) { - object.auditConfigs = []; - for (var j = 0; j < message.auditConfigs.length; ++j) - object.auditConfigs[j] = $root.google.iam.v1.AuditConfig.toObject(message.auditConfigs[j], options); - } + /** + * Creates a GetOperationRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.GetOperationRequest} GetOperationRequest + */ + GetOperationRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.GetOperationRequest) return object; - }; + var message = new $root.google.longrunning.GetOperationRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; + + /** + * Creates a plain object from a GetOperationRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {google.longrunning.GetOperationRequest} message GetOperationRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + GetOperationRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; - /** - * Converts this Policy to JSON. - * @function toJSON - * @memberof google.iam.v1.Policy - * @instance - * @returns {Object.} JSON object - */ - Policy.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Converts this GetOperationRequest to JSON. + * @function toJSON + * @memberof google.longrunning.GetOperationRequest + * @instance + * @returns {Object.} JSON object + */ + GetOperationRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Gets the default type url for Policy - * @function getTypeUrl - * @memberof google.iam.v1.Policy - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Policy.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.Policy"; - }; + /** + * Gets the default type url for GetOperationRequest + * @function getTypeUrl + * @memberof google.longrunning.GetOperationRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + GetOperationRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.longrunning.GetOperationRequest"; + }; - return Policy; - })(); + return GetOperationRequest; + })(); - v1.Binding = (function() { + longrunning.ListOperationsRequest = (function() { - /** - * Properties of a Binding. - * @memberof google.iam.v1 - * @interface IBinding - * @property {string|null} [role] Binding role - * @property {Array.|null} [members] Binding members - * @property {google.type.IExpr|null} [condition] Binding condition - */ + /** + * Properties of a ListOperationsRequest. + * @memberof google.longrunning + * @interface IListOperationsRequest + * @property {string|null} [name] ListOperationsRequest name + * @property {string|null} [filter] ListOperationsRequest filter + * @property {number|null} [pageSize] ListOperationsRequest pageSize + * @property {string|null} [pageToken] ListOperationsRequest pageToken + */ - /** - * Constructs a new Binding. - * @memberof google.iam.v1 - * @classdesc Represents a Binding. - * @implements IBinding - * @constructor - * @param {google.iam.v1.IBinding=} [properties] Properties to set - */ - function Binding(properties) { - this.members = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + /** + * Constructs a new ListOperationsRequest. + * @memberof google.longrunning + * @classdesc Represents a ListOperationsRequest. + * @implements IListOperationsRequest + * @constructor + * @param {google.longrunning.IListOperationsRequest=} [properties] Properties to set + */ + function ListOperationsRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Binding role. - * @member {string} role - * @memberof google.iam.v1.Binding - * @instance - */ - Binding.prototype.role = ""; + /** + * ListOperationsRequest name. + * @member {string} name + * @memberof google.longrunning.ListOperationsRequest + * @instance + */ + ListOperationsRequest.prototype.name = ""; - /** - * Binding members. - * @member {Array.} members - * @memberof google.iam.v1.Binding - * @instance - */ - Binding.prototype.members = $util.emptyArray; + /** + * ListOperationsRequest filter. + * @member {string} filter + * @memberof google.longrunning.ListOperationsRequest + * @instance + */ + ListOperationsRequest.prototype.filter = ""; - /** - * Binding condition. - * @member {google.type.IExpr|null|undefined} condition - * @memberof google.iam.v1.Binding - * @instance - */ - Binding.prototype.condition = null; + /** + * ListOperationsRequest pageSize. + * @member {number} pageSize + * @memberof google.longrunning.ListOperationsRequest + * @instance + */ + ListOperationsRequest.prototype.pageSize = 0; - /** - * Creates a new Binding instance using the specified properties. - * @function create - * @memberof google.iam.v1.Binding - * @static - * @param {google.iam.v1.IBinding=} [properties] Properties to set - * @returns {google.iam.v1.Binding} Binding instance - */ - Binding.create = function create(properties) { - return new Binding(properties); - }; + /** + * ListOperationsRequest pageToken. + * @member {string} pageToken + * @memberof google.longrunning.ListOperationsRequest + * @instance + */ + ListOperationsRequest.prototype.pageToken = ""; - /** - * Encodes the specified Binding message. Does not implicitly {@link google.iam.v1.Binding.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.Binding - * @static - * @param {google.iam.v1.IBinding} message Binding message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Binding.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.role != null && Object.hasOwnProperty.call(message, "role")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.role); - if (message.members != null && message.members.length) - for (var i = 0; i < message.members.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.members[i]); - if (message.condition != null && Object.hasOwnProperty.call(message, "condition")) - $root.google.type.Expr.encode(message.condition, writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - return writer; - }; + /** + * Creates a new ListOperationsRequest instance using the specified properties. + * @function create + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {google.longrunning.IListOperationsRequest=} [properties] Properties to set + * @returns {google.longrunning.ListOperationsRequest} ListOperationsRequest instance + */ + ListOperationsRequest.create = function create(properties) { + return new ListOperationsRequest(properties); + }; - /** - * Encodes the specified Binding message, length delimited. Does not implicitly {@link google.iam.v1.Binding.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.Binding - * @static - * @param {google.iam.v1.IBinding} message Binding message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - Binding.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Encodes the specified ListOperationsRequest message. Does not implicitly {@link google.longrunning.ListOperationsRequest.verify|verify} messages. + * @function encode + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {google.longrunning.IListOperationsRequest} message ListOperationsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListOperationsRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.filter != null && Object.hasOwnProperty.call(message, "filter")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.filter); + if (message.pageSize != null && Object.hasOwnProperty.call(message, "pageSize")) + writer.uint32(/* id 2, wireType 0 =*/16).int32(message.pageSize); + if (message.pageToken != null && Object.hasOwnProperty.call(message, "pageToken")) + writer.uint32(/* id 3, wireType 2 =*/26).string(message.pageToken); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.name); + return writer; + }; - /** - * Decodes a Binding message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.Binding - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.Binding} Binding - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Binding.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.Binding(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.role = reader.string(); - break; - } - case 2: { - if (!(message.members && message.members.length)) - message.members = []; - message.members.push(reader.string()); - break; - } - case 3: { - message.condition = $root.google.type.Expr.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); + /** + * Encodes the specified ListOperationsRequest message, length delimited. Does not implicitly {@link google.longrunning.ListOperationsRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {google.longrunning.IListOperationsRequest} message ListOperationsRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListOperationsRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a ListOperationsRequest message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.ListOperationsRequest} ListOperationsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListOperationsRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.ListOperationsRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 4: { + message.name = reader.string(); + break; + } + case 1: { + message.filter = reader.string(); + break; + } + case 2: { + message.pageSize = reader.int32(); break; } + case 3: { + message.pageToken = reader.string(); + break; + } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Decodes a Binding message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.Binding - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.Binding} Binding - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - Binding.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + } + return message; + }; - /** - * Verifies a Binding message. - * @function verify - * @memberof google.iam.v1.Binding - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - Binding.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.role != null && message.hasOwnProperty("role")) - if (!$util.isString(message.role)) - return "role: string expected"; - if (message.members != null && message.hasOwnProperty("members")) { - if (!Array.isArray(message.members)) - return "members: array expected"; - for (var i = 0; i < message.members.length; ++i) - if (!$util.isString(message.members[i])) - return "members: string[] expected"; - } - if (message.condition != null && message.hasOwnProperty("condition")) { - var error = $root.google.type.Expr.verify(message.condition); - if (error) - return "condition." + error; - } - return null; - }; + /** + * Decodes a ListOperationsRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.ListOperationsRequest} ListOperationsRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListOperationsRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Creates a Binding message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.Binding - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.Binding} Binding - */ - Binding.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.Binding) - return object; - var message = new $root.google.iam.v1.Binding(); - if (object.role != null) - message.role = String(object.role); - if (object.members) { - if (!Array.isArray(object.members)) - throw TypeError(".google.iam.v1.Binding.members: array expected"); - message.members = []; - for (var i = 0; i < object.members.length; ++i) - message.members[i] = String(object.members[i]); - } - if (object.condition != null) { - if (typeof object.condition !== "object") - throw TypeError(".google.iam.v1.Binding.condition: object expected"); - message.condition = $root.google.type.Expr.fromObject(object.condition); - } - return message; - }; + /** + * Verifies a ListOperationsRequest message. + * @function verify + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ListOperationsRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.filter != null && message.hasOwnProperty("filter")) + if (!$util.isString(message.filter)) + return "filter: string expected"; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + if (!$util.isInteger(message.pageSize)) + return "pageSize: integer expected"; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + if (!$util.isString(message.pageToken)) + return "pageToken: string expected"; + return null; + }; - /** - * Creates a plain object from a Binding message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.Binding - * @static - * @param {google.iam.v1.Binding} message Binding - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - Binding.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.members = []; - if (options.defaults) { - object.role = ""; - object.condition = null; - } - if (message.role != null && message.hasOwnProperty("role")) - object.role = message.role; - if (message.members && message.members.length) { - object.members = []; - for (var j = 0; j < message.members.length; ++j) - object.members[j] = message.members[j]; - } - if (message.condition != null && message.hasOwnProperty("condition")) - object.condition = $root.google.type.Expr.toObject(message.condition, options); + /** + * Creates a ListOperationsRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.ListOperationsRequest} ListOperationsRequest + */ + ListOperationsRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.ListOperationsRequest) return object; - }; - - /** - * Converts this Binding to JSON. - * @function toJSON - * @memberof google.iam.v1.Binding - * @instance - * @returns {Object.} JSON object - */ - Binding.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + var message = new $root.google.longrunning.ListOperationsRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.filter != null) + message.filter = String(object.filter); + if (object.pageSize != null) + message.pageSize = object.pageSize | 0; + if (object.pageToken != null) + message.pageToken = String(object.pageToken); + return message; + }; - /** - * Gets the default type url for Binding - * @function getTypeUrl - * @memberof google.iam.v1.Binding - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - Binding.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.Binding"; - }; + /** + * Creates a plain object from a ListOperationsRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {google.longrunning.ListOperationsRequest} message ListOperationsRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ListOperationsRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.filter = ""; + object.pageSize = 0; + object.pageToken = ""; + object.name = ""; + } + if (message.filter != null && message.hasOwnProperty("filter")) + object.filter = message.filter; + if (message.pageSize != null && message.hasOwnProperty("pageSize")) + object.pageSize = message.pageSize; + if (message.pageToken != null && message.hasOwnProperty("pageToken")) + object.pageToken = message.pageToken; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; - return Binding; - })(); + /** + * Converts this ListOperationsRequest to JSON. + * @function toJSON + * @memberof google.longrunning.ListOperationsRequest + * @instance + * @returns {Object.} JSON object + */ + ListOperationsRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - v1.AuditConfig = (function() { + /** + * Gets the default type url for ListOperationsRequest + * @function getTypeUrl + * @memberof google.longrunning.ListOperationsRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ListOperationsRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.longrunning.ListOperationsRequest"; + }; - /** - * Properties of an AuditConfig. - * @memberof google.iam.v1 - * @interface IAuditConfig - * @property {string|null} [service] AuditConfig service - * @property {Array.|null} [auditLogConfigs] AuditConfig auditLogConfigs - */ + return ListOperationsRequest; + })(); - /** - * Constructs a new AuditConfig. - * @memberof google.iam.v1 - * @classdesc Represents an AuditConfig. - * @implements IAuditConfig - * @constructor - * @param {google.iam.v1.IAuditConfig=} [properties] Properties to set - */ - function AuditConfig(properties) { - this.auditLogConfigs = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; - } + longrunning.ListOperationsResponse = (function() { - /** - * AuditConfig service. - * @member {string} service - * @memberof google.iam.v1.AuditConfig - * @instance - */ - AuditConfig.prototype.service = ""; + /** + * Properties of a ListOperationsResponse. + * @memberof google.longrunning + * @interface IListOperationsResponse + * @property {Array.|null} [operations] ListOperationsResponse operations + * @property {string|null} [nextPageToken] ListOperationsResponse nextPageToken + */ - /** - * AuditConfig auditLogConfigs. - * @member {Array.} auditLogConfigs - * @memberof google.iam.v1.AuditConfig - * @instance - */ - AuditConfig.prototype.auditLogConfigs = $util.emptyArray; + /** + * Constructs a new ListOperationsResponse. + * @memberof google.longrunning + * @classdesc Represents a ListOperationsResponse. + * @implements IListOperationsResponse + * @constructor + * @param {google.longrunning.IListOperationsResponse=} [properties] Properties to set + */ + function ListOperationsResponse(properties) { + this.operations = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new AuditConfig instance using the specified properties. - * @function create - * @memberof google.iam.v1.AuditConfig - * @static - * @param {google.iam.v1.IAuditConfig=} [properties] Properties to set - * @returns {google.iam.v1.AuditConfig} AuditConfig instance - */ - AuditConfig.create = function create(properties) { - return new AuditConfig(properties); - }; + /** + * ListOperationsResponse operations. + * @member {Array.} operations + * @memberof google.longrunning.ListOperationsResponse + * @instance + */ + ListOperationsResponse.prototype.operations = $util.emptyArray; - /** - * Encodes the specified AuditConfig message. Does not implicitly {@link google.iam.v1.AuditConfig.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.AuditConfig - * @static - * @param {google.iam.v1.IAuditConfig} message AuditConfig message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditConfig.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.service != null && Object.hasOwnProperty.call(message, "service")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.service); - if (message.auditLogConfigs != null && message.auditLogConfigs.length) - for (var i = 0; i < message.auditLogConfigs.length; ++i) - $root.google.iam.v1.AuditLogConfig.encode(message.auditLogConfigs[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); - return writer; - }; + /** + * ListOperationsResponse nextPageToken. + * @member {string} nextPageToken + * @memberof google.longrunning.ListOperationsResponse + * @instance + */ + ListOperationsResponse.prototype.nextPageToken = ""; - /** - * Encodes the specified AuditConfig message, length delimited. Does not implicitly {@link google.iam.v1.AuditConfig.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.AuditConfig - * @static - * @param {google.iam.v1.IAuditConfig} message AuditConfig message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditConfig.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Creates a new ListOperationsResponse instance using the specified properties. + * @function create + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {google.longrunning.IListOperationsResponse=} [properties] Properties to set + * @returns {google.longrunning.ListOperationsResponse} ListOperationsResponse instance + */ + ListOperationsResponse.create = function create(properties) { + return new ListOperationsResponse(properties); + }; - /** - * Decodes an AuditConfig message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.AuditConfig - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.AuditConfig} AuditConfig - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditConfig.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditConfig(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.service = reader.string(); - break; - } - case 3: { - if (!(message.auditLogConfigs && message.auditLogConfigs.length)) - message.auditLogConfigs = []; - message.auditLogConfigs.push($root.google.iam.v1.AuditLogConfig.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Encodes the specified ListOperationsResponse message. Does not implicitly {@link google.longrunning.ListOperationsResponse.verify|verify} messages. + * @function encode + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {google.longrunning.IListOperationsResponse} message ListOperationsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListOperationsResponse.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.operations != null && message.operations.length) + for (var i = 0; i < message.operations.length; ++i) + $root.google.longrunning.Operation.encode(message.operations[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); + if (message.nextPageToken != null && Object.hasOwnProperty.call(message, "nextPageToken")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.nextPageToken); + return writer; + }; - /** - * Decodes an AuditConfig message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.AuditConfig - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.AuditConfig} AuditConfig - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditConfig.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified ListOperationsResponse message, length delimited. Does not implicitly {@link google.longrunning.ListOperationsResponse.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {google.longrunning.IListOperationsResponse} message ListOperationsResponse message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + ListOperationsResponse.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Verifies an AuditConfig message. - * @function verify - * @memberof google.iam.v1.AuditConfig - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - AuditConfig.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.service != null && message.hasOwnProperty("service")) - if (!$util.isString(message.service)) - return "service: string expected"; - if (message.auditLogConfigs != null && message.hasOwnProperty("auditLogConfigs")) { - if (!Array.isArray(message.auditLogConfigs)) - return "auditLogConfigs: array expected"; - for (var i = 0; i < message.auditLogConfigs.length; ++i) { - var error = $root.google.iam.v1.AuditLogConfig.verify(message.auditLogConfigs[i]); - if (error) - return "auditLogConfigs." + error; + /** + * Decodes a ListOperationsResponse message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.ListOperationsResponse} ListOperationsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListOperationsResponse.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.ListOperationsResponse(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + if (!(message.operations && message.operations.length)) + message.operations = []; + message.operations.push($root.google.longrunning.Operation.decode(reader, reader.uint32())); + break; } - } - return null; - }; - - /** - * Creates an AuditConfig message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.AuditConfig - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.AuditConfig} AuditConfig - */ - AuditConfig.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.AuditConfig) - return object; - var message = new $root.google.iam.v1.AuditConfig(); - if (object.service != null) - message.service = String(object.service); - if (object.auditLogConfigs) { - if (!Array.isArray(object.auditLogConfigs)) - throw TypeError(".google.iam.v1.AuditConfig.auditLogConfigs: array expected"); - message.auditLogConfigs = []; - for (var i = 0; i < object.auditLogConfigs.length; ++i) { - if (typeof object.auditLogConfigs[i] !== "object") - throw TypeError(".google.iam.v1.AuditConfig.auditLogConfigs: object expected"); - message.auditLogConfigs[i] = $root.google.iam.v1.AuditLogConfig.fromObject(object.auditLogConfigs[i]); + case 2: { + message.nextPageToken = reader.string(); + break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Creates a plain object from an AuditConfig message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.AuditConfig - * @static - * @param {google.iam.v1.AuditConfig} message AuditConfig - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - AuditConfig.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.auditLogConfigs = []; - if (options.defaults) - object.service = ""; - if (message.service != null && message.hasOwnProperty("service")) - object.service = message.service; - if (message.auditLogConfigs && message.auditLogConfigs.length) { - object.auditLogConfigs = []; - for (var j = 0; j < message.auditLogConfigs.length; ++j) - object.auditLogConfigs[j] = $root.google.iam.v1.AuditLogConfig.toObject(message.auditLogConfigs[j], options); - } - return object; - }; + } + return message; + }; - /** - * Converts this AuditConfig to JSON. - * @function toJSON - * @memberof google.iam.v1.AuditConfig - * @instance - * @returns {Object.} JSON object - */ - AuditConfig.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Decodes a ListOperationsResponse message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.ListOperationsResponse} ListOperationsResponse + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + ListOperationsResponse.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Gets the default type url for AuditConfig - * @function getTypeUrl - * @memberof google.iam.v1.AuditConfig - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - AuditConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; + /** + * Verifies a ListOperationsResponse message. + * @function verify + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + ListOperationsResponse.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.operations != null && message.hasOwnProperty("operations")) { + if (!Array.isArray(message.operations)) + return "operations: array expected"; + for (var i = 0; i < message.operations.length; ++i) { + var error = $root.google.longrunning.Operation.verify(message.operations[i]); + if (error) + return "operations." + error; } - return typeUrlPrefix + "/google.iam.v1.AuditConfig"; - }; + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + if (!$util.isString(message.nextPageToken)) + return "nextPageToken: string expected"; + return null; + }; - return AuditConfig; - })(); + /** + * Creates a ListOperationsResponse message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.ListOperationsResponse} ListOperationsResponse + */ + ListOperationsResponse.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.ListOperationsResponse) + return object; + var message = new $root.google.longrunning.ListOperationsResponse(); + if (object.operations) { + if (!Array.isArray(object.operations)) + throw TypeError(".google.longrunning.ListOperationsResponse.operations: array expected"); + message.operations = []; + for (var i = 0; i < object.operations.length; ++i) { + if (typeof object.operations[i] !== "object") + throw TypeError(".google.longrunning.ListOperationsResponse.operations: object expected"); + message.operations[i] = $root.google.longrunning.Operation.fromObject(object.operations[i]); + } + } + if (object.nextPageToken != null) + message.nextPageToken = String(object.nextPageToken); + return message; + }; - v1.AuditLogConfig = (function() { + /** + * Creates a plain object from a ListOperationsResponse message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {google.longrunning.ListOperationsResponse} message ListOperationsResponse + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + ListOperationsResponse.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.operations = []; + if (options.defaults) + object.nextPageToken = ""; + if (message.operations && message.operations.length) { + object.operations = []; + for (var j = 0; j < message.operations.length; ++j) + object.operations[j] = $root.google.longrunning.Operation.toObject(message.operations[j], options); + } + if (message.nextPageToken != null && message.hasOwnProperty("nextPageToken")) + object.nextPageToken = message.nextPageToken; + return object; + }; - /** - * Properties of an AuditLogConfig. - * @memberof google.iam.v1 - * @interface IAuditLogConfig - * @property {google.iam.v1.AuditLogConfig.LogType|null} [logType] AuditLogConfig logType - * @property {Array.|null} [exemptedMembers] AuditLogConfig exemptedMembers - */ + /** + * Converts this ListOperationsResponse to JSON. + * @function toJSON + * @memberof google.longrunning.ListOperationsResponse + * @instance + * @returns {Object.} JSON object + */ + ListOperationsResponse.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new AuditLogConfig. - * @memberof google.iam.v1 - * @classdesc Represents an AuditLogConfig. - * @implements IAuditLogConfig - * @constructor - * @param {google.iam.v1.IAuditLogConfig=} [properties] Properties to set - */ - function AuditLogConfig(properties) { - this.exemptedMembers = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Gets the default type url for ListOperationsResponse + * @function getTypeUrl + * @memberof google.longrunning.ListOperationsResponse + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + ListOperationsResponse.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } + return typeUrlPrefix + "/google.longrunning.ListOperationsResponse"; + }; - /** - * AuditLogConfig logType. - * @member {google.iam.v1.AuditLogConfig.LogType} logType - * @memberof google.iam.v1.AuditLogConfig - * @instance - */ - AuditLogConfig.prototype.logType = 0; + return ListOperationsResponse; + })(); - /** - * AuditLogConfig exemptedMembers. - * @member {Array.} exemptedMembers - * @memberof google.iam.v1.AuditLogConfig - * @instance - */ - AuditLogConfig.prototype.exemptedMembers = $util.emptyArray; + longrunning.CancelOperationRequest = (function() { - /** - * Creates a new AuditLogConfig instance using the specified properties. - * @function create - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {google.iam.v1.IAuditLogConfig=} [properties] Properties to set - * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig instance - */ - AuditLogConfig.create = function create(properties) { - return new AuditLogConfig(properties); - }; + /** + * Properties of a CancelOperationRequest. + * @memberof google.longrunning + * @interface ICancelOperationRequest + * @property {string|null} [name] CancelOperationRequest name + */ - /** - * Encodes the specified AuditLogConfig message. Does not implicitly {@link google.iam.v1.AuditLogConfig.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {google.iam.v1.IAuditLogConfig} message AuditLogConfig message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditLogConfig.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.logType != null && Object.hasOwnProperty.call(message, "logType")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.logType); - if (message.exemptedMembers != null && message.exemptedMembers.length) - for (var i = 0; i < message.exemptedMembers.length; ++i) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.exemptedMembers[i]); - return writer; - }; + /** + * Constructs a new CancelOperationRequest. + * @memberof google.longrunning + * @classdesc Represents a CancelOperationRequest. + * @implements ICancelOperationRequest + * @constructor + * @param {google.longrunning.ICancelOperationRequest=} [properties] Properties to set + */ + function CancelOperationRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified AuditLogConfig message, length delimited. Does not implicitly {@link google.iam.v1.AuditLogConfig.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {google.iam.v1.IAuditLogConfig} message AuditLogConfig message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditLogConfig.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * CancelOperationRequest name. + * @member {string} name + * @memberof google.longrunning.CancelOperationRequest + * @instance + */ + CancelOperationRequest.prototype.name = ""; - /** - * Decodes an AuditLogConfig message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditLogConfig.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditLogConfig(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.logType = reader.int32(); - break; - } - case 2: { - if (!(message.exemptedMembers && message.exemptedMembers.length)) - message.exemptedMembers = []; - message.exemptedMembers.push(reader.string()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Creates a new CancelOperationRequest instance using the specified properties. + * @function create + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {google.longrunning.ICancelOperationRequest=} [properties] Properties to set + * @returns {google.longrunning.CancelOperationRequest} CancelOperationRequest instance + */ + CancelOperationRequest.create = function create(properties) { + return new CancelOperationRequest(properties); + }; - /** - * Decodes an AuditLogConfig message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditLogConfig.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified CancelOperationRequest message. Does not implicitly {@link google.longrunning.CancelOperationRequest.verify|verify} messages. + * @function encode + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {google.longrunning.ICancelOperationRequest} message CancelOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CancelOperationRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; - /** - * Verifies an AuditLogConfig message. - * @function verify - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - AuditLogConfig.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.logType != null && message.hasOwnProperty("logType")) - switch (message.logType) { - default: - return "logType: enum value expected"; - case 0: - case 1: - case 2: - case 3: - break; - } - if (message.exemptedMembers != null && message.hasOwnProperty("exemptedMembers")) { - if (!Array.isArray(message.exemptedMembers)) - return "exemptedMembers: array expected"; - for (var i = 0; i < message.exemptedMembers.length; ++i) - if (!$util.isString(message.exemptedMembers[i])) - return "exemptedMembers: string[] expected"; - } - return null; - }; + /** + * Encodes the specified CancelOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.CancelOperationRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {google.longrunning.ICancelOperationRequest} message CancelOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + CancelOperationRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Creates an AuditLogConfig message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.AuditLogConfig} AuditLogConfig - */ - AuditLogConfig.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.AuditLogConfig) - return object; - var message = new $root.google.iam.v1.AuditLogConfig(); - switch (object.logType) { - default: - if (typeof object.logType === "number") { - message.logType = object.logType; + /** + * Decodes a CancelOperationRequest message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.CancelOperationRequest} CancelOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CancelOperationRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.CancelOperationRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); break; } + default: + reader.skipType(tag & 7); break; - case "LOG_TYPE_UNSPECIFIED": - case 0: - message.logType = 0; - break; - case "ADMIN_READ": - case 1: - message.logType = 1; - break; - case "DATA_WRITE": - case 2: - message.logType = 2; - break; - case "DATA_READ": - case 3: - message.logType = 3; - break; - } - if (object.exemptedMembers) { - if (!Array.isArray(object.exemptedMembers)) - throw TypeError(".google.iam.v1.AuditLogConfig.exemptedMembers: array expected"); - message.exemptedMembers = []; - for (var i = 0; i < object.exemptedMembers.length; ++i) - message.exemptedMembers[i] = String(object.exemptedMembers[i]); - } - return message; - }; - - /** - * Creates a plain object from an AuditLogConfig message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {google.iam.v1.AuditLogConfig} message AuditLogConfig - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - AuditLogConfig.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) - object.exemptedMembers = []; - if (options.defaults) - object.logType = options.enums === String ? "LOG_TYPE_UNSPECIFIED" : 0; - if (message.logType != null && message.hasOwnProperty("logType")) - object.logType = options.enums === String ? $root.google.iam.v1.AuditLogConfig.LogType[message.logType] === undefined ? message.logType : $root.google.iam.v1.AuditLogConfig.LogType[message.logType] : message.logType; - if (message.exemptedMembers && message.exemptedMembers.length) { - object.exemptedMembers = []; - for (var j = 0; j < message.exemptedMembers.length; ++j) - object.exemptedMembers[j] = message.exemptedMembers[j]; } - return object; - }; - - /** - * Converts this AuditLogConfig to JSON. - * @function toJSON - * @memberof google.iam.v1.AuditLogConfig - * @instance - * @returns {Object.} JSON object - */ - AuditLogConfig.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + } + return message; + }; - /** - * Gets the default type url for AuditLogConfig - * @function getTypeUrl - * @memberof google.iam.v1.AuditLogConfig - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - AuditLogConfig.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.AuditLogConfig"; - }; + /** + * Decodes a CancelOperationRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.CancelOperationRequest} CancelOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + CancelOperationRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * LogType enum. - * @name google.iam.v1.AuditLogConfig.LogType - * @enum {number} - * @property {number} LOG_TYPE_UNSPECIFIED=0 LOG_TYPE_UNSPECIFIED value - * @property {number} ADMIN_READ=1 ADMIN_READ value - * @property {number} DATA_WRITE=2 DATA_WRITE value - * @property {number} DATA_READ=3 DATA_READ value - */ - AuditLogConfig.LogType = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "LOG_TYPE_UNSPECIFIED"] = 0; - values[valuesById[1] = "ADMIN_READ"] = 1; - values[valuesById[2] = "DATA_WRITE"] = 2; - values[valuesById[3] = "DATA_READ"] = 3; - return values; - })(); + /** + * Verifies a CancelOperationRequest message. + * @function verify + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + CancelOperationRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; - return AuditLogConfig; - })(); + /** + * Creates a CancelOperationRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.CancelOperationRequest} CancelOperationRequest + */ + CancelOperationRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.CancelOperationRequest) + return object; + var message = new $root.google.longrunning.CancelOperationRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; - v1.PolicyDelta = (function() { + /** + * Creates a plain object from a CancelOperationRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {google.longrunning.CancelOperationRequest} message CancelOperationRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + CancelOperationRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; - /** - * Properties of a PolicyDelta. - * @memberof google.iam.v1 - * @interface IPolicyDelta - * @property {Array.|null} [bindingDeltas] PolicyDelta bindingDeltas - * @property {Array.|null} [auditConfigDeltas] PolicyDelta auditConfigDeltas - */ + /** + * Converts this CancelOperationRequest to JSON. + * @function toJSON + * @memberof google.longrunning.CancelOperationRequest + * @instance + * @returns {Object.} JSON object + */ + CancelOperationRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new PolicyDelta. - * @memberof google.iam.v1 - * @classdesc Represents a PolicyDelta. - * @implements IPolicyDelta - * @constructor - * @param {google.iam.v1.IPolicyDelta=} [properties] Properties to set - */ - function PolicyDelta(properties) { - this.bindingDeltas = []; - this.auditConfigDeltas = []; - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Gets the default type url for CancelOperationRequest + * @function getTypeUrl + * @memberof google.longrunning.CancelOperationRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + CancelOperationRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } + return typeUrlPrefix + "/google.longrunning.CancelOperationRequest"; + }; - /** - * PolicyDelta bindingDeltas. - * @member {Array.} bindingDeltas - * @memberof google.iam.v1.PolicyDelta - * @instance - */ - PolicyDelta.prototype.bindingDeltas = $util.emptyArray; + return CancelOperationRequest; + })(); - /** - * PolicyDelta auditConfigDeltas. - * @member {Array.} auditConfigDeltas - * @memberof google.iam.v1.PolicyDelta - * @instance - */ - PolicyDelta.prototype.auditConfigDeltas = $util.emptyArray; + longrunning.DeleteOperationRequest = (function() { - /** - * Creates a new PolicyDelta instance using the specified properties. - * @function create - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {google.iam.v1.IPolicyDelta=} [properties] Properties to set - * @returns {google.iam.v1.PolicyDelta} PolicyDelta instance - */ - PolicyDelta.create = function create(properties) { - return new PolicyDelta(properties); - }; + /** + * Properties of a DeleteOperationRequest. + * @memberof google.longrunning + * @interface IDeleteOperationRequest + * @property {string|null} [name] DeleteOperationRequest name + */ - /** - * Encodes the specified PolicyDelta message. Does not implicitly {@link google.iam.v1.PolicyDelta.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {google.iam.v1.IPolicyDelta} message PolicyDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - PolicyDelta.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.bindingDeltas != null && message.bindingDeltas.length) - for (var i = 0; i < message.bindingDeltas.length; ++i) - $root.google.iam.v1.BindingDelta.encode(message.bindingDeltas[i], writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim(); - if (message.auditConfigDeltas != null && message.auditConfigDeltas.length) - for (var i = 0; i < message.auditConfigDeltas.length; ++i) - $root.google.iam.v1.AuditConfigDelta.encode(message.auditConfigDeltas[i], writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); - return writer; - }; + /** + * Constructs a new DeleteOperationRequest. + * @memberof google.longrunning + * @classdesc Represents a DeleteOperationRequest. + * @implements IDeleteOperationRequest + * @constructor + * @param {google.longrunning.IDeleteOperationRequest=} [properties] Properties to set + */ + function DeleteOperationRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified PolicyDelta message, length delimited. Does not implicitly {@link google.iam.v1.PolicyDelta.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {google.iam.v1.IPolicyDelta} message PolicyDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - PolicyDelta.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * DeleteOperationRequest name. + * @member {string} name + * @memberof google.longrunning.DeleteOperationRequest + * @instance + */ + DeleteOperationRequest.prototype.name = ""; - /** - * Decodes a PolicyDelta message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.PolicyDelta} PolicyDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - PolicyDelta.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.PolicyDelta(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - if (!(message.bindingDeltas && message.bindingDeltas.length)) - message.bindingDeltas = []; - message.bindingDeltas.push($root.google.iam.v1.BindingDelta.decode(reader, reader.uint32())); - break; - } - case 2: { - if (!(message.auditConfigDeltas && message.auditConfigDeltas.length)) - message.auditConfigDeltas = []; - message.auditConfigDeltas.push($root.google.iam.v1.AuditConfigDelta.decode(reader, reader.uint32())); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Creates a new DeleteOperationRequest instance using the specified properties. + * @function create + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {google.longrunning.IDeleteOperationRequest=} [properties] Properties to set + * @returns {google.longrunning.DeleteOperationRequest} DeleteOperationRequest instance + */ + DeleteOperationRequest.create = function create(properties) { + return new DeleteOperationRequest(properties); + }; - /** - * Decodes a PolicyDelta message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.PolicyDelta} PolicyDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - PolicyDelta.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified DeleteOperationRequest message. Does not implicitly {@link google.longrunning.DeleteOperationRequest.verify|verify} messages. + * @function encode + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {google.longrunning.IDeleteOperationRequest} message DeleteOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeleteOperationRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + return writer; + }; - /** - * Verifies a PolicyDelta message. - * @function verify - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - PolicyDelta.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.bindingDeltas != null && message.hasOwnProperty("bindingDeltas")) { - if (!Array.isArray(message.bindingDeltas)) - return "bindingDeltas: array expected"; - for (var i = 0; i < message.bindingDeltas.length; ++i) { - var error = $root.google.iam.v1.BindingDelta.verify(message.bindingDeltas[i]); - if (error) - return "bindingDeltas." + error; - } - } - if (message.auditConfigDeltas != null && message.hasOwnProperty("auditConfigDeltas")) { - if (!Array.isArray(message.auditConfigDeltas)) - return "auditConfigDeltas: array expected"; - for (var i = 0; i < message.auditConfigDeltas.length; ++i) { - var error = $root.google.iam.v1.AuditConfigDelta.verify(message.auditConfigDeltas[i]); - if (error) - return "auditConfigDeltas." + error; - } - } - return null; - }; + /** + * Encodes the specified DeleteOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.DeleteOperationRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {google.longrunning.IDeleteOperationRequest} message DeleteOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + DeleteOperationRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Creates a PolicyDelta message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.PolicyDelta} PolicyDelta - */ - PolicyDelta.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.PolicyDelta) - return object; - var message = new $root.google.iam.v1.PolicyDelta(); - if (object.bindingDeltas) { - if (!Array.isArray(object.bindingDeltas)) - throw TypeError(".google.iam.v1.PolicyDelta.bindingDeltas: array expected"); - message.bindingDeltas = []; - for (var i = 0; i < object.bindingDeltas.length; ++i) { - if (typeof object.bindingDeltas[i] !== "object") - throw TypeError(".google.iam.v1.PolicyDelta.bindingDeltas: object expected"); - message.bindingDeltas[i] = $root.google.iam.v1.BindingDelta.fromObject(object.bindingDeltas[i]); - } - } - if (object.auditConfigDeltas) { - if (!Array.isArray(object.auditConfigDeltas)) - throw TypeError(".google.iam.v1.PolicyDelta.auditConfigDeltas: array expected"); - message.auditConfigDeltas = []; - for (var i = 0; i < object.auditConfigDeltas.length; ++i) { - if (typeof object.auditConfigDeltas[i] !== "object") - throw TypeError(".google.iam.v1.PolicyDelta.auditConfigDeltas: object expected"); - message.auditConfigDeltas[i] = $root.google.iam.v1.AuditConfigDelta.fromObject(object.auditConfigDeltas[i]); + /** + * Decodes a DeleteOperationRequest message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.DeleteOperationRequest} DeleteOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeleteOperationRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.DeleteOperationRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); + break; } + default: + reader.skipType(tag & 7); + break; } - return message; - }; - - /** - * Creates a plain object from a PolicyDelta message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {google.iam.v1.PolicyDelta} message PolicyDelta - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - PolicyDelta.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.arrays || options.defaults) { - object.bindingDeltas = []; - object.auditConfigDeltas = []; - } - if (message.bindingDeltas && message.bindingDeltas.length) { - object.bindingDeltas = []; - for (var j = 0; j < message.bindingDeltas.length; ++j) - object.bindingDeltas[j] = $root.google.iam.v1.BindingDelta.toObject(message.bindingDeltas[j], options); - } - if (message.auditConfigDeltas && message.auditConfigDeltas.length) { - object.auditConfigDeltas = []; - for (var j = 0; j < message.auditConfigDeltas.length; ++j) - object.auditConfigDeltas[j] = $root.google.iam.v1.AuditConfigDelta.toObject(message.auditConfigDeltas[j], options); - } - return object; - }; + } + return message; + }; - /** - * Converts this PolicyDelta to JSON. - * @function toJSON - * @memberof google.iam.v1.PolicyDelta - * @instance - * @returns {Object.} JSON object - */ - PolicyDelta.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Decodes a DeleteOperationRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.DeleteOperationRequest} DeleteOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + DeleteOperationRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Gets the default type url for PolicyDelta - * @function getTypeUrl - * @memberof google.iam.v1.PolicyDelta - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - PolicyDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.PolicyDelta"; - }; + /** + * Verifies a DeleteOperationRequest message. + * @function verify + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + DeleteOperationRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + return null; + }; - return PolicyDelta; - })(); + /** + * Creates a DeleteOperationRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.DeleteOperationRequest} DeleteOperationRequest + */ + DeleteOperationRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.DeleteOperationRequest) + return object; + var message = new $root.google.longrunning.DeleteOperationRequest(); + if (object.name != null) + message.name = String(object.name); + return message; + }; - v1.BindingDelta = (function() { + /** + * Creates a plain object from a DeleteOperationRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {google.longrunning.DeleteOperationRequest} message DeleteOperationRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + DeleteOperationRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.name = ""; + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + return object; + }; - /** - * Properties of a BindingDelta. - * @memberof google.iam.v1 - * @interface IBindingDelta - * @property {google.iam.v1.BindingDelta.Action|null} [action] BindingDelta action - * @property {string|null} [role] BindingDelta role - * @property {string|null} [member] BindingDelta member - * @property {google.type.IExpr|null} [condition] BindingDelta condition - */ + /** + * Converts this DeleteOperationRequest to JSON. + * @function toJSON + * @memberof google.longrunning.DeleteOperationRequest + * @instance + * @returns {Object.} JSON object + */ + DeleteOperationRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * Constructs a new BindingDelta. - * @memberof google.iam.v1 - * @classdesc Represents a BindingDelta. - * @implements IBindingDelta - * @constructor - * @param {google.iam.v1.IBindingDelta=} [properties] Properties to set - */ - function BindingDelta(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Gets the default type url for DeleteOperationRequest + * @function getTypeUrl + * @memberof google.longrunning.DeleteOperationRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + DeleteOperationRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; } + return typeUrlPrefix + "/google.longrunning.DeleteOperationRequest"; + }; - /** - * BindingDelta action. - * @member {google.iam.v1.BindingDelta.Action} action - * @memberof google.iam.v1.BindingDelta - * @instance - */ - BindingDelta.prototype.action = 0; + return DeleteOperationRequest; + })(); - /** - * BindingDelta role. - * @member {string} role - * @memberof google.iam.v1.BindingDelta - * @instance - */ - BindingDelta.prototype.role = ""; + longrunning.WaitOperationRequest = (function() { - /** - * BindingDelta member. - * @member {string} member - * @memberof google.iam.v1.BindingDelta - * @instance - */ - BindingDelta.prototype.member = ""; + /** + * Properties of a WaitOperationRequest. + * @memberof google.longrunning + * @interface IWaitOperationRequest + * @property {string|null} [name] WaitOperationRequest name + * @property {google.protobuf.IDuration|null} [timeout] WaitOperationRequest timeout + */ - /** - * BindingDelta condition. - * @member {google.type.IExpr|null|undefined} condition - * @memberof google.iam.v1.BindingDelta - * @instance - */ - BindingDelta.prototype.condition = null; + /** + * Constructs a new WaitOperationRequest. + * @memberof google.longrunning + * @classdesc Represents a WaitOperationRequest. + * @implements IWaitOperationRequest + * @constructor + * @param {google.longrunning.IWaitOperationRequest=} [properties] Properties to set + */ + function WaitOperationRequest(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Creates a new BindingDelta instance using the specified properties. - * @function create - * @memberof google.iam.v1.BindingDelta - * @static - * @param {google.iam.v1.IBindingDelta=} [properties] Properties to set - * @returns {google.iam.v1.BindingDelta} BindingDelta instance - */ - BindingDelta.create = function create(properties) { - return new BindingDelta(properties); - }; + /** + * WaitOperationRequest name. + * @member {string} name + * @memberof google.longrunning.WaitOperationRequest + * @instance + */ + WaitOperationRequest.prototype.name = ""; - /** - * Encodes the specified BindingDelta message. Does not implicitly {@link google.iam.v1.BindingDelta.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.BindingDelta - * @static - * @param {google.iam.v1.IBindingDelta} message BindingDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - BindingDelta.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.action != null && Object.hasOwnProperty.call(message, "action")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.action); - if (message.role != null && Object.hasOwnProperty.call(message, "role")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.role); - if (message.member != null && Object.hasOwnProperty.call(message, "member")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.member); - if (message.condition != null && Object.hasOwnProperty.call(message, "condition")) - $root.google.type.Expr.encode(message.condition, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); - return writer; - }; + /** + * WaitOperationRequest timeout. + * @member {google.protobuf.IDuration|null|undefined} timeout + * @memberof google.longrunning.WaitOperationRequest + * @instance + */ + WaitOperationRequest.prototype.timeout = null; - /** - * Encodes the specified BindingDelta message, length delimited. Does not implicitly {@link google.iam.v1.BindingDelta.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.BindingDelta - * @static - * @param {google.iam.v1.IBindingDelta} message BindingDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - BindingDelta.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * Creates a new WaitOperationRequest instance using the specified properties. + * @function create + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {google.longrunning.IWaitOperationRequest=} [properties] Properties to set + * @returns {google.longrunning.WaitOperationRequest} WaitOperationRequest instance + */ + WaitOperationRequest.create = function create(properties) { + return new WaitOperationRequest(properties); + }; - /** - * Decodes a BindingDelta message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.BindingDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.BindingDelta} BindingDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - BindingDelta.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.BindingDelta(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.action = reader.int32(); - break; - } - case 2: { - message.role = reader.string(); - break; - } - case 3: { - message.member = reader.string(); - break; - } - case 4: { - message.condition = $root.google.type.Expr.decode(reader, reader.uint32()); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * Encodes the specified WaitOperationRequest message. Does not implicitly {@link google.longrunning.WaitOperationRequest.verify|verify} messages. + * @function encode + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {google.longrunning.IWaitOperationRequest} message WaitOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + WaitOperationRequest.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.name != null && Object.hasOwnProperty.call(message, "name")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.name); + if (message.timeout != null && Object.hasOwnProperty.call(message, "timeout")) + $root.google.protobuf.Duration.encode(message.timeout, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim(); + return writer; + }; - /** - * Decodes a BindingDelta message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.BindingDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.BindingDelta} BindingDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - BindingDelta.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Encodes the specified WaitOperationRequest message, length delimited. Does not implicitly {@link google.longrunning.WaitOperationRequest.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {google.longrunning.IWaitOperationRequest} message WaitOperationRequest message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + WaitOperationRequest.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; - /** - * Verifies a BindingDelta message. - * @function verify - * @memberof google.iam.v1.BindingDelta - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - BindingDelta.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.action != null && message.hasOwnProperty("action")) - switch (message.action) { - default: - return "action: enum value expected"; - case 0: - case 1: - case 2: + /** + * Decodes a WaitOperationRequest message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.WaitOperationRequest} WaitOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + WaitOperationRequest.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.WaitOperationRequest(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.name = reader.string(); break; } - if (message.role != null && message.hasOwnProperty("role")) - if (!$util.isString(message.role)) - return "role: string expected"; - if (message.member != null && message.hasOwnProperty("member")) - if (!$util.isString(message.member)) - return "member: string expected"; - if (message.condition != null && message.hasOwnProperty("condition")) { - var error = $root.google.type.Expr.verify(message.condition); - if (error) - return "condition." + error; - } - return null; - }; - - /** - * Creates a BindingDelta message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.BindingDelta - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.BindingDelta} BindingDelta - */ - BindingDelta.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.BindingDelta) - return object; - var message = new $root.google.iam.v1.BindingDelta(); - switch (object.action) { - default: - if (typeof object.action === "number") { - message.action = object.action; + case 2: { + message.timeout = $root.google.protobuf.Duration.decode(reader, reader.uint32()); break; } + default: + reader.skipType(tag & 7); break; - case "ACTION_UNSPECIFIED": - case 0: - message.action = 0; - break; - case "ADD": - case 1: - message.action = 1; - break; - case "REMOVE": - case 2: - message.action = 2; - break; - } - if (object.role != null) - message.role = String(object.role); - if (object.member != null) - message.member = String(object.member); - if (object.condition != null) { - if (typeof object.condition !== "object") - throw TypeError(".google.iam.v1.BindingDelta.condition: object expected"); - message.condition = $root.google.type.Expr.fromObject(object.condition); - } - return message; - }; - - /** - * Creates a plain object from a BindingDelta message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.BindingDelta - * @static - * @param {google.iam.v1.BindingDelta} message BindingDelta - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - BindingDelta.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.action = options.enums === String ? "ACTION_UNSPECIFIED" : 0; - object.role = ""; - object.member = ""; - object.condition = null; - } - if (message.action != null && message.hasOwnProperty("action")) - object.action = options.enums === String ? $root.google.iam.v1.BindingDelta.Action[message.action] === undefined ? message.action : $root.google.iam.v1.BindingDelta.Action[message.action] : message.action; - if (message.role != null && message.hasOwnProperty("role")) - object.role = message.role; - if (message.member != null && message.hasOwnProperty("member")) - object.member = message.member; - if (message.condition != null && message.hasOwnProperty("condition")) - object.condition = $root.google.type.Expr.toObject(message.condition, options); - return object; - }; - - /** - * Converts this BindingDelta to JSON. - * @function toJSON - * @memberof google.iam.v1.BindingDelta - * @instance - * @returns {Object.} JSON object - */ - BindingDelta.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; - - /** - * Gets the default type url for BindingDelta - * @function getTypeUrl - * @memberof google.iam.v1.BindingDelta - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - BindingDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.iam.v1.BindingDelta"; - }; - - /** - * Action enum. - * @name google.iam.v1.BindingDelta.Action - * @enum {number} - * @property {number} ACTION_UNSPECIFIED=0 ACTION_UNSPECIFIED value - * @property {number} ADD=1 ADD value - * @property {number} REMOVE=2 REMOVE value - */ - BindingDelta.Action = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ACTION_UNSPECIFIED"] = 0; - values[valuesById[1] = "ADD"] = 1; - values[valuesById[2] = "REMOVE"] = 2; - return values; - })(); + } + return message; + }; - return BindingDelta; - })(); + /** + * Decodes a WaitOperationRequest message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.WaitOperationRequest} WaitOperationRequest + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + WaitOperationRequest.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - v1.AuditConfigDelta = (function() { + /** + * Verifies a WaitOperationRequest message. + * @function verify + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + WaitOperationRequest.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.name != null && message.hasOwnProperty("name")) + if (!$util.isString(message.name)) + return "name: string expected"; + if (message.timeout != null && message.hasOwnProperty("timeout")) { + var error = $root.google.protobuf.Duration.verify(message.timeout); + if (error) + return "timeout." + error; + } + return null; + }; - /** - * Properties of an AuditConfigDelta. - * @memberof google.iam.v1 - * @interface IAuditConfigDelta - * @property {google.iam.v1.AuditConfigDelta.Action|null} [action] AuditConfigDelta action - * @property {string|null} [service] AuditConfigDelta service - * @property {string|null} [exemptedMember] AuditConfigDelta exemptedMember - * @property {string|null} [logType] AuditConfigDelta logType - */ + /** + * Creates a WaitOperationRequest message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.WaitOperationRequest} WaitOperationRequest + */ + WaitOperationRequest.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.WaitOperationRequest) + return object; + var message = new $root.google.longrunning.WaitOperationRequest(); + if (object.name != null) + message.name = String(object.name); + if (object.timeout != null) { + if (typeof object.timeout !== "object") + throw TypeError(".google.longrunning.WaitOperationRequest.timeout: object expected"); + message.timeout = $root.google.protobuf.Duration.fromObject(object.timeout); + } + return message; + }; - /** - * Constructs a new AuditConfigDelta. - * @memberof google.iam.v1 - * @classdesc Represents an AuditConfigDelta. - * @implements IAuditConfigDelta - * @constructor - * @param {google.iam.v1.IAuditConfigDelta=} [properties] Properties to set - */ - function AuditConfigDelta(properties) { - if (properties) - for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) - if (properties[keys[i]] != null) - this[keys[i]] = properties[keys[i]]; + /** + * Creates a plain object from a WaitOperationRequest message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {google.longrunning.WaitOperationRequest} message WaitOperationRequest + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + WaitOperationRequest.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.name = ""; + object.timeout = null; } + if (message.name != null && message.hasOwnProperty("name")) + object.name = message.name; + if (message.timeout != null && message.hasOwnProperty("timeout")) + object.timeout = $root.google.protobuf.Duration.toObject(message.timeout, options); + return object; + }; - /** - * AuditConfigDelta action. - * @member {google.iam.v1.AuditConfigDelta.Action} action - * @memberof google.iam.v1.AuditConfigDelta - * @instance - */ - AuditConfigDelta.prototype.action = 0; + /** + * Converts this WaitOperationRequest to JSON. + * @function toJSON + * @memberof google.longrunning.WaitOperationRequest + * @instance + * @returns {Object.} JSON object + */ + WaitOperationRequest.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - /** - * AuditConfigDelta service. - * @member {string} service - * @memberof google.iam.v1.AuditConfigDelta - * @instance - */ - AuditConfigDelta.prototype.service = ""; + /** + * Gets the default type url for WaitOperationRequest + * @function getTypeUrl + * @memberof google.longrunning.WaitOperationRequest + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + WaitOperationRequest.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.longrunning.WaitOperationRequest"; + }; - /** - * AuditConfigDelta exemptedMember. - * @member {string} exemptedMember - * @memberof google.iam.v1.AuditConfigDelta - * @instance - */ - AuditConfigDelta.prototype.exemptedMember = ""; + return WaitOperationRequest; + })(); - /** - * AuditConfigDelta logType. - * @member {string} logType - * @memberof google.iam.v1.AuditConfigDelta - * @instance - */ - AuditConfigDelta.prototype.logType = ""; + longrunning.OperationInfo = (function() { - /** - * Creates a new AuditConfigDelta instance using the specified properties. - * @function create - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {google.iam.v1.IAuditConfigDelta=} [properties] Properties to set - * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta instance - */ - AuditConfigDelta.create = function create(properties) { - return new AuditConfigDelta(properties); - }; + /** + * Properties of an OperationInfo. + * @memberof google.longrunning + * @interface IOperationInfo + * @property {string|null} [responseType] OperationInfo responseType + * @property {string|null} [metadataType] OperationInfo metadataType + */ - /** - * Encodes the specified AuditConfigDelta message. Does not implicitly {@link google.iam.v1.AuditConfigDelta.verify|verify} messages. - * @function encode - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {google.iam.v1.IAuditConfigDelta} message AuditConfigDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditConfigDelta.encode = function encode(message, writer) { - if (!writer) - writer = $Writer.create(); - if (message.action != null && Object.hasOwnProperty.call(message, "action")) - writer.uint32(/* id 1, wireType 0 =*/8).int32(message.action); - if (message.service != null && Object.hasOwnProperty.call(message, "service")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.service); - if (message.exemptedMember != null && Object.hasOwnProperty.call(message, "exemptedMember")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.exemptedMember); - if (message.logType != null && Object.hasOwnProperty.call(message, "logType")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.logType); - return writer; - }; + /** + * Constructs a new OperationInfo. + * @memberof google.longrunning + * @classdesc Represents an OperationInfo. + * @implements IOperationInfo + * @constructor + * @param {google.longrunning.IOperationInfo=} [properties] Properties to set + */ + function OperationInfo(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } - /** - * Encodes the specified AuditConfigDelta message, length delimited. Does not implicitly {@link google.iam.v1.AuditConfigDelta.verify|verify} messages. - * @function encodeDelimited - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {google.iam.v1.IAuditConfigDelta} message AuditConfigDelta message or plain object to encode - * @param {$protobuf.Writer} [writer] Writer to encode to - * @returns {$protobuf.Writer} Writer - */ - AuditConfigDelta.encodeDelimited = function encodeDelimited(message, writer) { - return this.encode(message, writer).ldelim(); - }; + /** + * OperationInfo responseType. + * @member {string} responseType + * @memberof google.longrunning.OperationInfo + * @instance + */ + OperationInfo.prototype.responseType = ""; - /** - * Decodes an AuditConfigDelta message from the specified reader or buffer. - * @function decode - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @param {number} [length] Message length if known beforehand - * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditConfigDelta.decode = function decode(reader, length) { - if (!(reader instanceof $Reader)) - reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.iam.v1.AuditConfigDelta(); - while (reader.pos < end) { - var tag = reader.uint32(); - switch (tag >>> 3) { - case 1: { - message.action = reader.int32(); - break; - } - case 2: { - message.service = reader.string(); - break; - } - case 3: { - message.exemptedMember = reader.string(); - break; - } - case 4: { - message.logType = reader.string(); - break; - } - default: - reader.skipType(tag & 7); - break; - } - } - return message; - }; + /** + * OperationInfo metadataType. + * @member {string} metadataType + * @memberof google.longrunning.OperationInfo + * @instance + */ + OperationInfo.prototype.metadataType = ""; - /** - * Decodes an AuditConfigDelta message from the specified reader or buffer, length delimited. - * @function decodeDelimited - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta - * @throws {Error} If the payload is not a reader or valid buffer - * @throws {$protobuf.util.ProtocolError} If required fields are missing - */ - AuditConfigDelta.decodeDelimited = function decodeDelimited(reader) { - if (!(reader instanceof $Reader)) - reader = new $Reader(reader); - return this.decode(reader, reader.uint32()); - }; + /** + * Creates a new OperationInfo instance using the specified properties. + * @function create + * @memberof google.longrunning.OperationInfo + * @static + * @param {google.longrunning.IOperationInfo=} [properties] Properties to set + * @returns {google.longrunning.OperationInfo} OperationInfo instance + */ + OperationInfo.create = function create(properties) { + return new OperationInfo(properties); + }; - /** - * Verifies an AuditConfigDelta message. - * @function verify - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {Object.} message Plain object to verify - * @returns {string|null} `null` if valid, otherwise the reason why it is not - */ - AuditConfigDelta.verify = function verify(message) { - if (typeof message !== "object" || message === null) - return "object expected"; - if (message.action != null && message.hasOwnProperty("action")) - switch (message.action) { - default: - return "action: enum value expected"; - case 0: - case 1: - case 2: + /** + * Encodes the specified OperationInfo message. Does not implicitly {@link google.longrunning.OperationInfo.verify|verify} messages. + * @function encode + * @memberof google.longrunning.OperationInfo + * @static + * @param {google.longrunning.IOperationInfo} message OperationInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + OperationInfo.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.responseType != null && Object.hasOwnProperty.call(message, "responseType")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.responseType); + if (message.metadataType != null && Object.hasOwnProperty.call(message, "metadataType")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.metadataType); + return writer; + }; + + /** + * Encodes the specified OperationInfo message, length delimited. Does not implicitly {@link google.longrunning.OperationInfo.verify|verify} messages. + * @function encodeDelimited + * @memberof google.longrunning.OperationInfo + * @static + * @param {google.longrunning.IOperationInfo} message OperationInfo message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + OperationInfo.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes an OperationInfo message from the specified reader or buffer. + * @function decode + * @memberof google.longrunning.OperationInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {google.longrunning.OperationInfo} OperationInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + OperationInfo.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.longrunning.OperationInfo(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: { + message.responseType = reader.string(); break; } - if (message.service != null && message.hasOwnProperty("service")) - if (!$util.isString(message.service)) - return "service: string expected"; - if (message.exemptedMember != null && message.hasOwnProperty("exemptedMember")) - if (!$util.isString(message.exemptedMember)) - return "exemptedMember: string expected"; - if (message.logType != null && message.hasOwnProperty("logType")) - if (!$util.isString(message.logType)) - return "logType: string expected"; - return null; - }; - - /** - * Creates an AuditConfigDelta message from a plain object. Also converts values to their respective internal types. - * @function fromObject - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {Object.} object Plain object - * @returns {google.iam.v1.AuditConfigDelta} AuditConfigDelta - */ - AuditConfigDelta.fromObject = function fromObject(object) { - if (object instanceof $root.google.iam.v1.AuditConfigDelta) - return object; - var message = new $root.google.iam.v1.AuditConfigDelta(); - switch (object.action) { - default: - if (typeof object.action === "number") { - message.action = object.action; + case 2: { + message.metadataType = reader.string(); break; } - break; - case "ACTION_UNSPECIFIED": - case 0: - message.action = 0; - break; - case "ADD": - case 1: - message.action = 1; - break; - case "REMOVE": - case 2: - message.action = 2; + default: + reader.skipType(tag & 7); break; } - if (object.service != null) - message.service = String(object.service); - if (object.exemptedMember != null) - message.exemptedMember = String(object.exemptedMember); - if (object.logType != null) - message.logType = String(object.logType); - return message; - }; + } + return message; + }; - /** - * Creates a plain object from an AuditConfigDelta message. Also converts values to other types if specified. - * @function toObject - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {google.iam.v1.AuditConfigDelta} message AuditConfigDelta - * @param {$protobuf.IConversionOptions} [options] Conversion options - * @returns {Object.} Plain object - */ - AuditConfigDelta.toObject = function toObject(message, options) { - if (!options) - options = {}; - var object = {}; - if (options.defaults) { - object.action = options.enums === String ? "ACTION_UNSPECIFIED" : 0; - object.service = ""; - object.exemptedMember = ""; - object.logType = ""; - } - if (message.action != null && message.hasOwnProperty("action")) - object.action = options.enums === String ? $root.google.iam.v1.AuditConfigDelta.Action[message.action] === undefined ? message.action : $root.google.iam.v1.AuditConfigDelta.Action[message.action] : message.action; - if (message.service != null && message.hasOwnProperty("service")) - object.service = message.service; - if (message.exemptedMember != null && message.hasOwnProperty("exemptedMember")) - object.exemptedMember = message.exemptedMember; - if (message.logType != null && message.hasOwnProperty("logType")) - object.logType = message.logType; - return object; - }; + /** + * Decodes an OperationInfo message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof google.longrunning.OperationInfo + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {google.longrunning.OperationInfo} OperationInfo + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + OperationInfo.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; - /** - * Converts this AuditConfigDelta to JSON. - * @function toJSON - * @memberof google.iam.v1.AuditConfigDelta - * @instance - * @returns {Object.} JSON object - */ - AuditConfigDelta.prototype.toJSON = function toJSON() { - return this.constructor.toObject(this, $protobuf.util.toJSONOptions); - }; + /** + * Verifies an OperationInfo message. + * @function verify + * @memberof google.longrunning.OperationInfo + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + OperationInfo.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.responseType != null && message.hasOwnProperty("responseType")) + if (!$util.isString(message.responseType)) + return "responseType: string expected"; + if (message.metadataType != null && message.hasOwnProperty("metadataType")) + if (!$util.isString(message.metadataType)) + return "metadataType: string expected"; + return null; + }; - /** - * Gets the default type url for AuditConfigDelta - * @function getTypeUrl - * @memberof google.iam.v1.AuditConfigDelta - * @static - * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") - * @returns {string} The default type url - */ - AuditConfigDelta.getTypeUrl = function getTypeUrl(typeUrlPrefix) { - if (typeUrlPrefix === undefined) { - typeUrlPrefix = "type.googleapis.com"; - } - return typeUrlPrefix + "/google.iam.v1.AuditConfigDelta"; - }; + /** + * Creates an OperationInfo message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof google.longrunning.OperationInfo + * @static + * @param {Object.} object Plain object + * @returns {google.longrunning.OperationInfo} OperationInfo + */ + OperationInfo.fromObject = function fromObject(object) { + if (object instanceof $root.google.longrunning.OperationInfo) + return object; + var message = new $root.google.longrunning.OperationInfo(); + if (object.responseType != null) + message.responseType = String(object.responseType); + if (object.metadataType != null) + message.metadataType = String(object.metadataType); + return message; + }; - /** - * Action enum. - * @name google.iam.v1.AuditConfigDelta.Action - * @enum {number} - * @property {number} ACTION_UNSPECIFIED=0 ACTION_UNSPECIFIED value - * @property {number} ADD=1 ADD value - * @property {number} REMOVE=2 REMOVE value - */ - AuditConfigDelta.Action = (function() { - var valuesById = {}, values = Object.create(valuesById); - values[valuesById[0] = "ACTION_UNSPECIFIED"] = 0; - values[valuesById[1] = "ADD"] = 1; - values[valuesById[2] = "REMOVE"] = 2; - return values; - })(); + /** + * Creates a plain object from an OperationInfo message. Also converts values to other types if specified. + * @function toObject + * @memberof google.longrunning.OperationInfo + * @static + * @param {google.longrunning.OperationInfo} message OperationInfo + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + OperationInfo.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.responseType = ""; + object.metadataType = ""; + } + if (message.responseType != null && message.hasOwnProperty("responseType")) + object.responseType = message.responseType; + if (message.metadataType != null && message.hasOwnProperty("metadataType")) + object.metadataType = message.metadataType; + return object; + }; - return AuditConfigDelta; - })(); + /** + * Converts this OperationInfo to JSON. + * @function toJSON + * @memberof google.longrunning.OperationInfo + * @instance + * @returns {Object.} JSON object + */ + OperationInfo.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; - return v1; + /** + * Gets the default type url for OperationInfo + * @function getTypeUrl + * @memberof google.longrunning.OperationInfo + * @static + * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") + * @returns {string} The default type url + */ + OperationInfo.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + if (typeUrlPrefix === undefined) { + typeUrlPrefix = "type.googleapis.com"; + } + return typeUrlPrefix + "/google.longrunning.OperationInfo"; + }; + + return OperationInfo; })(); - return iam; + return longrunning; })(); - google.type = (function() { + google.rpc = (function() { /** - * Namespace type. + * Namespace rpc. * @memberof google * @namespace */ - var type = {}; + var rpc = {}; - type.Expr = (function() { + rpc.Status = (function() { /** - * Properties of an Expr. - * @memberof google.type - * @interface IExpr - * @property {string|null} [expression] Expr expression - * @property {string|null} [title] Expr title - * @property {string|null} [description] Expr description - * @property {string|null} [location] Expr location + * Properties of a Status. + * @memberof google.rpc + * @interface IStatus + * @property {number|null} [code] Status code + * @property {string|null} [message] Status message + * @property {Array.|null} [details] Status details */ /** - * Constructs a new Expr. - * @memberof google.type - * @classdesc Represents an Expr. - * @implements IExpr + * Constructs a new Status. + * @memberof google.rpc + * @classdesc Represents a Status. + * @implements IStatus * @constructor - * @param {google.type.IExpr=} [properties] Properties to set + * @param {google.rpc.IStatus=} [properties] Properties to set */ - function Expr(properties) { + function Status(properties) { + this.details = []; if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -64469,117 +71913,106 @@ } /** - * Expr expression. - * @member {string} expression - * @memberof google.type.Expr - * @instance - */ - Expr.prototype.expression = ""; - - /** - * Expr title. - * @member {string} title - * @memberof google.type.Expr + * Status code. + * @member {number} code + * @memberof google.rpc.Status * @instance */ - Expr.prototype.title = ""; + Status.prototype.code = 0; /** - * Expr description. - * @member {string} description - * @memberof google.type.Expr + * Status message. + * @member {string} message + * @memberof google.rpc.Status * @instance */ - Expr.prototype.description = ""; + Status.prototype.message = ""; /** - * Expr location. - * @member {string} location - * @memberof google.type.Expr + * Status details. + * @member {Array.} details + * @memberof google.rpc.Status * @instance */ - Expr.prototype.location = ""; + Status.prototype.details = $util.emptyArray; /** - * Creates a new Expr instance using the specified properties. + * Creates a new Status instance using the specified properties. * @function create - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static - * @param {google.type.IExpr=} [properties] Properties to set - * @returns {google.type.Expr} Expr instance + * @param {google.rpc.IStatus=} [properties] Properties to set + * @returns {google.rpc.Status} Status instance */ - Expr.create = function create(properties) { - return new Expr(properties); + Status.create = function create(properties) { + return new Status(properties); }; /** - * Encodes the specified Expr message. Does not implicitly {@link google.type.Expr.verify|verify} messages. + * Encodes the specified Status message. Does not implicitly {@link google.rpc.Status.verify|verify} messages. * @function encode - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static - * @param {google.type.IExpr} message Expr message or plain object to encode + * @param {google.rpc.IStatus} message Status message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Expr.encode = function encode(message, writer) { + Status.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); - if (message.expression != null && Object.hasOwnProperty.call(message, "expression")) - writer.uint32(/* id 1, wireType 2 =*/10).string(message.expression); - if (message.title != null && Object.hasOwnProperty.call(message, "title")) - writer.uint32(/* id 2, wireType 2 =*/18).string(message.title); - if (message.description != null && Object.hasOwnProperty.call(message, "description")) - writer.uint32(/* id 3, wireType 2 =*/26).string(message.description); - if (message.location != null && Object.hasOwnProperty.call(message, "location")) - writer.uint32(/* id 4, wireType 2 =*/34).string(message.location); + if (message.code != null && Object.hasOwnProperty.call(message, "code")) + writer.uint32(/* id 1, wireType 0 =*/8).int32(message.code); + if (message.message != null && Object.hasOwnProperty.call(message, "message")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.message); + if (message.details != null && message.details.length) + for (var i = 0; i < message.details.length; ++i) + $root.google.protobuf.Any.encode(message.details[i], writer.uint32(/* id 3, wireType 2 =*/26).fork()).ldelim(); return writer; }; /** - * Encodes the specified Expr message, length delimited. Does not implicitly {@link google.type.Expr.verify|verify} messages. + * Encodes the specified Status message, length delimited. Does not implicitly {@link google.rpc.Status.verify|verify} messages. * @function encodeDelimited - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static - * @param {google.type.IExpr} message Expr message or plain object to encode + * @param {google.rpc.IStatus} message Status message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Expr.encodeDelimited = function encodeDelimited(message, writer) { + Status.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes an Expr message from the specified reader or buffer. + * Decodes a Status message from the specified reader or buffer. * @function decode - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {google.type.Expr} Expr + * @returns {google.rpc.Status} Status * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Expr.decode = function decode(reader, length) { + Status.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.type.Expr(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.google.rpc.Status(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { case 1: { - message.expression = reader.string(); + message.code = reader.int32(); break; } case 2: { - message.title = reader.string(); + message.message = reader.string(); break; } case 3: { - message.description = reader.string(); - break; - } - case 4: { - message.location = reader.string(); + if (!(message.details && message.details.length)) + message.details = []; + message.details.push($root.google.protobuf.Any.decode(reader, reader.uint32())); break; } default: @@ -64591,130 +72024,140 @@ }; /** - * Decodes an Expr message from the specified reader or buffer, length delimited. + * Decodes a Status message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {google.type.Expr} Expr + * @returns {google.rpc.Status} Status * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Expr.decodeDelimited = function decodeDelimited(reader) { + Status.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies an Expr message. + * Verifies a Status message. * @function verify - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Expr.verify = function verify(message) { + Status.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; - if (message.expression != null && message.hasOwnProperty("expression")) - if (!$util.isString(message.expression)) - return "expression: string expected"; - if (message.title != null && message.hasOwnProperty("title")) - if (!$util.isString(message.title)) - return "title: string expected"; - if (message.description != null && message.hasOwnProperty("description")) - if (!$util.isString(message.description)) - return "description: string expected"; - if (message.location != null && message.hasOwnProperty("location")) - if (!$util.isString(message.location)) - return "location: string expected"; + if (message.code != null && message.hasOwnProperty("code")) + if (!$util.isInteger(message.code)) + return "code: integer expected"; + if (message.message != null && message.hasOwnProperty("message")) + if (!$util.isString(message.message)) + return "message: string expected"; + if (message.details != null && message.hasOwnProperty("details")) { + if (!Array.isArray(message.details)) + return "details: array expected"; + for (var i = 0; i < message.details.length; ++i) { + var error = $root.google.protobuf.Any.verify(message.details[i]); + if (error) + return "details." + error; + } + } return null; }; /** - * Creates an Expr message from a plain object. Also converts values to their respective internal types. + * Creates a Status message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static * @param {Object.} object Plain object - * @returns {google.type.Expr} Expr + * @returns {google.rpc.Status} Status */ - Expr.fromObject = function fromObject(object) { - if (object instanceof $root.google.type.Expr) + Status.fromObject = function fromObject(object) { + if (object instanceof $root.google.rpc.Status) return object; - var message = new $root.google.type.Expr(); - if (object.expression != null) - message.expression = String(object.expression); - if (object.title != null) - message.title = String(object.title); - if (object.description != null) - message.description = String(object.description); - if (object.location != null) - message.location = String(object.location); + var message = new $root.google.rpc.Status(); + if (object.code != null) + message.code = object.code | 0; + if (object.message != null) + message.message = String(object.message); + if (object.details) { + if (!Array.isArray(object.details)) + throw TypeError(".google.rpc.Status.details: array expected"); + message.details = []; + for (var i = 0; i < object.details.length; ++i) { + if (typeof object.details[i] !== "object") + throw TypeError(".google.rpc.Status.details: object expected"); + message.details[i] = $root.google.protobuf.Any.fromObject(object.details[i]); + } + } return message; }; /** - * Creates a plain object from an Expr message. Also converts values to other types if specified. + * Creates a plain object from a Status message. Also converts values to other types if specified. * @function toObject - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static - * @param {google.type.Expr} message Expr + * @param {google.rpc.Status} message Status * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Expr.toObject = function toObject(message, options) { + Status.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; + if (options.arrays || options.defaults) + object.details = []; if (options.defaults) { - object.expression = ""; - object.title = ""; - object.description = ""; - object.location = ""; + object.code = 0; + object.message = ""; + } + if (message.code != null && message.hasOwnProperty("code")) + object.code = message.code; + if (message.message != null && message.hasOwnProperty("message")) + object.message = message.message; + if (message.details && message.details.length) { + object.details = []; + for (var j = 0; j < message.details.length; ++j) + object.details[j] = $root.google.protobuf.Any.toObject(message.details[j], options); } - if (message.expression != null && message.hasOwnProperty("expression")) - object.expression = message.expression; - if (message.title != null && message.hasOwnProperty("title")) - object.title = message.title; - if (message.description != null && message.hasOwnProperty("description")) - object.description = message.description; - if (message.location != null && message.hasOwnProperty("location")) - object.location = message.location; return object; }; /** - * Converts this Expr to JSON. + * Converts this Status to JSON. * @function toJSON - * @memberof google.type.Expr + * @memberof google.rpc.Status * @instance * @returns {Object.} JSON object */ - Expr.prototype.toJSON = function toJSON() { + Status.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; /** - * Gets the default type url for Expr + * Gets the default type url for Status * @function getTypeUrl - * @memberof google.type.Expr + * @memberof google.rpc.Status * @static * @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com") * @returns {string} The default type url */ - Expr.getTypeUrl = function getTypeUrl(typeUrlPrefix) { + Status.getTypeUrl = function getTypeUrl(typeUrlPrefix) { if (typeUrlPrefix === undefined) { typeUrlPrefix = "type.googleapis.com"; } - return typeUrlPrefix + "/google.type.Expr"; + return typeUrlPrefix + "/google.rpc.Status"; }; - return Expr; + return Status; })(); - return type; + return rpc; })(); return google; diff --git a/packages/google-cloud-datacatalog/protos/protos.json b/packages/google-cloud-datacatalog/protos/protos.json index 09104e69509..b52b51d0eb1 100644 --- a/packages/google-cloud-datacatalog/protos/protos.json +++ b/packages/google-cloud-datacatalog/protos/protos.json @@ -103,7 +103,16 @@ "BIGQUERY": 1, "CLOUD_PUBSUB": 2, "DATAPROC_METASTORE": 3, - "DATAPLEX": 4 + "DATAPLEX": 4, + "CLOUD_SQL": 8, + "LOOKER": 9 + } + }, + "ManagingSystem": { + "values": { + "MANAGING_SYSTEM_UNSPECIFIED": 0, + "MANAGING_SYSTEM_DATAPLEX": 1, + "MANAGING_SYSTEM_OTHER": 2 } }, "DataSource": { @@ -706,6 +715,30 @@ } ] }, + "ReconcileTags": { + "requestType": "ReconcileTagsRequest", + "responseType": "google.longrunning.Operation", + "options": { + "(google.api.http).post": "/v1/{parent=projects/*/locations/*/entryGroups/*/entries/*}/tags:reconcile", + "(google.api.http).body": "*", + "(google.longrunning.operation_info).response_type": "ReconcileTagsResponse", + "(google.longrunning.operation_info).metadata_type": "ReconcileTagsMetadata" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "post": "/v1/{parent=projects/*/locations/*/entryGroups/*/entries/*}/tags:reconcile", + "body": "*" + } + }, + { + "(google.longrunning.operation_info)": { + "response_type": "ReconcileTagsResponse", + "metadata_type": "ReconcileTagsMetadata" + } + } + ] + }, "StarEntry": { "requestType": "StarEntryRequest", "responseType": "StarEntryResponse", @@ -831,6 +864,30 @@ } } ] + }, + "ImportEntries": { + "requestType": "ImportEntriesRequest", + "responseType": "google.longrunning.Operation", + "options": { + "(google.api.http).post": "/v1/{parent=projects/*/locations/*/entryGroups/*}/entries:import", + "(google.api.http).body": "*", + "(google.longrunning.operation_info).response_type": "ImportEntriesResponse", + "(google.longrunning.operation_info).metadata_type": "ImportEntriesMetadata" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "post": "/v1/{parent=projects/*/locations/*/entryGroups/*}/entries:import", + "body": "*" + } + }, + { + "(google.longrunning.operation_info)": { + "response_type": "ImportEntriesResponse", + "metadata_type": "ImportEntriesMetadata" + } + } + ] } } }, @@ -1148,6 +1205,12 @@ "userSpecifiedSystem" ] }, + "systemSpec": { + "oneof": [ + "sqlDatabaseSystemSpec", + "lookerSystemSpec" + ] + }, "typeSpec": { "oneof": [ "gcsFilesetSpec", @@ -1200,6 +1263,14 @@ "type": "string", "id": 18 }, + "sqlDatabaseSystemSpec": { + "type": "SqlDatabaseSystemSpec", + "id": 39 + }, + "lookerSystemSpec": { + "type": "LookerSystemSpec", + "id": 40 + }, "gcsFilesetSpec": { "type": "GcsFilesetSpec", "id": 6 @@ -1291,6 +1362,10 @@ "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } + }, + "databaseViewSpec": { + "type": "DatabaseViewSpec", + "id": 3 } }, "nested": { @@ -1300,6 +1375,39 @@ "NATIVE": 1, "EXTERNAL": 2 } + }, + "DatabaseViewSpec": { + "oneofs": { + "sourceDefinition": { + "oneof": [ + "baseTable", + "sqlQuery" + ] + } + }, + "fields": { + "viewType": { + "type": "ViewType", + "id": 1 + }, + "baseTable": { + "type": "string", + "id": 2 + }, + "sqlQuery": { + "type": "string", + "id": 3 + } + }, + "nested": { + "ViewType": { + "values": { + "VIEW_TYPE_UNSPECIFIED": 0, + "STANDARD_VIEW": 1, + "MATERIALIZED_VIEW": 2 + } + } + } } } }, @@ -1390,6 +1498,50 @@ } } }, + "SqlDatabaseSystemSpec": { + "fields": { + "sqlEngine": { + "type": "string", + "id": 1 + }, + "databaseVersion": { + "type": "string", + "id": 2 + }, + "instanceHost": { + "type": "string", + "id": 3 + } + } + }, + "LookerSystemSpec": { + "fields": { + "parentInstanceId": { + "type": "string", + "id": 1 + }, + "parentInstanceDisplayName": { + "type": "string", + "id": 2 + }, + "parentModelId": { + "type": "string", + "id": 3 + }, + "parentModelDisplayName": { + "type": "string", + "id": 4 + }, + "parentViewId": { + "type": "string", + "id": 5 + }, + "parentViewDisplayName": { + "type": "string", + "id": 6 + } + } + }, "BusinessContext": { "fields": { "entryOverview": { @@ -1720,6 +1872,74 @@ } } }, + "ReconcileTagsRequest": { + "fields": { + "parent": { + "type": "string", + "id": 1, + "options": { + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "datacatalog.googleapis.com/Entry" + } + }, + "tagTemplate": { + "type": "string", + "id": 2, + "options": { + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).type": "datacatalog.googleapis.com/TagTemplate" + } + }, + "forceDeleteMissing": { + "type": "bool", + "id": 3 + }, + "tags": { + "rule": "repeated", + "type": "Tag", + "id": 4 + } + } + }, + "ReconcileTagsResponse": { + "fields": { + "createdTagsCount": { + "type": "int64", + "id": 1 + }, + "updatedTagsCount": { + "type": "int64", + "id": 2 + }, + "deletedTagsCount": { + "type": "int64", + "id": 3 + } + } + }, + "ReconcileTagsMetadata": { + "fields": { + "state": { + "type": "ReconciliationState", + "id": 1 + }, + "errors": { + "keyType": "string", + "type": "google.rpc.Status", + "id": 2 + } + }, + "nested": { + "ReconciliationState": { + "values": { + "RECONCILIATION_STATE_UNSPECIFIED": 0, + "RECONCILIATION_QUEUED": 1, + "RECONCILIATION_IN_PROGRESS": 2, + "RECONCILIATION_DONE": 3 + } + } + } + }, "ListEntriesRequest": { "fields": { "parent": { @@ -1787,6 +2007,83 @@ "UnstarEntryResponse": { "fields": {} }, + "ImportEntriesRequest": { + "oneofs": { + "source": { + "oneof": [ + "gcsBucketPath" + ] + } + }, + "fields": { + "parent": { + "type": "string", + "id": 1, + "options": { + "(google.api.field_behavior)": "REQUIRED", + "(google.api.resource_reference).child_type": "datacatalog.googleapis.com/Entry" + } + }, + "gcsBucketPath": { + "type": "string", + "id": 2 + } + } + }, + "ImportEntriesResponse": { + "oneofs": { + "_upsertedEntriesCount": { + "oneof": [ + "upsertedEntriesCount" + ] + }, + "_deletedEntriesCount": { + "oneof": [ + "deletedEntriesCount" + ] + } + }, + "fields": { + "upsertedEntriesCount": { + "type": "int64", + "id": 5, + "options": { + "proto3_optional": true + } + }, + "deletedEntriesCount": { + "type": "int64", + "id": 6, + "options": { + "proto3_optional": true + } + } + } + }, + "ImportEntriesMetadata": { + "fields": { + "state": { + "type": "ImportState", + "id": 1 + }, + "errors": { + "rule": "repeated", + "type": "google.rpc.Status", + "id": 2 + } + }, + "nested": { + "ImportState": { + "values": { + "IMPORT_STATE_UNSPECIFIED": 0, + "IMPORT_QUEUED": 1, + "IMPORT_IN_PROGRESS": 2, + "IMPORT_DONE": 3, + "IMPORT_OBSOLETE": 4 + } + } + } + }, "ModifyEntryOverviewRequest": { "fields": { "name": { @@ -1838,7 +2135,11 @@ "ROUTINE": 9, "LAKE": 10, "ZONE": 11, - "SERVICE": 14 + "SERVICE": 14, + "DATABASE_SCHEMA": 15, + "DASHBOARD": 16, + "EXPLORE": 17, + "LOOK": 18 } }, "DataplexSpec": { @@ -2055,6 +2356,13 @@ } }, "ColumnSchema": { + "oneofs": { + "systemSpec": { + "oneof": [ + "lookerColumnSpec" + ] + } + }, "fields": { "column": { "type": "string", @@ -2084,6 +2392,27 @@ "(google.api.field_behavior)": "OPTIONAL" } }, + "defaultValue": { + "type": "string", + "id": 8, + "options": { + "(google.api.field_behavior)": "OPTIONAL" + } + }, + "ordinalPosition": { + "type": "int32", + "id": 9, + "options": { + "(google.api.field_behavior)": "OPTIONAL" + } + }, + "highestIndexingType": { + "type": "IndexingType", + "id": 10, + "options": { + "(google.api.field_behavior)": "OPTIONAL" + } + }, "subcolumns": { "rule": "repeated", "type": "ColumnSchema", @@ -2091,6 +2420,48 @@ "options": { "(google.api.field_behavior)": "OPTIONAL" } + }, + "lookerColumnSpec": { + "type": "LookerColumnSpec", + "id": 18 + }, + "gcRule": { + "type": "string", + "id": 11, + "options": { + "(google.api.field_behavior)": "OPTIONAL" + } + } + }, + "nested": { + "IndexingType": { + "values": { + "INDEXING_TYPE_UNSPECIFIED": 0, + "INDEXING_TYPE_NONE": 1, + "INDEXING_TYPE_NON_UNIQUE": 2, + "INDEXING_TYPE_UNIQUE": 3, + "INDEXING_TYPE_PRIMARY_KEY": 4 + } + }, + "LookerColumnSpec": { + "fields": { + "type": { + "type": "LookerColumnType", + "id": 1 + } + }, + "nested": { + "LookerColumnType": { + "values": { + "LOOKER_COLUMN_TYPE_UNSPECIFIED": 0, + "DIMENSION": 1, + "DIMENSION_GROUP": 2, + "FILTER": 3, + "MEASURE": 4, + "PARAMETER": 5 + } + } + } } } }, @@ -2497,7 +2868,32 @@ } } }, + "CommonUsageStats": { + "oneofs": { + "_viewCount": { + "oneof": [ + "viewCount" + ] + } + }, + "fields": { + "viewCount": { + "type": "int64", + "id": 1, + "options": { + "proto3_optional": true + } + } + } + }, "UsageSignal": { + "oneofs": { + "_favoriteCount": { + "oneof": [ + "favoriteCount" + ] + } + }, "fields": { "updateTime": { "type": "google.protobuf.Timestamp", @@ -2510,6 +2906,58 @@ "options": { "(google.api.field_behavior)": "OUTPUT_ONLY" } + }, + "commonUsageWithinTimeRange": { + "keyType": "string", + "type": "CommonUsageStats", + "id": 3 + }, + "favoriteCount": { + "type": "int64", + "id": 4, + "options": { + "proto3_optional": true + } + } + } + }, + "TaggedEntry": { + "oneofs": { + "entry": { + "oneof": [ + "v1Entry" + ] + } + }, + "fields": { + "v1Entry": { + "type": "Entry", + "id": 1 + }, + "presentTags": { + "rule": "repeated", + "type": "Tag", + "id": 2 + }, + "absentTags": { + "rule": "repeated", + "type": "Tag", + "id": 3 + } + } + }, + "DumpItem": { + "oneofs": { + "item": { + "oneof": [ + "taggedEntry" + ] + } + }, + "fields": { + "taggedEntry": { + "type": "TaggedEntry", + "id": 1 } } }, @@ -2823,6 +3271,13 @@ "options": { "(google.api.field_behavior)": "OPTIONAL" } + }, + "service": { + "type": "Service", + "id": 7, + "options": { + "(google.api.field_behavior)": "OUTPUT_ONLY" + } } }, "nested": { @@ -2831,6 +3286,18 @@ "POLICY_TYPE_UNSPECIFIED": 0, "FINE_GRAINED_ACCESS_CONTROL": 1 } + }, + "Service": { + "fields": { + "name": { + "type": "ManagingSystem", + "id": 1 + }, + "identity": { + "type": "string", + "id": 2 + } + } } } }, @@ -2929,6 +3396,10 @@ "pageToken": { "type": "string", "id": 3 + }, + "filter": { + "type": "string", + "id": 4 } } }, @@ -6826,6 +7297,30 @@ } } }, + "Any": { + "fields": { + "type_url": { + "type": "string", + "id": 1 + }, + "value": { + "type": "bytes", + "id": 2 + } + } + }, + "Duration": { + "fields": { + "seconds": { + "type": "int64", + "id": 1 + }, + "nanos": { + "type": "int32", + "id": 2 + } + } + }, "Empty": { "fields": {} } @@ -7156,6 +7651,251 @@ } } } + }, + "longrunning": { + "options": { + "cc_enable_arenas": true, + "csharp_namespace": "Google.LongRunning", + "go_package": "google.golang.org/genproto/googleapis/longrunning;longrunning", + "java_multiple_files": true, + "java_outer_classname": "OperationsProto", + "java_package": "com.google.longrunning", + "php_namespace": "Google\\LongRunning" + }, + "nested": { + "operationInfo": { + "type": "google.longrunning.OperationInfo", + "id": 1049, + "extend": "google.protobuf.MethodOptions" + }, + "Operations": { + "options": { + "(google.api.default_host)": "longrunning.googleapis.com" + }, + "methods": { + "ListOperations": { + "requestType": "ListOperationsRequest", + "responseType": "ListOperationsResponse", + "options": { + "(google.api.http).get": "/v1/{name=operations}", + "(google.api.method_signature)": "name,filter" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "get": "/v1/{name=operations}" + } + }, + { + "(google.api.method_signature)": "name,filter" + } + ] + }, + "GetOperation": { + "requestType": "GetOperationRequest", + "responseType": "Operation", + "options": { + "(google.api.http).get": "/v1/{name=operations/**}", + "(google.api.method_signature)": "name" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "get": "/v1/{name=operations/**}" + } + }, + { + "(google.api.method_signature)": "name" + } + ] + }, + "DeleteOperation": { + "requestType": "DeleteOperationRequest", + "responseType": "google.protobuf.Empty", + "options": { + "(google.api.http).delete": "/v1/{name=operations/**}", + "(google.api.method_signature)": "name" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "delete": "/v1/{name=operations/**}" + } + }, + { + "(google.api.method_signature)": "name" + } + ] + }, + "CancelOperation": { + "requestType": "CancelOperationRequest", + "responseType": "google.protobuf.Empty", + "options": { + "(google.api.http).post": "/v1/{name=operations/**}:cancel", + "(google.api.http).body": "*", + "(google.api.method_signature)": "name" + }, + "parsedOptions": [ + { + "(google.api.http)": { + "post": "/v1/{name=operations/**}:cancel", + "body": "*" + } + }, + { + "(google.api.method_signature)": "name" + } + ] + }, + "WaitOperation": { + "requestType": "WaitOperationRequest", + "responseType": "Operation" + } + } + }, + "Operation": { + "oneofs": { + "result": { + "oneof": [ + "error", + "response" + ] + } + }, + "fields": { + "name": { + "type": "string", + "id": 1 + }, + "metadata": { + "type": "google.protobuf.Any", + "id": 2 + }, + "done": { + "type": "bool", + "id": 3 + }, + "error": { + "type": "google.rpc.Status", + "id": 4 + }, + "response": { + "type": "google.protobuf.Any", + "id": 5 + } + } + }, + "GetOperationRequest": { + "fields": { + "name": { + "type": "string", + "id": 1 + } + } + }, + "ListOperationsRequest": { + "fields": { + "name": { + "type": "string", + "id": 4 + }, + "filter": { + "type": "string", + "id": 1 + }, + "pageSize": { + "type": "int32", + "id": 2 + }, + "pageToken": { + "type": "string", + "id": 3 + } + } + }, + "ListOperationsResponse": { + "fields": { + "operations": { + "rule": "repeated", + "type": "Operation", + "id": 1 + }, + "nextPageToken": { + "type": "string", + "id": 2 + } + } + }, + "CancelOperationRequest": { + "fields": { + "name": { + "type": "string", + "id": 1 + } + } + }, + "DeleteOperationRequest": { + "fields": { + "name": { + "type": "string", + "id": 1 + } + } + }, + "WaitOperationRequest": { + "fields": { + "name": { + "type": "string", + "id": 1 + }, + "timeout": { + "type": "google.protobuf.Duration", + "id": 2 + } + } + }, + "OperationInfo": { + "fields": { + "responseType": { + "type": "string", + "id": 1 + }, + "metadataType": { + "type": "string", + "id": 2 + } + } + } + } + }, + "rpc": { + "options": { + "cc_enable_arenas": true, + "go_package": "google.golang.org/genproto/googleapis/rpc/status;status", + "java_multiple_files": true, + "java_outer_classname": "StatusProto", + "java_package": "com.google.rpc", + "objc_class_prefix": "RPC" + }, + "nested": { + "Status": { + "fields": { + "code": { + "type": "int32", + "id": 1 + }, + "message": { + "type": "string", + "id": 2 + }, + "details": { + "rule": "repeated", + "type": "google.protobuf.Any", + "id": 3 + } + } + } + } } } } diff --git a/packages/google-cloud-datacatalog/samples/README.md b/packages/google-cloud-datacatalog/samples/README.md index f383764dc4b..c55a995ec6c 100644 --- a/packages/google-cloud-datacatalog/samples/README.md +++ b/packages/google-cloud-datacatalog/samples/README.md @@ -26,12 +26,14 @@ * [Data_catalog.get_entry_group](#data_catalog.get_entry_group) * [Data_catalog.get_iam_policy](#data_catalog.get_iam_policy) * [Data_catalog.get_tag_template](#data_catalog.get_tag_template) + * [Data_catalog.import_entries](#data_catalog.import_entries) * [Data_catalog.list_entries](#data_catalog.list_entries) * [Data_catalog.list_entry_groups](#data_catalog.list_entry_groups) * [Data_catalog.list_tags](#data_catalog.list_tags) * [Data_catalog.lookup_entry](#data_catalog.lookup_entry) * [Data_catalog.modify_entry_contacts](#data_catalog.modify_entry_contacts) * [Data_catalog.modify_entry_overview](#data_catalog.modify_entry_overview) + * [Data_catalog.reconcile_tags](#data_catalog.reconcile_tags) * [Data_catalog.rename_tag_template_field](#data_catalog.rename_tag_template_field) * [Data_catalog.rename_tag_template_field_enum_value](#data_catalog.rename_tag_template_field_enum_value) * [Data_catalog.search_catalog](#data_catalog.search_catalog) @@ -358,6 +360,23 @@ __Usage:__ +### Data_catalog.import_entries + +View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js,samples/README.md) + +__Usage:__ + + +`node packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js` + + +----- + + + + ### Data_catalog.list_entries View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.list_entries.js). @@ -460,6 +479,23 @@ __Usage:__ +### Data_catalog.reconcile_tags + +View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js,samples/README.md) + +__Usage:__ + + +`node packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js` + + +----- + + + + ### Data_catalog.rename_tag_template_field View the [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js). diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.create_entry_group.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.create_entry_group.js index 172086fd62d..fe61648712e 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.create_entry_group.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.create_entry_group.js @@ -29,7 +29,8 @@ function main(parent, entryGroupId) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. The names of the project and location that the new entry group belongs to. + * Required. The names of the project and location that the new entry group + * belongs to. * Note: The entry group itself and its child resources might not be * stored in the location specified in its name. */ diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js new file mode 100644 index 00000000000..2610373f9af --- /dev/null +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.import_entries.js @@ -0,0 +1,66 @@ +// Copyright 2023 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 +// +// https://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. +// +// ** This file is automatically generated by gapic-generator-typescript. ** +// ** https://github.com/googleapis/gapic-generator-typescript ** +// ** All changes to this file may be overwritten. ** + + + +'use strict'; + +function main(parent) { + // [START datacatalog_v1_generated_DataCatalog_ImportEntries_async] + /** + * This snippet has been automatically generated and should be regarded as a code template only. + * It will require modifications to work. + * It may require correct/in-range values for request initialization. + * TODO(developer): Uncomment these variables before running the sample. + */ + /** + * Required. Target entry group for ingested entries. + */ + // const parent = 'abc123' + /** + * Path to a Cloud Storage bucket that contains a dump ready for ingestion. + */ + // const gcsBucketPath = 'abc123' + + // Imports the Datacatalog library + const {DataCatalogClient} = require('@google-cloud/datacatalog').v1; + + // Instantiates a client + const datacatalogClient = new DataCatalogClient(); + + async function callImportEntries() { + // Construct request + const request = { + parent, + }; + + // Run request + const [operation] = await datacatalogClient.importEntries(request); + const [response] = await operation.promise(); + console.log(response); + } + + callImportEntries(); + // [END datacatalog_v1_generated_DataCatalog_ImportEntries_async] +} + +process.on('unhandledRejection', err => { + console.error(err.message); + process.exitCode = 1; +}); +main(...process.argv.slice(2)); diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js new file mode 100644 index 00000000000..46d6cff7e6d --- /dev/null +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.reconcile_tags.js @@ -0,0 +1,80 @@ +// Copyright 2023 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 +// +// https://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. +// +// ** This file is automatically generated by gapic-generator-typescript. ** +// ** https://github.com/googleapis/gapic-generator-typescript ** +// ** All changes to this file may be overwritten. ** + + + +'use strict'; + +function main(parent, tagTemplate) { + // [START datacatalog_v1_generated_DataCatalog_ReconcileTags_async] + /** + * This snippet has been automatically generated and should be regarded as a code template only. + * It will require modifications to work. + * It may require correct/in-range values for request initialization. + * TODO(developer): Uncomment these variables before running the sample. + */ + /** + * Required. Name of Entry google.cloud.datacatalog.v1.Entry to be tagged. + */ + // const parent = 'abc123' + /** + * Required. The name of the tag template, which is used for reconciliation. + */ + // const tagTemplate = 'abc123' + /** + * If set to `true`, deletes entry tags related to a tag template + * not listed in the tags source from an entry. If set to `false`, + * unlisted tags are retained. + */ + // const forceDeleteMissing = true + /** + * A list of tags to apply to an entry. A tag can specify a + * tag template, which must be the template specified in the + * `ReconcileTagsRequest`. + * The sole entry and each of its columns must be mentioned at most once. + */ + // const tags = 1234 + + // Imports the Datacatalog library + const {DataCatalogClient} = require('@google-cloud/datacatalog').v1; + + // Instantiates a client + const datacatalogClient = new DataCatalogClient(); + + async function callReconcileTags() { + // Construct request + const request = { + parent, + tagTemplate, + }; + + // Run request + const [operation] = await datacatalogClient.reconcileTags(request); + const [response] = await operation.promise(); + console.log(response); + } + + callReconcileTags(); + // [END datacatalog_v1_generated_DataCatalog_ReconcileTags_async] +} + +process.on('unhandledRejection', err => { + console.error(err.message); + process.exitCode = 1; +}); +main(...process.argv.slice(2)); diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js index e431706834d..52472bdba87 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field.js @@ -33,7 +33,8 @@ function main(name, newTagTemplateFieldId) { */ // const name = 'abc123' /** - * Required. The new ID of this tag template field. For example, `my_new_field`. + * Required. The new ID of this tag template field. For example, + * `my_new_field`. */ // const newTagTemplateFieldId = 'abc123' diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js index 1973e8d2006..74bada70b74 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.rename_tag_template_field_enum_value.js @@ -33,7 +33,8 @@ function main(name, newEnumValueDisplayName) { */ // const name = 'abc123' /** - * Required. The new display name of the enum value. For example, `my_new_enum_value`. + * Required. The new display name of the enum value. For example, + * `my_new_enum_value`. */ // const newEnumValueDisplayName = 'abc123' diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js index e2bd764d1fd..1f196fab0f1 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.search_catalog.js @@ -36,9 +36,8 @@ function main(scope) { */ // const scope = {} /** - * Optional. The query string with a minimum of 3 characters and specific syntax. - * For more information, see - * Data Catalog search + * Optional. The query string with a minimum of 3 characters and specific + * syntax. For more information, see Data Catalog search * syntax (https://cloud.google.com/data-catalog/docs/how-to/search-reference). * An empty query string returns all data assets (in the specified scope) * that you have access to. @@ -56,9 +55,10 @@ function main(scope) { */ // const pageSize = 1234 /** - * Optional. Pagination token that, if specified, returns the next page of search - * results. If empty, returns the first page. - * This token is returned in the SearchCatalogResponse.next_page_token google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token + * Optional. Pagination token that, if specified, returns the next page of + * search results. If empty, returns the first page. + * This token is returned in the + * SearchCatalogResponse.next_page_token google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token * field of the response to a previous * SearchCatalogRequest google.cloud.datacatalog.v1.DataCatalog.SearchCatalog * call. diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.update_tag_template_field.js b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.update_tag_template_field.js index 3a6410817b9..e0d7921daeb 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.update_tag_template_field.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/data_catalog.update_tag_template_field.js @@ -37,8 +37,8 @@ function main(name, tagTemplateField) { */ // const tagTemplateField = {} /** - * Optional. Names of fields whose values to overwrite on an individual field of a tag - * template. The following fields are modifiable: + * Optional. Names of fields whose values to overwrite on an individual field + * of a tag template. The following fields are modifiable: * * `display_name` * * `type.enum_type` * * `is_required` diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager.list_taxonomies.js b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager.list_taxonomies.js index 71c86e8c5fe..27059ee7a89 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager.list_taxonomies.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager.list_taxonomies.js @@ -43,6 +43,11 @@ function main(parent) { * The token is returned in the response to a previous list request. */ // const pageToken = 'abc123' + /** + * Supported field for filter is 'service' and value is 'dataplex'. + * Eg: service=dataplex. + */ + // const filter = 'abc123' // Imports the Datacatalog library const {PolicyTagManagerClient} = require('@google-cloud/datacatalog').v1; diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.export_taxonomies.js b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.export_taxonomies.js index 8fe14f405e0..250d83d699f 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.export_taxonomies.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.export_taxonomies.js @@ -29,7 +29,8 @@ function main(parent, taxonomies) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. Resource name of the project that the exported taxonomies belong to. + * Required. Resource name of the project that the exported taxonomies belong + * to. */ // const parent = 'abc123' /** diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.import_taxonomies.js b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.import_taxonomies.js index 1f38fcfe42a..bfba7f87028 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.import_taxonomies.js +++ b/packages/google-cloud-datacatalog/samples/generated/v1/policy_tag_manager_serialization.import_taxonomies.js @@ -29,7 +29,8 @@ function main(parent) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. Resource name of project that the imported taxonomies will belong to. + * Required. Resource name of project that the imported taxonomies will belong + * to. */ // const parent = 'abc123' /** diff --git a/packages/google-cloud-datacatalog/samples/generated/v1/snippet_metadata.google.cloud.datacatalog.v1.json b/packages/google-cloud-datacatalog/samples/generated/v1/snippet_metadata.google.cloud.datacatalog.v1.json index f2f9262468f..4d05ccd6fbb 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1/snippet_metadata.google.cloud.datacatalog.v1.json +++ b/packages/google-cloud-datacatalog/samples/generated/v1/snippet_metadata.google.cloud.datacatalog.v1.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-datacatalog", - "version": "3.2.0", + "version": "3.2.1", "language": "TYPESCRIPT", "apis": [ { @@ -78,7 +78,7 @@ "segments": [ { "start": 25, - "end": 67, + "end": 68, "type": "FULL" } ], @@ -938,7 +938,7 @@ "segments": [ { "start": 25, - "end": 58, + "end": 59, "type": "FULL" } ], @@ -982,7 +982,7 @@ "segments": [ { "start": 25, - "end": 58, + "end": 59, "type": "FULL" } ], @@ -1235,6 +1235,58 @@ } } }, + { + "regionTag": "datacatalog_v1_generated_DataCatalog_ReconcileTags_async", + "title": "DataCatalog reconcileTags Sample", + "origin": "API_DEFINITION", + "description": " `ReconcileTags` creates or updates a list of tags on the entry. If the [ReconcileTagsRequest.force_delete_missing][google.cloud.datacatalog.v1.ReconcileTagsRequest.force_delete_missing] parameter is set, the operation deletes tags not included in the input tag list. `ReconcileTags` returns a [long-running operation] [google.longrunning.Operation] resource that can be queried with [Operations.GetOperation][google.longrunning.Operations.GetOperation] to return [ReconcileTagsMetadata] [google.cloud.datacatalog.v1.ReconcileTagsMetadata] and a [ReconcileTagsResponse] [google.cloud.datacatalog.v1.ReconcileTagsResponse] message.", + "canonical": true, + "file": "data_catalog.reconcile_tags.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 72, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ReconcileTags", + "fullName": "google.cloud.datacatalog.v1.DataCatalog.ReconcileTags", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "tag_template", + "type": "TYPE_STRING" + }, + { + "name": "force_delete_missing", + "type": "TYPE_BOOL" + }, + { + "name": "tags", + "type": "TYPE_MESSAGE[]" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "DataCatalogClient", + "fullName": "google.cloud.datacatalog.v1.DataCatalogClient" + }, + "method": { + "shortName": "ReconcileTags", + "fullName": "google.cloud.datacatalog.v1.DataCatalog.ReconcileTags", + "service": { + "shortName": "DataCatalog", + "fullName": "google.cloud.datacatalog.v1.DataCatalog" + } + } + } + }, { "regionTag": "datacatalog_v1_generated_DataCatalog_StarEntry_async", "title": "DataCatalog starEntry Sample", @@ -1451,6 +1503,50 @@ } } }, + { + "regionTag": "datacatalog_v1_generated_DataCatalog_ImportEntries_async", + "title": "DataCatalog importEntries Sample", + "origin": "API_DEFINITION", + "description": " Imports entries from a source, such as data previously dumped into a Cloud Storage bucket, into Data Catalog. Import of entries is a sync operation that reconciles the state of the third-party system with the Data Catalog. `ImportEntries` accepts source data snapshots of a third-party system. Snapshot should be delivered as a .wire or base65-encoded .txt file containing a sequence of Protocol Buffer messages of [DumpItem][google.cloud.datacatalog.v1.DumpItem] type. `ImportEntries` returns a [long-running operation] [google.longrunning.Operation] resource that can be queried with [Operations.GetOperation][google.longrunning.Operations.GetOperation] to return [ImportEntriesMetadata][google.cloud.datacatalog.v1.ImportEntriesMetadata] and an [ImportEntriesResponse][google.cloud.datacatalog.v1.ImportEntriesResponse] message.", + "canonical": true, + "file": "data_catalog.import_entries.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ImportEntries", + "fullName": "google.cloud.datacatalog.v1.DataCatalog.ImportEntries", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "gcs_bucket_path", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "DataCatalogClient", + "fullName": "google.cloud.datacatalog.v1.DataCatalogClient" + }, + "method": { + "shortName": "ImportEntries", + "fullName": "google.cloud.datacatalog.v1.DataCatalog.ImportEntries", + "service": { + "shortName": "DataCatalog", + "fullName": "google.cloud.datacatalog.v1.DataCatalog" + } + } + } + }, { "regionTag": "datacatalog_v1_generated_PolicyTagManager_CreateTaxonomy_async", "title": "DataCatalog createTaxonomy Sample", @@ -1590,7 +1686,7 @@ "segments": [ { "start": 25, - "end": 66, + "end": 71, "type": "FULL" } ], @@ -1610,6 +1706,10 @@ { "name": "page_token", "type": "TYPE_STRING" + }, + { + "name": "filter", + "type": "TYPE_STRING" } ], "resultType": ".google.cloud.datacatalog.v1.ListTaxonomiesResponse", @@ -2074,7 +2174,7 @@ "segments": [ { "start": 25, - "end": 61, + "end": 62, "type": "FULL" } ], @@ -2122,7 +2222,7 @@ "segments": [ { "start": 25, - "end": 63, + "end": 64, "type": "FULL" } ], diff --git a/packages/google-cloud-datacatalog/samples/generated/v1beta1/snippet_metadata.google.cloud.datacatalog.v1beta1.json b/packages/google-cloud-datacatalog/samples/generated/v1beta1/snippet_metadata.google.cloud.datacatalog.v1beta1.json index b4455b62b29..f7cf20f2182 100644 --- a/packages/google-cloud-datacatalog/samples/generated/v1beta1/snippet_metadata.google.cloud.datacatalog.v1beta1.json +++ b/packages/google-cloud-datacatalog/samples/generated/v1beta1/snippet_metadata.google.cloud.datacatalog.v1beta1.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-datacatalog", - "version": "3.2.0", + "version": "3.2.1", "language": "TYPESCRIPT", "apis": [ { diff --git a/packages/google-cloud-datacatalog/src/v1/data_catalog_client.ts b/packages/google-cloud-datacatalog/src/v1/data_catalog_client.ts index 27ece16c23c..41cfa8f0261 100644 --- a/packages/google-cloud-datacatalog/src/v1/data_catalog_client.ts +++ b/packages/google-cloud-datacatalog/src/v1/data_catalog_client.ts @@ -23,6 +23,8 @@ import type { CallOptions, Descriptors, ClientOptions, + GrpcClientOptions, + LROperation, PaginationCallback, GaxCall, } from 'google-gax'; @@ -61,6 +63,7 @@ export class DataCatalogClient { warn: (code: string, message: string, warnType?: string) => void; innerApiCalls: {[name: string]: Function}; pathTemplates: {[name: string]: gax.PathTemplate}; + operationsClient: gax.OperationsClient; dataCatalogStub?: Promise<{[name: string]: Function}>; /** @@ -234,6 +237,64 @@ export class DataCatalogClient { ), }; + const protoFilesRoot = this._gaxModule.protobuf.Root.fromJSON(jsonProtos); + // This API contains "long-running operations", which return a + // an Operation object that allows for tracking of the operation, + // rather than holding a request open. + const lroOptions: GrpcClientOptions = { + auth: this.auth, + grpc: 'grpc' in this._gaxGrpc ? this._gaxGrpc.grpc : undefined, + }; + if (opts.fallback === 'rest') { + lroOptions.protoJson = protoFilesRoot; + lroOptions.httpRules = [ + { + selector: 'google.longrunning.Operations.CancelOperation', + post: '/v1/{name=projects/*/locations/*/operations/*}:cancel', + }, + { + selector: 'google.longrunning.Operations.DeleteOperation', + delete: '/v1/{name=projects/*/locations/*/operations/*}', + }, + { + selector: 'google.longrunning.Operations.GetOperation', + get: '/v1/{name=projects/*/locations/*/operations/*}', + }, + { + selector: 'google.longrunning.Operations.ListOperations', + get: '/v1/{name=projects/*/locations/*}/operations', + }, + ]; + } + this.operationsClient = this._gaxModule + .lro(lroOptions) + .operationsClient(opts); + const reconcileTagsResponse = protoFilesRoot.lookup( + '.google.cloud.datacatalog.v1.ReconcileTagsResponse' + ) as gax.protobuf.Type; + const reconcileTagsMetadata = protoFilesRoot.lookup( + '.google.cloud.datacatalog.v1.ReconcileTagsMetadata' + ) as gax.protobuf.Type; + const importEntriesResponse = protoFilesRoot.lookup( + '.google.cloud.datacatalog.v1.ImportEntriesResponse' + ) as gax.protobuf.Type; + const importEntriesMetadata = protoFilesRoot.lookup( + '.google.cloud.datacatalog.v1.ImportEntriesMetadata' + ) as gax.protobuf.Type; + + this.descriptors.longrunning = { + reconcileTags: new this._gaxModule.LongrunningDescriptor( + this.operationsClient, + reconcileTagsResponse.decode.bind(reconcileTagsResponse), + reconcileTagsMetadata.decode.bind(reconcileTagsMetadata) + ), + importEntries: new this._gaxModule.LongrunningDescriptor( + this.operationsClient, + importEntriesResponse.decode.bind(importEntriesResponse), + importEntriesMetadata.decode.bind(importEntriesMetadata) + ), + }; + // Put together the default options sent with requests. this._defaults = this._gaxGrpc.constructSettings( 'google.cloud.datacatalog.v1.DataCatalog', @@ -311,11 +372,13 @@ export class DataCatalogClient { 'updateTag', 'deleteTag', 'listTags', + 'reconcileTags', 'starEntry', 'unstarEntry', 'setIamPolicy', 'getIamPolicy', 'testIamPermissions', + 'importEntries', ]; for (const methodName of dataCatalogStubMethods) { const callPromise = this.dataCatalogStub.then( @@ -332,7 +395,10 @@ export class DataCatalogClient { } ); - const descriptor = this.descriptors.page[methodName] || undefined; + const descriptor = + this.descriptors.page[methodName] || + this.descriptors.longrunning[methodName] || + undefined; const apiCall = this._gaxModule.createApiCall( callPromise, this._defaults[methodName], @@ -431,7 +497,8 @@ export class DataCatalogClient { * @param {Object} request * The request object that will be sent. * @param {string} request.parent - * Required. The names of the project and location that the new entry group belongs to. + * Required. The names of the project and location that the new entry group + * belongs to. * * Note: The entry group itself and its child resources might not be * stored in the location specified in its name. @@ -2089,8 +2156,8 @@ export class DataCatalogClient { * @param {google.cloud.datacatalog.v1.TagTemplateField} request.tagTemplateField * Required. The template to update. * @param {google.protobuf.FieldMask} [request.updateMask] - * Optional. Names of fields whose values to overwrite on an individual field of a tag - * template. The following fields are modifiable: + * Optional. Names of fields whose values to overwrite on an individual field + * of a tag template. The following fields are modifiable: * * * `display_name` * * `type.enum_type` @@ -2211,7 +2278,8 @@ export class DataCatalogClient { * @param {string} request.name * Required. The name of the tag template field. * @param {string} request.newTagTemplateFieldId - * Required. The new ID of this tag template field. For example, `my_new_field`. + * Required. The new ID of this tag template field. For example, + * `my_new_field`. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. @@ -2316,7 +2384,8 @@ export class DataCatalogClient { * @param {string} request.name * Required. The name of the enum field value. * @param {string} request.newEnumValueDisplayName - * Required. The new display name of the enum value. For example, `my_new_enum_value`. + * Required. The new display name of the enum value. For example, + * `my_new_enum_value`. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. @@ -3295,6 +3364,324 @@ export class DataCatalogClient { return this.innerApiCalls.testIamPermissions(request, options, callback); } + /** + * `ReconcileTags` creates or updates a list of tags on the entry. + * If the + * {@link google.cloud.datacatalog.v1.ReconcileTagsRequest.force_delete_missing|ReconcileTagsRequest.force_delete_missing} + * parameter is set, the operation deletes tags not included in the input tag + * list. + * + * `ReconcileTags` returns a [long-running operation] + * [google.longrunning.Operation] resource that can be queried with + * {@link google.longrunning.Operations.GetOperation|Operations.GetOperation} + * to return [ReconcileTagsMetadata] + * [google.cloud.datacatalog.v1.ReconcileTagsMetadata] and + * a [ReconcileTagsResponse] + * [google.cloud.datacatalog.v1.ReconcileTagsResponse] message. + * + * @param {Object} request + * The request object that will be sent. + * @param {string} request.parent + * Required. Name of {@link google.cloud.datacatalog.v1.Entry|Entry} to be tagged. + * @param {string} request.tagTemplate + * Required. The name of the tag template, which is used for reconciliation. + * @param {boolean} request.forceDeleteMissing + * If set to `true`, deletes entry tags related to a tag template + * not listed in the tags source from an entry. If set to `false`, + * unlisted tags are retained. + * @param {number[]} request.tags + * A list of tags to apply to an entry. A tag can specify a + * tag template, which must be the template specified in the + * `ReconcileTagsRequest`. + * The sole entry and each of its columns must be mentioned at most once. + * @param {object} [options] + * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. + * @returns {Promise} - The promise which resolves to an array. + * The first element of the array is an object representing + * a long running operation. Its `promise()` method returns a promise + * you can `await` for. + * Please see the + * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) + * for more details and examples. + * @example include:samples/generated/v1/data_catalog.reconcile_tags.js + * region_tag:datacatalog_v1_generated_DataCatalog_ReconcileTags_async + */ + reconcileTags( + request?: protos.google.cloud.datacatalog.v1.IReconcileTagsRequest, + options?: CallOptions + ): Promise< + [ + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | undefined, + {} | undefined + ] + >; + reconcileTags( + request: protos.google.cloud.datacatalog.v1.IReconcileTagsRequest, + options: CallOptions, + callback: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): void; + reconcileTags( + request: protos.google.cloud.datacatalog.v1.IReconcileTagsRequest, + callback: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): void; + reconcileTags( + request?: protos.google.cloud.datacatalog.v1.IReconcileTagsRequest, + optionsOrCallback?: + | CallOptions + | Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + >, + callback?: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): Promise< + [ + LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >, + protos.google.longrunning.IOperation | undefined, + {} | undefined + ] + > | void { + request = request || {}; + let options: CallOptions; + if (typeof optionsOrCallback === 'function' && callback === undefined) { + callback = optionsOrCallback; + options = {}; + } else { + options = optionsOrCallback as CallOptions; + } + options = options || {}; + options.otherArgs = options.otherArgs || {}; + options.otherArgs.headers = options.otherArgs.headers || {}; + options.otherArgs.headers['x-goog-request-params'] = + this._gaxModule.routingHeader.fromParams({ + parent: request.parent ?? '', + }); + this.initialize(); + return this.innerApiCalls.reconcileTags(request, options, callback); + } + /** + * Check the status of the long running operation returned by `reconcileTags()`. + * @param {String} name + * The operation name that will be passed. + * @returns {Promise} - The promise which resolves to an object. + * The decoded operation object has result and metadata field to get information from. + * Please see the + * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) + * for more details and examples. + * @example include:samples/generated/v1/data_catalog.reconcile_tags.js + * region_tag:datacatalog_v1_generated_DataCatalog_ReconcileTags_async + */ + async checkReconcileTagsProgress( + name: string + ): Promise< + LROperation< + protos.google.cloud.datacatalog.v1.ReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.ReconcileTagsMetadata + > + > { + const request = + new this._gaxModule.operationsProtos.google.longrunning.GetOperationRequest( + {name} + ); + const [operation] = await this.operationsClient.getOperation(request); + const decodeOperation = new this._gaxModule.Operation( + operation, + this.descriptors.longrunning.reconcileTags, + this._gaxModule.createDefaultBackoffSettings() + ); + return decodeOperation as LROperation< + protos.google.cloud.datacatalog.v1.ReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.ReconcileTagsMetadata + >; + } + /** + * Imports entries from a source, such as data previously dumped into a + * Cloud Storage bucket, into Data Catalog. Import of entries + * is a sync operation that reconciles the state of the third-party system + * with the Data Catalog. + * + * `ImportEntries` accepts source data snapshots of a third-party system. + * Snapshot should be delivered as a .wire or base65-encoded .txt file + * containing a sequence of Protocol Buffer messages of + * {@link google.cloud.datacatalog.v1.DumpItem|DumpItem} type. + * + * `ImportEntries` returns a [long-running operation] + * [google.longrunning.Operation] resource that can be queried with + * {@link google.longrunning.Operations.GetOperation|Operations.GetOperation} + * to return + * {@link google.cloud.datacatalog.v1.ImportEntriesMetadata|ImportEntriesMetadata} + * and an + * {@link google.cloud.datacatalog.v1.ImportEntriesResponse|ImportEntriesResponse} + * message. + * + * @param {Object} request + * The request object that will be sent. + * @param {string} request.parent + * Required. Target entry group for ingested entries. + * @param {string} request.gcsBucketPath + * Path to a Cloud Storage bucket that contains a dump ready for ingestion. + * @param {object} [options] + * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. + * @returns {Promise} - The promise which resolves to an array. + * The first element of the array is an object representing + * a long running operation. Its `promise()` method returns a promise + * you can `await` for. + * Please see the + * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) + * for more details and examples. + * @example include:samples/generated/v1/data_catalog.import_entries.js + * region_tag:datacatalog_v1_generated_DataCatalog_ImportEntries_async + */ + importEntries( + request?: protos.google.cloud.datacatalog.v1.IImportEntriesRequest, + options?: CallOptions + ): Promise< + [ + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | undefined, + {} | undefined + ] + >; + importEntries( + request: protos.google.cloud.datacatalog.v1.IImportEntriesRequest, + options: CallOptions, + callback: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): void; + importEntries( + request: protos.google.cloud.datacatalog.v1.IImportEntriesRequest, + callback: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): void; + importEntries( + request?: protos.google.cloud.datacatalog.v1.IImportEntriesRequest, + optionsOrCallback?: + | CallOptions + | Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + >, + callback?: Callback< + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | null | undefined, + {} | null | undefined + > + ): Promise< + [ + LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >, + protos.google.longrunning.IOperation | undefined, + {} | undefined + ] + > | void { + request = request || {}; + let options: CallOptions; + if (typeof optionsOrCallback === 'function' && callback === undefined) { + callback = optionsOrCallback; + options = {}; + } else { + options = optionsOrCallback as CallOptions; + } + options = options || {}; + options.otherArgs = options.otherArgs || {}; + options.otherArgs.headers = options.otherArgs.headers || {}; + options.otherArgs.headers['x-goog-request-params'] = + this._gaxModule.routingHeader.fromParams({ + parent: request.parent ?? '', + }); + this.initialize(); + return this.innerApiCalls.importEntries(request, options, callback); + } + /** + * Check the status of the long running operation returned by `importEntries()`. + * @param {String} name + * The operation name that will be passed. + * @returns {Promise} - The promise which resolves to an object. + * The decoded operation object has result and metadata field to get information from. + * Please see the + * [documentation](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#long-running-operations) + * for more details and examples. + * @example include:samples/generated/v1/data_catalog.import_entries.js + * region_tag:datacatalog_v1_generated_DataCatalog_ImportEntries_async + */ + async checkImportEntriesProgress( + name: string + ): Promise< + LROperation< + protos.google.cloud.datacatalog.v1.ImportEntriesResponse, + protos.google.cloud.datacatalog.v1.ImportEntriesMetadata + > + > { + const request = + new this._gaxModule.operationsProtos.google.longrunning.GetOperationRequest( + {name} + ); + const [operation] = await this.operationsClient.getOperation(request); + const decodeOperation = new this._gaxModule.Operation( + operation, + this.descriptors.longrunning.importEntries, + this._gaxModule.createDefaultBackoffSettings() + ); + return decodeOperation as LROperation< + protos.google.cloud.datacatalog.v1.ImportEntriesResponse, + protos.google.cloud.datacatalog.v1.ImportEntriesMetadata + >; + } /** * Searches Data Catalog for multiple resources like entries and tags that * match a query. @@ -3321,9 +3708,8 @@ export class DataCatalogClient { * empty AND `include_gcp_public_datasets` is set to `false`. In this case, * the request returns an error. * @param {string} [request.query] - * Optional. The query string with a minimum of 3 characters and specific syntax. - * For more information, see - * [Data Catalog search + * Optional. The query string with a minimum of 3 characters and specific + * syntax. For more information, see [Data Catalog search * syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference). * * An empty query string returns all data assets (in the specified scope) @@ -3341,10 +3727,11 @@ export class DataCatalogClient { * The maximum number is 1000. If exceeded, throws an "invalid argument" * exception. * @param {string} [request.pageToken] - * Optional. Pagination token that, if specified, returns the next page of search - * results. If empty, returns the first page. + * Optional. Pagination token that, if specified, returns the next page of + * search results. If empty, returns the first page. * - * This token is returned in the {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} + * This token is returned in the + * {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} * field of the response to a previous * {@link google.cloud.datacatalog.v1.DataCatalog.SearchCatalog|SearchCatalogRequest} * call. @@ -3453,9 +3840,8 @@ export class DataCatalogClient { * empty AND `include_gcp_public_datasets` is set to `false`. In this case, * the request returns an error. * @param {string} [request.query] - * Optional. The query string with a minimum of 3 characters and specific syntax. - * For more information, see - * [Data Catalog search + * Optional. The query string with a minimum of 3 characters and specific + * syntax. For more information, see [Data Catalog search * syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference). * * An empty query string returns all data assets (in the specified scope) @@ -3473,10 +3859,11 @@ export class DataCatalogClient { * The maximum number is 1000. If exceeded, throws an "invalid argument" * exception. * @param {string} [request.pageToken] - * Optional. Pagination token that, if specified, returns the next page of search - * results. If empty, returns the first page. + * Optional. Pagination token that, if specified, returns the next page of + * search results. If empty, returns the first page. * - * This token is returned in the {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} + * This token is returned in the + * {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} * field of the response to a previous * {@link google.cloud.datacatalog.v1.DataCatalog.SearchCatalog|SearchCatalogRequest} * call. @@ -3533,9 +3920,8 @@ export class DataCatalogClient { * empty AND `include_gcp_public_datasets` is set to `false`. In this case, * the request returns an error. * @param {string} [request.query] - * Optional. The query string with a minimum of 3 characters and specific syntax. - * For more information, see - * [Data Catalog search + * Optional. The query string with a minimum of 3 characters and specific + * syntax. For more information, see [Data Catalog search * syntax](https://cloud.google.com/data-catalog/docs/how-to/search-reference). * * An empty query string returns all data assets (in the specified scope) @@ -3553,10 +3939,11 @@ export class DataCatalogClient { * The maximum number is 1000. If exceeded, throws an "invalid argument" * exception. * @param {string} [request.pageToken] - * Optional. Pagination token that, if specified, returns the next page of search - * results. If empty, returns the first page. + * Optional. Pagination token that, if specified, returns the next page of + * search results. If empty, returns the first page. * - * This token is returned in the {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} + * This token is returned in the + * {@link google.cloud.datacatalog.v1.SearchCatalogResponse.next_page_token|SearchCatalogResponse.next_page_token} * field of the response to a previous * {@link google.cloud.datacatalog.v1.DataCatalog.SearchCatalog|SearchCatalogRequest} * call. @@ -4852,6 +5239,7 @@ export class DataCatalogClient { return this.dataCatalogStub.then(stub => { this._terminated = true; stub.close(); + this.operationsClient.close(); }); } return Promise.resolve(); diff --git a/packages/google-cloud-datacatalog/src/v1/data_catalog_client_config.json b/packages/google-cloud-datacatalog/src/v1/data_catalog_client_config.json index c1f90ae8198..89de713f1a9 100644 --- a/packages/google-cloud-datacatalog/src/v1/data_catalog_client_config.json +++ b/packages/google-cloud-datacatalog/src/v1/data_catalog_client_config.json @@ -158,6 +158,11 @@ "retry_codes_name": "unavailable", "retry_params_name": "default" }, + "ReconcileTags": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, "StarEntry": { "timeout_millis": 60000, "retry_codes_name": "non_idempotent", @@ -182,6 +187,11 @@ "timeout_millis": 60000, "retry_codes_name": "non_idempotent", "retry_params_name": "default" + }, + "ImportEntries": { + "timeout_millis": 60000, + "retry_codes_name": "unavailable", + "retry_params_name": "default" } } } diff --git a/packages/google-cloud-datacatalog/src/v1/data_catalog_proto_list.json b/packages/google-cloud-datacatalog/src/v1/data_catalog_proto_list.json index c86ea1d1950..e2d2eeac32a 100644 --- a/packages/google-cloud-datacatalog/src/v1/data_catalog_proto_list.json +++ b/packages/google-cloud-datacatalog/src/v1/data_catalog_proto_list.json @@ -4,6 +4,7 @@ "../../protos/google/cloud/datacatalog/v1/data_source.proto", "../../protos/google/cloud/datacatalog/v1/datacatalog.proto", "../../protos/google/cloud/datacatalog/v1/dataplex_spec.proto", + "../../protos/google/cloud/datacatalog/v1/dump_content.proto", "../../protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto", "../../protos/google/cloud/datacatalog/v1/physical_schema.proto", "../../protos/google/cloud/datacatalog/v1/policytagmanager.proto", diff --git a/packages/google-cloud-datacatalog/src/v1/gapic_metadata.json b/packages/google-cloud-datacatalog/src/v1/gapic_metadata.json index c7eca6551a1..a9d9c034d09 100644 --- a/packages/google-cloud-datacatalog/src/v1/gapic_metadata.json +++ b/packages/google-cloud-datacatalog/src/v1/gapic_metadata.json @@ -150,6 +150,16 @@ "testIamPermissions" ] }, + "ReconcileTags": { + "methods": [ + "reconcileTags" + ] + }, + "ImportEntries": { + "methods": [ + "importEntries" + ] + }, "SearchCatalog": { "methods": [ "searchCatalog", @@ -323,6 +333,16 @@ "testIamPermissions" ] }, + "ReconcileTags": { + "methods": [ + "reconcileTags" + ] + }, + "ImportEntries": { + "methods": [ + "importEntries" + ] + }, "SearchCatalog": { "methods": [ "searchCatalog", diff --git a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_client.ts b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_client.ts index 792d347004c..eb998c96b1a 100644 --- a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_client.ts +++ b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_client.ts @@ -1416,6 +1416,9 @@ export class PolicyTagManagerClient { * the first page is returned. * * The token is returned in the response to a previous list request. + * @param {string} request.filter + * Supported field for filter is 'service' and value is 'dataplex'. + * Eg: service=dataplex. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. @@ -1518,6 +1521,9 @@ export class PolicyTagManagerClient { * the first page is returned. * * The token is returned in the response to a previous list request. + * @param {string} request.filter + * Supported field for filter is 'service' and value is 'dataplex'. + * Eg: service=dataplex. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} @@ -1568,6 +1574,9 @@ export class PolicyTagManagerClient { * the first page is returned. * * The token is returned in the response to a previous list request. + * @param {string} request.filter + * Supported field for filter is 'service' and value is 'dataplex'. + * Eg: service=dataplex. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Object} diff --git a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_proto_list.json b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_proto_list.json index c86ea1d1950..e2d2eeac32a 100644 --- a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_proto_list.json +++ b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_proto_list.json @@ -4,6 +4,7 @@ "../../protos/google/cloud/datacatalog/v1/data_source.proto", "../../protos/google/cloud/datacatalog/v1/datacatalog.proto", "../../protos/google/cloud/datacatalog/v1/dataplex_spec.proto", + "../../protos/google/cloud/datacatalog/v1/dump_content.proto", "../../protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto", "../../protos/google/cloud/datacatalog/v1/physical_schema.proto", "../../protos/google/cloud/datacatalog/v1/policytagmanager.proto", diff --git a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_client.ts b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_client.ts index ce259e6553d..24873fae26b 100644 --- a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_client.ts +++ b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_client.ts @@ -461,7 +461,8 @@ export class PolicyTagManagerSerializationClient { * @param {Object} request * The request object that will be sent. * @param {string} request.parent - * Required. Resource name of project that the imported taxonomies will belong to. + * Required. Resource name of project that the imported taxonomies will belong + * to. * @param {google.cloud.datacatalog.v1.InlineSource} request.inlineSource * Inline source taxonomy to import. * @param {google.cloud.datacatalog.v1.CrossRegionalSource} request.crossRegionalSource @@ -561,7 +562,8 @@ export class PolicyTagManagerSerializationClient { * @param {Object} request * The request object that will be sent. * @param {string} request.parent - * Required. Resource name of the project that the exported taxonomies belong to. + * Required. Resource name of the project that the exported taxonomies belong + * to. * @param {string[]} request.taxonomies * Required. Resource names of the taxonomies to export. * @param {boolean} request.serializedTaxonomies diff --git a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_proto_list.json b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_proto_list.json index c86ea1d1950..e2d2eeac32a 100644 --- a/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_proto_list.json +++ b/packages/google-cloud-datacatalog/src/v1/policy_tag_manager_serialization_proto_list.json @@ -4,6 +4,7 @@ "../../protos/google/cloud/datacatalog/v1/data_source.proto", "../../protos/google/cloud/datacatalog/v1/datacatalog.proto", "../../protos/google/cloud/datacatalog/v1/dataplex_spec.proto", + "../../protos/google/cloud/datacatalog/v1/dump_content.proto", "../../protos/google/cloud/datacatalog/v1/gcs_fileset_spec.proto", "../../protos/google/cloud/datacatalog/v1/physical_schema.proto", "../../protos/google/cloud/datacatalog/v1/policytagmanager.proto", diff --git a/packages/google-cloud-datacatalog/test/gapic_data_catalog_v1.ts b/packages/google-cloud-datacatalog/test/gapic_data_catalog_v1.ts index b32c24e6a3e..3431dd918ab 100644 --- a/packages/google-cloud-datacatalog/test/gapic_data_catalog_v1.ts +++ b/packages/google-cloud-datacatalog/test/gapic_data_catalog_v1.ts @@ -25,7 +25,7 @@ import * as datacatalogModule from '../src'; import {PassThrough} from 'stream'; -import {protobuf} from 'google-gax'; +import {protobuf, LROperation, operationsProtos} from 'google-gax'; // Dynamically loaded proto JSON is needed to get the type information // to fill in default values for request objects @@ -66,6 +66,38 @@ function stubSimpleCallWithCallback( : sinon.stub().callsArgWith(2, null, response); } +function stubLongRunningCall( + response?: ResponseType, + callError?: Error, + lroError?: Error +) { + const innerStub = lroError + ? sinon.stub().rejects(lroError) + : sinon.stub().resolves([response]); + const mockOperation = { + promise: innerStub, + }; + return callError + ? sinon.stub().rejects(callError) + : sinon.stub().resolves([mockOperation]); +} + +function stubLongRunningCallWithCallback( + response?: ResponseType, + callError?: Error, + lroError?: Error +) { + const innerStub = lroError + ? sinon.stub().rejects(lroError) + : sinon.stub().resolves([response]); + const mockOperation = { + promise: innerStub, + }; + return callError + ? sinon.stub().callsArgWith(2, callError) + : sinon.stub().callsArgWith(2, null, mockOperation); +} + function stubPageStreamingCall( responses?: ResponseType[], error?: Error @@ -3857,6 +3889,394 @@ describe('v1.DataCatalogClient', () => { }); }); + describe('reconcileTags', () => { + it('invokes reconcileTags without error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ReconcileTagsRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ReconcileTagsRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedResponse = generateSampleMessage( + new protos.google.longrunning.Operation() + ); + client.innerApiCalls.reconcileTags = + stubLongRunningCall(expectedResponse); + const [operation] = await client.reconcileTags(request); + const [response] = await operation.promise(); + assert.deepStrictEqual(response, expectedResponse); + const actualRequest = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes reconcileTags without error using callback', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ReconcileTagsRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ReconcileTagsRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedResponse = generateSampleMessage( + new protos.google.longrunning.Operation() + ); + client.innerApiCalls.reconcileTags = + stubLongRunningCallWithCallback(expectedResponse); + const promise = new Promise((resolve, reject) => { + client.reconcileTags( + request, + ( + err?: Error | null, + result?: LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + > | null + ) => { + if (err) { + reject(err); + } else { + resolve(result); + } + } + ); + }); + const operation = (await promise) as LROperation< + protos.google.cloud.datacatalog.v1.IReconcileTagsResponse, + protos.google.cloud.datacatalog.v1.IReconcileTagsMetadata + >; + const [response] = await operation.promise(); + assert.deepStrictEqual(response, expectedResponse); + const actualRequest = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes reconcileTags with call error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ReconcileTagsRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ReconcileTagsRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedError = new Error('expected'); + client.innerApiCalls.reconcileTags = stubLongRunningCall( + undefined, + expectedError + ); + await assert.rejects(client.reconcileTags(request), expectedError); + const actualRequest = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes reconcileTags with LRO error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ReconcileTagsRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ReconcileTagsRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedError = new Error('expected'); + client.innerApiCalls.reconcileTags = stubLongRunningCall( + undefined, + undefined, + expectedError + ); + const [operation] = await client.reconcileTags(request); + await assert.rejects(operation.promise(), expectedError); + const actualRequest = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.reconcileTags as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes checkReconcileTagsProgress without error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const expectedResponse = generateSampleMessage( + new operationsProtos.google.longrunning.Operation() + ); + expectedResponse.name = 'test'; + expectedResponse.response = {type_url: 'url', value: Buffer.from('')}; + expectedResponse.metadata = {type_url: 'url', value: Buffer.from('')}; + + client.operationsClient.getOperation = stubSimpleCall(expectedResponse); + const decodedOperation = await client.checkReconcileTagsProgress( + expectedResponse.name + ); + assert.deepStrictEqual(decodedOperation.name, expectedResponse.name); + assert(decodedOperation.metadata); + assert((client.operationsClient.getOperation as SinonStub).getCall(0)); + }); + + it('invokes checkReconcileTagsProgress with error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const expectedError = new Error('expected'); + + client.operationsClient.getOperation = stubSimpleCall( + undefined, + expectedError + ); + await assert.rejects( + client.checkReconcileTagsProgress(''), + expectedError + ); + assert((client.operationsClient.getOperation as SinonStub).getCall(0)); + }); + }); + + describe('importEntries', () => { + it('invokes importEntries without error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ImportEntriesRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ImportEntriesRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedResponse = generateSampleMessage( + new protos.google.longrunning.Operation() + ); + client.innerApiCalls.importEntries = + stubLongRunningCall(expectedResponse); + const [operation] = await client.importEntries(request); + const [response] = await operation.promise(); + assert.deepStrictEqual(response, expectedResponse); + const actualRequest = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes importEntries without error using callback', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ImportEntriesRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ImportEntriesRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedResponse = generateSampleMessage( + new protos.google.longrunning.Operation() + ); + client.innerApiCalls.importEntries = + stubLongRunningCallWithCallback(expectedResponse); + const promise = new Promise((resolve, reject) => { + client.importEntries( + request, + ( + err?: Error | null, + result?: LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + > | null + ) => { + if (err) { + reject(err); + } else { + resolve(result); + } + } + ); + }); + const operation = (await promise) as LROperation< + protos.google.cloud.datacatalog.v1.IImportEntriesResponse, + protos.google.cloud.datacatalog.v1.IImportEntriesMetadata + >; + const [response] = await operation.promise(); + assert.deepStrictEqual(response, expectedResponse); + const actualRequest = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes importEntries with call error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ImportEntriesRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ImportEntriesRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedError = new Error('expected'); + client.innerApiCalls.importEntries = stubLongRunningCall( + undefined, + expectedError + ); + await assert.rejects(client.importEntries(request), expectedError); + const actualRequest = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes importEntries with LRO error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.datacatalog.v1.ImportEntriesRequest() + ); + const defaultValue1 = getTypeDefaultValue( + '.google.cloud.datacatalog.v1.ImportEntriesRequest', + ['parent'] + ); + request.parent = defaultValue1; + const expectedHeaderRequestParams = `parent=${defaultValue1}`; + const expectedError = new Error('expected'); + client.innerApiCalls.importEntries = stubLongRunningCall( + undefined, + undefined, + expectedError + ); + const [operation] = await client.importEntries(request); + await assert.rejects(operation.promise(), expectedError); + const actualRequest = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[0]; + assert.deepStrictEqual(actualRequest, request); + const actualHeaderRequestParams = ( + client.innerApiCalls.importEntries as SinonStub + ).getCall(0).args[1].otherArgs.headers['x-goog-request-params']; + assert(actualHeaderRequestParams.includes(expectedHeaderRequestParams)); + }); + + it('invokes checkImportEntriesProgress without error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const expectedResponse = generateSampleMessage( + new operationsProtos.google.longrunning.Operation() + ); + expectedResponse.name = 'test'; + expectedResponse.response = {type_url: 'url', value: Buffer.from('')}; + expectedResponse.metadata = {type_url: 'url', value: Buffer.from('')}; + + client.operationsClient.getOperation = stubSimpleCall(expectedResponse); + const decodedOperation = await client.checkImportEntriesProgress( + expectedResponse.name + ); + assert.deepStrictEqual(decodedOperation.name, expectedResponse.name); + assert(decodedOperation.metadata); + assert((client.operationsClient.getOperation as SinonStub).getCall(0)); + }); + + it('invokes checkImportEntriesProgress with error', async () => { + const client = new datacatalogModule.v1.DataCatalogClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const expectedError = new Error('expected'); + + client.operationsClient.getOperation = stubSimpleCall( + undefined, + expectedError + ); + await assert.rejects( + client.checkImportEntriesProgress(''), + expectedError + ); + assert((client.operationsClient.getOperation as SinonStub).getCall(0)); + }); + }); + describe('searchCatalog', () => { it('invokes searchCatalog without error', async () => { const client = new datacatalogModule.v1.DataCatalogClient({