From 5906122a237872867a860830ecb7567a6073c51e Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Fri, 18 Feb 2022 02:04:55 +0000 Subject: [PATCH] docs(samples): include metadata file, add exclusions for samples to handwritten libraries (#402) - [ ] Regenerate this pull request now. PiperOrigin-RevId: 429395631 Source-Link: https://github.com/googleapis/googleapis/commit/84594b35af0c38efcd6967e8179d801702ad96ff Source-Link: https://github.com/googleapis/googleapis-gen/commit/ed74f970fd82914874e6b27b04763cfa66bafe9b Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWQ3NGY5NzBmZDgyOTE0ODc0ZTZiMjdiMDQ3NjNjZmE2NmJhZmU5YiJ9 --- .../v4/company_service.create_company.js | 9 +- .../v4/company_service.delete_company.js | 9 +- .../v4/company_service.get_company.js | 9 +- .../v4/company_service.list_companies.js | 9 +- .../v4/company_service.update_company.js | 9 +- .../generated/v4/completion.complete_query.js | 9 +- .../v4/event_service.create_client_event.js | 9 +- .../v4/job_service.batch_create_jobs.js | 9 +- .../v4/job_service.batch_delete_jobs.js | 9 +- .../v4/job_service.batch_update_jobs.js | 9 +- .../generated/v4/job_service.create_job.js | 9 +- .../generated/v4/job_service.delete_job.js | 9 +- .../generated/v4/job_service.get_job.js | 9 +- .../generated/v4/job_service.list_jobs.js | 9 +- .../generated/v4/job_service.search_jobs.js | 9 +- .../v4/job_service.search_jobs_for_alert.js | 9 +- .../generated/v4/job_service.update_job.js | 9 +- ...ippet_metadata.google.cloud.talent.v4.json | 1111 +++++++++++ .../v4/tenant_service.create_tenant.js | 9 +- .../v4/tenant_service.delete_tenant.js | 9 +- .../generated/v4/tenant_service.get_tenant.js | 9 +- .../v4/tenant_service.list_tenants.js | 9 +- .../v4/tenant_service.update_tenant.js | 9 +- .../application_service.create_application.js | 9 +- .../application_service.delete_application.js | 9 +- .../application_service.get_application.js | 9 +- .../application_service.list_applications.js | 9 +- .../application_service.update_application.js | 9 +- .../v4beta1/company_service.create_company.js | 9 +- .../v4beta1/company_service.delete_company.js | 9 +- .../v4beta1/company_service.get_company.js | 9 +- .../v4beta1/company_service.list_companies.js | 9 +- .../v4beta1/company_service.update_company.js | 9 +- .../v4beta1/completion.complete_query.js | 9 +- .../event_service.create_client_event.js | 9 +- .../v4beta1/job_service.batch_create_jobs.js | 9 +- .../v4beta1/job_service.batch_delete_jobs.js | 9 +- .../v4beta1/job_service.batch_update_jobs.js | 9 +- .../v4beta1/job_service.create_job.js | 9 +- .../v4beta1/job_service.delete_job.js | 9 +- .../generated/v4beta1/job_service.get_job.js | 9 +- .../v4beta1/job_service.list_jobs.js | 9 +- .../v4beta1/job_service.search_jobs.js | 9 +- .../job_service.search_jobs_for_alert.js | 9 +- .../v4beta1/job_service.update_job.js | 9 +- .../v4beta1/profile_service.create_profile.js | 9 +- .../v4beta1/profile_service.delete_profile.js | 9 +- .../v4beta1/profile_service.get_profile.js | 9 +- .../v4beta1/profile_service.list_profiles.js | 9 +- .../profile_service.search_profiles.js | 9 +- .../v4beta1/profile_service.update_profile.js | 9 +- ..._metadata.google.cloud.talent.v4beta1.json | 1635 +++++++++++++++++ .../v4beta1/tenant_service.create_tenant.js | 9 +- .../v4beta1/tenant_service.delete_tenant.js | 9 +- .../v4beta1/tenant_service.get_tenant.js | 9 +- .../v4beta1/tenant_service.list_tenants.js | 9 +- .../v4beta1/tenant_service.update_tenant.js | 9 +- .../src/v4/company_service_client.ts | 5 +- .../src/v4/completion_client.ts | 5 +- .../src/v4/event_service_client.ts | 5 +- .../src/v4/job_service_client.ts | 5 +- .../src/v4/tenant_service_client.ts | 5 +- .../src/v4beta1/application_service_client.ts | 5 +- .../src/v4beta1/company_service_client.ts | 5 +- .../src/v4beta1/completion_client.ts | 5 +- .../src/v4beta1/event_service_client.ts | 5 +- .../src/v4beta1/job_service_client.ts | 5 +- .../src/v4beta1/profile_service_client.ts | 5 +- .../src/v4beta1/tenant_service_client.ts | 5 +- .../test/gapic_application_service_v4beta1.ts | 89 +- .../test/gapic_company_service_v4.ts | 84 +- .../test/gapic_company_service_v4beta1.ts | 84 +- .../test/gapic_completion_v4.ts | 35 +- .../test/gapic_completion_v4beta1.ts | 35 +- .../test/gapic_event_service_v4.ts | 35 +- .../test/gapic_event_service_v4beta1.ts | 35 +- .../test/gapic_job_service_v4.ts | 116 +- .../test/gapic_job_service_v4beta1.ts | 132 +- .../test/gapic_profile_service_v4beta1.ts | 100 +- .../test/gapic_tenant_service_v4.ts | 84 +- .../test/gapic_tenant_service_v4beta1.ts | 84 +- 81 files changed, 4044 insertions(+), 170 deletions(-) create mode 100644 packages/google-cloud-talent/samples/generated/v4/snippet_metadata.google.cloud.talent.v4.json create mode 100644 packages/google-cloud-talent/samples/generated/v4beta1/snippet_metadata.google.cloud.talent.v4beta1.json diff --git a/packages/google-cloud-talent/samples/generated/v4/company_service.create_company.js b/packages/google-cloud-talent/samples/generated/v4/company_service.create_company.js index 2155e14307d..9b123988265 100644 --- a/packages/google-cloud-talent/samples/generated/v4/company_service.create_company.js +++ b/packages/google-cloud-talent/samples/generated/v4/company_service.create_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/company_service.delete_company.js b/packages/google-cloud-talent/samples/generated/v4/company_service.delete_company.js index 8dacdd930a1..f9d5c0c5e0e 100644 --- a/packages/google-cloud-talent/samples/generated/v4/company_service.delete_company.js +++ b/packages/google-cloud-talent/samples/generated/v4/company_service.delete_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/company_service.get_company.js b/packages/google-cloud-talent/samples/generated/v4/company_service.get_company.js index 0c5d31b6906..0cf0c8eacad 100644 --- a/packages/google-cloud-talent/samples/generated/v4/company_service.get_company.js +++ b/packages/google-cloud-talent/samples/generated/v4/company_service.get_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/company_service.list_companies.js b/packages/google-cloud-talent/samples/generated/v4/company_service.list_companies.js index d92864c992d..dd801dd1253 100644 --- a/packages/google-cloud-talent/samples/generated/v4/company_service.list_companies.js +++ b/packages/google-cloud-talent/samples/generated/v4/company_service.list_companies.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/company_service.update_company.js b/packages/google-cloud-talent/samples/generated/v4/company_service.update_company.js index 4c0ce9fdf9b..8d052a666d5 100644 --- a/packages/google-cloud-talent/samples/generated/v4/company_service.update_company.js +++ b/packages/google-cloud-talent/samples/generated/v4/company_service.update_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/completion.complete_query.js b/packages/google-cloud-talent/samples/generated/v4/completion.complete_query.js index 9450bbd68c2..092dae70d77 100644 --- a/packages/google-cloud-talent/samples/generated/v4/completion.complete_query.js +++ b/packages/google-cloud-talent/samples/generated/v4/completion.complete_query.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/event_service.create_client_event.js b/packages/google-cloud-talent/samples/generated/v4/event_service.create_client_event.js index 84943c2a04a..f086c073a6d 100644 --- a/packages/google-cloud-talent/samples/generated/v4/event_service.create_client_event.js +++ b/packages/google-cloud-talent/samples/generated/v4/event_service.create_client_event.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_create_jobs.js b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_create_jobs.js index df75355a1ab..dfeac960a33 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_create_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_create_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_delete_jobs.js b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_delete_jobs.js index 4c5a8544ddf..2b6c3467b77 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_delete_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_delete_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_update_jobs.js b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_update_jobs.js index e5b47439cab..e1eddb21782 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.batch_update_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.batch_update_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.create_job.js b/packages/google-cloud-talent/samples/generated/v4/job_service.create_job.js index 29b861e0da2..349df868be6 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.create_job.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.create_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.delete_job.js b/packages/google-cloud-talent/samples/generated/v4/job_service.delete_job.js index 195b9714eeb..d6ff60c2dc2 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.delete_job.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.delete_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.get_job.js b/packages/google-cloud-talent/samples/generated/v4/job_service.get_job.js index 8143593fa52..2ca96b97d79 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.get_job.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.get_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.list_jobs.js b/packages/google-cloud-talent/samples/generated/v4/job_service.list_jobs.js index d2010a6129f..27f0cab6477 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.list_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.list_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs.js b/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs.js index 39512b29dc4..1d662a016e2 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs_for_alert.js b/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs_for_alert.js index 8dd5cc83d41..42823a11f8d 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs_for_alert.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.search_jobs_for_alert.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/job_service.update_job.js b/packages/google-cloud-talent/samples/generated/v4/job_service.update_job.js index e8996081073..37ced9bc31d 100644 --- a/packages/google-cloud-talent/samples/generated/v4/job_service.update_job.js +++ b/packages/google-cloud-talent/samples/generated/v4/job_service.update_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/snippet_metadata.google.cloud.talent.v4.json b/packages/google-cloud-talent/samples/generated/v4/snippet_metadata.google.cloud.talent.v4.json new file mode 100644 index 00000000000..a0721b29935 --- /dev/null +++ b/packages/google-cloud-talent/samples/generated/v4/snippet_metadata.google.cloud.talent.v4.json @@ -0,0 +1,1111 @@ +{ + "clientLibrary": { + "name": "nodejs-talent", + "version": "0.1.0", + "language": "TYPESCRIPT", + "apis": [ + { + "id": "google.cloud.talent.v4", + "version": "v4" + } + ] + }, + "snippets": [ + { + "regionTag": "jobs_v4_generated_CompanyService_CreateCompany_async", + "title": "talent createCompany Sample", + "origin": "API_DEFINITION", + "description": " Creates a new company entity.", + "canonical": true, + "file": "company_service.create_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 57, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateCompany", + "fullName": "google.cloud.talent.v4.CompanyService.CreateCompany", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "company", + "type": ".google.cloud.talent.v4.Company" + } + ], + "resultType": ".google.cloud.talent.v4.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4.CompanyServiceClient" + }, + "method": { + "shortName": "CreateCompany", + "fullName": "google.cloud.talent.v4.CompanyService.CreateCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_CompanyService_GetCompany_async", + "title": "talent getCompany Sample", + "origin": "API_DEFINITION", + "description": " Retrieves specified company.", + "canonical": true, + "file": "company_service.get_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetCompany", + "fullName": "google.cloud.talent.v4.CompanyService.GetCompany", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4.CompanyServiceClient" + }, + "method": { + "shortName": "GetCompany", + "fullName": "google.cloud.talent.v4.CompanyService.GetCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_CompanyService_UpdateCompany_async", + "title": "talent updateCompany Sample", + "origin": "API_DEFINITION", + "description": " Updates specified company.", + "canonical": true, + "file": "company_service.update_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateCompany", + "fullName": "google.cloud.talent.v4.CompanyService.UpdateCompany", + "async": true, + "parameters": [ + { + "name": "company", + "type": ".google.cloud.talent.v4.Company" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4.CompanyServiceClient" + }, + "method": { + "shortName": "UpdateCompany", + "fullName": "google.cloud.talent.v4.CompanyService.UpdateCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_CompanyService_DeleteCompany_async", + "title": "talent deleteCompany Sample", + "origin": "API_DEFINITION", + "description": " Deletes specified company. Prerequisite: The company has no jobs associated with it.", + "canonical": true, + "file": "company_service.delete_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteCompany", + "fullName": "google.cloud.talent.v4.CompanyService.DeleteCompany", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4.CompanyServiceClient" + }, + "method": { + "shortName": "DeleteCompany", + "fullName": "google.cloud.talent.v4.CompanyService.DeleteCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_CompanyService_ListCompanies_async", + "title": "talent listCompanies Sample", + "origin": "API_DEFINITION", + "description": " Lists all companies associated with the project.", + "canonical": true, + "file": "company_service.list_companies.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 70, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListCompanies", + "fullName": "google.cloud.talent.v4.CompanyService.ListCompanies", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "require_open_jobs", + "type": "TYPE_BOOL" + } + ], + "resultType": ".google.cloud.talent.v4.ListCompaniesResponse", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4.CompanyServiceClient" + }, + "method": { + "shortName": "ListCompanies", + "fullName": "google.cloud.talent.v4.CompanyService.ListCompanies", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_Completion_CompleteQuery_async", + "title": "talent completeQuery Sample", + "origin": "API_DEFINITION", + "description": " Completes the specified prefix with keyword suggestions. Intended for use by a job search auto-complete search box.", + "canonical": true, + "file": "completion.complete_query.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 87, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CompleteQuery", + "fullName": "google.cloud.talent.v4.Completion.CompleteQuery", + "async": true, + "parameters": [ + { + "name": "tenant", + "type": "TYPE_STRING" + }, + { + "name": "query", + "type": "TYPE_STRING" + }, + { + "name": "language_codes", + "type": "TYPE_STRING[]" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "company", + "type": "TYPE_STRING" + }, + { + "name": "scope", + "type": ".google.cloud.talent.v4.CompleteQueryRequest.CompletionScope" + }, + { + "name": "type", + "type": ".google.cloud.talent.v4.CompleteQueryRequest.CompletionType" + } + ], + "resultType": ".google.cloud.talent.v4.CompleteQueryResponse", + "client": { + "shortName": "CompletionClient", + "fullName": "google.cloud.talent.v4.CompletionClient" + }, + "method": { + "shortName": "CompleteQuery", + "fullName": "google.cloud.talent.v4.Completion.CompleteQuery", + "service": { + "shortName": "Completion", + "fullName": "google.cloud.talent.v4.Completion" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_EventService_CreateClientEvent_async", + "title": "talent createClientEvent Sample", + "origin": "API_DEFINITION", + "description": " Report events issued when end user interacts with customer's application that uses Cloud Talent Solution. You may inspect the created events in [self service tools](https://console.cloud.google.com/talent-solution/overview). [Learn more](https://cloud.google.com/talent-solution/docs/management-tools) about self service tools.", + "canonical": true, + "file": "event_service.create_client_event.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateClientEvent", + "fullName": "google.cloud.talent.v4.EventService.CreateClientEvent", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "client_event", + "type": ".google.cloud.talent.v4.ClientEvent" + } + ], + "resultType": ".google.cloud.talent.v4.ClientEvent", + "client": { + "shortName": "EventServiceClient", + "fullName": "google.cloud.talent.v4.EventServiceClient" + }, + "method": { + "shortName": "CreateClientEvent", + "fullName": "google.cloud.talent.v4.EventService.CreateClientEvent", + "service": { + "shortName": "EventService", + "fullName": "google.cloud.talent.v4.EventService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_CreateJob_async", + "title": "talent createJob Sample", + "origin": "API_DEFINITION", + "description": " Creates a new job. Typically, the job becomes searchable within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.create_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 57, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateJob", + "fullName": "google.cloud.talent.v4.JobService.CreateJob", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "job", + "type": ".google.cloud.talent.v4.Job" + } + ], + "resultType": ".google.cloud.talent.v4.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "CreateJob", + "fullName": "google.cloud.talent.v4.JobService.CreateJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_BatchCreateJobs_async", + "title": "talent batchCreateJobs Sample", + "origin": "API_DEFINITION", + "description": " Begins executing a batch create jobs operation.", + "canonical": true, + "file": "job_service.batch_create_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 59, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchCreateJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchCreateJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "jobs", + "type": "TYPE_MESSAGE[]" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "BatchCreateJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchCreateJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_GetJob_async", + "title": "talent getJob Sample", + "origin": "API_DEFINITION", + "description": " Retrieves the specified job, whose status is OPEN or recently EXPIRED within the last 90 days.", + "canonical": true, + "file": "job_service.get_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetJob", + "fullName": "google.cloud.talent.v4.JobService.GetJob", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "GetJob", + "fullName": "google.cloud.talent.v4.JobService.GetJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_UpdateJob_async", + "title": "talent updateJob Sample", + "origin": "API_DEFINITION", + "description": " Updates specified job. Typically, updated contents become visible in search results within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.update_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateJob", + "fullName": "google.cloud.talent.v4.JobService.UpdateJob", + "async": true, + "parameters": [ + { + "name": "job", + "type": ".google.cloud.talent.v4.Job" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "UpdateJob", + "fullName": "google.cloud.talent.v4.JobService.UpdateJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_BatchUpdateJobs_async", + "title": "talent batchUpdateJobs Sample", + "origin": "API_DEFINITION", + "description": " Begins executing a batch update jobs operation.", + "canonical": true, + "file": "job_service.batch_update_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 73, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchUpdateJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchUpdateJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "jobs", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "BatchUpdateJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchUpdateJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_DeleteJob_async", + "title": "talent deleteJob Sample", + "origin": "API_DEFINITION", + "description": " Deletes the specified job. Typically, the job becomes unsearchable within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.delete_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteJob", + "fullName": "google.cloud.talent.v4.JobService.DeleteJob", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "DeleteJob", + "fullName": "google.cloud.talent.v4.JobService.DeleteJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_BatchDeleteJobs_async", + "title": "talent batchDeleteJobs Sample", + "origin": "API_DEFINITION", + "description": " Begins executing a batch delete jobs operation.", + "canonical": true, + "file": "job_service.batch_delete_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 61, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchDeleteJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchDeleteJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "names", + "type": "TYPE_STRING[]" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "BatchDeleteJobs", + "fullName": "google.cloud.talent.v4.JobService.BatchDeleteJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_ListJobs_async", + "title": "talent listJobs Sample", + "origin": "API_DEFINITION", + "description": " Lists jobs by filter.", + "canonical": true, + "file": "job_service.list_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 92, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListJobs", + "fullName": "google.cloud.talent.v4.JobService.ListJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "filter", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4.JobView" + } + ], + "resultType": ".google.cloud.talent.v4.ListJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "ListJobs", + "fullName": "google.cloud.talent.v4.JobService.ListJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_SearchJobs_async", + "title": "talent searchJobs Sample", + "origin": "API_DEFINITION", + "description": " Searches for jobs using the provided [SearchJobsRequest][google.cloud.talent.v4.SearchJobsRequest]. This call constrains the [visibility][google.cloud.talent.v4.Job.visibility] of jobs present in the database, and only returns jobs that the caller has permission to search against.", + "canonical": true, + "file": "job_service.search_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 287, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "SearchJobs", + "fullName": "google.cloud.talent.v4.JobService.SearchJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "search_mode", + "type": ".google.cloud.talent.v4.SearchJobsRequest.SearchMode" + }, + { + "name": "request_metadata", + "type": ".google.cloud.talent.v4.RequestMetadata" + }, + { + "name": "job_query", + "type": ".google.cloud.talent.v4.JobQuery" + }, + { + "name": "enable_broadening", + "type": "TYPE_BOOL" + }, + { + "name": "histogram_queries", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4.JobView" + }, + { + "name": "offset", + "type": "TYPE_INT32" + }, + { + "name": "max_page_size", + "type": "TYPE_INT32" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "order_by", + "type": "TYPE_STRING" + }, + { + "name": "diversification_level", + "type": ".google.cloud.talent.v4.SearchJobsRequest.DiversificationLevel" + }, + { + "name": "custom_ranking_info", + "type": ".google.cloud.talent.v4.SearchJobsRequest.CustomRankingInfo" + }, + { + "name": "disable_keyword_match", + "type": "TYPE_BOOL" + }, + { + "name": "keyword_match_mode", + "type": ".google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode" + } + ], + "resultType": ".google.cloud.talent.v4.SearchJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "SearchJobs", + "fullName": "google.cloud.talent.v4.JobService.SearchJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_JobService_SearchJobsForAlert_async", + "title": "talent searchJobsForAlert Sample", + "origin": "API_DEFINITION", + "description": " Searches for jobs using the provided [SearchJobsRequest][google.cloud.talent.v4.SearchJobsRequest]. This API call is intended for the use case of targeting passive job seekers (for example, job seekers who have signed up to receive email alerts about potential job opportunities), it has different algorithmic adjustments that are designed to specifically target passive job seekers. This call constrains the [visibility][google.cloud.talent.v4.Job.visibility] of jobs present in the database, and only returns jobs the caller has permission to search against.", + "canonical": true, + "file": "job_service.search_jobs_for_alert.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 287, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "SearchJobsForAlert", + "fullName": "google.cloud.talent.v4.JobService.SearchJobsForAlert", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "search_mode", + "type": ".google.cloud.talent.v4.SearchJobsRequest.SearchMode" + }, + { + "name": "request_metadata", + "type": ".google.cloud.talent.v4.RequestMetadata" + }, + { + "name": "job_query", + "type": ".google.cloud.talent.v4.JobQuery" + }, + { + "name": "enable_broadening", + "type": "TYPE_BOOL" + }, + { + "name": "histogram_queries", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4.JobView" + }, + { + "name": "offset", + "type": "TYPE_INT32" + }, + { + "name": "max_page_size", + "type": "TYPE_INT32" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "order_by", + "type": "TYPE_STRING" + }, + { + "name": "diversification_level", + "type": ".google.cloud.talent.v4.SearchJobsRequest.DiversificationLevel" + }, + { + "name": "custom_ranking_info", + "type": ".google.cloud.talent.v4.SearchJobsRequest.CustomRankingInfo" + }, + { + "name": "disable_keyword_match", + "type": "TYPE_BOOL" + }, + { + "name": "keyword_match_mode", + "type": ".google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode" + } + ], + "resultType": ".google.cloud.talent.v4.SearchJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4.JobServiceClient" + }, + "method": { + "shortName": "SearchJobsForAlert", + "fullName": "google.cloud.talent.v4.JobService.SearchJobsForAlert", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_TenantService_CreateTenant_async", + "title": "talent createTenant Sample", + "origin": "API_DEFINITION", + "description": " Creates a new tenant entity.", + "canonical": true, + "file": "tenant_service.create_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 57, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateTenant", + "fullName": "google.cloud.talent.v4.TenantService.CreateTenant", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "tenant", + "type": ".google.cloud.talent.v4.Tenant" + } + ], + "resultType": ".google.cloud.talent.v4.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4.TenantServiceClient" + }, + "method": { + "shortName": "CreateTenant", + "fullName": "google.cloud.talent.v4.TenantService.CreateTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_TenantService_GetTenant_async", + "title": "talent getTenant Sample", + "origin": "API_DEFINITION", + "description": " Retrieves specified tenant.", + "canonical": true, + "file": "tenant_service.get_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 52, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetTenant", + "fullName": "google.cloud.talent.v4.TenantService.GetTenant", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4.TenantServiceClient" + }, + "method": { + "shortName": "GetTenant", + "fullName": "google.cloud.talent.v4.TenantService.GetTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_TenantService_UpdateTenant_async", + "title": "talent updateTenant Sample", + "origin": "API_DEFINITION", + "description": " Updates specified tenant.", + "canonical": true, + "file": "tenant_service.update_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateTenant", + "fullName": "google.cloud.talent.v4.TenantService.UpdateTenant", + "async": true, + "parameters": [ + { + "name": "tenant", + "type": ".google.cloud.talent.v4.Tenant" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4.TenantServiceClient" + }, + "method": { + "shortName": "UpdateTenant", + "fullName": "google.cloud.talent.v4.TenantService.UpdateTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_TenantService_DeleteTenant_async", + "title": "talent deleteTenant Sample", + "origin": "API_DEFINITION", + "description": " Deletes specified tenant.", + "canonical": true, + "file": "tenant_service.delete_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 52, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteTenant", + "fullName": "google.cloud.talent.v4.TenantService.DeleteTenant", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4.TenantServiceClient" + }, + "method": { + "shortName": "DeleteTenant", + "fullName": "google.cloud.talent.v4.TenantService.DeleteTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4_generated_TenantService_ListTenants_async", + "title": "talent listTenants Sample", + "origin": "API_DEFINITION", + "description": " Lists all tenants associated with the project.", + "canonical": true, + "file": "tenant_service.list_tenants.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 63, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListTenants", + "fullName": "google.cloud.talent.v4.TenantService.ListTenants", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + } + ], + "resultType": ".google.cloud.talent.v4.ListTenantsResponse", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4.TenantServiceClient" + }, + "method": { + "shortName": "ListTenants", + "fullName": "google.cloud.talent.v4.TenantService.ListTenants", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4.TenantService" + } + } + } + } + ] +} diff --git a/packages/google-cloud-talent/samples/generated/v4/tenant_service.create_tenant.js b/packages/google-cloud-talent/samples/generated/v4/tenant_service.create_tenant.js index 0dd0a27bd15..d634b8a73eb 100644 --- a/packages/google-cloud-talent/samples/generated/v4/tenant_service.create_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4/tenant_service.create_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/tenant_service.delete_tenant.js b/packages/google-cloud-talent/samples/generated/v4/tenant_service.delete_tenant.js index ca5ae42339f..a2ef1f9ca6e 100644 --- a/packages/google-cloud-talent/samples/generated/v4/tenant_service.delete_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4/tenant_service.delete_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/tenant_service.get_tenant.js b/packages/google-cloud-talent/samples/generated/v4/tenant_service.get_tenant.js index 308bde408e9..460a3502a85 100644 --- a/packages/google-cloud-talent/samples/generated/v4/tenant_service.get_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4/tenant_service.get_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/tenant_service.list_tenants.js b/packages/google-cloud-talent/samples/generated/v4/tenant_service.list_tenants.js index d3074ad7f56..f01ef74e530 100644 --- a/packages/google-cloud-talent/samples/generated/v4/tenant_service.list_tenants.js +++ b/packages/google-cloud-talent/samples/generated/v4/tenant_service.list_tenants.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4/tenant_service.update_tenant.js b/packages/google-cloud-talent/samples/generated/v4/tenant_service.update_tenant.js index c3cd7ac1224..a89ad3a5f1d 100644 --- a/packages/google-cloud-talent/samples/generated/v4/tenant_service.update_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4/tenant_service.update_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.create_application.js b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.create_application.js index ed16edf6d86..137e1b223cb 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.create_application.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.create_application.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.delete_application.js b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.delete_application.js index 2cccb8b2e68..317e90c8383 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.delete_application.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.delete_application.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.get_application.js b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.get_application.js index f89208838f2..2b3693ab062 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.get_application.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.get_application.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.list_applications.js b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.list_applications.js index 6470da5620e..a983ae0291a 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.list_applications.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.list_applications.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.update_application.js b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.update_application.js index a1e36ebbcce..ce5611bbe97 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/application_service.update_application.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/application_service.update_application.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.create_company.js b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.create_company.js index 383b2395151..1d345f30839 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.create_company.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.create_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.delete_company.js b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.delete_company.js index 3b74c688068..8c5f96e1385 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.delete_company.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.delete_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.get_company.js b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.get_company.js index 27681cceee9..12f2d3c1fee 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.get_company.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.get_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.list_companies.js b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.list_companies.js index 2905167cafd..5c4db46aeb4 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.list_companies.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.list_companies.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.update_company.js b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.update_company.js index c5305adebd2..648b00dd334 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/company_service.update_company.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/company_service.update_company.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/completion.complete_query.js b/packages/google-cloud-talent/samples/generated/v4beta1/completion.complete_query.js index 84a742d9431..5e2e57e2e3b 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/completion.complete_query.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/completion.complete_query.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/event_service.create_client_event.js b/packages/google-cloud-talent/samples/generated/v4beta1/event_service.create_client_event.js index ab68cc108fa..9782a181819 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/event_service.create_client_event.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/event_service.create_client_event.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_create_jobs.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_create_jobs.js index ddf2649e0eb..596cf252967 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_create_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_create_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_delete_jobs.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_delete_jobs.js index dca452e3518..44a9b9f4c84 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_delete_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_delete_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_update_jobs.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_update_jobs.js index e30927d3900..c822222819f 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_update_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.batch_update_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.create_job.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.create_job.js index a29530fe520..58d79b6d4d8 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.create_job.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.create_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.delete_job.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.delete_job.js index cbffffdf348..3a9e12a5925 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.delete_job.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.delete_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.get_job.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.get_job.js index a9a870b6f93..f4f4aa6b918 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.get_job.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.get_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.list_jobs.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.list_jobs.js index cabf763a45b..fce325739d0 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.list_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.list_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs.js index 13216e72aec..0249a8386f4 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs_for_alert.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs_for_alert.js index 475f41c6207..e4ebad2b2cf 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs_for_alert.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.search_jobs_for_alert.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.update_job.js b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.update_job.js index 31a025bd44e..935ecb9c3e5 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/job_service.update_job.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/job_service.update_job.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.create_profile.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.create_profile.js index ed9e7ae31c6..77ab632395c 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.create_profile.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.create_profile.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.delete_profile.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.delete_profile.js index 9398abeae92..3d28a2ed9ed 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.delete_profile.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.delete_profile.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.get_profile.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.get_profile.js index 62280761b45..7dff795e1c0 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.get_profile.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.get_profile.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.list_profiles.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.list_profiles.js index 51109462e47..421059d078f 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.list_profiles.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.list_profiles.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.search_profiles.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.search_profiles.js index 19c0b7cd4c9..eb0ec371727 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.search_profiles.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.search_profiles.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.update_profile.js b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.update_profile.js index bad2e4fae3b..5c1e429496e 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.update_profile.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/profile_service.update_profile.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/snippet_metadata.google.cloud.talent.v4beta1.json b/packages/google-cloud-talent/samples/generated/v4beta1/snippet_metadata.google.cloud.talent.v4beta1.json new file mode 100644 index 00000000000..57b52cb3d67 --- /dev/null +++ b/packages/google-cloud-talent/samples/generated/v4beta1/snippet_metadata.google.cloud.talent.v4beta1.json @@ -0,0 +1,1635 @@ +{ + "clientLibrary": { + "name": "nodejs-talent", + "version": "0.1.0", + "language": "TYPESCRIPT", + "apis": [ + { + "id": "google.cloud.talent.v4beta1", + "version": "v4beta1" + } + ] + }, + "snippets": [ + { + "regionTag": "jobs_v4beta1_generated_ApplicationService_CreateApplication_async", + "title": "talent createApplication Sample", + "origin": "API_DEFINITION", + "description": " Creates a new application entity.", + "canonical": true, + "file": "application_service.create_application.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.CreateApplication", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "application", + "type": ".google.cloud.talent.v4beta1.Application" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Application", + "client": { + "shortName": "ApplicationServiceClient", + "fullName": "google.cloud.talent.v4beta1.ApplicationServiceClient" + }, + "method": { + "shortName": "CreateApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.CreateApplication", + "service": { + "shortName": "ApplicationService", + "fullName": "google.cloud.talent.v4beta1.ApplicationService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ApplicationService_GetApplication_async", + "title": "talent getApplication Sample", + "origin": "API_DEFINITION", + "description": " Retrieves specified application.", + "canonical": true, + "file": "application_service.get_application.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.GetApplication", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Application", + "client": { + "shortName": "ApplicationServiceClient", + "fullName": "google.cloud.talent.v4beta1.ApplicationServiceClient" + }, + "method": { + "shortName": "GetApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.GetApplication", + "service": { + "shortName": "ApplicationService", + "fullName": "google.cloud.talent.v4beta1.ApplicationService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ApplicationService_UpdateApplication_async", + "title": "talent updateApplication Sample", + "origin": "API_DEFINITION", + "description": " Updates specified application.", + "canonical": true, + "file": "application_service.update_application.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.UpdateApplication", + "async": true, + "parameters": [ + { + "name": "application", + "type": ".google.cloud.talent.v4beta1.Application" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Application", + "client": { + "shortName": "ApplicationServiceClient", + "fullName": "google.cloud.talent.v4beta1.ApplicationServiceClient" + }, + "method": { + "shortName": "UpdateApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.UpdateApplication", + "service": { + "shortName": "ApplicationService", + "fullName": "google.cloud.talent.v4beta1.ApplicationService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ApplicationService_DeleteApplication_async", + "title": "talent deleteApplication Sample", + "origin": "API_DEFINITION", + "description": " Deletes specified application.", + "canonical": true, + "file": "application_service.delete_application.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.DeleteApplication", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "ApplicationServiceClient", + "fullName": "google.cloud.talent.v4beta1.ApplicationServiceClient" + }, + "method": { + "shortName": "DeleteApplication", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.DeleteApplication", + "service": { + "shortName": "ApplicationService", + "fullName": "google.cloud.talent.v4beta1.ApplicationService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ApplicationService_ListApplications_async", + "title": "talent listApplications Sample", + "origin": "API_DEFINITION", + "description": " Lists all applications associated with the profile.", + "canonical": true, + "file": "application_service.list_applications.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 64, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListApplications", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.ListApplications", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ListApplicationsResponse", + "client": { + "shortName": "ApplicationServiceClient", + "fullName": "google.cloud.talent.v4beta1.ApplicationServiceClient" + }, + "method": { + "shortName": "ListApplications", + "fullName": "google.cloud.talent.v4beta1.ApplicationService.ListApplications", + "service": { + "shortName": "ApplicationService", + "fullName": "google.cloud.talent.v4beta1.ApplicationService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_CompanyService_CreateCompany_async", + "title": "talent createCompany Sample", + "origin": "API_DEFINITION", + "description": " Creates a new company entity.", + "canonical": true, + "file": "company_service.create_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.CreateCompany", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "company", + "type": ".google.cloud.talent.v4beta1.Company" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4beta1.CompanyServiceClient" + }, + "method": { + "shortName": "CreateCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.CreateCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4beta1.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_CompanyService_GetCompany_async", + "title": "talent getCompany Sample", + "origin": "API_DEFINITION", + "description": " Retrieves specified company.", + "canonical": true, + "file": "company_service.get_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 55, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.GetCompany", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4beta1.CompanyServiceClient" + }, + "method": { + "shortName": "GetCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.GetCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4beta1.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_CompanyService_UpdateCompany_async", + "title": "talent updateCompany Sample", + "origin": "API_DEFINITION", + "description": " Updates specified company.", + "canonical": true, + "file": "company_service.update_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.UpdateCompany", + "async": true, + "parameters": [ + { + "name": "company", + "type": ".google.cloud.talent.v4beta1.Company" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Company", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4beta1.CompanyServiceClient" + }, + "method": { + "shortName": "UpdateCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.UpdateCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4beta1.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_CompanyService_DeleteCompany_async", + "title": "talent deleteCompany Sample", + "origin": "API_DEFINITION", + "description": " Deletes specified company. Prerequisite: The company has no jobs associated with it.", + "canonical": true, + "file": "company_service.delete_company.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 55, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.DeleteCompany", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4beta1.CompanyServiceClient" + }, + "method": { + "shortName": "DeleteCompany", + "fullName": "google.cloud.talent.v4beta1.CompanyService.DeleteCompany", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4beta1.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_CompanyService_ListCompanies_async", + "title": "talent listCompanies Sample", + "origin": "API_DEFINITION", + "description": " Lists all companies associated with the project.", + "canonical": true, + "file": "company_service.list_companies.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 72, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListCompanies", + "fullName": "google.cloud.talent.v4beta1.CompanyService.ListCompanies", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "require_open_jobs", + "type": "TYPE_BOOL" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ListCompaniesResponse", + "client": { + "shortName": "CompanyServiceClient", + "fullName": "google.cloud.talent.v4beta1.CompanyServiceClient" + }, + "method": { + "shortName": "ListCompanies", + "fullName": "google.cloud.talent.v4beta1.CompanyService.ListCompanies", + "service": { + "shortName": "CompanyService", + "fullName": "google.cloud.talent.v4beta1.CompanyService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_Completion_CompleteQuery_async", + "title": "talent completeQuery Sample", + "origin": "API_DEFINITION", + "description": " Completes the specified prefix with keyword suggestions. Intended for use by a job search auto-complete search box.", + "canonical": true, + "file": "completion.complete_query.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 91, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CompleteQuery", + "fullName": "google.cloud.talent.v4beta1.Completion.CompleteQuery", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "query", + "type": "TYPE_STRING" + }, + { + "name": "language_codes", + "type": "TYPE_STRING[]" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "company", + "type": "TYPE_STRING" + }, + { + "name": "scope", + "type": ".google.cloud.talent.v4beta1.CompleteQueryRequest.CompletionScope" + }, + { + "name": "type", + "type": ".google.cloud.talent.v4beta1.CompleteQueryRequest.CompletionType" + } + ], + "resultType": ".google.cloud.talent.v4beta1.CompleteQueryResponse", + "client": { + "shortName": "CompletionClient", + "fullName": "google.cloud.talent.v4beta1.CompletionClient" + }, + "method": { + "shortName": "CompleteQuery", + "fullName": "google.cloud.talent.v4beta1.Completion.CompleteQuery", + "service": { + "shortName": "Completion", + "fullName": "google.cloud.talent.v4beta1.Completion" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_EventService_CreateClientEvent_async", + "title": "talent createClientEvent Sample", + "origin": "API_DEFINITION", + "description": " Report events issued when end user interacts with customer's application that uses Cloud Talent Solution. You may inspect the created events in [self service tools](https://console.cloud.google.com/talent-solution/overview). [Learn more](https://cloud.google.com/talent-solution/docs/management-tools) about self service tools.", + "canonical": true, + "file": "event_service.create_client_event.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 59, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateClientEvent", + "fullName": "google.cloud.talent.v4beta1.EventService.CreateClientEvent", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "client_event", + "type": ".google.cloud.talent.v4beta1.ClientEvent" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ClientEvent", + "client": { + "shortName": "EventServiceClient", + "fullName": "google.cloud.talent.v4beta1.EventServiceClient" + }, + "method": { + "shortName": "CreateClientEvent", + "fullName": "google.cloud.talent.v4beta1.EventService.CreateClientEvent", + "service": { + "shortName": "EventService", + "fullName": "google.cloud.talent.v4beta1.EventService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_CreateJob_async", + "title": "talent createJob Sample", + "origin": "API_DEFINITION", + "description": " Creates a new job. Typically, the job becomes searchable within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.create_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateJob", + "fullName": "google.cloud.talent.v4beta1.JobService.CreateJob", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "job", + "type": ".google.cloud.talent.v4beta1.Job" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "CreateJob", + "fullName": "google.cloud.talent.v4beta1.JobService.CreateJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_BatchCreateJobs_async", + "title": "talent batchCreateJobs Sample", + "origin": "API_DEFINITION", + "description": " Begins executing a batch create jobs operation.", + "canonical": true, + "file": "job_service.batch_create_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 59, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchCreateJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchCreateJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "jobs", + "type": "TYPE_MESSAGE[]" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "BatchCreateJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchCreateJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_GetJob_async", + "title": "talent getJob Sample", + "origin": "API_DEFINITION", + "description": " Retrieves the specified job, whose status is OPEN or recently EXPIRED within the last 90 days.", + "canonical": true, + "file": "job_service.get_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 55, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetJob", + "fullName": "google.cloud.talent.v4beta1.JobService.GetJob", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "GetJob", + "fullName": "google.cloud.talent.v4beta1.JobService.GetJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_UpdateJob_async", + "title": "talent updateJob Sample", + "origin": "API_DEFINITION", + "description": " Updates specified job. Typically, updated contents become visible in search results within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.update_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateJob", + "fullName": "google.cloud.talent.v4beta1.JobService.UpdateJob", + "async": true, + "parameters": [ + { + "name": "job", + "type": ".google.cloud.talent.v4beta1.Job" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Job", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "UpdateJob", + "fullName": "google.cloud.talent.v4beta1.JobService.UpdateJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_BatchUpdateJobs_async", + "title": "talent batchUpdateJobs Sample", + "origin": "API_DEFINITION", + "description": " Begins executing a batch update jobs operation.", + "canonical": true, + "file": "job_service.batch_update_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 73, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchUpdateJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchUpdateJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "jobs", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.longrunning.Operation", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "BatchUpdateJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchUpdateJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_DeleteJob_async", + "title": "talent deleteJob Sample", + "origin": "API_DEFINITION", + "description": " Deletes the specified job. Typically, the job becomes unsearchable within 10 seconds, but it may take up to 5 minutes.", + "canonical": true, + "file": "job_service.delete_job.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 55, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteJob", + "fullName": "google.cloud.talent.v4beta1.JobService.DeleteJob", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "DeleteJob", + "fullName": "google.cloud.talent.v4beta1.JobService.DeleteJob", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_BatchDeleteJobs_async", + "title": "talent batchDeleteJobs Sample", + "origin": "API_DEFINITION", + "description": " Deletes a list of [Job][google.cloud.talent.v4beta1.Job]s by filter.", + "canonical": true, + "file": "job_service.batch_delete_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 64, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "BatchDeleteJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchDeleteJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "filter", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "BatchDeleteJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.BatchDeleteJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_ListJobs_async", + "title": "talent listJobs Sample", + "origin": "API_DEFINITION", + "description": " Lists jobs by filter.", + "canonical": true, + "file": "job_service.list_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 89, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.ListJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "filter", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4beta1.JobView" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ListJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "ListJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.ListJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_SearchJobs_async", + "title": "talent searchJobs Sample", + "origin": "API_DEFINITION", + "description": " Searches for jobs using the provided [SearchJobsRequest][google.cloud.talent.v4beta1.SearchJobsRequest]. This call constrains the [visibility][google.cloud.talent.v4beta1.Job.visibility] of jobs present in the database, and only returns jobs that the caller has permission to search against.", + "canonical": true, + "file": "job_service.search_jobs.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 282, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "SearchJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.SearchJobs", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "search_mode", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.SearchMode" + }, + { + "name": "request_metadata", + "type": ".google.cloud.talent.v4beta1.RequestMetadata" + }, + { + "name": "job_query", + "type": ".google.cloud.talent.v4beta1.JobQuery" + }, + { + "name": "enable_broadening", + "type": "TYPE_BOOL" + }, + { + "name": "require_precise_result_size", + "type": "TYPE_BOOL" + }, + { + "name": "histogram_queries", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4beta1.JobView" + }, + { + "name": "offset", + "type": "TYPE_INT32" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "order_by", + "type": "TYPE_STRING" + }, + { + "name": "diversification_level", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.DiversificationLevel" + }, + { + "name": "custom_ranking_info", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.CustomRankingInfo" + }, + { + "name": "disable_keyword_match", + "type": "TYPE_BOOL" + } + ], + "resultType": ".google.cloud.talent.v4beta1.SearchJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "SearchJobs", + "fullName": "google.cloud.talent.v4beta1.JobService.SearchJobs", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_JobService_SearchJobsForAlert_async", + "title": "talent searchJobsForAlert Sample", + "origin": "API_DEFINITION", + "description": " Searches for jobs using the provided [SearchJobsRequest][google.cloud.talent.v4beta1.SearchJobsRequest]. This API call is intended for the use case of targeting passive job seekers (for example, job seekers who have signed up to receive email alerts about potential job opportunities), and has different algorithmic adjustments that are targeted to passive job seekers. This call constrains the [visibility][google.cloud.talent.v4beta1.Job.visibility] of jobs present in the database, and only returns jobs the caller has permission to search against.", + "canonical": true, + "file": "job_service.search_jobs_for_alert.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 282, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "SearchJobsForAlert", + "fullName": "google.cloud.talent.v4beta1.JobService.SearchJobsForAlert", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "search_mode", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.SearchMode" + }, + { + "name": "request_metadata", + "type": ".google.cloud.talent.v4beta1.RequestMetadata" + }, + { + "name": "job_query", + "type": ".google.cloud.talent.v4beta1.JobQuery" + }, + { + "name": "enable_broadening", + "type": "TYPE_BOOL" + }, + { + "name": "require_precise_result_size", + "type": "TYPE_BOOL" + }, + { + "name": "histogram_queries", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "job_view", + "type": ".google.cloud.talent.v4beta1.JobView" + }, + { + "name": "offset", + "type": "TYPE_INT32" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "order_by", + "type": "TYPE_STRING" + }, + { + "name": "diversification_level", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.DiversificationLevel" + }, + { + "name": "custom_ranking_info", + "type": ".google.cloud.talent.v4beta1.SearchJobsRequest.CustomRankingInfo" + }, + { + "name": "disable_keyword_match", + "type": "TYPE_BOOL" + } + ], + "resultType": ".google.cloud.talent.v4beta1.SearchJobsResponse", + "client": { + "shortName": "JobServiceClient", + "fullName": "google.cloud.talent.v4beta1.JobServiceClient" + }, + "method": { + "shortName": "SearchJobsForAlert", + "fullName": "google.cloud.talent.v4beta1.JobService.SearchJobsForAlert", + "service": { + "shortName": "JobService", + "fullName": "google.cloud.talent.v4beta1.JobService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_ListProfiles_async", + "title": "talent listProfiles Sample", + "origin": "API_DEFINITION", + "description": " Lists profiles by filter. The order is unspecified.", + "canonical": true, + "file": "profile_service.list_profiles.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 86, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListProfiles", + "fullName": "google.cloud.talent.v4beta1.ProfileService.ListProfiles", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "filter", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "read_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ListProfilesResponse", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "ListProfiles", + "fullName": "google.cloud.talent.v4beta1.ProfileService.ListProfiles", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_CreateProfile_async", + "title": "talent createProfile Sample", + "origin": "API_DEFINITION", + "description": " Creates and returns a new profile.", + "canonical": true, + "file": "profile_service.create_profile.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 57, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.CreateProfile", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "profile", + "type": ".google.cloud.talent.v4beta1.Profile" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Profile", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "CreateProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.CreateProfile", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_GetProfile_async", + "title": "talent getProfile Sample", + "origin": "API_DEFINITION", + "description": " Gets the specified profile.", + "canonical": true, + "file": "profile_service.get_profile.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.GetProfile", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Profile", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "GetProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.GetProfile", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_UpdateProfile_async", + "title": "talent updateProfile Sample", + "origin": "API_DEFINITION", + "description": " Updates the specified profile and returns the updated result.", + "canonical": true, + "file": "profile_service.update_profile.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 55, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.UpdateProfile", + "async": true, + "parameters": [ + { + "name": "profile", + "type": ".google.cloud.talent.v4beta1.Profile" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Profile", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "UpdateProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.UpdateProfile", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_DeleteProfile_async", + "title": "talent deleteProfile Sample", + "origin": "API_DEFINITION", + "description": " Deletes the specified profile. Prerequisite: The profile has no associated applications or assignments associated.", + "canonical": true, + "file": "profile_service.delete_profile.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 53, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.DeleteProfile", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "DeleteProfile", + "fullName": "google.cloud.talent.v4beta1.ProfileService.DeleteProfile", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_ProfileService_SearchProfiles_async", + "title": "talent searchProfiles Sample", + "origin": "API_DEFINITION", + "description": " Searches for profiles within a tenant. For example, search by raw queries \"software engineer in Mountain View\" or search by structured filters (location filter, education filter, etc.). See [SearchProfilesRequest][google.cloud.talent.v4beta1.SearchProfilesRequest] for more information.", + "canonical": true, + "file": "profile_service.search_profiles.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 219, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "SearchProfiles", + "fullName": "google.cloud.talent.v4beta1.ProfileService.SearchProfiles", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "request_metadata", + "type": ".google.cloud.talent.v4beta1.RequestMetadata" + }, + { + "name": "profile_query", + "type": ".google.cloud.talent.v4beta1.ProfileQuery" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "offset", + "type": "TYPE_INT32" + }, + { + "name": "disable_spell_check", + "type": "TYPE_BOOL" + }, + { + "name": "order_by", + "type": "TYPE_STRING" + }, + { + "name": "case_sensitive_sort", + "type": "TYPE_BOOL" + }, + { + "name": "histogram_queries", + "type": "TYPE_MESSAGE[]" + }, + { + "name": "result_set_id", + "type": "TYPE_STRING" + }, + { + "name": "strict_keywords_search", + "type": "TYPE_BOOL" + } + ], + "resultType": ".google.cloud.talent.v4beta1.SearchProfilesResponse", + "client": { + "shortName": "ProfileServiceClient", + "fullName": "google.cloud.talent.v4beta1.ProfileServiceClient" + }, + "method": { + "shortName": "SearchProfiles", + "fullName": "google.cloud.talent.v4beta1.ProfileService.SearchProfiles", + "service": { + "shortName": "ProfileService", + "fullName": "google.cloud.talent.v4beta1.ProfileService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_TenantService_CreateTenant_async", + "title": "talent createTenant Sample", + "origin": "API_DEFINITION", + "description": " Creates a new tenant entity.", + "canonical": true, + "file": "tenant_service.create_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 57, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "CreateTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.CreateTenant", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "tenant", + "type": ".google.cloud.talent.v4beta1.Tenant" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4beta1.TenantServiceClient" + }, + "method": { + "shortName": "CreateTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.CreateTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4beta1.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_TenantService_GetTenant_async", + "title": "talent getTenant Sample", + "origin": "API_DEFINITION", + "description": " Retrieves specified tenant.", + "canonical": true, + "file": "tenant_service.get_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 52, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "GetTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.GetTenant", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4beta1.TenantServiceClient" + }, + "method": { + "shortName": "GetTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.GetTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4beta1.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_TenantService_UpdateTenant_async", + "title": "talent updateTenant Sample", + "origin": "API_DEFINITION", + "description": " Updates specified tenant.", + "canonical": true, + "file": "tenant_service.update_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 58, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "UpdateTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.UpdateTenant", + "async": true, + "parameters": [ + { + "name": "tenant", + "type": ".google.cloud.talent.v4beta1.Tenant" + }, + { + "name": "update_mask", + "type": ".google.protobuf.FieldMask" + } + ], + "resultType": ".google.cloud.talent.v4beta1.Tenant", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4beta1.TenantServiceClient" + }, + "method": { + "shortName": "UpdateTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.UpdateTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4beta1.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_TenantService_DeleteTenant_async", + "title": "talent deleteTenant Sample", + "origin": "API_DEFINITION", + "description": " Deletes specified tenant.", + "canonical": true, + "file": "tenant_service.delete_tenant.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 52, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "DeleteTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.DeleteTenant", + "async": true, + "parameters": [ + { + "name": "name", + "type": "TYPE_STRING" + } + ], + "resultType": ".google.protobuf.Empty", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4beta1.TenantServiceClient" + }, + "method": { + "shortName": "DeleteTenant", + "fullName": "google.cloud.talent.v4beta1.TenantService.DeleteTenant", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4beta1.TenantService" + } + } + } + }, + { + "regionTag": "jobs_v4beta1_generated_TenantService_ListTenants_async", + "title": "talent listTenants Sample", + "origin": "API_DEFINITION", + "description": " Lists all tenants associated with the project.", + "canonical": true, + "file": "tenant_service.list_tenants.js", + "language": "JAVASCRIPT", + "segments": [ + { + "start": 25, + "end": 63, + "type": "FULL" + } + ], + "clientMethod": { + "shortName": "ListTenants", + "fullName": "google.cloud.talent.v4beta1.TenantService.ListTenants", + "async": true, + "parameters": [ + { + "name": "parent", + "type": "TYPE_STRING" + }, + { + "name": "page_token", + "type": "TYPE_STRING" + }, + { + "name": "page_size", + "type": "TYPE_INT32" + } + ], + "resultType": ".google.cloud.talent.v4beta1.ListTenantsResponse", + "client": { + "shortName": "TenantServiceClient", + "fullName": "google.cloud.talent.v4beta1.TenantServiceClient" + }, + "method": { + "shortName": "ListTenants", + "fullName": "google.cloud.talent.v4beta1.TenantService.ListTenants", + "service": { + "shortName": "TenantService", + "fullName": "google.cloud.talent.v4beta1.TenantService" + } + } + } + } + ] +} diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.create_tenant.js b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.create_tenant.js index f54396e2687..97936f8447d 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.create_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.create_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.delete_tenant.js b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.delete_tenant.js index d9196ebf10b..925ceeb21bf 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.delete_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.delete_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.get_tenant.js b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.get_tenant.js index 3d1cc02c34c..97e821c76d9 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.get_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.get_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.list_tenants.js b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.list_tenants.js index 0662b8fbc4a..13e8830e851 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.list_tenants.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.list_tenants.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.update_tenant.js b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.update_tenant.js index 01c0af9b715..ae94bc2cd08 100644 --- a/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.update_tenant.js +++ b/packages/google-cloud-talent/samples/generated/v4beta1/tenant_service.update_tenant.js @@ -1,16 +1,21 @@ -// Copyright 2021 Google LLC +// 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 +// 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'; diff --git a/packages/google-cloud-talent/src/v4/company_service_client.ts b/packages/google-cloud-talent/src/v4/company_service_client.ts index 45c956f9e9d..53c28b853af 100644 --- a/packages/google-cloud-talent/src/v4/company_service_client.ts +++ b/packages/google-cloud-talent/src/v4/company_service_client.ts @@ -1048,9 +1048,8 @@ export class CompanyServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.companyServiceStub!.then(stub => { + if (this.companyServiceStub && !this._terminated) { + return this.companyServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4/completion_client.ts b/packages/google-cloud-talent/src/v4/completion_client.ts index 1f80a252ac6..da2abc768f8 100644 --- a/packages/google-cloud-talent/src/v4/completion_client.ts +++ b/packages/google-cloud-talent/src/v4/completion_client.ts @@ -560,9 +560,8 @@ export class CompletionClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.completionStub!.then(stub => { + if (this.completionStub && !this._terminated) { + return this.completionStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4/event_service_client.ts b/packages/google-cloud-talent/src/v4/event_service_client.ts index 972251dbc20..0f2e8851e1e 100644 --- a/packages/google-cloud-talent/src/v4/event_service_client.ts +++ b/packages/google-cloud-talent/src/v4/event_service_client.ts @@ -549,9 +549,8 @@ export class EventServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.eventServiceStub!.then(stub => { + if (this.eventServiceStub && !this._terminated) { + return this.eventServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4/job_service_client.ts b/packages/google-cloud-talent/src/v4/job_service_client.ts index e4c3db36e55..5d45499ed25 100644 --- a/packages/google-cloud-talent/src/v4/job_service_client.ts +++ b/packages/google-cloud-talent/src/v4/job_service_client.ts @@ -2306,9 +2306,8 @@ export class JobServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.jobServiceStub!.then(stub => { + if (this.jobServiceStub && !this._terminated) { + return this.jobServiceStub.then(stub => { this._terminated = true; stub.close(); this.operationsClient.close(); diff --git a/packages/google-cloud-talent/src/v4/tenant_service_client.ts b/packages/google-cloud-talent/src/v4/tenant_service_client.ts index 58b60ed1397..5bfac1eaaae 100644 --- a/packages/google-cloud-talent/src/v4/tenant_service_client.ts +++ b/packages/google-cloud-talent/src/v4/tenant_service_client.ts @@ -1042,9 +1042,8 @@ export class TenantServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.tenantServiceStub!.then(stub => { + if (this.tenantServiceStub && !this._terminated) { + return this.tenantServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/application_service_client.ts b/packages/google-cloud-talent/src/v4beta1/application_service_client.ts index dc0ce36e921..ce3cd6c76dc 100644 --- a/packages/google-cloud-talent/src/v4beta1/application_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/application_service_client.ts @@ -1284,9 +1284,8 @@ export class ApplicationServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.applicationServiceStub!.then(stub => { + if (this.applicationServiceStub && !this._terminated) { + return this.applicationServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/company_service_client.ts b/packages/google-cloud-talent/src/v4beta1/company_service_client.ts index b4b5bb3f3a9..74abbd84638 100644 --- a/packages/google-cloud-talent/src/v4beta1/company_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/company_service_client.ts @@ -1337,9 +1337,8 @@ export class CompanyServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.companyServiceStub!.then(stub => { + if (this.companyServiceStub && !this._terminated) { + return this.companyServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/completion_client.ts b/packages/google-cloud-talent/src/v4beta1/completion_client.ts index bdd33f02647..b6ce4b99de1 100644 --- a/packages/google-cloud-talent/src/v4beta1/completion_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/completion_client.ts @@ -819,9 +819,8 @@ export class CompletionClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.completionStub!.then(stub => { + if (this.completionStub && !this._terminated) { + return this.completionStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/event_service_client.ts b/packages/google-cloud-talent/src/v4beta1/event_service_client.ts index 0f066f607d5..6a88b4dd663 100644 --- a/packages/google-cloud-talent/src/v4beta1/event_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/event_service_client.ts @@ -797,9 +797,8 @@ export class EventServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.eventServiceStub!.then(stub => { + if (this.eventServiceStub && !this._terminated) { + return this.eventServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/job_service_client.ts b/packages/google-cloud-talent/src/v4beta1/job_service_client.ts index 9f61774710a..6637b4ccf41 100644 --- a/packages/google-cloud-talent/src/v4beta1/job_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/job_service_client.ts @@ -2469,9 +2469,8 @@ export class JobServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.jobServiceStub!.then(stub => { + if (this.jobServiceStub && !this._terminated) { + return this.jobServiceStub.then(stub => { this._terminated = true; stub.close(); this.operationsClient.close(); diff --git a/packages/google-cloud-talent/src/v4beta1/profile_service_client.ts b/packages/google-cloud-talent/src/v4beta1/profile_service_client.ts index 51dd70ef222..59df4acc6fc 100644 --- a/packages/google-cloud-talent/src/v4beta1/profile_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/profile_service_client.ts @@ -1652,9 +1652,8 @@ export class ProfileServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.profileServiceStub!.then(stub => { + if (this.profileServiceStub && !this._terminated) { + return this.profileServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/src/v4beta1/tenant_service_client.ts b/packages/google-cloud-talent/src/v4beta1/tenant_service_client.ts index 85e0f1c66f3..88ac2f4f41c 100644 --- a/packages/google-cloud-talent/src/v4beta1/tenant_service_client.ts +++ b/packages/google-cloud-talent/src/v4beta1/tenant_service_client.ts @@ -1297,9 +1297,8 @@ export class TenantServiceClient { * @returns {Promise} A promise that resolves when the client is closed. */ close(): Promise { - this.initialize(); - if (!this._terminated) { - return this.tenantServiceStub!.then(stub => { + if (this.tenantServiceStub && !this._terminated) { + return this.tenantServiceStub.then(stub => { this._terminated = true; stub.close(); }); diff --git a/packages/google-cloud-talent/test/gapic_application_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_application_service_v4beta1.ts index 9e40adef442..52bcd293c57 100644 --- a/packages/google-cloud-talent/test/gapic_application_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_application_service_v4beta1.ts @@ -156,13 +156,29 @@ describe('v4beta1.ApplicationServiceClient', () => { assert(client.applicationServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new applicationserviceModule.v4beta1.ApplicationServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.applicationServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = + new applicationserviceModule.v4beta1.ApplicationServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.applicationServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -313,6 +329,23 @@ describe('v4beta1.ApplicationServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createApplication with closed client', async () => { + const client = + new applicationserviceModule.v4beta1.ApplicationServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateApplicationRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createApplication(request), expectedError); + }); }); describe('getApplication', () => { @@ -427,6 +460,23 @@ describe('v4beta1.ApplicationServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getApplication with closed client', async () => { + const client = + new applicationserviceModule.v4beta1.ApplicationServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.GetApplicationRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getApplication(request), expectedError); + }); }); describe('updateApplication', () => { @@ -544,6 +594,24 @@ describe('v4beta1.ApplicationServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateApplication with closed client', async () => { + const client = + new applicationserviceModule.v4beta1.ApplicationServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.UpdateApplicationRequest() + ); + request.application = {}; + request.application.name = ''; + const expectedHeaderRequestParams = 'application.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateApplication(request), expectedError); + }); }); describe('deleteApplication', () => { @@ -658,6 +726,23 @@ describe('v4beta1.ApplicationServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteApplication with closed client', async () => { + const client = + new applicationserviceModule.v4beta1.ApplicationServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.DeleteApplicationRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteApplication(request), expectedError); + }); }); describe('listApplications', () => { diff --git a/packages/google-cloud-talent/test/gapic_company_service_v4.ts b/packages/google-cloud-talent/test/gapic_company_service_v4.ts index b38e1d817c4..c9db6dd193e 100644 --- a/packages/google-cloud-talent/test/gapic_company_service_v4.ts +++ b/packages/google-cloud-talent/test/gapic_company_service_v4.ts @@ -153,12 +153,27 @@ describe('v4.CompanyServiceClient', () => { assert(client.companyServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new companyserviceModule.v4.CompanyServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.companyServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new companyserviceModule.v4.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.companyServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -304,6 +319,22 @@ describe('v4.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createCompany with closed client', async () => { + const client = new companyserviceModule.v4.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.CreateCompanyRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createCompany(request), expectedError); + }); }); describe('getCompany', () => { @@ -415,6 +446,22 @@ describe('v4.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getCompany with closed client', async () => { + const client = new companyserviceModule.v4.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.GetCompanyRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getCompany(request), expectedError); + }); }); describe('updateCompany', () => { @@ -529,6 +576,23 @@ describe('v4.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateCompany with closed client', async () => { + const client = new companyserviceModule.v4.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.UpdateCompanyRequest() + ); + request.company = {}; + request.company.name = ''; + const expectedHeaderRequestParams = 'company.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateCompany(request), expectedError); + }); }); describe('deleteCompany', () => { @@ -640,6 +704,22 @@ describe('v4.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteCompany with closed client', async () => { + const client = new companyserviceModule.v4.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.DeleteCompanyRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteCompany(request), expectedError); + }); }); describe('listCompanies', () => { diff --git a/packages/google-cloud-talent/test/gapic_company_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_company_service_v4beta1.ts index 3015cc84f37..6f6b0ed5bb8 100644 --- a/packages/google-cloud-talent/test/gapic_company_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_company_service_v4beta1.ts @@ -153,12 +153,27 @@ describe('v4beta1.CompanyServiceClient', () => { assert(client.companyServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new companyserviceModule.v4beta1.CompanyServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.companyServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new companyserviceModule.v4beta1.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.companyServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -304,6 +319,22 @@ describe('v4beta1.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createCompany with closed client', async () => { + const client = new companyserviceModule.v4beta1.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateCompanyRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createCompany(request), expectedError); + }); }); describe('getCompany', () => { @@ -415,6 +446,22 @@ describe('v4beta1.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getCompany with closed client', async () => { + const client = new companyserviceModule.v4beta1.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.GetCompanyRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getCompany(request), expectedError); + }); }); describe('updateCompany', () => { @@ -529,6 +576,23 @@ describe('v4beta1.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateCompany with closed client', async () => { + const client = new companyserviceModule.v4beta1.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.UpdateCompanyRequest() + ); + request.company = {}; + request.company.name = ''; + const expectedHeaderRequestParams = 'company.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateCompany(request), expectedError); + }); }); describe('deleteCompany', () => { @@ -640,6 +704,22 @@ describe('v4beta1.CompanyServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteCompany with closed client', async () => { + const client = new companyserviceModule.v4beta1.CompanyServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.DeleteCompanyRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteCompany(request), expectedError); + }); }); describe('listCompanies', () => { diff --git a/packages/google-cloud-talent/test/gapic_completion_v4.ts b/packages/google-cloud-talent/test/gapic_completion_v4.ts index 2f9aae80aee..789d3b0236a 100644 --- a/packages/google-cloud-talent/test/gapic_completion_v4.ts +++ b/packages/google-cloud-talent/test/gapic_completion_v4.ts @@ -88,12 +88,27 @@ describe('v4.CompletionClient', () => { assert(client.completionStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new completionModule.v4.CompletionClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.completionStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new completionModule.v4.CompletionClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.completionStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -239,6 +254,22 @@ describe('v4.CompletionClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes completeQuery with closed client', async () => { + const client = new completionModule.v4.CompletionClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.CompleteQueryRequest() + ); + request.tenant = ''; + const expectedHeaderRequestParams = 'tenant='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.completeQuery(request), expectedError); + }); }); describe('Path templates', () => { diff --git a/packages/google-cloud-talent/test/gapic_completion_v4beta1.ts b/packages/google-cloud-talent/test/gapic_completion_v4beta1.ts index 588a90aaaf6..4dd555b0ead 100644 --- a/packages/google-cloud-talent/test/gapic_completion_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_completion_v4beta1.ts @@ -88,12 +88,27 @@ describe('v4beta1.CompletionClient', () => { assert(client.completionStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new completionModule.v4beta1.CompletionClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.completionStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new completionModule.v4beta1.CompletionClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.completionStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -239,6 +254,22 @@ describe('v4beta1.CompletionClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes completeQuery with closed client', async () => { + const client = new completionModule.v4beta1.CompletionClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CompleteQueryRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.completeQuery(request), expectedError); + }); }); describe('Path templates', () => { diff --git a/packages/google-cloud-talent/test/gapic_event_service_v4.ts b/packages/google-cloud-talent/test/gapic_event_service_v4.ts index 1158988c2e9..25a878930bb 100644 --- a/packages/google-cloud-talent/test/gapic_event_service_v4.ts +++ b/packages/google-cloud-talent/test/gapic_event_service_v4.ts @@ -88,12 +88,27 @@ describe('v4.EventServiceClient', () => { assert(client.eventServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new eventserviceModule.v4.EventServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.eventServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new eventserviceModule.v4.EventServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.eventServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -239,6 +254,22 @@ describe('v4.EventServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createClientEvent with closed client', async () => { + const client = new eventserviceModule.v4.EventServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.CreateClientEventRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createClientEvent(request), expectedError); + }); }); describe('Path templates', () => { diff --git a/packages/google-cloud-talent/test/gapic_event_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_event_service_v4beta1.ts index e219578d1ad..61caa399e10 100644 --- a/packages/google-cloud-talent/test/gapic_event_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_event_service_v4beta1.ts @@ -90,12 +90,27 @@ describe('v4beta1.EventServiceClient', () => { assert(client.eventServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new eventserviceModule.v4beta1.EventServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.eventServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new eventserviceModule.v4beta1.EventServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.eventServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -241,6 +256,22 @@ describe('v4beta1.EventServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createClientEvent with closed client', async () => { + const client = new eventserviceModule.v4beta1.EventServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateClientEventRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createClientEvent(request), expectedError); + }); }); describe('Path templates', () => { diff --git a/packages/google-cloud-talent/test/gapic_job_service_v4.ts b/packages/google-cloud-talent/test/gapic_job_service_v4.ts index 1c5b22850ca..b59aa147a02 100644 --- a/packages/google-cloud-talent/test/gapic_job_service_v4.ts +++ b/packages/google-cloud-talent/test/gapic_job_service_v4.ts @@ -183,12 +183,27 @@ describe('v4.JobServiceClient', () => { assert(client.jobServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new jobserviceModule.v4.JobServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.jobServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.jobServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -331,6 +346,22 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createJob with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.CreateJobRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createJob(request), expectedError); + }); }); describe('getJob', () => { @@ -439,6 +470,22 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getJob with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.GetJobRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getJob(request), expectedError); + }); }); describe('updateJob', () => { @@ -550,6 +597,23 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateJob with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.UpdateJobRequest() + ); + request.job = {}; + request.job.name = ''; + const expectedHeaderRequestParams = 'job.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateJob(request), expectedError); + }); }); describe('deleteJob', () => { @@ -658,6 +722,22 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteJob with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.DeleteJobRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteJob(request), expectedError); + }); }); describe('searchJobs', () => { @@ -769,6 +849,22 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes searchJobs with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.SearchJobsRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.searchJobs(request), expectedError); + }); }); describe('searchJobsForAlert', () => { @@ -881,6 +977,22 @@ describe('v4.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes searchJobsForAlert with closed client', async () => { + const client = new jobserviceModule.v4.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.SearchJobsRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.searchJobsForAlert(request), expectedError); + }); }); describe('batchCreateJobs', () => { diff --git a/packages/google-cloud-talent/test/gapic_job_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_job_service_v4beta1.ts index a55a0438fc1..a665561d6a3 100644 --- a/packages/google-cloud-talent/test/gapic_job_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_job_service_v4beta1.ts @@ -183,12 +183,27 @@ describe('v4beta1.JobServiceClient', () => { assert(client.jobServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new jobserviceModule.v4beta1.JobServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.jobServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.jobServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -331,6 +346,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createJob with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateJobRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createJob(request), expectedError); + }); }); describe('getJob', () => { @@ -439,6 +470,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getJob with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.GetJobRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getJob(request), expectedError); + }); }); describe('updateJob', () => { @@ -550,6 +597,23 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateJob with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.UpdateJobRequest() + ); + request.job = {}; + request.job.name = ''; + const expectedHeaderRequestParams = 'job.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateJob(request), expectedError); + }); }); describe('deleteJob', () => { @@ -658,6 +722,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteJob with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.DeleteJobRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteJob(request), expectedError); + }); }); describe('batchDeleteJobs', () => { @@ -769,6 +849,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes batchDeleteJobs with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.BatchDeleteJobsRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.batchDeleteJobs(request), expectedError); + }); }); describe('searchJobs', () => { @@ -880,6 +976,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes searchJobs with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.SearchJobsRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.searchJobs(request), expectedError); + }); }); describe('searchJobsForAlert', () => { @@ -992,6 +1104,22 @@ describe('v4beta1.JobServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes searchJobsForAlert with closed client', async () => { + const client = new jobserviceModule.v4beta1.JobServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.SearchJobsRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.searchJobsForAlert(request), expectedError); + }); }); describe('batchCreateJobs', () => { diff --git a/packages/google-cloud-talent/test/gapic_profile_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_profile_service_v4beta1.ts index b03742f6822..a6bc48b0be1 100644 --- a/packages/google-cloud-talent/test/gapic_profile_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_profile_service_v4beta1.ts @@ -153,12 +153,27 @@ describe('v4beta1.ProfileServiceClient', () => { assert(client.profileServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new profileserviceModule.v4beta1.ProfileServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.profileServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.profileServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -304,6 +319,22 @@ describe('v4beta1.ProfileServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createProfile with closed client', async () => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateProfileRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createProfile(request), expectedError); + }); }); describe('getProfile', () => { @@ -415,6 +446,22 @@ describe('v4beta1.ProfileServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getProfile with closed client', async () => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.GetProfileRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getProfile(request), expectedError); + }); }); describe('updateProfile', () => { @@ -529,6 +576,23 @@ describe('v4beta1.ProfileServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateProfile with closed client', async () => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.UpdateProfileRequest() + ); + request.profile = {}; + request.profile.name = ''; + const expectedHeaderRequestParams = 'profile.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateProfile(request), expectedError); + }); }); describe('deleteProfile', () => { @@ -640,6 +704,22 @@ describe('v4beta1.ProfileServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteProfile with closed client', async () => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.DeleteProfileRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteProfile(request), expectedError); + }); }); describe('searchProfiles', () => { @@ -751,6 +831,22 @@ describe('v4beta1.ProfileServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes searchProfiles with closed client', async () => { + const client = new profileserviceModule.v4beta1.ProfileServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.SearchProfilesRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.searchProfiles(request), expectedError); + }); }); describe('listProfiles', () => { diff --git a/packages/google-cloud-talent/test/gapic_tenant_service_v4.ts b/packages/google-cloud-talent/test/gapic_tenant_service_v4.ts index 4324ce49197..6a55533bebe 100644 --- a/packages/google-cloud-talent/test/gapic_tenant_service_v4.ts +++ b/packages/google-cloud-talent/test/gapic_tenant_service_v4.ts @@ -151,12 +151,27 @@ describe('v4.TenantServiceClient', () => { assert(client.tenantServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new tenantserviceModule.v4.TenantServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.tenantServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new tenantserviceModule.v4.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.tenantServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -302,6 +317,22 @@ describe('v4.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createTenant with closed client', async () => { + const client = new tenantserviceModule.v4.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.CreateTenantRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createTenant(request), expectedError); + }); }); describe('getTenant', () => { @@ -410,6 +441,22 @@ describe('v4.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getTenant with closed client', async () => { + const client = new tenantserviceModule.v4.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.GetTenantRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getTenant(request), expectedError); + }); }); describe('updateTenant', () => { @@ -524,6 +571,23 @@ describe('v4.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateTenant with closed client', async () => { + const client = new tenantserviceModule.v4.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.UpdateTenantRequest() + ); + request.tenant = {}; + request.tenant.name = ''; + const expectedHeaderRequestParams = 'tenant.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateTenant(request), expectedError); + }); }); describe('deleteTenant', () => { @@ -635,6 +699,22 @@ describe('v4.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteTenant with closed client', async () => { + const client = new tenantserviceModule.v4.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4.DeleteTenantRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteTenant(request), expectedError); + }); }); describe('listTenants', () => { diff --git a/packages/google-cloud-talent/test/gapic_tenant_service_v4beta1.ts b/packages/google-cloud-talent/test/gapic_tenant_service_v4beta1.ts index d5988b86aa0..aaac8654250 100644 --- a/packages/google-cloud-talent/test/gapic_tenant_service_v4beta1.ts +++ b/packages/google-cloud-talent/test/gapic_tenant_service_v4beta1.ts @@ -153,12 +153,27 @@ describe('v4beta1.TenantServiceClient', () => { assert(client.tenantServiceStub); }); - it('has close method', () => { + it('has close method for the initialized client', done => { const client = new tenantserviceModule.v4beta1.TenantServiceClient({ credentials: {client_email: 'bogus', private_key: 'bogus'}, projectId: 'bogus', }); - client.close(); + client.initialize(); + assert(client.tenantServiceStub); + client.close().then(() => { + done(); + }); + }); + + it('has close method for the non-initialized client', done => { + const client = new tenantserviceModule.v4beta1.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + assert.strictEqual(client.tenantServiceStub, undefined); + client.close().then(() => { + done(); + }); }); it('has getProjectId method', async () => { @@ -304,6 +319,22 @@ describe('v4beta1.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes createTenant with closed client', async () => { + const client = new tenantserviceModule.v4beta1.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.CreateTenantRequest() + ); + request.parent = ''; + const expectedHeaderRequestParams = 'parent='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.createTenant(request), expectedError); + }); }); describe('getTenant', () => { @@ -412,6 +443,22 @@ describe('v4beta1.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes getTenant with closed client', async () => { + const client = new tenantserviceModule.v4beta1.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.GetTenantRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.getTenant(request), expectedError); + }); }); describe('updateTenant', () => { @@ -526,6 +573,23 @@ describe('v4beta1.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes updateTenant with closed client', async () => { + const client = new tenantserviceModule.v4beta1.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.UpdateTenantRequest() + ); + request.tenant = {}; + request.tenant.name = ''; + const expectedHeaderRequestParams = 'tenant.name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.updateTenant(request), expectedError); + }); }); describe('deleteTenant', () => { @@ -637,6 +701,22 @@ describe('v4beta1.TenantServiceClient', () => { .calledWith(request, expectedOptions, undefined) ); }); + + it('invokes deleteTenant with closed client', async () => { + const client = new tenantserviceModule.v4beta1.TenantServiceClient({ + credentials: {client_email: 'bogus', private_key: 'bogus'}, + projectId: 'bogus', + }); + client.initialize(); + const request = generateSampleMessage( + new protos.google.cloud.talent.v4beta1.DeleteTenantRequest() + ); + request.name = ''; + const expectedHeaderRequestParams = 'name='; + const expectedError = new Error('The client has already been closed.'); + client.close(); + await assert.rejects(client.deleteTenant(request), expectedError); + }); }); describe('listTenants', () => {