google-apis-gameservices_v1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,1437 @@
1
+ # Copyright 2020 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
+ # http://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
+ require 'google/apis/core/base_service'
16
+ require 'google/apis/core/json_representation'
17
+ require 'google/apis/core/hashable'
18
+ require 'google/apis/errors'
19
+
20
+ module Google
21
+ module Apis
22
+ module GameservicesV1
23
+ # Game Services API
24
+ #
25
+ # Deploy and manage infrastructure for global multiplayer gaming experiences.
26
+ #
27
+ # @example
28
+ # require 'google/apis/gameservices_v1'
29
+ #
30
+ # Gameservices = Google::Apis::GameservicesV1 # Alias the module
31
+ # service = Gameservices::GameServicesService.new
32
+ #
33
+ # @see https://cloud.google.com/solutions/gaming/
34
+ class GameServicesService < Google::Apis::Core::BaseService
35
+ # @return [String]
36
+ # API key. Your API key identifies your project and provides you with API access,
37
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
38
+ attr_accessor :key
39
+
40
+ # @return [String]
41
+ # Available to use for quota purposes for server-side applications. Can be any
42
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
43
+ attr_accessor :quota_user
44
+
45
+ def initialize
46
+ super('https://gameservices.googleapis.com/', '',
47
+ client_name: 'google-apis-gameservices_v1',
48
+ client_version: Google::Apis::GameservicesV1::GEM_VERSION)
49
+ @batch_path = 'batch'
50
+ end
51
+
52
+ # Gets information about a location.
53
+ # @param [String] name
54
+ # Resource name for the location.
55
+ # @param [String] fields
56
+ # Selector specifying which fields to include in a partial response.
57
+ # @param [String] quota_user
58
+ # Available to use for quota purposes for server-side applications. Can be any
59
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
60
+ # @param [Google::Apis::RequestOptions] options
61
+ # Request-specific options
62
+ #
63
+ # @yield [result, err] Result & error if block supplied
64
+ # @yieldparam result [Google::Apis::GameservicesV1::Location] parsed result object
65
+ # @yieldparam err [StandardError] error object if request failed
66
+ #
67
+ # @return [Google::Apis::GameservicesV1::Location]
68
+ #
69
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
70
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
71
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
72
+ def get_project_location(name, fields: nil, quota_user: nil, options: nil, &block)
73
+ command = make_simple_command(:get, 'v1/{+name}', options)
74
+ command.response_representation = Google::Apis::GameservicesV1::Location::Representation
75
+ command.response_class = Google::Apis::GameservicesV1::Location
76
+ command.params['name'] = name unless name.nil?
77
+ command.query['fields'] = fields unless fields.nil?
78
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
79
+ execute_or_queue_command(command, &block)
80
+ end
81
+
82
+ # Lists information about the supported locations for this service.
83
+ # @param [String] name
84
+ # The resource that owns the locations collection, if applicable.
85
+ # @param [String] filter
86
+ # The standard list filter.
87
+ # @param [Boolean] include_unrevealed_locations
88
+ # If true, the returned list will include locations which are not yet revealed.
89
+ # @param [Fixnum] page_size
90
+ # The standard list page size.
91
+ # @param [String] page_token
92
+ # The standard list page token.
93
+ # @param [String] fields
94
+ # Selector specifying which fields to include in a partial response.
95
+ # @param [String] quota_user
96
+ # Available to use for quota purposes for server-side applications. Can be any
97
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
98
+ # @param [Google::Apis::RequestOptions] options
99
+ # Request-specific options
100
+ #
101
+ # @yield [result, err] Result & error if block supplied
102
+ # @yieldparam result [Google::Apis::GameservicesV1::ListLocationsResponse] parsed result object
103
+ # @yieldparam err [StandardError] error object if request failed
104
+ #
105
+ # @return [Google::Apis::GameservicesV1::ListLocationsResponse]
106
+ #
107
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
108
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
109
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
110
+ def list_project_locations(name, filter: nil, include_unrevealed_locations: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
111
+ command = make_simple_command(:get, 'v1/{+name}/locations', options)
112
+ command.response_representation = Google::Apis::GameservicesV1::ListLocationsResponse::Representation
113
+ command.response_class = Google::Apis::GameservicesV1::ListLocationsResponse
114
+ command.params['name'] = name unless name.nil?
115
+ command.query['filter'] = filter unless filter.nil?
116
+ command.query['includeUnrevealedLocations'] = include_unrevealed_locations unless include_unrevealed_locations.nil?
117
+ command.query['pageSize'] = page_size unless page_size.nil?
118
+ command.query['pageToken'] = page_token unless page_token.nil?
119
+ command.query['fields'] = fields unless fields.nil?
120
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
121
+ execute_or_queue_command(command, &block)
122
+ end
123
+
124
+ # Creates a new game server deployment in a given project and location.
125
+ # @param [String] parent
126
+ # Required. The parent resource name, in the following form: `projects/`project`/
127
+ # locations/`location``.
128
+ # @param [Google::Apis::GameservicesV1::GameServerDeployment] game_server_deployment_object
129
+ # @param [String] deployment_id
130
+ # Required. The ID of the game server delpoyment resource to be created.
131
+ # @param [String] fields
132
+ # Selector specifying which fields to include in a partial response.
133
+ # @param [String] quota_user
134
+ # Available to use for quota purposes for server-side applications. Can be any
135
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
136
+ # @param [Google::Apis::RequestOptions] options
137
+ # Request-specific options
138
+ #
139
+ # @yield [result, err] Result & error if block supplied
140
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
141
+ # @yieldparam err [StandardError] error object if request failed
142
+ #
143
+ # @return [Google::Apis::GameservicesV1::Operation]
144
+ #
145
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
146
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
147
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
148
+ def create_project_location_game_server_deployment(parent, game_server_deployment_object = nil, deployment_id: nil, fields: nil, quota_user: nil, options: nil, &block)
149
+ command = make_simple_command(:post, 'v1/{+parent}/gameServerDeployments', options)
150
+ command.request_representation = Google::Apis::GameservicesV1::GameServerDeployment::Representation
151
+ command.request_object = game_server_deployment_object
152
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
153
+ command.response_class = Google::Apis::GameservicesV1::Operation
154
+ command.params['parent'] = parent unless parent.nil?
155
+ command.query['deploymentId'] = deployment_id unless deployment_id.nil?
156
+ command.query['fields'] = fields unless fields.nil?
157
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
158
+ execute_or_queue_command(command, &block)
159
+ end
160
+
161
+ # Deletes a single game server deployment.
162
+ # @param [String] name
163
+ # Required. The name of the game server delpoyment to delete, in the following
164
+ # form: `projects/`project`/locations/`location`/gameServerDeployments/`
165
+ # deployment``.
166
+ # @param [String] fields
167
+ # Selector specifying which fields to include in a partial response.
168
+ # @param [String] quota_user
169
+ # Available to use for quota purposes for server-side applications. Can be any
170
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
171
+ # @param [Google::Apis::RequestOptions] options
172
+ # Request-specific options
173
+ #
174
+ # @yield [result, err] Result & error if block supplied
175
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
176
+ # @yieldparam err [StandardError] error object if request failed
177
+ #
178
+ # @return [Google::Apis::GameservicesV1::Operation]
179
+ #
180
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
181
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
182
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
183
+ def delete_project_location_game_server_deployment(name, fields: nil, quota_user: nil, options: nil, &block)
184
+ command = make_simple_command(:delete, 'v1/{+name}', options)
185
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
186
+ command.response_class = Google::Apis::GameservicesV1::Operation
187
+ command.params['name'] = name unless name.nil?
188
+ command.query['fields'] = fields unless fields.nil?
189
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
190
+ execute_or_queue_command(command, &block)
191
+ end
192
+
193
+ # Retrieves information about the current state of the game server deployment.
194
+ # Gathers all the Agones fleets and Agones autoscalers, including fleets running
195
+ # an older version of the game server deployment.
196
+ # @param [String] name
197
+ # Required. The name of the game server delpoyment, in the following form: `
198
+ # projects/`project`/locations/`location`/gameServerDeployments/`deployment``.
199
+ # @param [Google::Apis::GameservicesV1::FetchDeploymentStateRequest] fetch_deployment_state_request_object
200
+ # @param [String] fields
201
+ # Selector specifying which fields to include in a partial response.
202
+ # @param [String] quota_user
203
+ # Available to use for quota purposes for server-side applications. Can be any
204
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
205
+ # @param [Google::Apis::RequestOptions] options
206
+ # Request-specific options
207
+ #
208
+ # @yield [result, err] Result & error if block supplied
209
+ # @yieldparam result [Google::Apis::GameservicesV1::FetchDeploymentStateResponse] parsed result object
210
+ # @yieldparam err [StandardError] error object if request failed
211
+ #
212
+ # @return [Google::Apis::GameservicesV1::FetchDeploymentStateResponse]
213
+ #
214
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
215
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
216
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
217
+ def fetch_game_server_deployment_deployment_state(name, fetch_deployment_state_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
218
+ command = make_simple_command(:post, 'v1/{+name}:fetchDeploymentState', options)
219
+ command.request_representation = Google::Apis::GameservicesV1::FetchDeploymentStateRequest::Representation
220
+ command.request_object = fetch_deployment_state_request_object
221
+ command.response_representation = Google::Apis::GameservicesV1::FetchDeploymentStateResponse::Representation
222
+ command.response_class = Google::Apis::GameservicesV1::FetchDeploymentStateResponse
223
+ command.params['name'] = name unless name.nil?
224
+ command.query['fields'] = fields unless fields.nil?
225
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
226
+ execute_or_queue_command(command, &block)
227
+ end
228
+
229
+ # Gets details of a single game server deployment.
230
+ # @param [String] name
231
+ # Required. The name of the game server delpoyment to retrieve, in the following
232
+ # form: `projects/`project`/locations/`location`/gameServerDeployments/`
233
+ # deployment``.
234
+ # @param [String] fields
235
+ # Selector specifying which fields to include in a partial response.
236
+ # @param [String] quota_user
237
+ # Available to use for quota purposes for server-side applications. Can be any
238
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
239
+ # @param [Google::Apis::RequestOptions] options
240
+ # Request-specific options
241
+ #
242
+ # @yield [result, err] Result & error if block supplied
243
+ # @yieldparam result [Google::Apis::GameservicesV1::GameServerDeployment] parsed result object
244
+ # @yieldparam err [StandardError] error object if request failed
245
+ #
246
+ # @return [Google::Apis::GameservicesV1::GameServerDeployment]
247
+ #
248
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
249
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
250
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
251
+ def get_project_location_game_server_deployment(name, fields: nil, quota_user: nil, options: nil, &block)
252
+ command = make_simple_command(:get, 'v1/{+name}', options)
253
+ command.response_representation = Google::Apis::GameservicesV1::GameServerDeployment::Representation
254
+ command.response_class = Google::Apis::GameservicesV1::GameServerDeployment
255
+ command.params['name'] = name unless name.nil?
256
+ command.query['fields'] = fields unless fields.nil?
257
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
258
+ execute_or_queue_command(command, &block)
259
+ end
260
+
261
+ # Gets the access control policy for a resource. Returns an empty policy if the
262
+ # resource exists and does not have a policy set.
263
+ # @param [String] resource
264
+ # REQUIRED: The resource for which the policy is being requested. See the
265
+ # operation documentation for the appropriate value for this field.
266
+ # @param [Fixnum] options_requested_policy_version
267
+ # Optional. The policy format version to be returned. Valid values are 0, 1, and
268
+ # 3. Requests specifying an invalid value will be rejected. Requests for
269
+ # policies with any conditional bindings must specify version 3. Policies
270
+ # without any conditional bindings may specify any valid value or leave the
271
+ # field unset. To learn which resources support conditions in their IAM policies,
272
+ # see the [IAM documentation](https://cloud.google.com/iam/help/conditions/
273
+ # resource-policies).
274
+ # @param [String] fields
275
+ # Selector specifying which fields to include in a partial response.
276
+ # @param [String] quota_user
277
+ # Available to use for quota purposes for server-side applications. Can be any
278
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
279
+ # @param [Google::Apis::RequestOptions] options
280
+ # Request-specific options
281
+ #
282
+ # @yield [result, err] Result & error if block supplied
283
+ # @yieldparam result [Google::Apis::GameservicesV1::Policy] parsed result object
284
+ # @yieldparam err [StandardError] error object if request failed
285
+ #
286
+ # @return [Google::Apis::GameservicesV1::Policy]
287
+ #
288
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
289
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
290
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
291
+ def get_project_location_game_server_deployment_iam_policy(resource, options_requested_policy_version: nil, fields: nil, quota_user: nil, options: nil, &block)
292
+ command = make_simple_command(:get, 'v1/{+resource}:getIamPolicy', options)
293
+ command.response_representation = Google::Apis::GameservicesV1::Policy::Representation
294
+ command.response_class = Google::Apis::GameservicesV1::Policy
295
+ command.params['resource'] = resource unless resource.nil?
296
+ command.query['options.requestedPolicyVersion'] = options_requested_policy_version unless options_requested_policy_version.nil?
297
+ command.query['fields'] = fields unless fields.nil?
298
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
299
+ execute_or_queue_command(command, &block)
300
+ end
301
+
302
+ # Gets details a single game server deployment rollout.
303
+ # @param [String] name
304
+ # Required. The name of the game server delpoyment to retrieve, in the following
305
+ # form: `projects/`project`/locations/`location`/gameServerDeployments/`
306
+ # deployment`/rollout`.
307
+ # @param [String] fields
308
+ # Selector specifying which fields to include in a partial response.
309
+ # @param [String] quota_user
310
+ # Available to use for quota purposes for server-side applications. Can be any
311
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
312
+ # @param [Google::Apis::RequestOptions] options
313
+ # Request-specific options
314
+ #
315
+ # @yield [result, err] Result & error if block supplied
316
+ # @yieldparam result [Google::Apis::GameservicesV1::GameServerDeploymentRollout] parsed result object
317
+ # @yieldparam err [StandardError] error object if request failed
318
+ #
319
+ # @return [Google::Apis::GameservicesV1::GameServerDeploymentRollout]
320
+ #
321
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
322
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
323
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
324
+ def get_project_location_game_server_deployment_rollout(name, fields: nil, quota_user: nil, options: nil, &block)
325
+ command = make_simple_command(:get, 'v1/{+name}/rollout', options)
326
+ command.response_representation = Google::Apis::GameservicesV1::GameServerDeploymentRollout::Representation
327
+ command.response_class = Google::Apis::GameservicesV1::GameServerDeploymentRollout
328
+ command.params['name'] = name unless name.nil?
329
+ command.query['fields'] = fields unless fields.nil?
330
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
331
+ execute_or_queue_command(command, &block)
332
+ end
333
+
334
+ # Lists game server deployments in a given project and location.
335
+ # @param [String] parent
336
+ # Required. The parent resource name, in the following form: `projects/`project`/
337
+ # locations/`location``.
338
+ # @param [String] filter
339
+ # Optional. The filter to apply to list results.
340
+ # @param [String] order_by
341
+ # Optional. Specifies the ordering of results following syntax at https://cloud.
342
+ # google.com/apis/design/design_patterns#sorting_order.
343
+ # @param [Fixnum] page_size
344
+ # Optional. The maximum number of items to return. If unspecified, the server
345
+ # will pick an appropriate default. The server may return fewer items than
346
+ # requested. A caller should only rely on response's next_page_token to
347
+ # determine if there are more GameServerDeployments left to be queried.
348
+ # @param [String] page_token
349
+ # Optional. The next_page_token value returned from a previous List request, if
350
+ # any.
351
+ # @param [String] fields
352
+ # Selector specifying which fields to include in a partial response.
353
+ # @param [String] quota_user
354
+ # Available to use for quota purposes for server-side applications. Can be any
355
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
356
+ # @param [Google::Apis::RequestOptions] options
357
+ # Request-specific options
358
+ #
359
+ # @yield [result, err] Result & error if block supplied
360
+ # @yieldparam result [Google::Apis::GameservicesV1::ListGameServerDeploymentsResponse] parsed result object
361
+ # @yieldparam err [StandardError] error object if request failed
362
+ #
363
+ # @return [Google::Apis::GameservicesV1::ListGameServerDeploymentsResponse]
364
+ #
365
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
366
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
367
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
368
+ def list_project_location_game_server_deployments(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
369
+ command = make_simple_command(:get, 'v1/{+parent}/gameServerDeployments', options)
370
+ command.response_representation = Google::Apis::GameservicesV1::ListGameServerDeploymentsResponse::Representation
371
+ command.response_class = Google::Apis::GameservicesV1::ListGameServerDeploymentsResponse
372
+ command.params['parent'] = parent unless parent.nil?
373
+ command.query['filter'] = filter unless filter.nil?
374
+ command.query['orderBy'] = order_by unless order_by.nil?
375
+ command.query['pageSize'] = page_size unless page_size.nil?
376
+ command.query['pageToken'] = page_token unless page_token.nil?
377
+ command.query['fields'] = fields unless fields.nil?
378
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
379
+ execute_or_queue_command(command, &block)
380
+ end
381
+
382
+ # Patches a game server deployment.
383
+ # @param [String] name
384
+ # The resource name of the game server deployment, in the following form: `
385
+ # projects/`project`/locations/`location`/gameServerDeployments/`deployment``.
386
+ # For example, `projects/my-project/locations/global/gameServerDeployments/my-
387
+ # deployment`.
388
+ # @param [Google::Apis::GameservicesV1::GameServerDeployment] game_server_deployment_object
389
+ # @param [String] update_mask
390
+ # Required. Mask of fields to update. At least one path must be supplied in this
391
+ # field. For the `FieldMask` definition, see https://developers.google.com/
392
+ # protocol-buffers/docs/reference/google.protobuf#fieldmask
393
+ # @param [String] fields
394
+ # Selector specifying which fields to include in a partial response.
395
+ # @param [String] quota_user
396
+ # Available to use for quota purposes for server-side applications. Can be any
397
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
398
+ # @param [Google::Apis::RequestOptions] options
399
+ # Request-specific options
400
+ #
401
+ # @yield [result, err] Result & error if block supplied
402
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
403
+ # @yieldparam err [StandardError] error object if request failed
404
+ #
405
+ # @return [Google::Apis::GameservicesV1::Operation]
406
+ #
407
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
408
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
409
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
410
+ def patch_project_location_game_server_deployment(name, game_server_deployment_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
411
+ command = make_simple_command(:patch, 'v1/{+name}', options)
412
+ command.request_representation = Google::Apis::GameservicesV1::GameServerDeployment::Representation
413
+ command.request_object = game_server_deployment_object
414
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
415
+ command.response_class = Google::Apis::GameservicesV1::Operation
416
+ command.params['name'] = name unless name.nil?
417
+ command.query['updateMask'] = update_mask unless update_mask.nil?
418
+ command.query['fields'] = fields unless fields.nil?
419
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
420
+ execute_or_queue_command(command, &block)
421
+ end
422
+
423
+ # Previews the game server deployment rollout. This API does not mutate the
424
+ # rollout resource.
425
+ # @param [String] name
426
+ # The resource name of the game server deployment rollout, in the following form:
427
+ # `projects/`project`/locations/`location`/gameServerDeployments/`deployment`/
428
+ # rollout`. For example, `projects/my-project/locations/global/
429
+ # gameServerDeployments/my-deployment/rollout`.
430
+ # @param [Google::Apis::GameservicesV1::GameServerDeploymentRollout] game_server_deployment_rollout_object
431
+ # @param [String] preview_time
432
+ # Optional. The target timestamp to compute the preview. Defaults to the
433
+ # immediately after the proposed rollout completes.
434
+ # @param [String] update_mask
435
+ # Optional. Mask of fields to update. At least one path must be supplied in this
436
+ # field. For the `FieldMask` definition, see https://developers.google.com/
437
+ # protocol-buffers/docs/reference/google.protobuf#fieldmask
438
+ # @param [String] fields
439
+ # Selector specifying which fields to include in a partial response.
440
+ # @param [String] quota_user
441
+ # Available to use for quota purposes for server-side applications. Can be any
442
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
443
+ # @param [Google::Apis::RequestOptions] options
444
+ # Request-specific options
445
+ #
446
+ # @yield [result, err] Result & error if block supplied
447
+ # @yieldparam result [Google::Apis::GameservicesV1::PreviewGameServerDeploymentRolloutResponse] parsed result object
448
+ # @yieldparam err [StandardError] error object if request failed
449
+ #
450
+ # @return [Google::Apis::GameservicesV1::PreviewGameServerDeploymentRolloutResponse]
451
+ #
452
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
453
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
454
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
455
+ def preview_project_location_game_server_deployment_rollout(name, game_server_deployment_rollout_object = nil, preview_time: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
456
+ command = make_simple_command(:patch, 'v1/{+name}/rollout:preview', options)
457
+ command.request_representation = Google::Apis::GameservicesV1::GameServerDeploymentRollout::Representation
458
+ command.request_object = game_server_deployment_rollout_object
459
+ command.response_representation = Google::Apis::GameservicesV1::PreviewGameServerDeploymentRolloutResponse::Representation
460
+ command.response_class = Google::Apis::GameservicesV1::PreviewGameServerDeploymentRolloutResponse
461
+ command.params['name'] = name unless name.nil?
462
+ command.query['previewTime'] = preview_time unless preview_time.nil?
463
+ command.query['updateMask'] = update_mask unless update_mask.nil?
464
+ command.query['fields'] = fields unless fields.nil?
465
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
466
+ execute_or_queue_command(command, &block)
467
+ end
468
+
469
+ # Sets the access control policy on the specified resource. Replaces any
470
+ # existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `
471
+ # PERMISSION_DENIED` errors.
472
+ # @param [String] resource
473
+ # REQUIRED: The resource for which the policy is being specified. See the
474
+ # operation documentation for the appropriate value for this field.
475
+ # @param [Google::Apis::GameservicesV1::SetIamPolicyRequest] set_iam_policy_request_object
476
+ # @param [String] fields
477
+ # Selector specifying which fields to include in a partial response.
478
+ # @param [String] quota_user
479
+ # Available to use for quota purposes for server-side applications. Can be any
480
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
481
+ # @param [Google::Apis::RequestOptions] options
482
+ # Request-specific options
483
+ #
484
+ # @yield [result, err] Result & error if block supplied
485
+ # @yieldparam result [Google::Apis::GameservicesV1::Policy] parsed result object
486
+ # @yieldparam err [StandardError] error object if request failed
487
+ #
488
+ # @return [Google::Apis::GameservicesV1::Policy]
489
+ #
490
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
491
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
492
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
493
+ def set_game_server_deployment_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
494
+ command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
495
+ command.request_representation = Google::Apis::GameservicesV1::SetIamPolicyRequest::Representation
496
+ command.request_object = set_iam_policy_request_object
497
+ command.response_representation = Google::Apis::GameservicesV1::Policy::Representation
498
+ command.response_class = Google::Apis::GameservicesV1::Policy
499
+ command.params['resource'] = resource unless resource.nil?
500
+ command.query['fields'] = fields unless fields.nil?
501
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
502
+ execute_or_queue_command(command, &block)
503
+ end
504
+
505
+ # Returns permissions that a caller has on the specified resource. If the
506
+ # resource does not exist, this will return an empty set of permissions, not a `
507
+ # NOT_FOUND` error. Note: This operation is designed to be used for building
508
+ # permission-aware UIs and command-line tools, not for authorization checking.
509
+ # This operation may "fail open" without warning.
510
+ # @param [String] resource
511
+ # REQUIRED: The resource for which the policy detail is being requested. See the
512
+ # operation documentation for the appropriate value for this field.
513
+ # @param [Google::Apis::GameservicesV1::TestIamPermissionsRequest] test_iam_permissions_request_object
514
+ # @param [String] fields
515
+ # Selector specifying which fields to include in a partial response.
516
+ # @param [String] quota_user
517
+ # Available to use for quota purposes for server-side applications. Can be any
518
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
519
+ # @param [Google::Apis::RequestOptions] options
520
+ # Request-specific options
521
+ #
522
+ # @yield [result, err] Result & error if block supplied
523
+ # @yieldparam result [Google::Apis::GameservicesV1::TestIamPermissionsResponse] parsed result object
524
+ # @yieldparam err [StandardError] error object if request failed
525
+ #
526
+ # @return [Google::Apis::GameservicesV1::TestIamPermissionsResponse]
527
+ #
528
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
529
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
530
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
531
+ def test_game_server_deployment_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
532
+ command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
533
+ command.request_representation = Google::Apis::GameservicesV1::TestIamPermissionsRequest::Representation
534
+ command.request_object = test_iam_permissions_request_object
535
+ command.response_representation = Google::Apis::GameservicesV1::TestIamPermissionsResponse::Representation
536
+ command.response_class = Google::Apis::GameservicesV1::TestIamPermissionsResponse
537
+ command.params['resource'] = resource unless resource.nil?
538
+ command.query['fields'] = fields unless fields.nil?
539
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
540
+ execute_or_queue_command(command, &block)
541
+ end
542
+
543
+ # Patches a single game server deployment rollout. The method will not return an
544
+ # error if the update does not affect any existing realms. For example - if the
545
+ # default_game_server_config is changed but all existing realms use the override,
546
+ # that is valid. Similarly, if a non existing realm is explicitly called out in
547
+ # game_server_config_overrides field, that will also not result in an error.
548
+ # @param [String] name
549
+ # The resource name of the game server deployment rollout, in the following form:
550
+ # `projects/`project`/locations/`location`/gameServerDeployments/`deployment`/
551
+ # rollout`. For example, `projects/my-project/locations/global/
552
+ # gameServerDeployments/my-deployment/rollout`.
553
+ # @param [Google::Apis::GameservicesV1::GameServerDeploymentRollout] game_server_deployment_rollout_object
554
+ # @param [String] update_mask
555
+ # Required. Mask of fields to update. At least one path must be supplied in this
556
+ # field. For the `FieldMask` definition, see https://developers.google.com/
557
+ # protocol-buffers/docs/reference/google.protobuf#fieldmask
558
+ # @param [String] fields
559
+ # Selector specifying which fields to include in a partial response.
560
+ # @param [String] quota_user
561
+ # Available to use for quota purposes for server-side applications. Can be any
562
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
563
+ # @param [Google::Apis::RequestOptions] options
564
+ # Request-specific options
565
+ #
566
+ # @yield [result, err] Result & error if block supplied
567
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
568
+ # @yieldparam err [StandardError] error object if request failed
569
+ #
570
+ # @return [Google::Apis::GameservicesV1::Operation]
571
+ #
572
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
573
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
574
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
575
+ def update_project_location_game_server_deployment_rollout(name, game_server_deployment_rollout_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
576
+ command = make_simple_command(:patch, 'v1/{+name}/rollout', options)
577
+ command.request_representation = Google::Apis::GameservicesV1::GameServerDeploymentRollout::Representation
578
+ command.request_object = game_server_deployment_rollout_object
579
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
580
+ command.response_class = Google::Apis::GameservicesV1::Operation
581
+ command.params['name'] = name unless name.nil?
582
+ command.query['updateMask'] = update_mask unless update_mask.nil?
583
+ command.query['fields'] = fields unless fields.nil?
584
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
585
+ execute_or_queue_command(command, &block)
586
+ end
587
+
588
+ # Creates a new game server config in a given project, location, and game server
589
+ # deployment. Game server configs are immutable, and are not applied until
590
+ # referenced in the game server deployment rollout resource.
591
+ # @param [String] parent
592
+ # Required. The parent resource name, in the following form: `projects/`project`/
593
+ # locations/`location`/gameServerDeployments/`deployment`/`.
594
+ # @param [Google::Apis::GameservicesV1::GameServerConfig] game_server_config_object
595
+ # @param [String] config_id
596
+ # Required. The ID of the game server config resource to be created.
597
+ # @param [String] fields
598
+ # Selector specifying which fields to include in a partial response.
599
+ # @param [String] quota_user
600
+ # Available to use for quota purposes for server-side applications. Can be any
601
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
602
+ # @param [Google::Apis::RequestOptions] options
603
+ # Request-specific options
604
+ #
605
+ # @yield [result, err] Result & error if block supplied
606
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
607
+ # @yieldparam err [StandardError] error object if request failed
608
+ #
609
+ # @return [Google::Apis::GameservicesV1::Operation]
610
+ #
611
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
612
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
613
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
614
+ def create_project_location_game_server_deployment_config(parent, game_server_config_object = nil, config_id: nil, fields: nil, quota_user: nil, options: nil, &block)
615
+ command = make_simple_command(:post, 'v1/{+parent}/configs', options)
616
+ command.request_representation = Google::Apis::GameservicesV1::GameServerConfig::Representation
617
+ command.request_object = game_server_config_object
618
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
619
+ command.response_class = Google::Apis::GameservicesV1::Operation
620
+ command.params['parent'] = parent unless parent.nil?
621
+ command.query['configId'] = config_id unless config_id.nil?
622
+ command.query['fields'] = fields unless fields.nil?
623
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
624
+ execute_or_queue_command(command, &block)
625
+ end
626
+
627
+ # Deletes a single game server config. The deletion will fail if the game server
628
+ # config is referenced in a game server deployment rollout.
629
+ # @param [String] name
630
+ # Required. The name of the game server config to delete, in the following form:
631
+ # `projects/`project`/locations/`location`/gameServerDeployments/`deployment`/
632
+ # configs/`config``.
633
+ # @param [String] fields
634
+ # Selector specifying which fields to include in a partial response.
635
+ # @param [String] quota_user
636
+ # Available to use for quota purposes for server-side applications. Can be any
637
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
638
+ # @param [Google::Apis::RequestOptions] options
639
+ # Request-specific options
640
+ #
641
+ # @yield [result, err] Result & error if block supplied
642
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
643
+ # @yieldparam err [StandardError] error object if request failed
644
+ #
645
+ # @return [Google::Apis::GameservicesV1::Operation]
646
+ #
647
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
648
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
649
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
650
+ def delete_project_location_game_server_deployment_config(name, fields: nil, quota_user: nil, options: nil, &block)
651
+ command = make_simple_command(:delete, 'v1/{+name}', options)
652
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
653
+ command.response_class = Google::Apis::GameservicesV1::Operation
654
+ command.params['name'] = name unless name.nil?
655
+ command.query['fields'] = fields unless fields.nil?
656
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
657
+ execute_or_queue_command(command, &block)
658
+ end
659
+
660
+ # Gets details of a single game server config.
661
+ # @param [String] name
662
+ # Required. The name of the game server config to retrieve, in the following
663
+ # form: `projects/`project`/locations/`location`/gameServerDeployments/`
664
+ # deployment`/configs/`config``.
665
+ # @param [String] fields
666
+ # Selector specifying which fields to include in a partial response.
667
+ # @param [String] quota_user
668
+ # Available to use for quota purposes for server-side applications. Can be any
669
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
670
+ # @param [Google::Apis::RequestOptions] options
671
+ # Request-specific options
672
+ #
673
+ # @yield [result, err] Result & error if block supplied
674
+ # @yieldparam result [Google::Apis::GameservicesV1::GameServerConfig] parsed result object
675
+ # @yieldparam err [StandardError] error object if request failed
676
+ #
677
+ # @return [Google::Apis::GameservicesV1::GameServerConfig]
678
+ #
679
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
680
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
681
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
682
+ def get_project_location_game_server_deployment_config(name, fields: nil, quota_user: nil, options: nil, &block)
683
+ command = make_simple_command(:get, 'v1/{+name}', options)
684
+ command.response_representation = Google::Apis::GameservicesV1::GameServerConfig::Representation
685
+ command.response_class = Google::Apis::GameservicesV1::GameServerConfig
686
+ command.params['name'] = name unless name.nil?
687
+ command.query['fields'] = fields unless fields.nil?
688
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
689
+ execute_or_queue_command(command, &block)
690
+ end
691
+
692
+ # Lists game server configs in a given project, location, and game server
693
+ # deployment.
694
+ # @param [String] parent
695
+ # Required. The parent resource name, in the following form: `projects/`project`/
696
+ # locations/`location`/gameServerDeployments/`deployment`/configs/*`.
697
+ # @param [String] filter
698
+ # Optional. The filter to apply to list results.
699
+ # @param [String] order_by
700
+ # Optional. Specifies the ordering of results following syntax at https://cloud.
701
+ # google.com/apis/design/design_patterns#sorting_order.
702
+ # @param [Fixnum] page_size
703
+ # Optional. The maximum number of items to return. If unspecified, server will
704
+ # pick an appropriate default. Server may return fewer items than requested. A
705
+ # caller should only rely on response's next_page_token to determine if there
706
+ # are more GameServerConfigs left to be queried.
707
+ # @param [String] page_token
708
+ # Optional. The next_page_token value returned from a previous list request, if
709
+ # any.
710
+ # @param [String] fields
711
+ # Selector specifying which fields to include in a partial response.
712
+ # @param [String] quota_user
713
+ # Available to use for quota purposes for server-side applications. Can be any
714
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
715
+ # @param [Google::Apis::RequestOptions] options
716
+ # Request-specific options
717
+ #
718
+ # @yield [result, err] Result & error if block supplied
719
+ # @yieldparam result [Google::Apis::GameservicesV1::ListGameServerConfigsResponse] parsed result object
720
+ # @yieldparam err [StandardError] error object if request failed
721
+ #
722
+ # @return [Google::Apis::GameservicesV1::ListGameServerConfigsResponse]
723
+ #
724
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
725
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
726
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
727
+ def list_project_location_game_server_deployment_configs(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
728
+ command = make_simple_command(:get, 'v1/{+parent}/configs', options)
729
+ command.response_representation = Google::Apis::GameservicesV1::ListGameServerConfigsResponse::Representation
730
+ command.response_class = Google::Apis::GameservicesV1::ListGameServerConfigsResponse
731
+ command.params['parent'] = parent unless parent.nil?
732
+ command.query['filter'] = filter unless filter.nil?
733
+ command.query['orderBy'] = order_by unless order_by.nil?
734
+ command.query['pageSize'] = page_size unless page_size.nil?
735
+ command.query['pageToken'] = page_token unless page_token.nil?
736
+ command.query['fields'] = fields unless fields.nil?
737
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
738
+ execute_or_queue_command(command, &block)
739
+ end
740
+
741
+ # Starts asynchronous cancellation on a long-running operation. The server makes
742
+ # a best effort to cancel the operation, but success is not guaranteed. If the
743
+ # server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.
744
+ # Clients can use Operations.GetOperation or other methods to check whether the
745
+ # cancellation succeeded or whether the operation completed despite cancellation.
746
+ # On successful cancellation, the operation is not deleted; instead, it becomes
747
+ # an operation with an Operation.error value with a google.rpc.Status.code of 1,
748
+ # corresponding to `Code.CANCELLED`.
749
+ # @param [String] name
750
+ # The name of the operation resource to be cancelled.
751
+ # @param [Google::Apis::GameservicesV1::CancelOperationRequest] cancel_operation_request_object
752
+ # @param [String] fields
753
+ # Selector specifying which fields to include in a partial response.
754
+ # @param [String] quota_user
755
+ # Available to use for quota purposes for server-side applications. Can be any
756
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
757
+ # @param [Google::Apis::RequestOptions] options
758
+ # Request-specific options
759
+ #
760
+ # @yield [result, err] Result & error if block supplied
761
+ # @yieldparam result [Google::Apis::GameservicesV1::Empty] parsed result object
762
+ # @yieldparam err [StandardError] error object if request failed
763
+ #
764
+ # @return [Google::Apis::GameservicesV1::Empty]
765
+ #
766
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
767
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
768
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
769
+ def cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
770
+ command = make_simple_command(:post, 'v1/{+name}:cancel', options)
771
+ command.request_representation = Google::Apis::GameservicesV1::CancelOperationRequest::Representation
772
+ command.request_object = cancel_operation_request_object
773
+ command.response_representation = Google::Apis::GameservicesV1::Empty::Representation
774
+ command.response_class = Google::Apis::GameservicesV1::Empty
775
+ command.params['name'] = name unless name.nil?
776
+ command.query['fields'] = fields unless fields.nil?
777
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
778
+ execute_or_queue_command(command, &block)
779
+ end
780
+
781
+ # Deletes a long-running operation. This method indicates that the client is no
782
+ # longer interested in the operation result. It does not cancel the operation.
783
+ # If the server doesn't support this method, it returns `google.rpc.Code.
784
+ # UNIMPLEMENTED`.
785
+ # @param [String] name
786
+ # The name of the operation resource to be deleted.
787
+ # @param [String] fields
788
+ # Selector specifying which fields to include in a partial response.
789
+ # @param [String] quota_user
790
+ # Available to use for quota purposes for server-side applications. Can be any
791
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
792
+ # @param [Google::Apis::RequestOptions] options
793
+ # Request-specific options
794
+ #
795
+ # @yield [result, err] Result & error if block supplied
796
+ # @yieldparam result [Google::Apis::GameservicesV1::Empty] parsed result object
797
+ # @yieldparam err [StandardError] error object if request failed
798
+ #
799
+ # @return [Google::Apis::GameservicesV1::Empty]
800
+ #
801
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
802
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
803
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
804
+ def delete_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
805
+ command = make_simple_command(:delete, 'v1/{+name}', options)
806
+ command.response_representation = Google::Apis::GameservicesV1::Empty::Representation
807
+ command.response_class = Google::Apis::GameservicesV1::Empty
808
+ command.params['name'] = name unless name.nil?
809
+ command.query['fields'] = fields unless fields.nil?
810
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
811
+ execute_or_queue_command(command, &block)
812
+ end
813
+
814
+ # Gets the latest state of a long-running operation. Clients can use this method
815
+ # to poll the operation result at intervals as recommended by the API service.
816
+ # @param [String] name
817
+ # The name of the operation resource.
818
+ # @param [String] fields
819
+ # Selector specifying which fields to include in a partial response.
820
+ # @param [String] quota_user
821
+ # Available to use for quota purposes for server-side applications. Can be any
822
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
823
+ # @param [Google::Apis::RequestOptions] options
824
+ # Request-specific options
825
+ #
826
+ # @yield [result, err] Result & error if block supplied
827
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
828
+ # @yieldparam err [StandardError] error object if request failed
829
+ #
830
+ # @return [Google::Apis::GameservicesV1::Operation]
831
+ #
832
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
833
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
834
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
835
+ def get_project_location_operation(name, fields: nil, quota_user: nil, options: nil, &block)
836
+ command = make_simple_command(:get, 'v1/{+name}', options)
837
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
838
+ command.response_class = Google::Apis::GameservicesV1::Operation
839
+ command.params['name'] = name unless name.nil?
840
+ command.query['fields'] = fields unless fields.nil?
841
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
842
+ execute_or_queue_command(command, &block)
843
+ end
844
+
845
+ # Lists operations that match the specified filter in the request. If the server
846
+ # doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name`
847
+ # binding allows API services to override the binding to use different resource
848
+ # name schemes, such as `users/*/operations`. To override the binding, API
849
+ # services can add a binding such as `"/v1/`name=users/*`/operations"` to their
850
+ # service configuration. For backwards compatibility, the default name includes
851
+ # the operations collection id, however overriding users must ensure the name
852
+ # binding is the parent resource, without the operations collection id.
853
+ # @param [String] name
854
+ # The name of the operation's parent resource.
855
+ # @param [String] filter
856
+ # The standard list filter.
857
+ # @param [Fixnum] page_size
858
+ # The standard list page size.
859
+ # @param [String] page_token
860
+ # The standard list page token.
861
+ # @param [String] fields
862
+ # Selector specifying which fields to include in a partial response.
863
+ # @param [String] quota_user
864
+ # Available to use for quota purposes for server-side applications. Can be any
865
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
866
+ # @param [Google::Apis::RequestOptions] options
867
+ # Request-specific options
868
+ #
869
+ # @yield [result, err] Result & error if block supplied
870
+ # @yieldparam result [Google::Apis::GameservicesV1::ListOperationsResponse] parsed result object
871
+ # @yieldparam err [StandardError] error object if request failed
872
+ #
873
+ # @return [Google::Apis::GameservicesV1::ListOperationsResponse]
874
+ #
875
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
876
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
877
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
878
+ def list_project_location_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
879
+ command = make_simple_command(:get, 'v1/{+name}/operations', options)
880
+ command.response_representation = Google::Apis::GameservicesV1::ListOperationsResponse::Representation
881
+ command.response_class = Google::Apis::GameservicesV1::ListOperationsResponse
882
+ command.params['name'] = name unless name.nil?
883
+ command.query['filter'] = filter unless filter.nil?
884
+ command.query['pageSize'] = page_size unless page_size.nil?
885
+ command.query['pageToken'] = page_token unless page_token.nil?
886
+ command.query['fields'] = fields unless fields.nil?
887
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
888
+ execute_or_queue_command(command, &block)
889
+ end
890
+
891
+ # Creates a new realm in a given project and location.
892
+ # @param [String] parent
893
+ # Required. The parent resource name, in the following form: `projects/`project`/
894
+ # locations/`location``.
895
+ # @param [Google::Apis::GameservicesV1::Realm] realm_object
896
+ # @param [String] realm_id
897
+ # Required. The ID of the realm resource to be created.
898
+ # @param [String] fields
899
+ # Selector specifying which fields to include in a partial response.
900
+ # @param [String] quota_user
901
+ # Available to use for quota purposes for server-side applications. Can be any
902
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
903
+ # @param [Google::Apis::RequestOptions] options
904
+ # Request-specific options
905
+ #
906
+ # @yield [result, err] Result & error if block supplied
907
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
908
+ # @yieldparam err [StandardError] error object if request failed
909
+ #
910
+ # @return [Google::Apis::GameservicesV1::Operation]
911
+ #
912
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
913
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
914
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
915
+ def create_project_location_realm(parent, realm_object = nil, realm_id: nil, fields: nil, quota_user: nil, options: nil, &block)
916
+ command = make_simple_command(:post, 'v1/{+parent}/realms', options)
917
+ command.request_representation = Google::Apis::GameservicesV1::Realm::Representation
918
+ command.request_object = realm_object
919
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
920
+ command.response_class = Google::Apis::GameservicesV1::Operation
921
+ command.params['parent'] = parent unless parent.nil?
922
+ command.query['realmId'] = realm_id unless realm_id.nil?
923
+ command.query['fields'] = fields unless fields.nil?
924
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
925
+ execute_or_queue_command(command, &block)
926
+ end
927
+
928
+ # Deletes a single realm.
929
+ # @param [String] name
930
+ # Required. The name of the realm to delete, in the following form: `projects/`
931
+ # project`/locations/`location`/realms/`realm``.
932
+ # @param [String] fields
933
+ # Selector specifying which fields to include in a partial response.
934
+ # @param [String] quota_user
935
+ # Available to use for quota purposes for server-side applications. Can be any
936
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
937
+ # @param [Google::Apis::RequestOptions] options
938
+ # Request-specific options
939
+ #
940
+ # @yield [result, err] Result & error if block supplied
941
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
942
+ # @yieldparam err [StandardError] error object if request failed
943
+ #
944
+ # @return [Google::Apis::GameservicesV1::Operation]
945
+ #
946
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
947
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
948
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
949
+ def delete_project_location_realm(name, fields: nil, quota_user: nil, options: nil, &block)
950
+ command = make_simple_command(:delete, 'v1/{+name}', options)
951
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
952
+ command.response_class = Google::Apis::GameservicesV1::Operation
953
+ command.params['name'] = name unless name.nil?
954
+ command.query['fields'] = fields unless fields.nil?
955
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
956
+ execute_or_queue_command(command, &block)
957
+ end
958
+
959
+ # Gets details of a single realm.
960
+ # @param [String] name
961
+ # Required. The name of the realm to retrieve, in the following form: `projects/`
962
+ # project`/locations/`location`/realms/`realm``.
963
+ # @param [String] fields
964
+ # Selector specifying which fields to include in a partial response.
965
+ # @param [String] quota_user
966
+ # Available to use for quota purposes for server-side applications. Can be any
967
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
968
+ # @param [Google::Apis::RequestOptions] options
969
+ # Request-specific options
970
+ #
971
+ # @yield [result, err] Result & error if block supplied
972
+ # @yieldparam result [Google::Apis::GameservicesV1::Realm] parsed result object
973
+ # @yieldparam err [StandardError] error object if request failed
974
+ #
975
+ # @return [Google::Apis::GameservicesV1::Realm]
976
+ #
977
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
978
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
979
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
980
+ def get_project_location_realm(name, fields: nil, quota_user: nil, options: nil, &block)
981
+ command = make_simple_command(:get, 'v1/{+name}', options)
982
+ command.response_representation = Google::Apis::GameservicesV1::Realm::Representation
983
+ command.response_class = Google::Apis::GameservicesV1::Realm
984
+ command.params['name'] = name unless name.nil?
985
+ command.query['fields'] = fields unless fields.nil?
986
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
987
+ execute_or_queue_command(command, &block)
988
+ end
989
+
990
+ # Lists realms in a given project and location.
991
+ # @param [String] parent
992
+ # Required. The parent resource name, in the following form: `projects/`project`/
993
+ # locations/`location``.
994
+ # @param [String] filter
995
+ # Optional. The filter to apply to list results.
996
+ # @param [String] order_by
997
+ # Optional. Specifies the ordering of results following syntax at https://cloud.
998
+ # google.com/apis/design/design_patterns#sorting_order.
999
+ # @param [Fixnum] page_size
1000
+ # Optional. The maximum number of items to return. If unspecified, server will
1001
+ # pick an appropriate default. Server may return fewer items than requested. A
1002
+ # caller should only rely on response's next_page_token to determine if there
1003
+ # are more realms left to be queried.
1004
+ # @param [String] page_token
1005
+ # Optional. The next_page_token value returned from a previous List request, if
1006
+ # any.
1007
+ # @param [String] fields
1008
+ # Selector specifying which fields to include in a partial response.
1009
+ # @param [String] quota_user
1010
+ # Available to use for quota purposes for server-side applications. Can be any
1011
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1012
+ # @param [Google::Apis::RequestOptions] options
1013
+ # Request-specific options
1014
+ #
1015
+ # @yield [result, err] Result & error if block supplied
1016
+ # @yieldparam result [Google::Apis::GameservicesV1::ListRealmsResponse] parsed result object
1017
+ # @yieldparam err [StandardError] error object if request failed
1018
+ #
1019
+ # @return [Google::Apis::GameservicesV1::ListRealmsResponse]
1020
+ #
1021
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1022
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1023
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1024
+ def list_project_location_realms(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
1025
+ command = make_simple_command(:get, 'v1/{+parent}/realms', options)
1026
+ command.response_representation = Google::Apis::GameservicesV1::ListRealmsResponse::Representation
1027
+ command.response_class = Google::Apis::GameservicesV1::ListRealmsResponse
1028
+ command.params['parent'] = parent unless parent.nil?
1029
+ command.query['filter'] = filter unless filter.nil?
1030
+ command.query['orderBy'] = order_by unless order_by.nil?
1031
+ command.query['pageSize'] = page_size unless page_size.nil?
1032
+ command.query['pageToken'] = page_token unless page_token.nil?
1033
+ command.query['fields'] = fields unless fields.nil?
1034
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1035
+ execute_or_queue_command(command, &block)
1036
+ end
1037
+
1038
+ # Patches a single realm.
1039
+ # @param [String] name
1040
+ # The resource name of the realm, in the following form: `projects/`project`/
1041
+ # locations/`location`/realms/`realm``. For example, `projects/my-project/
1042
+ # locations/`location`/realms/my-realm`.
1043
+ # @param [Google::Apis::GameservicesV1::Realm] realm_object
1044
+ # @param [String] update_mask
1045
+ # Required. The update mask applies to the resource. For the `FieldMask`
1046
+ # definition, see https://developers.google.com/protocol-buffers/docs/reference/
1047
+ # google.protobuf#fieldmask
1048
+ # @param [String] fields
1049
+ # Selector specifying which fields to include in a partial response.
1050
+ # @param [String] quota_user
1051
+ # Available to use for quota purposes for server-side applications. Can be any
1052
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1053
+ # @param [Google::Apis::RequestOptions] options
1054
+ # Request-specific options
1055
+ #
1056
+ # @yield [result, err] Result & error if block supplied
1057
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
1058
+ # @yieldparam err [StandardError] error object if request failed
1059
+ #
1060
+ # @return [Google::Apis::GameservicesV1::Operation]
1061
+ #
1062
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1063
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1064
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1065
+ def patch_project_location_realm(name, realm_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
1066
+ command = make_simple_command(:patch, 'v1/{+name}', options)
1067
+ command.request_representation = Google::Apis::GameservicesV1::Realm::Representation
1068
+ command.request_object = realm_object
1069
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
1070
+ command.response_class = Google::Apis::GameservicesV1::Operation
1071
+ command.params['name'] = name unless name.nil?
1072
+ command.query['updateMask'] = update_mask unless update_mask.nil?
1073
+ command.query['fields'] = fields unless fields.nil?
1074
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1075
+ execute_or_queue_command(command, &block)
1076
+ end
1077
+
1078
+ # Previews patches to a single realm.
1079
+ # @param [String] name
1080
+ # The resource name of the realm, in the following form: `projects/`project`/
1081
+ # locations/`location`/realms/`realm``. For example, `projects/my-project/
1082
+ # locations/`location`/realms/my-realm`.
1083
+ # @param [Google::Apis::GameservicesV1::Realm] realm_object
1084
+ # @param [String] preview_time
1085
+ # Optional. The target timestamp to compute the preview.
1086
+ # @param [String] update_mask
1087
+ # Required. The update mask applies to the resource. For the `FieldMask`
1088
+ # definition, see https://developers.google.com/protocol-buffers/docs/reference/
1089
+ # google.protobuf#fieldmask
1090
+ # @param [String] fields
1091
+ # Selector specifying which fields to include in a partial response.
1092
+ # @param [String] quota_user
1093
+ # Available to use for quota purposes for server-side applications. Can be any
1094
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1095
+ # @param [Google::Apis::RequestOptions] options
1096
+ # Request-specific options
1097
+ #
1098
+ # @yield [result, err] Result & error if block supplied
1099
+ # @yieldparam result [Google::Apis::GameservicesV1::PreviewRealmUpdateResponse] parsed result object
1100
+ # @yieldparam err [StandardError] error object if request failed
1101
+ #
1102
+ # @return [Google::Apis::GameservicesV1::PreviewRealmUpdateResponse]
1103
+ #
1104
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1105
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1106
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1107
+ def preview_project_location_realm_update(name, realm_object = nil, preview_time: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
1108
+ command = make_simple_command(:patch, 'v1/{+name}:previewUpdate', options)
1109
+ command.request_representation = Google::Apis::GameservicesV1::Realm::Representation
1110
+ command.request_object = realm_object
1111
+ command.response_representation = Google::Apis::GameservicesV1::PreviewRealmUpdateResponse::Representation
1112
+ command.response_class = Google::Apis::GameservicesV1::PreviewRealmUpdateResponse
1113
+ command.params['name'] = name unless name.nil?
1114
+ command.query['previewTime'] = preview_time unless preview_time.nil?
1115
+ command.query['updateMask'] = update_mask unless update_mask.nil?
1116
+ command.query['fields'] = fields unless fields.nil?
1117
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1118
+ execute_or_queue_command(command, &block)
1119
+ end
1120
+
1121
+ # Creates a new game server cluster in a given project and location.
1122
+ # @param [String] parent
1123
+ # Required. The parent resource name, in the following form: `projects/`project`/
1124
+ # locations/`location`/realms/`realm-id``.
1125
+ # @param [Google::Apis::GameservicesV1::GameServerCluster] game_server_cluster_object
1126
+ # @param [String] game_server_cluster_id
1127
+ # Required. The ID of the game server cluster resource to be created.
1128
+ # @param [String] fields
1129
+ # Selector specifying which fields to include in a partial response.
1130
+ # @param [String] quota_user
1131
+ # Available to use for quota purposes for server-side applications. Can be any
1132
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1133
+ # @param [Google::Apis::RequestOptions] options
1134
+ # Request-specific options
1135
+ #
1136
+ # @yield [result, err] Result & error if block supplied
1137
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
1138
+ # @yieldparam err [StandardError] error object if request failed
1139
+ #
1140
+ # @return [Google::Apis::GameservicesV1::Operation]
1141
+ #
1142
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1143
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1144
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1145
+ def create_project_location_realm_game_server_cluster(parent, game_server_cluster_object = nil, game_server_cluster_id: nil, fields: nil, quota_user: nil, options: nil, &block)
1146
+ command = make_simple_command(:post, 'v1/{+parent}/gameServerClusters', options)
1147
+ command.request_representation = Google::Apis::GameservicesV1::GameServerCluster::Representation
1148
+ command.request_object = game_server_cluster_object
1149
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
1150
+ command.response_class = Google::Apis::GameservicesV1::Operation
1151
+ command.params['parent'] = parent unless parent.nil?
1152
+ command.query['gameServerClusterId'] = game_server_cluster_id unless game_server_cluster_id.nil?
1153
+ command.query['fields'] = fields unless fields.nil?
1154
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1155
+ execute_or_queue_command(command, &block)
1156
+ end
1157
+
1158
+ # Deletes a single game server cluster.
1159
+ # @param [String] name
1160
+ # Required. The name of the game server cluster to delete, in the following form:
1161
+ # `projects/`project`/locations/`location`/gameServerClusters/`cluster``.
1162
+ # @param [String] fields
1163
+ # Selector specifying which fields to include in a partial response.
1164
+ # @param [String] quota_user
1165
+ # Available to use for quota purposes for server-side applications. Can be any
1166
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1167
+ # @param [Google::Apis::RequestOptions] options
1168
+ # Request-specific options
1169
+ #
1170
+ # @yield [result, err] Result & error if block supplied
1171
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
1172
+ # @yieldparam err [StandardError] error object if request failed
1173
+ #
1174
+ # @return [Google::Apis::GameservicesV1::Operation]
1175
+ #
1176
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1177
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1178
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1179
+ def delete_project_location_realm_game_server_cluster(name, fields: nil, quota_user: nil, options: nil, &block)
1180
+ command = make_simple_command(:delete, 'v1/{+name}', options)
1181
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
1182
+ command.response_class = Google::Apis::GameservicesV1::Operation
1183
+ command.params['name'] = name unless name.nil?
1184
+ command.query['fields'] = fields unless fields.nil?
1185
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1186
+ execute_or_queue_command(command, &block)
1187
+ end
1188
+
1189
+ # Gets details of a single game server cluster.
1190
+ # @param [String] name
1191
+ # Required. The name of the game server cluster to retrieve, in the following
1192
+ # form: `projects/`project`/locations/`location`/realms/`realm-id`/
1193
+ # gameServerClusters/`cluster``.
1194
+ # @param [String] fields
1195
+ # Selector specifying which fields to include in a partial response.
1196
+ # @param [String] quota_user
1197
+ # Available to use for quota purposes for server-side applications. Can be any
1198
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1199
+ # @param [Google::Apis::RequestOptions] options
1200
+ # Request-specific options
1201
+ #
1202
+ # @yield [result, err] Result & error if block supplied
1203
+ # @yieldparam result [Google::Apis::GameservicesV1::GameServerCluster] parsed result object
1204
+ # @yieldparam err [StandardError] error object if request failed
1205
+ #
1206
+ # @return [Google::Apis::GameservicesV1::GameServerCluster]
1207
+ #
1208
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1209
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1210
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1211
+ def get_project_location_realm_game_server_cluster(name, fields: nil, quota_user: nil, options: nil, &block)
1212
+ command = make_simple_command(:get, 'v1/{+name}', options)
1213
+ command.response_representation = Google::Apis::GameservicesV1::GameServerCluster::Representation
1214
+ command.response_class = Google::Apis::GameservicesV1::GameServerCluster
1215
+ command.params['name'] = name unless name.nil?
1216
+ command.query['fields'] = fields unless fields.nil?
1217
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1218
+ execute_or_queue_command(command, &block)
1219
+ end
1220
+
1221
+ # Lists game server clusters in a given project and location.
1222
+ # @param [String] parent
1223
+ # Required. The parent resource name, in the following form: "projects/`project`/
1224
+ # locations/`location`/realms/`realm`".
1225
+ # @param [String] filter
1226
+ # Optional. The filter to apply to list results.
1227
+ # @param [String] order_by
1228
+ # Optional. Specifies the ordering of results following syntax at https://cloud.
1229
+ # google.com/apis/design/design_patterns#sorting_order.
1230
+ # @param [Fixnum] page_size
1231
+ # Optional. The maximum number of items to return. If unspecified, the server
1232
+ # will pick an appropriate default. The server may return fewer items than
1233
+ # requested. A caller should only rely on response's next_page_token to
1234
+ # determine if there are more GameServerClusters left to be queried.
1235
+ # @param [String] page_token
1236
+ # Optional. The next_page_token value returned from a previous List request, if
1237
+ # any.
1238
+ # @param [String] fields
1239
+ # Selector specifying which fields to include in a partial response.
1240
+ # @param [String] quota_user
1241
+ # Available to use for quota purposes for server-side applications. Can be any
1242
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1243
+ # @param [Google::Apis::RequestOptions] options
1244
+ # Request-specific options
1245
+ #
1246
+ # @yield [result, err] Result & error if block supplied
1247
+ # @yieldparam result [Google::Apis::GameservicesV1::ListGameServerClustersResponse] parsed result object
1248
+ # @yieldparam err [StandardError] error object if request failed
1249
+ #
1250
+ # @return [Google::Apis::GameservicesV1::ListGameServerClustersResponse]
1251
+ #
1252
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1253
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1254
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1255
+ def list_project_location_realm_game_server_clusters(parent, filter: nil, order_by: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
1256
+ command = make_simple_command(:get, 'v1/{+parent}/gameServerClusters', options)
1257
+ command.response_representation = Google::Apis::GameservicesV1::ListGameServerClustersResponse::Representation
1258
+ command.response_class = Google::Apis::GameservicesV1::ListGameServerClustersResponse
1259
+ command.params['parent'] = parent unless parent.nil?
1260
+ command.query['filter'] = filter unless filter.nil?
1261
+ command.query['orderBy'] = order_by unless order_by.nil?
1262
+ command.query['pageSize'] = page_size unless page_size.nil?
1263
+ command.query['pageToken'] = page_token unless page_token.nil?
1264
+ command.query['fields'] = fields unless fields.nil?
1265
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1266
+ execute_or_queue_command(command, &block)
1267
+ end
1268
+
1269
+ # Patches a single game server cluster.
1270
+ # @param [String] name
1271
+ # Required. The resource name of the game server cluster, in the following form:
1272
+ # `projects/`project`/locations/`location`/realms/`realm`/gameServerClusters/`
1273
+ # cluster``. For example, `projects/my-project/locations/`location`/realms/
1274
+ # zanzibar/gameServerClusters/my-onprem-cluster`.
1275
+ # @param [Google::Apis::GameservicesV1::GameServerCluster] game_server_cluster_object
1276
+ # @param [String] update_mask
1277
+ # Required. Mask of fields to update. At least one path must be supplied in this
1278
+ # field. For the `FieldMask` definition, see https://developers.google.com/
1279
+ # protocol-buffers/docs/reference/google.protobuf#fieldmask
1280
+ # @param [String] fields
1281
+ # Selector specifying which fields to include in a partial response.
1282
+ # @param [String] quota_user
1283
+ # Available to use for quota purposes for server-side applications. Can be any
1284
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1285
+ # @param [Google::Apis::RequestOptions] options
1286
+ # Request-specific options
1287
+ #
1288
+ # @yield [result, err] Result & error if block supplied
1289
+ # @yieldparam result [Google::Apis::GameservicesV1::Operation] parsed result object
1290
+ # @yieldparam err [StandardError] error object if request failed
1291
+ #
1292
+ # @return [Google::Apis::GameservicesV1::Operation]
1293
+ #
1294
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1295
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1296
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1297
+ def patch_project_location_realm_game_server_cluster(name, game_server_cluster_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
1298
+ command = make_simple_command(:patch, 'v1/{+name}', options)
1299
+ command.request_representation = Google::Apis::GameservicesV1::GameServerCluster::Representation
1300
+ command.request_object = game_server_cluster_object
1301
+ command.response_representation = Google::Apis::GameservicesV1::Operation::Representation
1302
+ command.response_class = Google::Apis::GameservicesV1::Operation
1303
+ command.params['name'] = name unless name.nil?
1304
+ command.query['updateMask'] = update_mask unless update_mask.nil?
1305
+ command.query['fields'] = fields unless fields.nil?
1306
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1307
+ execute_or_queue_command(command, &block)
1308
+ end
1309
+
1310
+ # Previews creation of a new game server cluster in a given project and location.
1311
+ # @param [String] parent
1312
+ # Required. The parent resource name, in the following form: `projects/`project`/
1313
+ # locations/`location`/realms/`realm``.
1314
+ # @param [Google::Apis::GameservicesV1::GameServerCluster] game_server_cluster_object
1315
+ # @param [String] game_server_cluster_id
1316
+ # Required. The ID of the game server cluster resource to be created.
1317
+ # @param [String] preview_time
1318
+ # Optional. The target timestamp to compute the preview.
1319
+ # @param [String] fields
1320
+ # Selector specifying which fields to include in a partial response.
1321
+ # @param [String] quota_user
1322
+ # Available to use for quota purposes for server-side applications. Can be any
1323
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1324
+ # @param [Google::Apis::RequestOptions] options
1325
+ # Request-specific options
1326
+ #
1327
+ # @yield [result, err] Result & error if block supplied
1328
+ # @yieldparam result [Google::Apis::GameservicesV1::PreviewCreateGameServerClusterResponse] parsed result object
1329
+ # @yieldparam err [StandardError] error object if request failed
1330
+ #
1331
+ # @return [Google::Apis::GameservicesV1::PreviewCreateGameServerClusterResponse]
1332
+ #
1333
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1334
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1335
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1336
+ def preview_project_location_realm_game_server_cluster_create(parent, game_server_cluster_object = nil, game_server_cluster_id: nil, preview_time: nil, fields: nil, quota_user: nil, options: nil, &block)
1337
+ command = make_simple_command(:post, 'v1/{+parent}/gameServerClusters:previewCreate', options)
1338
+ command.request_representation = Google::Apis::GameservicesV1::GameServerCluster::Representation
1339
+ command.request_object = game_server_cluster_object
1340
+ command.response_representation = Google::Apis::GameservicesV1::PreviewCreateGameServerClusterResponse::Representation
1341
+ command.response_class = Google::Apis::GameservicesV1::PreviewCreateGameServerClusterResponse
1342
+ command.params['parent'] = parent unless parent.nil?
1343
+ command.query['gameServerClusterId'] = game_server_cluster_id unless game_server_cluster_id.nil?
1344
+ command.query['previewTime'] = preview_time unless preview_time.nil?
1345
+ command.query['fields'] = fields unless fields.nil?
1346
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1347
+ execute_or_queue_command(command, &block)
1348
+ end
1349
+
1350
+ # Previews deletion of a single game server cluster.
1351
+ # @param [String] name
1352
+ # Required. The name of the game server cluster to delete, in the following form:
1353
+ # `projects/`project`/locations/`location`/gameServerClusters/`cluster``.
1354
+ # @param [String] preview_time
1355
+ # Optional. The target timestamp to compute the preview.
1356
+ # @param [String] fields
1357
+ # Selector specifying which fields to include in a partial response.
1358
+ # @param [String] quota_user
1359
+ # Available to use for quota purposes for server-side applications. Can be any
1360
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1361
+ # @param [Google::Apis::RequestOptions] options
1362
+ # Request-specific options
1363
+ #
1364
+ # @yield [result, err] Result & error if block supplied
1365
+ # @yieldparam result [Google::Apis::GameservicesV1::PreviewDeleteGameServerClusterResponse] parsed result object
1366
+ # @yieldparam err [StandardError] error object if request failed
1367
+ #
1368
+ # @return [Google::Apis::GameservicesV1::PreviewDeleteGameServerClusterResponse]
1369
+ #
1370
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1371
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1372
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1373
+ def preview_project_location_realm_game_server_cluster_delete(name, preview_time: nil, fields: nil, quota_user: nil, options: nil, &block)
1374
+ command = make_simple_command(:delete, 'v1/{+name}:previewDelete', options)
1375
+ command.response_representation = Google::Apis::GameservicesV1::PreviewDeleteGameServerClusterResponse::Representation
1376
+ command.response_class = Google::Apis::GameservicesV1::PreviewDeleteGameServerClusterResponse
1377
+ command.params['name'] = name unless name.nil?
1378
+ command.query['previewTime'] = preview_time unless preview_time.nil?
1379
+ command.query['fields'] = fields unless fields.nil?
1380
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1381
+ execute_or_queue_command(command, &block)
1382
+ end
1383
+
1384
+ # Previews updating a GameServerCluster.
1385
+ # @param [String] name
1386
+ # Required. The resource name of the game server cluster, in the following form:
1387
+ # `projects/`project`/locations/`location`/realms/`realm`/gameServerClusters/`
1388
+ # cluster``. For example, `projects/my-project/locations/`location`/realms/
1389
+ # zanzibar/gameServerClusters/my-onprem-cluster`.
1390
+ # @param [Google::Apis::GameservicesV1::GameServerCluster] game_server_cluster_object
1391
+ # @param [String] preview_time
1392
+ # Optional. The target timestamp to compute the preview.
1393
+ # @param [String] update_mask
1394
+ # Required. Mask of fields to update. At least one path must be supplied in this
1395
+ # field. For the `FieldMask` definition, see https://developers.google.com/
1396
+ # protocol-buffers/docs/reference/google.protobuf#fieldmask
1397
+ # @param [String] fields
1398
+ # Selector specifying which fields to include in a partial response.
1399
+ # @param [String] quota_user
1400
+ # Available to use for quota purposes for server-side applications. Can be any
1401
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
1402
+ # @param [Google::Apis::RequestOptions] options
1403
+ # Request-specific options
1404
+ #
1405
+ # @yield [result, err] Result & error if block supplied
1406
+ # @yieldparam result [Google::Apis::GameservicesV1::PreviewUpdateGameServerClusterResponse] parsed result object
1407
+ # @yieldparam err [StandardError] error object if request failed
1408
+ #
1409
+ # @return [Google::Apis::GameservicesV1::PreviewUpdateGameServerClusterResponse]
1410
+ #
1411
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
1412
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
1413
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
1414
+ def preview_project_location_realm_game_server_cluster_update(name, game_server_cluster_object = nil, preview_time: nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
1415
+ command = make_simple_command(:patch, 'v1/{+name}:previewUpdate', options)
1416
+ command.request_representation = Google::Apis::GameservicesV1::GameServerCluster::Representation
1417
+ command.request_object = game_server_cluster_object
1418
+ command.response_representation = Google::Apis::GameservicesV1::PreviewUpdateGameServerClusterResponse::Representation
1419
+ command.response_class = Google::Apis::GameservicesV1::PreviewUpdateGameServerClusterResponse
1420
+ command.params['name'] = name unless name.nil?
1421
+ command.query['previewTime'] = preview_time unless preview_time.nil?
1422
+ command.query['updateMask'] = update_mask unless update_mask.nil?
1423
+ command.query['fields'] = fields unless fields.nil?
1424
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1425
+ execute_or_queue_command(command, &block)
1426
+ end
1427
+
1428
+ protected
1429
+
1430
+ def apply_command_defaults(command)
1431
+ command.query['key'] = key unless key.nil?
1432
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
1433
+ end
1434
+ end
1435
+ end
1436
+ end
1437
+ end