diff --git a/packages/google-maps-mapsplatformdatasets/.repo-metadata.json b/packages/google-maps-mapsplatformdatasets/.repo-metadata.json index ddac9e0dc01..8013245cf23 100644 --- a/packages/google-maps-mapsplatformdatasets/.repo-metadata.json +++ b/packages/google-maps-mapsplatformdatasets/.repo-metadata.json @@ -4,12 +4,12 @@ "product_documentation": "", "client_documentation": "https://cloud.google.com/nodejs/docs/reference/mapsplatformdatasets/latest", "issue_tracker": "https://github.com/googleapis/google-cloud-node/issues", - "release_level": "preview", + "release_level": "stable", "language": "nodejs", "repo": "googleapis/google-cloud-node", "distribution_name": "@google-cloud/mapsplatformdatasets", "api_id": "mapsplatformdatasets.googleapis.com", - "default_version": "v1alpha", + "default_version": "v1", "requires_billing": true, "library_type": "GAPIC_AUTO", "api_shortname": "mapsplatformdatasets" diff --git a/packages/google-maps-mapsplatformdatasets/README.md b/packages/google-maps-mapsplatformdatasets/README.md index ef9530dfab7..a32e7fda217 100644 --- a/packages/google-maps-mapsplatformdatasets/README.md +++ b/packages/google-maps-mapsplatformdatasets/README.md @@ -4,7 +4,7 @@ # [Maps Platform Datasets API: Node.js Client](https://github.com/googleapis/google-cloud-node/tree/main/packages/google-maps-mapsplatformdatasets) -[![release level](https://img.shields.io/badge/release%20level-preview-yellow.svg?style=flat)](https://cloud.google.com/terms/launch-stages) +[![release level](https://img.shields.io/badge/release%20level-stable-brightgreen.svg?style=flat)](https://cloud.google.com/terms/launch-stages) [![npm version](https://img.shields.io/npm/v/@googlemaps/maps-platform-datasets.svg)](https://www.npmjs.org/package/@googlemaps/maps-platform-datasets) @@ -159,13 +159,14 @@ This library follows [Semantic Versioning](http://semver.org/). +This library is considered to be **stable**. The code surface will not change in backwards-incompatible ways +unless absolutely necessary (e.g. because of critical security issues) or with +an extensive deprecation period. Issues and requests against **stable** libraries +are addressed with the highest priority. -This library is considered to be in **preview**. This means it is still a -work-in-progress and under active development. Any release is subject to -backwards-incompatible changes at any time. More Information: [Google Cloud Platform Launch Stages][launch_stages] diff --git a/packages/google-maps-mapsplatformdatasets/package.json b/packages/google-maps-mapsplatformdatasets/package.json index 930a9cdba7b..5a2bf0fcdac 100644 --- a/packages/google-maps-mapsplatformdatasets/package.json +++ b/packages/google-maps-mapsplatformdatasets/package.json @@ -68,4 +68,4 @@ "engines": { "node": ">=14.0.0" } -} \ No newline at end of file +} diff --git a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/data_source.proto b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/data_source.proto index 61844d00135..597d6822eda 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/data_source.proto +++ b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/data_source.proto @@ -16,6 +16,9 @@ syntax = "proto3"; package google.maps.mapsplatformdatasets.v1; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; + option csharp_namespace = "Google.Maps.MapsPlatformDatasets.V1"; option go_package = "cloud.google.com/go/maps/mapsplatformdatasets/apiv1/mapsplatformdatasetspb;mapsplatformdatasetspb"; option java_multiple_files = true; diff --git a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/dataset.proto b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/dataset.proto index 4f452c1573a..e280b1235f5 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/dataset.proto +++ b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/dataset.proto @@ -29,21 +29,23 @@ option java_package = "com.google.maps.mapsplatformdatasets.v1"; option objc_class_prefix = "MDV1"; option php_namespace = "Google\\Maps\\MapsPlatformDatasets\\V1"; -// A representation of a Maps Dataset resource. +// A representation of a dataset resource. message Dataset { option (google.api.resource) = { type: "mapsplatformdatasets.googleapis.com/Dataset" pattern: "projects/{project}/datasets/{dataset}" }; - // Resource name, - // projects/{project}/datasets/{dataset_id} + // Resource name. + // Format: projects/{project}/datasets/{dataset_id} string name = 1; - // Human readable name, shown in the console UI . + // Human readable name, shown in the console UI. + // + // Must be unique within a project. string display_name = 2; - // A description of this dataset . + // A description of this dataset. string description = 3; // The version ID of the dataset. @@ -72,7 +74,7 @@ message Dataset { google.protobuf.Timestamp update_time = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Output only. Time when the data was uploaded. + // Output only. Time when this version was created. google.protobuf.Timestamp version_create_time = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; @@ -118,12 +120,12 @@ message Status { // progress. STATE_PUBLISHING = 9; - // The publishing failed states. This state represents that the - // publishing failed. Publishing may be retried. + // The publishing failed states. This state represents that the publishing + // failed. Publishing may be retried. STATE_PUBLISHING_FAILED = 10; - // The completed state. This state represents the dataset being - // available for its specific usage. + // The completed state. This state represents the dataset being available + // for its specific usage. STATE_COMPLETED = 11; } diff --git a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets.proto b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets.proto index 72ff028866e..af76bab23c2 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets.proto +++ b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets.proto @@ -18,7 +18,6 @@ package google.maps.mapsplatformdatasets.v1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; -import "google/maps/mapsplatformdatasets/v1/data_source.proto"; import "google/maps/mapsplatformdatasets/v1/dataset.proto"; import "google/protobuf/field_mask.proto"; @@ -33,7 +32,7 @@ option php_namespace = "Google\\Maps\\MapsPlatformDatasets\\V1"; // Request to create a maps dataset. message CreateDatasetRequest { // Required. Parent project that will own the dataset. - // Format: projects/{$project} + // Format: projects/{project} string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -47,19 +46,27 @@ message CreateDatasetRequest { // Request to update the metadata fields of the dataset. message UpdateDatasetMetadataRequest { - // Required. The dataset to update. The dataset's name is used to identify the - // dataset to be updated. The name has the format: - // projects/{project}/datasets/{dataset_id} + // Required. Resource name of the dataset to update. + // Format: projects/{project}/datasets/{dataset_id} Dataset dataset = 1 [(google.api.field_behavior) = REQUIRED]; - // The list of fields to be updated. Support the value "*" for full - // replacement. + // The list of fields to be updated. + // + // The value "*" is used for full replacement (default). google.protobuf.FieldMask update_mask = 2; } // Request to get the specified dataset. message GetDatasetRequest { - // Required. Resource name. projects/{project}/datasets/{dataset_id} + // Required. Resource name. + // Format: projects/{project}/datasets/{dataset_id} + // + // + // Can also fetch some special versions by appending "@" and a tag. + // Format: projects/{project}/datasets/{dataset_id}@{tag} + // + // Tag "active": The info of the latest completed version will be included, + // and NOT_FOUND if the dataset does not have one. string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -71,6 +78,7 @@ message GetDatasetRequest { // Request to list datasets for the project. message ListDatasetsRequest { // Required. The name of the project to list all the datasets for. + // Format: projects/{project} string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -78,30 +86,42 @@ message ListDatasetsRequest { } ]; - // The maximum number of versions to return per page. + // The maximum number of datasets to return per page. + // // If unspecified (or zero), all datasets will be returned. int32 page_size = 2; // The page token, received from a previous ListDatasets call. // Provide this to retrieve the subsequent page. string page_token = 3; + + // The tag that specifies the desired version for each dataset. + // + // Note that when pagination is also specified, some filtering can happen + // after pagination, which may cause the response to contain fewer datasets + // than the page size, even if it's not the last page. + // + // Tag "active": Each dataset in the response will include the info of its + // latest completed version, and the dataset will be skipped if it does not + // have one. + string tag = 4; } -// Response to list datasets for the project. +// Response object of ListDatasets. message ListDatasetsResponse { // All the datasets for the project. repeated Dataset datasets = 1; // A token that can be sent as `page_token` to retrieve the next page. + // // If this field is omitted, there are no subsequent pages. string next_page_token = 2; } // Request to delete a dataset. -// -// The dataset to be deleted. message DeleteDatasetRequest { - // Required. Format: projects/${project}/datasets/{dataset_id} + // Required. The name of the dataset to delete. + // Format: projects/{project}/datasets/{dataset_id} string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { diff --git a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets_service.proto b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets_service.proto index be633ad2cb7..d96b1b3cdad 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets_service.proto +++ b/packages/google-maps-mapsplatformdatasets/protos/google/maps/mapsplatformdatasets/v1/maps_platform_datasets_service.proto @@ -37,7 +37,7 @@ service MapsPlatformDatasets { option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform"; - // Create a new dataset for the specified project. + // Creates a new dataset for the specified project. rpc CreateDataset(CreateDatasetRequest) returns (Dataset) { option (google.api.http) = { post: "/v1/{parent=projects/*}/datasets" @@ -46,7 +46,7 @@ service MapsPlatformDatasets { option (google.api.method_signature) = "parent,dataset"; } - // Update the metadata for the dataset. + // Updates the metadata for the dataset. rpc UpdateDatasetMetadata(UpdateDatasetMetadataRequest) returns (Dataset) { option (google.api.http) = { patch: "/v1/{dataset.name=projects/*/datasets/*}" @@ -55,7 +55,7 @@ service MapsPlatformDatasets { option (google.api.method_signature) = "dataset,update_mask"; } - // Get the dataset. + // Gets the dataset. rpc GetDataset(GetDatasetRequest) returns (Dataset) { option (google.api.http) = { get: "/v1/{name=projects/*/datasets/*}" @@ -63,7 +63,7 @@ service MapsPlatformDatasets { option (google.api.method_signature) = "name"; } - // List all the datasets for the specified project. + // Lists all the datasets for the specified project. rpc ListDatasets(ListDatasetsRequest) returns (ListDatasetsResponse) { option (google.api.http) = { get: "/v1/{parent=projects/*}/datasets" @@ -71,7 +71,7 @@ service MapsPlatformDatasets { option (google.api.method_signature) = "parent"; } - // Delete the specified dataset . + // Deletes the specified dataset. rpc DeleteDataset(DeleteDatasetRequest) returns (google.protobuf.Empty) { option (google.api.http) = { delete: "/v1/{name=projects/*/datasets/*}" diff --git a/packages/google-maps-mapsplatformdatasets/protos/protos.d.ts b/packages/google-maps-mapsplatformdatasets/protos/protos.d.ts index 56f877cf756..f9c1cb41c35 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/protos.d.ts +++ b/packages/google-maps-mapsplatformdatasets/protos/protos.d.ts @@ -848,6 +848,9 @@ export namespace google { /** ListDatasetsRequest pageToken */ pageToken?: (string|null); + + /** ListDatasetsRequest tag */ + tag?: (string|null); } /** Represents a ListDatasetsRequest. */ @@ -868,6 +871,9 @@ export namespace google { /** ListDatasetsRequest pageToken. */ public pageToken: string; + /** ListDatasetsRequest tag. */ + public tag: string; + /** * Creates a new ListDatasetsRequest instance using the specified properties. * @param [properties] Properties to set diff --git a/packages/google-maps-mapsplatformdatasets/protos/protos.js b/packages/google-maps-mapsplatformdatasets/protos/protos.js index b718f657d61..3afc2c881df 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/protos.js +++ b/packages/google-maps-mapsplatformdatasets/protos/protos.js @@ -2179,6 +2179,7 @@ * @property {string|null} [parent] ListDatasetsRequest parent * @property {number|null} [pageSize] ListDatasetsRequest pageSize * @property {string|null} [pageToken] ListDatasetsRequest pageToken + * @property {string|null} [tag] ListDatasetsRequest tag */ /** @@ -2220,6 +2221,14 @@ */ ListDatasetsRequest.prototype.pageToken = ""; + /** + * ListDatasetsRequest tag. + * @member {string} tag + * @memberof google.maps.mapsplatformdatasets.v1.ListDatasetsRequest + * @instance + */ + ListDatasetsRequest.prototype.tag = ""; + /** * Creates a new ListDatasetsRequest instance using the specified properties. * @function create @@ -2250,6 +2259,8 @@ 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.tag != null && Object.hasOwnProperty.call(message, "tag")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.tag); return writer; }; @@ -2296,6 +2307,10 @@ message.pageToken = reader.string(); break; } + case 4: { + message.tag = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -2340,6 +2355,9 @@ if (message.pageToken != null && message.hasOwnProperty("pageToken")) if (!$util.isString(message.pageToken)) return "pageToken: string expected"; + if (message.tag != null && message.hasOwnProperty("tag")) + if (!$util.isString(message.tag)) + return "tag: string expected"; return null; }; @@ -2361,6 +2379,8 @@ message.pageSize = object.pageSize | 0; if (object.pageToken != null) message.pageToken = String(object.pageToken); + if (object.tag != null) + message.tag = String(object.tag); return message; }; @@ -2381,6 +2401,7 @@ object.parent = ""; object.pageSize = 0; object.pageToken = ""; + object.tag = ""; } if (message.parent != null && message.hasOwnProperty("parent")) object.parent = message.parent; @@ -2388,6 +2409,8 @@ object.pageSize = message.pageSize; if (message.pageToken != null && message.hasOwnProperty("pageToken")) object.pageToken = message.pageToken; + if (message.tag != null && message.hasOwnProperty("tag")) + object.tag = message.tag; return object; }; diff --git a/packages/google-maps-mapsplatformdatasets/protos/protos.json b/packages/google-maps-mapsplatformdatasets/protos/protos.json index 5ccf8fe780d..ef842537532 100644 --- a/packages/google-maps-mapsplatformdatasets/protos/protos.json +++ b/packages/google-maps-mapsplatformdatasets/protos/protos.json @@ -229,6 +229,10 @@ "pageToken": { "type": "string", "id": 3 + }, + "tag": { + "type": "string", + "id": 4 } } }, diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.create_dataset.js b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.create_dataset.js index dc50f5473ee..06d5bfbdcce 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.create_dataset.js +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.create_dataset.js @@ -30,7 +30,7 @@ function main(parent, dataset) { */ /** * Required. Parent project that will own the dataset. - * Format: projects/{$project} + * Format: projects/{project} */ // const parent = 'abc123' /** diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.delete_dataset.js b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.delete_dataset.js index 78a645d428c..0ff3ba4dca9 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.delete_dataset.js +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.delete_dataset.js @@ -29,7 +29,8 @@ function main(name) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. Format: projects/${project}/datasets/{dataset_id} + * Required. The name of the dataset to delete. + * Format: projects/{project}/datasets/{dataset_id} */ // const name = 'abc123' diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.get_dataset.js b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.get_dataset.js index f629940dd4f..8ed0475d7f3 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.get_dataset.js +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.get_dataset.js @@ -29,7 +29,12 @@ function main(name) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. Resource name. projects/{project}/datasets/{dataset_id} + * Required. Resource name. + * Format: projects/{project}/datasets/{dataset_id} + * Can also fetch some special versions by appending "@" and a tag. + * Format: projects/{project}/datasets/{dataset_id}@{tag} + * Tag "active": The info of the latest completed version will be included, + * and NOT_FOUND if the dataset does not have one. */ // const name = 'abc123' diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.list_datasets.js b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.list_datasets.js index bdba6adba2b..9607587f456 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.list_datasets.js +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.list_datasets.js @@ -30,10 +30,11 @@ function main(parent) { */ /** * Required. The name of the project to list all the datasets for. + * Format: projects/{project} */ // const parent = 'abc123' /** - * The maximum number of versions to return per page. + * The maximum number of datasets to return per page. * If unspecified (or zero), all datasets will be returned. */ // const pageSize = 1234 @@ -42,6 +43,16 @@ function main(parent) { * Provide this to retrieve the subsequent page. */ // const pageToken = 'abc123' + /** + * The tag that specifies the desired version for each dataset. + * Note that when pagination is also specified, some filtering can happen + * after pagination, which may cause the response to contain fewer datasets + * than the page size, even if it's not the last page. + * Tag "active": Each dataset in the response will include the info of its + * latest completed version, and the dataset will be skipped if it does not + * have one. + */ + // const tag = 'abc123' // Imports the Mapsplatformdatasets library const {MapsPlatformDatasetsClient} = require('@googlemaps/maps-platform-datasets').v1; diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.update_dataset_metadata.js b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.update_dataset_metadata.js index af445674487..0455fff6e7e 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.update_dataset_metadata.js +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/maps_platform_datasets.update_dataset_metadata.js @@ -29,14 +29,13 @@ function main(dataset) { * TODO(developer): Uncomment these variables before running the sample. */ /** - * Required. The dataset to update. The dataset's name is used to identify the - * dataset to be updated. The name has the format: - * projects/{project}/datasets/{dataset_id} + * Required. Resource name of the dataset to update. + * Format: projects/{project}/datasets/{dataset_id} */ // const dataset = {} /** - * The list of fields to be updated. Support the value "*" for full - * replacement. + * The list of fields to be updated. + * The value "*" is used for full replacement (default). */ // const updateMask = {} diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata.google.maps.mapsplatformdatasets.v1.json b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata.google.maps.mapsplatformdatasets.v1.json index 59946dfa6f7..ff3231b0100 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata.google.maps.mapsplatformdatasets.v1.json +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata.google.maps.mapsplatformdatasets.v1.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-mapsplatformdatasets", - "version": "1.2.0", + "version": "1.3.0", "language": "TYPESCRIPT", "apis": [ { diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata_google.maps.mapsplatformdatasets.v1.json b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata_google.maps.mapsplatformdatasets.v1.json index 59946dfa6f7..7530a68bfc2 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata_google.maps.mapsplatformdatasets.v1.json +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1/snippet_metadata_google.maps.mapsplatformdatasets.v1.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-mapsplatformdatasets", - "version": "1.2.0", + "version": "1.3.0", "language": "TYPESCRIPT", "apis": [ { @@ -15,7 +15,7 @@ "regionTag": "mapsplatformdatasets_v1_generated_MapsPlatformDatasets_CreateDataset_async", "title": "MapsPlatformDatasets createDataset Sample", "origin": "API_DEFINITION", - "description": " Create a new dataset for the specified project.", + "description": " Creates a new dataset for the specified project.", "canonical": true, "file": "maps_platform_datasets.create_dataset.js", "language": "JAVASCRIPT", @@ -59,14 +59,14 @@ "regionTag": "mapsplatformdatasets_v1_generated_MapsPlatformDatasets_UpdateDatasetMetadata_async", "title": "MapsPlatformDatasets updateDatasetMetadata Sample", "origin": "API_DEFINITION", - "description": " Update the metadata for the dataset.", + "description": " Updates the metadata for the dataset.", "canonical": true, "file": "maps_platform_datasets.update_dataset_metadata.js", "language": "JAVASCRIPT", "segments": [ { "start": 25, - "end": 60, + "end": 59, "type": "FULL" } ], @@ -103,14 +103,14 @@ "regionTag": "mapsplatformdatasets_v1_generated_MapsPlatformDatasets_GetDataset_async", "title": "MapsPlatformDatasets getDataset Sample", "origin": "API_DEFINITION", - "description": " Get the dataset.", + "description": " Gets the dataset.", "canonical": true, "file": "maps_platform_datasets.get_dataset.js", "language": "JAVASCRIPT", "segments": [ { "start": 25, - "end": 53, + "end": 58, "type": "FULL" } ], @@ -143,14 +143,14 @@ "regionTag": "mapsplatformdatasets_v1_generated_MapsPlatformDatasets_ListDatasets_async", "title": "MapsPlatformDatasets listDatasets Sample", "origin": "API_DEFINITION", - "description": " List all the datasets for the specified project.", + "description": " Lists all the datasets for the specified project.", "canonical": true, "file": "maps_platform_datasets.list_datasets.js", "language": "JAVASCRIPT", "segments": [ { "start": 25, - "end": 65, + "end": 76, "type": "FULL" } ], @@ -170,6 +170,10 @@ { "name": "page_token", "type": "TYPE_STRING" + }, + { + "name": "tag", + "type": "TYPE_STRING" } ], "resultType": ".google.maps.mapsplatformdatasets.v1.ListDatasetsResponse", @@ -191,14 +195,14 @@ "regionTag": "mapsplatformdatasets_v1_generated_MapsPlatformDatasets_DeleteDataset_async", "title": "MapsPlatformDatasets deleteDataset Sample", "origin": "API_DEFINITION", - "description": " Delete the specified dataset .", + "description": " Deletes the specified dataset.", "canonical": true, "file": "maps_platform_datasets.delete_dataset.js", "language": "JAVASCRIPT", "segments": [ { "start": 25, - "end": 53, + "end": 54, "type": "FULL" } ], diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata.google.maps.mapsplatformdatasets.v1alpha.json b/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata.google.maps.mapsplatformdatasets.v1alpha.json index 9b5882adb5a..35d32597f69 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata.google.maps.mapsplatformdatasets.v1alpha.json +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata.google.maps.mapsplatformdatasets.v1alpha.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-mapsplatformdatasets", - "version": "1.2.0", + "version": "1.3.0", "language": "TYPESCRIPT", "apis": [ { diff --git a/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata_google.maps.mapsplatformdatasets.v1alpha.json b/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata_google.maps.mapsplatformdatasets.v1alpha.json index 9b5882adb5a..35d32597f69 100644 --- a/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata_google.maps.mapsplatformdatasets.v1alpha.json +++ b/packages/google-maps-mapsplatformdatasets/samples/generated/v1alpha/snippet_metadata_google.maps.mapsplatformdatasets.v1alpha.json @@ -1,7 +1,7 @@ { "clientLibrary": { "name": "nodejs-mapsplatformdatasets", - "version": "1.2.0", + "version": "1.3.0", "language": "TYPESCRIPT", "apis": [ { diff --git a/packages/google-maps-mapsplatformdatasets/src/index.ts b/packages/google-maps-mapsplatformdatasets/src/index.ts index 577f5320c1d..9fb43d20e67 100644 --- a/packages/google-maps-mapsplatformdatasets/src/index.ts +++ b/packages/google-maps-mapsplatformdatasets/src/index.ts @@ -19,12 +19,10 @@ import * as v1 from './v1'; import * as v1alpha from './v1alpha'; -const MapsPlatformDatasetsV1AlphaClient = - v1alpha.MapsPlatformDatasetsV1AlphaClient; -type MapsPlatformDatasetsV1AlphaClient = - v1alpha.MapsPlatformDatasetsV1AlphaClient; +const MapsPlatformDatasetsClient = v1.MapsPlatformDatasetsClient; +type MapsPlatformDatasetsClient = v1.MapsPlatformDatasetsClient; -export {v1, v1alpha, MapsPlatformDatasetsV1AlphaClient}; -export default {v1, v1alpha, MapsPlatformDatasetsV1AlphaClient}; +export {v1, v1alpha, MapsPlatformDatasetsClient}; +export default {v1, v1alpha, MapsPlatformDatasetsClient}; import * as protos from '../protos/protos'; export {protos}; diff --git a/packages/google-maps-mapsplatformdatasets/src/v1/maps_platform_datasets_client.ts b/packages/google-maps-mapsplatformdatasets/src/v1/maps_platform_datasets_client.ts index c2d56c606a7..7b59c02120b 100644 --- a/packages/google-maps-mapsplatformdatasets/src/v1/maps_platform_datasets_client.ts +++ b/packages/google-maps-mapsplatformdatasets/src/v1/maps_platform_datasets_client.ts @@ -386,13 +386,13 @@ export class MapsPlatformDatasetsClient { // -- Service calls -- // ------------------- /** - * Create a new dataset for the specified project. + * Creates a new dataset for the specified project. * * @param {Object} request * The request object that will be sent. * @param {string} request.parent * Required. Parent project that will own the dataset. - * Format: projects/{$project} + * Format: projects/{project} * @param {google.maps.mapsplatformdatasets.v1.Dataset} request.dataset * Required. The dataset version to create. * @param {object} [options] @@ -485,17 +485,17 @@ export class MapsPlatformDatasetsClient { return this.innerApiCalls.createDataset(request, options, callback); } /** - * Update the metadata for the dataset. + * Updates the metadata for the dataset. * * @param {Object} request * The request object that will be sent. * @param {google.maps.mapsplatformdatasets.v1.Dataset} request.dataset - * Required. The dataset to update. The dataset's name is used to identify the - * dataset to be updated. The name has the format: - * projects/{project}/datasets/{dataset_id} + * Required. Resource name of the dataset to update. + * Format: projects/{project}/datasets/{dataset_id} * @param {google.protobuf.FieldMask} request.updateMask - * The list of fields to be updated. Support the value "*" for full - * replacement. + * The list of fields to be updated. + * + * The value "*" is used for full replacement (default). * @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. @@ -586,12 +586,20 @@ export class MapsPlatformDatasetsClient { return this.innerApiCalls.updateDatasetMetadata(request, options, callback); } /** - * Get the dataset. + * Gets the dataset. * * @param {Object} request * The request object that will be sent. * @param {string} request.name - * Required. Resource name. projects/{project}/datasets/{dataset_id} + * Required. Resource name. + * Format: projects/{project}/datasets/{dataset_id} + * + * + * Can also fetch some special versions by appending "@" and a tag. + * Format: projects/{project}/datasets/{dataset_id}@{tag} + * + * Tag "active": The info of the latest completed version will be included, + * and NOT_FOUND if the dataset does not have one. * @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. @@ -676,12 +684,13 @@ export class MapsPlatformDatasetsClient { return this.innerApiCalls.getDataset(request, options, callback); } /** - * Delete the specified dataset . + * Deletes the specified dataset. * * @param {Object} request * The request object that will be sent. * @param {string} request.name - * Required. Format: projects/${project}/datasets/{dataset_id} + * Required. The name of the dataset to delete. + * Format: projects/{project}/datasets/{dataset_id} * @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. @@ -773,18 +782,30 @@ export class MapsPlatformDatasetsClient { } /** - * List all the datasets for the specified project. + * Lists all the datasets for the specified project. * * @param {Object} request * The request object that will be sent. * @param {string} request.parent * Required. The name of the project to list all the datasets for. + * Format: projects/{project} * @param {number} request.pageSize - * The maximum number of versions to return per page. + * The maximum number of datasets to return per page. + * * If unspecified (or zero), all datasets will be returned. * @param {string} request.pageToken * The page token, received from a previous ListDatasets call. * Provide this to retrieve the subsequent page. + * @param {string} request.tag + * The tag that specifies the desired version for each dataset. + * + * Note that when pagination is also specified, some filtering can happen + * after pagination, which may cause the response to contain fewer datasets + * than the page size, even if it's not the last page. + * + * Tag "active": Each dataset in the response will include the info of its + * latest completed version, and the dataset will be skipped if it does not + * have one. * @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. @@ -878,12 +899,24 @@ export class MapsPlatformDatasetsClient { * The request object that will be sent. * @param {string} request.parent * Required. The name of the project to list all the datasets for. + * Format: projects/{project} * @param {number} request.pageSize - * The maximum number of versions to return per page. + * The maximum number of datasets to return per page. + * * If unspecified (or zero), all datasets will be returned. * @param {string} request.pageToken * The page token, received from a previous ListDatasets call. * Provide this to retrieve the subsequent page. + * @param {string} request.tag + * The tag that specifies the desired version for each dataset. + * + * Note that when pagination is also specified, some filtering can happen + * after pagination, which may cause the response to contain fewer datasets + * than the page size, even if it's not the last page. + * + * Tag "active": Each dataset in the response will include the info of its + * latest completed version, and the dataset will be skipped if it does not + * have one. * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Stream} @@ -925,12 +958,24 @@ export class MapsPlatformDatasetsClient { * The request object that will be sent. * @param {string} request.parent * Required. The name of the project to list all the datasets for. + * Format: projects/{project} * @param {number} request.pageSize - * The maximum number of versions to return per page. + * The maximum number of datasets to return per page. + * * If unspecified (or zero), all datasets will be returned. * @param {string} request.pageToken * The page token, received from a previous ListDatasets call. * Provide this to retrieve the subsequent page. + * @param {string} request.tag + * The tag that specifies the desired version for each dataset. + * + * Note that when pagination is also specified, some filtering can happen + * after pagination, which may cause the response to contain fewer datasets + * than the page size, even if it's not the last page. + * + * Tag "active": Each dataset in the response will include the info of its + * latest completed version, and the dataset will be skipped if it does not + * have one. * @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-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.js b/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.js index daa90ecb9ee..3d2c678573d 100644 --- a/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.js +++ b/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.js @@ -20,8 +20,8 @@ const mapsplatformdatasets = require('@googlemaps/maps-platform-datasets'); function main() { - const mapsPlatformDatasetsV1AlphaClient = - new mapsplatformdatasets.MapsPlatformDatasetsV1AlphaClient(); + const mapsPlatformDatasetsClient = + new mapsplatformdatasets.MapsPlatformDatasetsClient(); } main(); diff --git a/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.ts b/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.ts index 4395a0f05ed..f4a70d635ce 100644 --- a/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.ts +++ b/packages/google-maps-mapsplatformdatasets/system-test/fixtures/sample/src/index.ts @@ -16,22 +16,19 @@ // ** https://github.com/googleapis/gapic-generator-typescript ** // ** All changes to this file may be overwritten. ** -import {MapsPlatformDatasetsV1AlphaClient} from '@googlemaps/maps-platform-datasets'; +import {MapsPlatformDatasetsClient} from '@googlemaps/maps-platform-datasets'; // check that the client class type name can be used -function doStuffWithMapsPlatformDatasetsV1AlphaClient( - client: MapsPlatformDatasetsV1AlphaClient +function doStuffWithMapsPlatformDatasetsClient( + client: MapsPlatformDatasetsClient ) { client.close(); } function main() { // check that the client instance can be created - const mapsPlatformDatasetsV1AlphaClient = - new MapsPlatformDatasetsV1AlphaClient(); - doStuffWithMapsPlatformDatasetsV1AlphaClient( - mapsPlatformDatasetsV1AlphaClient - ); + const mapsPlatformDatasetsClient = new MapsPlatformDatasetsClient(); + doStuffWithMapsPlatformDatasetsClient(mapsPlatformDatasetsClient); } main(); diff --git a/packages/google-maps-mapsplatformdatasets/webpack.config.js b/packages/google-maps-mapsplatformdatasets/webpack.config.js index afe735f0276..b4c2d61eeca 100644 --- a/packages/google-maps-mapsplatformdatasets/webpack.config.js +++ b/packages/google-maps-mapsplatformdatasets/webpack.config.js @@ -17,8 +17,8 @@ const path = require('path'); module.exports = { entry: './src/index.ts', output: { - library: 'MapsPlatformDatasetsV1Alpha', - filename: './maps-platform-datasets-v1-alpha.js', + library: 'MapsPlatformDatasets', + filename: './maps-platform-datasets.js', }, node: { child_process: 'empty',