google-cloud-talent 0.8.1 → 0.20.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.yardopts +2 -1
- data/AUTHENTICATION.md +51 -59
- data/LICENSE.md +203 -0
- data/MIGRATING.md +347 -0
- data/README.md +35 -25
- data/lib/{google/cloud/talent/v4beta1/doc/google/protobuf/empty.rb → google-cloud-talent.rb} +5 -15
- data/lib/google/cloud/talent.rb +254 -442
- data/lib/google/cloud/talent/version.rb +6 -2
- metadata +62 -111
- data/LICENSE +0 -201
- data/lib/google/cloud/talent/v4beta1.rb +0 -543
- data/lib/google/cloud/talent/v4beta1/application_pb.rb +0 -62
- data/lib/google/cloud/talent/v4beta1/application_service_client.rb +0 -491
- data/lib/google/cloud/talent/v4beta1/application_service_client_config.json +0 -51
- data/lib/google/cloud/talent/v4beta1/application_service_pb.rb +0 -54
- data/lib/google/cloud/talent/v4beta1/application_service_services_pb.rb +0 -56
- data/lib/google/cloud/talent/v4beta1/batch_pb.rb +0 -18
- data/lib/google/cloud/talent/v4beta1/common_pb.rb +0 -341
- data/lib/google/cloud/talent/v4beta1/company_pb.rb +0 -40
- data/lib/google/cloud/talent/v4beta1/company_service_client.rb +0 -535
- data/lib/google/cloud/talent/v4beta1/company_service_client_config.json +0 -51
- data/lib/google/cloud/talent/v4beta1/company_service_pb.rb +0 -55
- data/lib/google/cloud/talent/v4beta1/company_service_services_pb.rb +0 -56
- data/lib/google/cloud/talent/v4beta1/completion_client.rb +0 -359
- data/lib/google/cloud/talent/v4beta1/completion_client_config.json +0 -31
- data/lib/google/cloud/talent/v4beta1/completion_service_pb.rb +0 -55
- data/lib/google/cloud/talent/v4beta1/completion_service_services_pb.rb +0 -48
- data/lib/google/cloud/talent/v4beta1/credentials.rb +0 -42
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/application.rb +0 -166
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/application_service.rb +0 -107
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/common.rb +0 -1147
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/company.rb +0 -110
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/company_service.rb +0 -122
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/completion_service.rb +0 -141
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/event.rb +0 -238
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/event_service.rb +0 -36
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/filters.rb +0 -847
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/histogram.rb +0 -55
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/job.rb +0 -363
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/job_service.rb +0 -762
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/profile.rb +0 -808
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/profile_service.rb +0 -446
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/tenant.rb +0 -74
- data/lib/google/cloud/talent/v4beta1/doc/google/cloud/talent/v4beta1/tenant_service.rb +0 -101
- data/lib/google/cloud/talent/v4beta1/doc/google/longrunning/operations.rb +0 -51
- data/lib/google/cloud/talent/v4beta1/doc/google/protobuf/any.rb +0 -131
- data/lib/google/cloud/talent/v4beta1/doc/google/protobuf/duration.rb +0 -91
- data/lib/google/cloud/talent/v4beta1/doc/google/protobuf/field_mask.rb +0 -222
- data/lib/google/cloud/talent/v4beta1/doc/google/protobuf/timestamp.rb +0 -113
- data/lib/google/cloud/talent/v4beta1/doc/google/protobuf/wrappers.rb +0 -34
- data/lib/google/cloud/talent/v4beta1/doc/google/rpc/status.rb +0 -87
- data/lib/google/cloud/talent/v4beta1/doc/google/type/date.rb +0 -43
- data/lib/google/cloud/talent/v4beta1/doc/google/type/latlng.rb +0 -31
- data/lib/google/cloud/talent/v4beta1/doc/google/type/money.rb +0 -36
- data/lib/google/cloud/talent/v4beta1/doc/google/type/postal_address.rb +0 -126
- data/lib/google/cloud/talent/v4beta1/doc/google/type/timeofday.rb +0 -37
- data/lib/google/cloud/talent/v4beta1/event_pb.rb +0 -69
- data/lib/google/cloud/talent/v4beta1/event_service_client.rb +0 -268
- data/lib/google/cloud/talent/v4beta1/event_service_client_config.json +0 -31
- data/lib/google/cloud/talent/v4beta1/event_service_pb.rb +0 -26
- data/lib/google/cloud/talent/v4beta1/event_service_services_pb.rb +0 -53
- data/lib/google/cloud/talent/v4beta1/filters_pb.rb +0 -187
- data/lib/google/cloud/talent/v4beta1/helpers.rb +0 -162
- data/lib/google/cloud/talent/v4beta1/histogram_pb.rb +0 -27
- data/lib/google/cloud/talent/v4beta1/job_pb.rb +0 -71
- data/lib/google/cloud/talent/v4beta1/job_service_client.rb +0 -1576
- data/lib/google/cloud/talent/v4beta1/job_service_client_config.json +0 -76
- data/lib/google/cloud/talent/v4beta1/job_service_pb.rb +0 -165
- data/lib/google/cloud/talent/v4beta1/job_service_services_pb.rb +0 -92
- data/lib/google/cloud/talent/v4beta1/profile_pb.rb +0 -212
- data/lib/google/cloud/talent/v4beta1/profile_service_client.rb +0 -844
- data/lib/google/cloud/talent/v4beta1/profile_service_client_config.json +0 -56
- data/lib/google/cloud/talent/v4beta1/profile_service_pb.rb +0 -88
- data/lib/google/cloud/talent/v4beta1/profile_service_services_pb.rb +0 -67
- data/lib/google/cloud/talent/v4beta1/tenant_pb.rb +0 -33
- data/lib/google/cloud/talent/v4beta1/tenant_service_client.rb +0 -476
- data/lib/google/cloud/talent/v4beta1/tenant_service_client_config.json +0 -51
- data/lib/google/cloud/talent/v4beta1/tenant_service_pb.rb +0 -54
- data/lib/google/cloud/talent/v4beta1/tenant_service_services_pb.rb +0 -55
@@ -1,62 +0,0 @@
|
|
1
|
-
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
-
# source: google/cloud/talent/v4beta1/application.proto
|
3
|
-
|
4
|
-
|
5
|
-
require 'google/protobuf'
|
6
|
-
|
7
|
-
require 'google/api/annotations_pb'
|
8
|
-
require 'google/api/field_behavior_pb'
|
9
|
-
require 'google/cloud/talent/v4beta1/common_pb'
|
10
|
-
require 'google/protobuf/timestamp_pb'
|
11
|
-
require 'google/protobuf/wrappers_pb'
|
12
|
-
require 'google/type/date_pb'
|
13
|
-
Google::Protobuf::DescriptorPool.generated_pool.build do
|
14
|
-
add_message "google.cloud.talent.v4beta1.Application" do
|
15
|
-
optional :name, :string, 1
|
16
|
-
optional :external_id, :string, 31
|
17
|
-
optional :profile, :string, 2
|
18
|
-
optional :job, :string, 4
|
19
|
-
optional :company, :string, 5
|
20
|
-
optional :application_date, :message, 7, "google.type.Date"
|
21
|
-
optional :stage, :enum, 11, "google.cloud.talent.v4beta1.Application.ApplicationStage"
|
22
|
-
optional :state, :enum, 13, "google.cloud.talent.v4beta1.Application.ApplicationState"
|
23
|
-
repeated :interviews, :message, 16, "google.cloud.talent.v4beta1.Interview"
|
24
|
-
optional :referral, :message, 18, "google.protobuf.BoolValue"
|
25
|
-
optional :create_time, :message, 19, "google.protobuf.Timestamp"
|
26
|
-
optional :update_time, :message, 20, "google.protobuf.Timestamp"
|
27
|
-
optional :outcome_notes, :string, 21
|
28
|
-
optional :outcome, :enum, 22, "google.cloud.talent.v4beta1.Outcome"
|
29
|
-
optional :is_match, :message, 28, "google.protobuf.BoolValue"
|
30
|
-
optional :job_title_snippet, :string, 29
|
31
|
-
end
|
32
|
-
add_enum "google.cloud.talent.v4beta1.Application.ApplicationState" do
|
33
|
-
value :APPLICATION_STATE_UNSPECIFIED, 0
|
34
|
-
value :IN_PROGRESS, 1
|
35
|
-
value :CANDIDATE_WITHDREW, 2
|
36
|
-
value :EMPLOYER_WITHDREW, 3
|
37
|
-
value :COMPLETED, 4
|
38
|
-
value :CLOSED, 5
|
39
|
-
end
|
40
|
-
add_enum "google.cloud.talent.v4beta1.Application.ApplicationStage" do
|
41
|
-
value :APPLICATION_STAGE_UNSPECIFIED, 0
|
42
|
-
value :NEW, 1
|
43
|
-
value :SCREEN, 2
|
44
|
-
value :HIRING_MANAGER_REVIEW, 3
|
45
|
-
value :INTERVIEW, 4
|
46
|
-
value :OFFER_EXTENDED, 5
|
47
|
-
value :OFFER_ACCEPTED, 6
|
48
|
-
value :STARTED, 7
|
49
|
-
end
|
50
|
-
end
|
51
|
-
|
52
|
-
module Google
|
53
|
-
module Cloud
|
54
|
-
module Talent
|
55
|
-
module V4beta1
|
56
|
-
Application = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.talent.v4beta1.Application").msgclass
|
57
|
-
Application::ApplicationState = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.talent.v4beta1.Application.ApplicationState").enummodule
|
58
|
-
Application::ApplicationStage = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.talent.v4beta1.Application.ApplicationStage").enummodule
|
59
|
-
end
|
60
|
-
end
|
61
|
-
end
|
62
|
-
end
|
@@ -1,491 +0,0 @@
|
|
1
|
-
# Copyright 2019 Google LLC
|
2
|
-
#
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
-
# you may not use this file except in compliance with the License.
|
5
|
-
# You may obtain a copy of the License at
|
6
|
-
#
|
7
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
8
|
-
#
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
-
# See the License for the specific language governing permissions and
|
13
|
-
# limitations under the License.
|
14
|
-
#
|
15
|
-
# EDITING INSTRUCTIONS
|
16
|
-
# This file was generated from the file
|
17
|
-
# https://github.com/googleapis/googleapis/blob/master/google/cloud/talent/v4beta1/application_service.proto,
|
18
|
-
# and updates to that file get reflected here through a refresh process.
|
19
|
-
# For the short term, the refresh process will only be runnable by Google
|
20
|
-
# engineers.
|
21
|
-
|
22
|
-
|
23
|
-
require "json"
|
24
|
-
require "pathname"
|
25
|
-
|
26
|
-
require "google/gax"
|
27
|
-
|
28
|
-
require "google/cloud/talent/v4beta1/application_service_pb"
|
29
|
-
require "google/cloud/talent/v4beta1/credentials"
|
30
|
-
require "google/cloud/talent/version"
|
31
|
-
|
32
|
-
module Google
|
33
|
-
module Cloud
|
34
|
-
module Talent
|
35
|
-
module V4beta1
|
36
|
-
# A service that handles application management, including CRUD and
|
37
|
-
# enumeration.
|
38
|
-
#
|
39
|
-
# @!attribute [r] application_service_stub
|
40
|
-
# @return [Google::Cloud::Talent::V4beta1::ApplicationService::Stub]
|
41
|
-
class ApplicationServiceClient
|
42
|
-
# @private
|
43
|
-
attr_reader :application_service_stub
|
44
|
-
|
45
|
-
# The default address of the service.
|
46
|
-
SERVICE_ADDRESS = "jobs.googleapis.com".freeze
|
47
|
-
|
48
|
-
# The default port of the service.
|
49
|
-
DEFAULT_SERVICE_PORT = 443
|
50
|
-
|
51
|
-
# The default set of gRPC interceptors.
|
52
|
-
GRPC_INTERCEPTORS = []
|
53
|
-
|
54
|
-
DEFAULT_TIMEOUT = 30
|
55
|
-
|
56
|
-
PAGE_DESCRIPTORS = {
|
57
|
-
"list_applications" => Google::Gax::PageDescriptor.new(
|
58
|
-
"page_token",
|
59
|
-
"next_page_token",
|
60
|
-
"applications")
|
61
|
-
}.freeze
|
62
|
-
|
63
|
-
private_constant :PAGE_DESCRIPTORS
|
64
|
-
|
65
|
-
# The scopes needed to make gRPC calls to all of the methods defined in
|
66
|
-
# this service.
|
67
|
-
ALL_SCOPES = [
|
68
|
-
"https://www.googleapis.com/auth/cloud-platform",
|
69
|
-
"https://www.googleapis.com/auth/jobs"
|
70
|
-
].freeze
|
71
|
-
|
72
|
-
|
73
|
-
APPLICATION_PATH_TEMPLATE = Google::Gax::PathTemplate.new(
|
74
|
-
"projects/{project}/tenants/{tenant}/profiles/{profile}/applications/{application}"
|
75
|
-
)
|
76
|
-
|
77
|
-
private_constant :APPLICATION_PATH_TEMPLATE
|
78
|
-
|
79
|
-
PROFILE_PATH_TEMPLATE = Google::Gax::PathTemplate.new(
|
80
|
-
"projects/{project}/tenants/{tenant}/profiles/{profile}"
|
81
|
-
)
|
82
|
-
|
83
|
-
private_constant :PROFILE_PATH_TEMPLATE
|
84
|
-
|
85
|
-
# Returns a fully-qualified application resource name string.
|
86
|
-
# @param project [String]
|
87
|
-
# @param tenant [String]
|
88
|
-
# @param profile [String]
|
89
|
-
# @param application [String]
|
90
|
-
# @return [String]
|
91
|
-
def self.application_path project, tenant, profile, application
|
92
|
-
APPLICATION_PATH_TEMPLATE.render(
|
93
|
-
:"project" => project,
|
94
|
-
:"tenant" => tenant,
|
95
|
-
:"profile" => profile,
|
96
|
-
:"application" => application
|
97
|
-
)
|
98
|
-
end
|
99
|
-
|
100
|
-
# Returns a fully-qualified profile resource name string.
|
101
|
-
# @param project [String]
|
102
|
-
# @param tenant [String]
|
103
|
-
# @param profile [String]
|
104
|
-
# @return [String]
|
105
|
-
def self.profile_path project, tenant, profile
|
106
|
-
PROFILE_PATH_TEMPLATE.render(
|
107
|
-
:"project" => project,
|
108
|
-
:"tenant" => tenant,
|
109
|
-
:"profile" => profile
|
110
|
-
)
|
111
|
-
end
|
112
|
-
|
113
|
-
# @param credentials [Google::Auth::Credentials, String, Hash, GRPC::Core::Channel, GRPC::Core::ChannelCredentials, Proc]
|
114
|
-
# Provides the means for authenticating requests made by the client. This parameter can
|
115
|
-
# be many types.
|
116
|
-
# A `Google::Auth::Credentials` uses a the properties of its represented keyfile for
|
117
|
-
# authenticating requests made by this client.
|
118
|
-
# A `String` will be treated as the path to the keyfile to be used for the construction of
|
119
|
-
# credentials for this client.
|
120
|
-
# A `Hash` will be treated as the contents of a keyfile to be used for the construction of
|
121
|
-
# credentials for this client.
|
122
|
-
# A `GRPC::Core::Channel` will be used to make calls through.
|
123
|
-
# A `GRPC::Core::ChannelCredentials` for the setting up the RPC client. The channel credentials
|
124
|
-
# should already be composed with a `GRPC::Core::CallCredentials` object.
|
125
|
-
# A `Proc` will be used as an updater_proc for the Grpc channel. The proc transforms the
|
126
|
-
# metadata for requests, generally, to give OAuth credentials.
|
127
|
-
# @param scopes [Array<String>]
|
128
|
-
# The OAuth scopes for this service. This parameter is ignored if
|
129
|
-
# an updater_proc is supplied.
|
130
|
-
# @param client_config [Hash]
|
131
|
-
# A Hash for call options for each method. See
|
132
|
-
# Google::Gax#construct_settings for the structure of
|
133
|
-
# this data. Falls back to the default config if not specified
|
134
|
-
# or the specified config is missing data points.
|
135
|
-
# @param timeout [Numeric]
|
136
|
-
# The default timeout, in seconds, for calls made through this client.
|
137
|
-
# @param metadata [Hash]
|
138
|
-
# Default metadata to be sent with each request. This can be overridden on a per call basis.
|
139
|
-
# @param service_address [String]
|
140
|
-
# Override for the service hostname, or `nil` to leave as the default.
|
141
|
-
# @param service_port [Integer]
|
142
|
-
# Override for the service port, or `nil` to leave as the default.
|
143
|
-
# @param exception_transformer [Proc]
|
144
|
-
# An optional proc that intercepts any exceptions raised during an API call to inject
|
145
|
-
# custom error handling.
|
146
|
-
def initialize \
|
147
|
-
credentials: nil,
|
148
|
-
scopes: ALL_SCOPES,
|
149
|
-
client_config: {},
|
150
|
-
timeout: DEFAULT_TIMEOUT,
|
151
|
-
metadata: nil,
|
152
|
-
service_address: nil,
|
153
|
-
service_port: nil,
|
154
|
-
exception_transformer: nil,
|
155
|
-
lib_name: nil,
|
156
|
-
lib_version: ""
|
157
|
-
# These require statements are intentionally placed here to initialize
|
158
|
-
# the gRPC module only when it's required.
|
159
|
-
# See https://github.com/googleapis/toolkit/issues/446
|
160
|
-
require "google/gax/grpc"
|
161
|
-
require "google/cloud/talent/v4beta1/application_service_services_pb"
|
162
|
-
|
163
|
-
credentials ||= Google::Cloud::Talent::V4beta1::Credentials.default
|
164
|
-
|
165
|
-
if credentials.is_a?(String) || credentials.is_a?(Hash)
|
166
|
-
updater_proc = Google::Cloud::Talent::V4beta1::Credentials.new(credentials).updater_proc
|
167
|
-
end
|
168
|
-
if credentials.is_a?(GRPC::Core::Channel)
|
169
|
-
channel = credentials
|
170
|
-
end
|
171
|
-
if credentials.is_a?(GRPC::Core::ChannelCredentials)
|
172
|
-
chan_creds = credentials
|
173
|
-
end
|
174
|
-
if credentials.is_a?(Proc)
|
175
|
-
updater_proc = credentials
|
176
|
-
end
|
177
|
-
if credentials.is_a?(Google::Auth::Credentials)
|
178
|
-
updater_proc = credentials.updater_proc
|
179
|
-
end
|
180
|
-
|
181
|
-
package_version = Google::Cloud::Talent::VERSION
|
182
|
-
|
183
|
-
google_api_client = "gl-ruby/#{RUBY_VERSION}"
|
184
|
-
google_api_client << " #{lib_name}/#{lib_version}" if lib_name
|
185
|
-
google_api_client << " gapic/#{package_version} gax/#{Google::Gax::VERSION}"
|
186
|
-
google_api_client << " grpc/#{GRPC::VERSION}"
|
187
|
-
google_api_client.freeze
|
188
|
-
|
189
|
-
headers = { :"x-goog-api-client" => google_api_client }
|
190
|
-
headers.merge!(metadata) unless metadata.nil?
|
191
|
-
client_config_file = Pathname.new(__dir__).join(
|
192
|
-
"application_service_client_config.json"
|
193
|
-
)
|
194
|
-
defaults = client_config_file.open do |f|
|
195
|
-
Google::Gax.construct_settings(
|
196
|
-
"google.cloud.talent.v4beta1.ApplicationService",
|
197
|
-
JSON.parse(f.read),
|
198
|
-
client_config,
|
199
|
-
Google::Gax::Grpc::STATUS_CODE_NAMES,
|
200
|
-
timeout,
|
201
|
-
page_descriptors: PAGE_DESCRIPTORS,
|
202
|
-
errors: Google::Gax::Grpc::API_ERRORS,
|
203
|
-
metadata: headers
|
204
|
-
)
|
205
|
-
end
|
206
|
-
|
207
|
-
# Allow overriding the service path/port in subclasses.
|
208
|
-
service_path = service_address || self.class::SERVICE_ADDRESS
|
209
|
-
port = service_port || self.class::DEFAULT_SERVICE_PORT
|
210
|
-
interceptors = self.class::GRPC_INTERCEPTORS
|
211
|
-
@application_service_stub = Google::Gax::Grpc.create_stub(
|
212
|
-
service_path,
|
213
|
-
port,
|
214
|
-
chan_creds: chan_creds,
|
215
|
-
channel: channel,
|
216
|
-
updater_proc: updater_proc,
|
217
|
-
scopes: scopes,
|
218
|
-
interceptors: interceptors,
|
219
|
-
&Google::Cloud::Talent::V4beta1::ApplicationService::Stub.method(:new)
|
220
|
-
)
|
221
|
-
|
222
|
-
@create_application = Google::Gax.create_api_call(
|
223
|
-
@application_service_stub.method(:create_application),
|
224
|
-
defaults["create_application"],
|
225
|
-
exception_transformer: exception_transformer,
|
226
|
-
params_extractor: proc do |request|
|
227
|
-
{'parent' => request.parent}
|
228
|
-
end
|
229
|
-
)
|
230
|
-
@get_application = Google::Gax.create_api_call(
|
231
|
-
@application_service_stub.method(:get_application),
|
232
|
-
defaults["get_application"],
|
233
|
-
exception_transformer: exception_transformer,
|
234
|
-
params_extractor: proc do |request|
|
235
|
-
{'name' => request.name}
|
236
|
-
end
|
237
|
-
)
|
238
|
-
@update_application = Google::Gax.create_api_call(
|
239
|
-
@application_service_stub.method(:update_application),
|
240
|
-
defaults["update_application"],
|
241
|
-
exception_transformer: exception_transformer,
|
242
|
-
params_extractor: proc do |request|
|
243
|
-
{'application.name' => request.application.name}
|
244
|
-
end
|
245
|
-
)
|
246
|
-
@delete_application = Google::Gax.create_api_call(
|
247
|
-
@application_service_stub.method(:delete_application),
|
248
|
-
defaults["delete_application"],
|
249
|
-
exception_transformer: exception_transformer,
|
250
|
-
params_extractor: proc do |request|
|
251
|
-
{'name' => request.name}
|
252
|
-
end
|
253
|
-
)
|
254
|
-
@list_applications = Google::Gax.create_api_call(
|
255
|
-
@application_service_stub.method(:list_applications),
|
256
|
-
defaults["list_applications"],
|
257
|
-
exception_transformer: exception_transformer,
|
258
|
-
params_extractor: proc do |request|
|
259
|
-
{'parent' => request.parent}
|
260
|
-
end
|
261
|
-
)
|
262
|
-
end
|
263
|
-
|
264
|
-
# Service calls
|
265
|
-
|
266
|
-
# Creates a new application entity.
|
267
|
-
#
|
268
|
-
# @param parent [String]
|
269
|
-
# Required. Resource name of the profile under which the application is
|
270
|
-
# created.
|
271
|
-
#
|
272
|
-
# The format is
|
273
|
-
# "projects/{project_id}/tenants/{tenant_id}/profiles/{profile_id}".
|
274
|
-
# For example, "projects/foo/tenants/bar/profiles/baz".
|
275
|
-
# @param application [Google::Cloud::Talent::V4beta1::Application | Hash]
|
276
|
-
# Required. The application to be created.
|
277
|
-
# A hash of the same form as `Google::Cloud::Talent::V4beta1::Application`
|
278
|
-
# can also be provided.
|
279
|
-
# @param options [Google::Gax::CallOptions]
|
280
|
-
# Overrides the default settings for this call, e.g, timeout,
|
281
|
-
# retries, etc.
|
282
|
-
# @yield [result, operation] Access the result along with the RPC operation
|
283
|
-
# @yieldparam result [Google::Cloud::Talent::V4beta1::Application]
|
284
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
285
|
-
# @return [Google::Cloud::Talent::V4beta1::Application]
|
286
|
-
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
287
|
-
# @example
|
288
|
-
# require "google/cloud/talent"
|
289
|
-
#
|
290
|
-
# application_client = Google::Cloud::Talent::ApplicationService.new(version: :v4beta1)
|
291
|
-
# formatted_parent = Google::Cloud::Talent::V4beta1::ApplicationServiceClient.profile_path("[PROJECT]", "[TENANT]", "[PROFILE]")
|
292
|
-
#
|
293
|
-
# # TODO: Initialize `application`:
|
294
|
-
# application = {}
|
295
|
-
# response = application_client.create_application(formatted_parent, application)
|
296
|
-
|
297
|
-
def create_application \
|
298
|
-
parent,
|
299
|
-
application,
|
300
|
-
options: nil,
|
301
|
-
&block
|
302
|
-
req = {
|
303
|
-
parent: parent,
|
304
|
-
application: application
|
305
|
-
}.delete_if { |_, v| v.nil? }
|
306
|
-
req = Google::Gax::to_proto(req, Google::Cloud::Talent::V4beta1::CreateApplicationRequest)
|
307
|
-
@create_application.call(req, options, &block)
|
308
|
-
end
|
309
|
-
|
310
|
-
# Retrieves specified application.
|
311
|
-
#
|
312
|
-
# @param name [String]
|
313
|
-
# Required. The resource name of the application to be retrieved.
|
314
|
-
#
|
315
|
-
# The format is
|
316
|
-
# "projects/{project_id}/tenants/{tenant_id}/profiles/{profile_id}/applications/{application_id}".
|
317
|
-
# For example, "projects/foo/tenants/bar/profiles/baz/applications/qux".
|
318
|
-
# @param options [Google::Gax::CallOptions]
|
319
|
-
# Overrides the default settings for this call, e.g, timeout,
|
320
|
-
# retries, etc.
|
321
|
-
# @yield [result, operation] Access the result along with the RPC operation
|
322
|
-
# @yieldparam result [Google::Cloud::Talent::V4beta1::Application]
|
323
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
324
|
-
# @return [Google::Cloud::Talent::V4beta1::Application]
|
325
|
-
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
326
|
-
# @example
|
327
|
-
# require "google/cloud/talent"
|
328
|
-
#
|
329
|
-
# application_client = Google::Cloud::Talent::ApplicationService.new(version: :v4beta1)
|
330
|
-
# formatted_name = Google::Cloud::Talent::V4beta1::ApplicationServiceClient.application_path("[PROJECT]", "[TENANT]", "[PROFILE]", "[APPLICATION]")
|
331
|
-
# response = application_client.get_application(formatted_name)
|
332
|
-
|
333
|
-
def get_application \
|
334
|
-
name,
|
335
|
-
options: nil,
|
336
|
-
&block
|
337
|
-
req = {
|
338
|
-
name: name
|
339
|
-
}.delete_if { |_, v| v.nil? }
|
340
|
-
req = Google::Gax::to_proto(req, Google::Cloud::Talent::V4beta1::GetApplicationRequest)
|
341
|
-
@get_application.call(req, options, &block)
|
342
|
-
end
|
343
|
-
|
344
|
-
# Updates specified application.
|
345
|
-
#
|
346
|
-
# @param application [Google::Cloud::Talent::V4beta1::Application | Hash]
|
347
|
-
# Required. The application resource to replace the current resource in the
|
348
|
-
# system.
|
349
|
-
# A hash of the same form as `Google::Cloud::Talent::V4beta1::Application`
|
350
|
-
# can also be provided.
|
351
|
-
# @param update_mask [Google::Protobuf::FieldMask | Hash]
|
352
|
-
# Strongly recommended for the best service experience.
|
353
|
-
#
|
354
|
-
# If
|
355
|
-
# {Google::Cloud::Talent::V4beta1::UpdateApplicationRequest#update_mask update_mask}
|
356
|
-
# is provided, only the specified fields in
|
357
|
-
# {Google::Cloud::Talent::V4beta1::UpdateApplicationRequest#application application}
|
358
|
-
# are updated. Otherwise all the fields are updated.
|
359
|
-
#
|
360
|
-
# A field mask to specify the application fields to be updated. Only
|
361
|
-
# top level fields of {Google::Cloud::Talent::V4beta1::Application Application}
|
362
|
-
# are supported.
|
363
|
-
# A hash of the same form as `Google::Protobuf::FieldMask`
|
364
|
-
# can also be provided.
|
365
|
-
# @param options [Google::Gax::CallOptions]
|
366
|
-
# Overrides the default settings for this call, e.g, timeout,
|
367
|
-
# retries, etc.
|
368
|
-
# @yield [result, operation] Access the result along with the RPC operation
|
369
|
-
# @yieldparam result [Google::Cloud::Talent::V4beta1::Application]
|
370
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
371
|
-
# @return [Google::Cloud::Talent::V4beta1::Application]
|
372
|
-
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
373
|
-
# @example
|
374
|
-
# require "google/cloud/talent"
|
375
|
-
#
|
376
|
-
# application_client = Google::Cloud::Talent::ApplicationService.new(version: :v4beta1)
|
377
|
-
#
|
378
|
-
# # TODO: Initialize `application`:
|
379
|
-
# application = {}
|
380
|
-
# response = application_client.update_application(application)
|
381
|
-
|
382
|
-
def update_application \
|
383
|
-
application,
|
384
|
-
update_mask: nil,
|
385
|
-
options: nil,
|
386
|
-
&block
|
387
|
-
req = {
|
388
|
-
application: application,
|
389
|
-
update_mask: update_mask
|
390
|
-
}.delete_if { |_, v| v.nil? }
|
391
|
-
req = Google::Gax::to_proto(req, Google::Cloud::Talent::V4beta1::UpdateApplicationRequest)
|
392
|
-
@update_application.call(req, options, &block)
|
393
|
-
end
|
394
|
-
|
395
|
-
# Deletes specified application.
|
396
|
-
#
|
397
|
-
# @param name [String]
|
398
|
-
# Required. The resource name of the application to be deleted.
|
399
|
-
#
|
400
|
-
# The format is
|
401
|
-
# "projects/{project_id}/tenants/{tenant_id}/profiles/{profile_id}/applications/{application_id}".
|
402
|
-
# For example, "projects/foo/tenants/bar/profiles/baz/applications/qux".
|
403
|
-
# @param options [Google::Gax::CallOptions]
|
404
|
-
# Overrides the default settings for this call, e.g, timeout,
|
405
|
-
# retries, etc.
|
406
|
-
# @yield [result, operation] Access the result along with the RPC operation
|
407
|
-
# @yieldparam result []
|
408
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
409
|
-
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
410
|
-
# @example
|
411
|
-
# require "google/cloud/talent"
|
412
|
-
#
|
413
|
-
# application_client = Google::Cloud::Talent::ApplicationService.new(version: :v4beta1)
|
414
|
-
# formatted_name = Google::Cloud::Talent::V4beta1::ApplicationServiceClient.application_path("[PROJECT]", "[TENANT]", "[PROFILE]", "[APPLICATION]")
|
415
|
-
# application_client.delete_application(formatted_name)
|
416
|
-
|
417
|
-
def delete_application \
|
418
|
-
name,
|
419
|
-
options: nil,
|
420
|
-
&block
|
421
|
-
req = {
|
422
|
-
name: name
|
423
|
-
}.delete_if { |_, v| v.nil? }
|
424
|
-
req = Google::Gax::to_proto(req, Google::Cloud::Talent::V4beta1::DeleteApplicationRequest)
|
425
|
-
@delete_application.call(req, options, &block)
|
426
|
-
nil
|
427
|
-
end
|
428
|
-
|
429
|
-
# Lists all applications associated with the profile.
|
430
|
-
#
|
431
|
-
# @param parent [String]
|
432
|
-
# Required. Resource name of the profile under which the application is
|
433
|
-
# created.
|
434
|
-
#
|
435
|
-
# The format is
|
436
|
-
# "projects/{project_id}/tenants/{tenant_id}/profiles/{profile_id}", for
|
437
|
-
# example, "projects/foo/tenants/bar/profiles/baz".
|
438
|
-
# @param page_size [Integer]
|
439
|
-
# The maximum number of resources contained in the underlying API
|
440
|
-
# response. If page streaming is performed per-resource, this
|
441
|
-
# parameter does not affect the return value. If page streaming is
|
442
|
-
# performed per-page, this determines the maximum number of
|
443
|
-
# resources in a page.
|
444
|
-
# @param options [Google::Gax::CallOptions]
|
445
|
-
# Overrides the default settings for this call, e.g, timeout,
|
446
|
-
# retries, etc.
|
447
|
-
# @yield [result, operation] Access the result along with the RPC operation
|
448
|
-
# @yieldparam result [Google::Gax::PagedEnumerable<Google::Cloud::Talent::V4beta1::Application>]
|
449
|
-
# @yieldparam operation [GRPC::ActiveCall::Operation]
|
450
|
-
# @return [Google::Gax::PagedEnumerable<Google::Cloud::Talent::V4beta1::Application>]
|
451
|
-
# An enumerable of Google::Cloud::Talent::V4beta1::Application instances.
|
452
|
-
# See Google::Gax::PagedEnumerable documentation for other
|
453
|
-
# operations such as per-page iteration or access to the response
|
454
|
-
# object.
|
455
|
-
# @raise [Google::Gax::GaxError] if the RPC is aborted.
|
456
|
-
# @example
|
457
|
-
# require "google/cloud/talent"
|
458
|
-
#
|
459
|
-
# application_client = Google::Cloud::Talent::ApplicationService.new(version: :v4beta1)
|
460
|
-
# formatted_parent = Google::Cloud::Talent::V4beta1::ApplicationServiceClient.profile_path("[PROJECT]", "[TENANT]", "[PROFILE]")
|
461
|
-
#
|
462
|
-
# # Iterate over all results.
|
463
|
-
# application_client.list_applications(formatted_parent).each do |element|
|
464
|
-
# # Process element.
|
465
|
-
# end
|
466
|
-
#
|
467
|
-
# # Or iterate over results one page at a time.
|
468
|
-
# application_client.list_applications(formatted_parent).each_page do |page|
|
469
|
-
# # Process each page at a time.
|
470
|
-
# page.each do |element|
|
471
|
-
# # Process element.
|
472
|
-
# end
|
473
|
-
# end
|
474
|
-
|
475
|
-
def list_applications \
|
476
|
-
parent,
|
477
|
-
page_size: nil,
|
478
|
-
options: nil,
|
479
|
-
&block
|
480
|
-
req = {
|
481
|
-
parent: parent,
|
482
|
-
page_size: page_size
|
483
|
-
}.delete_if { |_, v| v.nil? }
|
484
|
-
req = Google::Gax::to_proto(req, Google::Cloud::Talent::V4beta1::ListApplicationsRequest)
|
485
|
-
@list_applications.call(req, options, &block)
|
486
|
-
end
|
487
|
-
end
|
488
|
-
end
|
489
|
-
end
|
490
|
-
end
|
491
|
-
end
|