google-cloud-location 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 80ff0f7afa33afd6d9aefe7354c7b3082bfb31b7708b7abf71c7bec365fb32e7
4
- data.tar.gz: 4446f93bac9875365809819e28f5f6c53d1f4c8ed9a36c9da9ff63307e2a1154
3
+ metadata.gz: 4903c33a548e29d203cfffe807a228465c25d9ff3df3dafc89cd45af67bb8b89
4
+ data.tar.gz: 8071ea712f8ed7a258aac2bfc05572c07881412ad9b5daed433aa90de9cca135
5
5
  SHA512:
6
- metadata.gz: 2b6d0dda7a395b6bc165434b0d94111462cbf906d092f14fa75f265b678a551f00fc848a944ddb143631d5261b50e29aa9e838a46993f3072438ca9cf9f1b70f
7
- data.tar.gz: c68c0cb024dd14629ef3d579dd33327fa0c49b90f1b40311d7e5e79c2a2c1ec282b595c84dd5bbe0e3b922d5b5ee50f16c639d96a50335fec62894ee58c9befc
6
+ metadata.gz: c181888fcd1294e04d1582b69d806ef3f04d43739e7e4e05626c785c68ef52189c87cea81fbf718700caca49add67685b12348f4ec144b1d2ecf4325be9161b0
7
+ data.tar.gz: aa02637d9aa6602334e41edcf7e6063c8a6535b3546aff7b91bb42addd6295c03edd490fecdfa7490db20b0dffb6fc8e9b64023f044d361e6e45adfb0aa9aeb0
@@ -178,6 +178,27 @@ module Google
178
178
  #
179
179
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
180
180
  #
181
+ # @example Basic example
182
+ # require "google/cloud/location"
183
+ #
184
+ # # Create a client object. The client can be reused for multiple calls.
185
+ # client = Google::Cloud::Location::Locations::Client.new
186
+ #
187
+ # # Create a request. To set request fields, pass in keyword arguments.
188
+ # request = Google::Cloud::Location::ListLocationsRequest.new
189
+ #
190
+ # # Call the list_locations method.
191
+ # result = client.list_locations request
192
+ #
193
+ # # The returned object is of type Gapic::PagedEnumerable. You can
194
+ # # iterate over all elements by calling #each, and the enumerable
195
+ # # will lazily make API calls to fetch subsequent pages. Other
196
+ # # methods are also available for managing paging directly.
197
+ # result.each do |response|
198
+ # # Each element is of type ::Google::Cloud::Location::Location.
199
+ # p response
200
+ # end
201
+ #
181
202
  def list_locations request, options = nil
182
203
  raise ::ArgumentError, "request must be provided" if request.nil?
183
204
 
@@ -195,9 +216,11 @@ module Google
195
216
  gapic_version: ::Google::Cloud::Location::VERSION
196
217
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
197
218
 
198
- header_params = {
199
- "name" => request.name
200
- }
219
+ header_params = {}
220
+ if request.name
221
+ header_params["name"] = request.name
222
+ end
223
+
201
224
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
202
225
  metadata[:"x-goog-request-params"] ||= request_params_header
203
226
 
@@ -247,6 +270,21 @@ module Google
247
270
  #
248
271
  # @raise [::Google::Cloud::Error] if the RPC is aborted.
249
272
  #
273
+ # @example Basic example
274
+ # require "google/cloud/location"
275
+ #
276
+ # # Create a client object. The client can be reused for multiple calls.
277
+ # client = Google::Cloud::Location::Locations::Client.new
278
+ #
279
+ # # Create a request. To set request fields, pass in keyword arguments.
280
+ # request = Google::Cloud::Location::GetLocationRequest.new
281
+ #
282
+ # # Call the get_location method.
283
+ # result = client.get_location request
284
+ #
285
+ # # The returned object is of type Google::Cloud::Location::Location.
286
+ # p result
287
+ #
250
288
  def get_location request, options = nil
251
289
  raise ::ArgumentError, "request must be provided" if request.nil?
252
290
 
@@ -264,9 +302,11 @@ module Google
264
302
  gapic_version: ::Google::Cloud::Location::VERSION
265
303
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
266
304
 
267
- header_params = {
268
- "name" => request.name
269
- }
305
+ header_params = {}
306
+ if request.name
307
+ header_params["name"] = request.name
308
+ end
309
+
270
310
  request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
271
311
  metadata[:"x-goog-request-params"] ||= request_params_header
272
312
 
@@ -20,7 +20,7 @@
20
20
  module Google
21
21
  module Cloud
22
22
  module Location
23
- VERSION = "0.1.0"
23
+ VERSION = "0.1.1"
24
24
  end
25
25
  end
26
26
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-location
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-10-18 00:00:00.000000000 Z
11
+ date: 2021-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common