You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 13, 2023. It is now read-only.
Copy file name to clipboardExpand all lines: src/v4/company_service_client.ts
+83-64Lines changed: 83 additions & 64 deletions
Original file line number
Diff line number
Diff line change
@@ -60,8 +60,10 @@ export class CompanyServiceClient {
60
60
/**
61
61
* Construct an instance of CompanyServiceClient.
62
62
*
63
-
* @param {object} [options] - The configuration object. See the subsequent
64
-
* parameters for more details.
63
+
* @param {object} [options] - The configuration object.
64
+
* The options accepted by the constructor are described in detail
65
+
* in [this document](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#creating-the-client-instance).
// users can override the config from client side, like retry codes name.
104
-
// The detailed structure of the clientConfig can be found here: https://github.com/googleapis/gax-nodejs/blob/master/src/gax.ts#L546
105
-
// The way to override client config for Showcase API:
* @param {function(Error, string)} callback - the callback to
302
-
* be called with the current project Id.
303
+
* @returns {Promise} A promise that resolves to string containing the project ID.
303
304
*/
304
305
getProjectId(
305
306
callback?: Callback<string,undefined,undefined>
@@ -357,7 +358,11 @@ export class CompanyServiceClient {
357
358
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
358
359
* @returns {Promise} - The promise which resolves to an array.
359
360
* The first element of the array is an object representing [Company]{@link google.cloud.talent.v4.Company}.
360
-
* The promise has a method named "cancel" which cancels the ongoing API call.
@@ -443,7 +448,11 @@ export class CompanyServiceClient {
443
448
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
444
449
* @returns {Promise} - The promise which resolves to an array.
445
450
* The first element of the array is an object representing [Company]{@link google.cloud.talent.v4.Company}.
446
-
* The promise has a method named "cancel" which cancels the ongoing API call.
@@ -531,7 +540,11 @@ export class CompanyServiceClient {
531
540
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
532
541
* @returns {Promise} - The promise which resolves to an array.
533
542
* The first element of the array is an object representing [Company]{@link google.cloud.talent.v4.Company}.
534
-
* The promise has a method named "cancel" which cancels the ongoing API call.
@@ -618,7 +631,11 @@ export class CompanyServiceClient {
618
631
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
619
632
* @returns {Promise} - The promise which resolves to an array.
620
633
* The first element of the array is an object representing [Empty]{@link google.protobuf.Empty}.
621
-
* The promise has a method named "cancel" which cancels the ongoing API call.
@@ -716,19 +733,14 @@ export class CompanyServiceClient {
716
733
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
717
734
* @returns {Promise} - The promise which resolves to an array.
718
735
* The first element of the array is Array of [Company]{@link google.cloud.talent.v4.Company}.
719
-
* The client library support auto-pagination by default: it will call the API as many
736
+
* The client library will perform auto-pagination by default: it will call the API as many
720
737
* times as needed and will merge results from all the pages into this array.
721
-
*
722
-
* When autoPaginate: false is specified through options, the array has three elements.
723
-
* The first element is Array of [Company]{@link google.cloud.talent.v4.Company} that corresponds to
724
-
* the one page received from the API server.
725
-
* If the second element is not null it contains the request object of type [ListCompaniesRequest]{@link google.cloud.talent.v4.ListCompaniesRequest}
726
-
* that can be used to obtain the next page of the results.
727
-
* If it is null, the next page does not exist.
728
-
* The third element contains the raw response received from the API server. Its type is
* Equivalent to `method.name.toCamelCase()`, but returns a NodeJS Stream object.
789
790
* @param {Object} request
790
791
* The request object that will be sent.
791
792
* @param {string} request.parent
@@ -809,6 +810,13 @@ export class CompanyServiceClient {
809
810
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
810
811
* @returns {Stream}
811
812
* An object stream which emits an object representing [Company]{@link google.cloud.talent.v4.Company} on 'data' event.
813
+
* The client library will perform auto-pagination by default: it will call the API as many
814
+
* times as needed. Note that it can affect your quota.
815
+
* We recommend using `listCompaniesAsync()`
816
+
* method described below for async iteration which you can stop as needed.
@@ -833,10 +841,9 @@ export class CompanyServiceClient {
833
841
}
834
842
835
843
/**
836
-
* Equivalent to {@link listCompanies}, but returns an iterable object.
837
-
*
838
-
* for-await-of syntax is used with the iterable to recursively get response element on-demand.
844
+
* Equivalent to `listCompanies`, but returns an iterable object.
839
845
*
846
+
* `for`-`await`-`of` syntax is used with the iterable to get response elements on-demand.
840
847
* @param {Object} request
841
848
* The request object that will be sent.
842
849
* @param {string} request.parent
@@ -859,7 +866,18 @@ export class CompanyServiceClient {
859
866
* @param {object} [options]
860
867
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
861
868
* @returns {Object}
862
-
* An iterable Object that conforms to @link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols.
869
+
* An iterable Object that allows [async iteration](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols).
870
+
* When you iterate the returned iterable, each element will be an object representing
871
+
* [Company]{@link google.cloud.talent.v4.Company}. The API will be called under the hood as needed, once per the page,
872
+
* so you can stop the iteration when you don't need more results.
0 commit comments