google-maps-fleet_engine-v1 0.1.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1a438a388aa6bf7588a8bd2206feffb5f94e3947f5fe9635cf470415c78e4c6d
4
- data.tar.gz: bd9e1e572eb126e39bae8f35e1756c8fe583baf9d4ca8d18820f70a4438f2695
3
+ metadata.gz: c56b193986a6691e334dfc5b2110ed3a56f6c28765254fa34238118022aef9e8
4
+ data.tar.gz: 5b17387e879aee8f18116e96a17928136fe2a48ac5d8275445ca00be81afe8e5
5
5
  SHA512:
6
- metadata.gz: 923b2b9b357a52517b3ec3afb34befe2de7057191ea99036567d01badb13389d583831ed36e1eae695665c94a3225c6d04360945284d3c44c452db92bfcdc5a1
7
- data.tar.gz: b449537a94a179961ee6bca947dcc20e8890fb7b514aceea718c793f4285720038398fe6172b730c0d4ece1f633df45e77f8b8e93799b81f0a2f2f106f7720a6
6
+ metadata.gz: 0b7e0ab862ec9bc1ea14b3a9ea0b403744bde1780baf67dbe7a013ef9c67696d92f72a43d809b0cce4996a47154b5c31b112c134f09e95985076c9ab077b7474
7
+ data.tar.gz: 3b621a805c81e2933a702141405f5beb7ad34ab2fb1c87ab9653f3fa688108948ced694b36d87896e7a891f904664588cbcb3233934ed15598f540aed3725113
@@ -30,6 +30,9 @@ module Google
30
30
  # Trip management service.
31
31
  #
32
32
  class Client
33
+ # @private
34
+ API_VERSION = ""
35
+
33
36
  # @private
34
37
  DEFAULT_ENDPOINT_TEMPLATE = "fleetengine.$UNIVERSE_DOMAIN$"
35
38
 
@@ -286,10 +289,11 @@ module Google
286
289
  # Customize the options with defaults
287
290
  metadata = @config.rpcs.create_trip.metadata.to_h
288
291
 
289
- # Set x-goog-api-client and x-goog-user-project headers
292
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
290
293
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
291
294
  lib_name: @config.lib_name, lib_version: @config.lib_version,
292
295
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
296
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
293
297
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
294
298
 
295
299
  header_params = {}
@@ -407,10 +411,11 @@ module Google
407
411
  # Customize the options with defaults
408
412
  metadata = @config.rpcs.get_trip.metadata.to_h
409
413
 
410
- # Set x-goog-api-client and x-goog-user-project headers
414
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
411
415
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
412
416
  lib_name: @config.lib_name, lib_version: @config.lib_version,
413
417
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
418
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
414
419
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
415
420
 
416
421
  header_params = {}
@@ -510,10 +515,11 @@ module Google
510
515
  # Customize the options with defaults
511
516
  metadata = @config.rpcs.report_billable_trip.metadata.to_h
512
517
 
513
- # Set x-goog-api-client and x-goog-user-project headers
518
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
514
519
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
515
520
  lib_name: @config.lib_name, lib_version: @config.lib_version,
516
521
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
522
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
517
523
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
518
524
 
519
525
  header_params = {}
@@ -624,10 +630,11 @@ module Google
624
630
  # Customize the options with defaults
625
631
  metadata = @config.rpcs.search_trips.metadata.to_h
626
632
 
627
- # Set x-goog-api-client and x-goog-user-project headers
633
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
628
634
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
629
635
  lib_name: @config.lib_name, lib_version: @config.lib_version,
630
636
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
637
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
631
638
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
632
639
 
633
640
  header_params = {}
@@ -761,10 +768,11 @@ module Google
761
768
  # Customize the options with defaults
762
769
  metadata = @config.rpcs.update_trip.metadata.to_h
763
770
 
764
- # Set x-goog-api-client and x-goog-user-project headers
771
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
765
772
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
766
773
  lib_name: @config.lib_name, lib_version: @config.lib_version,
767
774
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
775
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
768
776
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
769
777
 
770
778
  header_params = {}
@@ -32,6 +32,9 @@ module Google
32
32
  # Trip management service.
33
33
  #
34
34
  class Client
35
+ # @private
36
+ API_VERSION = ""
37
+
35
38
  # @private
36
39
  DEFAULT_ENDPOINT_TEMPLATE = "fleetengine.$UNIVERSE_DOMAIN$"
37
40
 
@@ -278,12 +281,13 @@ module Google
278
281
  # Customize the options with defaults
279
282
  call_metadata = @config.rpcs.create_trip.metadata.to_h
280
283
 
281
- # Set x-goog-api-client and x-goog-user-project headers
284
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
282
285
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
283
286
  lib_name: @config.lib_name, lib_version: @config.lib_version,
284
287
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION,
285
288
  transports_version_send: [:rest]
286
289
 
290
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
287
291
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
288
292
 
289
293
  options.apply_defaults timeout: @config.rpcs.create_trip.timeout,
@@ -391,12 +395,13 @@ module Google
391
395
  # Customize the options with defaults
392
396
  call_metadata = @config.rpcs.get_trip.metadata.to_h
393
397
 
394
- # Set x-goog-api-client and x-goog-user-project headers
398
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
395
399
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
396
400
  lib_name: @config.lib_name, lib_version: @config.lib_version,
397
401
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION,
398
402
  transports_version_send: [:rest]
399
403
 
404
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
400
405
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
401
406
 
402
407
  options.apply_defaults timeout: @config.rpcs.get_trip.timeout,
@@ -486,12 +491,13 @@ module Google
486
491
  # Customize the options with defaults
487
492
  call_metadata = @config.rpcs.report_billable_trip.metadata.to_h
488
493
 
489
- # Set x-goog-api-client and x-goog-user-project headers
494
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
490
495
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
491
496
  lib_name: @config.lib_name, lib_version: @config.lib_version,
492
497
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION,
493
498
  transports_version_send: [:rest]
494
499
 
500
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
495
501
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
496
502
 
497
503
  options.apply_defaults timeout: @config.rpcs.report_billable_trip.timeout,
@@ -592,12 +598,13 @@ module Google
592
598
  # Customize the options with defaults
593
599
  call_metadata = @config.rpcs.search_trips.metadata.to_h
594
600
 
595
- # Set x-goog-api-client and x-goog-user-project headers
601
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
596
602
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
597
603
  lib_name: @config.lib_name, lib_version: @config.lib_version,
598
604
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION,
599
605
  transports_version_send: [:rest]
600
606
 
607
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
601
608
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
602
609
 
603
610
  options.apply_defaults timeout: @config.rpcs.search_trips.timeout,
@@ -721,12 +728,13 @@ module Google
721
728
  # Customize the options with defaults
722
729
  call_metadata = @config.rpcs.update_trip.metadata.to_h
723
730
 
724
- # Set x-goog-api-client and x-goog-user-project headers
731
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
725
732
  call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
726
733
  lib_name: @config.lib_name, lib_version: @config.lib_version,
727
734
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION,
728
735
  transports_version_send: [:rest]
729
736
 
737
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
730
738
  call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
731
739
 
732
740
  options.apply_defaults timeout: @config.rpcs.update_trip.timeout,
@@ -30,6 +30,9 @@ module Google
30
30
  # Vehicle management service.
31
31
  #
32
32
  class Client
33
+ # @private
34
+ API_VERSION = ""
35
+
33
36
  # @private
34
37
  DEFAULT_ENDPOINT_TEMPLATE = "fleetengine.$UNIVERSE_DOMAIN$"
35
38
 
@@ -309,10 +312,11 @@ module Google
309
312
  # Customize the options with defaults
310
313
  metadata = @config.rpcs.create_vehicle.metadata.to_h
311
314
 
312
- # Set x-goog-api-client and x-goog-user-project headers
315
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
313
316
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
314
317
  lib_name: @config.lib_name, lib_version: @config.lib_version,
315
318
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
319
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
316
320
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
317
321
 
318
322
  header_params = {}
@@ -412,10 +416,11 @@ module Google
412
416
  # Customize the options with defaults
413
417
  metadata = @config.rpcs.get_vehicle.metadata.to_h
414
418
 
415
- # Set x-goog-api-client and x-goog-user-project headers
419
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
416
420
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
417
421
  lib_name: @config.lib_name, lib_version: @config.lib_version,
418
422
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
423
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
419
424
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
420
425
 
421
426
  header_params = {}
@@ -540,10 +545,11 @@ module Google
540
545
  # Customize the options with defaults
541
546
  metadata = @config.rpcs.update_vehicle.metadata.to_h
542
547
 
543
- # Set x-goog-api-client and x-goog-user-project headers
548
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
544
549
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
545
550
  lib_name: @config.lib_name, lib_version: @config.lib_version,
546
551
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
552
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
547
553
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
548
554
 
549
555
  header_params = {}
@@ -571,107 +577,6 @@ module Google
571
577
  raise ::Google::Cloud::Error.from_error(e)
572
578
  end
573
579
 
574
- ##
575
- # Deprecated: Use the `UpdateVehicle` method instead.
576
- # UpdateVehicleLocation updates the location of the vehicle.
577
- #
578
- # @deprecated This method is deprecated and may be removed in the next major version update.
579
- #
580
- # @overload update_vehicle_location(request, options = nil)
581
- # Pass arguments to `update_vehicle_location` via a request object, either of type
582
- # {::Google::Maps::FleetEngine::V1::UpdateVehicleLocationRequest} or an equivalent Hash.
583
- #
584
- # @param request [::Google::Maps::FleetEngine::V1::UpdateVehicleLocationRequest, ::Hash]
585
- # A request object representing the call parameters. Required. To specify no
586
- # parameters, or to keep all the default parameter values, pass an empty Hash.
587
- # @param options [::Gapic::CallOptions, ::Hash]
588
- # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
589
- #
590
- # @overload update_vehicle_location(header: nil, name: nil, current_location: nil, current_state: nil)
591
- # Pass arguments to `update_vehicle_location` via keyword arguments. Note that at
592
- # least one keyword argument is required. To specify no parameters, or to keep all
593
- # the default parameter values, pass an empty Hash as a request object (see above).
594
- #
595
- # @param header [::Google::Maps::FleetEngine::V1::RequestHeader, ::Hash]
596
- # The standard Fleet Engine request header.
597
- # @param name [::String]
598
- # Required. Must be in the format
599
- # `providers/{provider}/vehicles/{vehicle}`.
600
- # The \\{provider} must be the Project ID (for example, `sample-cloud-project`)
601
- # of the Google Cloud Project of which the service account making
602
- # this call is a member.
603
- # @param current_location [::Google::Maps::FleetEngine::V1::VehicleLocation, ::Hash]
604
- # Required. The vehicle's most recent location. The `location` and
605
- # `update_time` subfields are required.
606
- # @param current_state [::Google::Maps::FleetEngine::V1::VehicleState]
607
- # Set the vehicle's state to either `ONLINE` or `OFFLINE`.
608
- # If set to `UNKNOWN_VEHICLE_STATE`, the vehicle's state will not be altered.
609
- #
610
- # @yield [response, operation] Access the result along with the RPC operation
611
- # @yieldparam response [::Google::Maps::FleetEngine::V1::VehicleLocation]
612
- # @yieldparam operation [::GRPC::ActiveCall::Operation]
613
- #
614
- # @return [::Google::Maps::FleetEngine::V1::VehicleLocation]
615
- #
616
- # @raise [::Google::Cloud::Error] if the RPC is aborted.
617
- #
618
- # @example Basic example
619
- # require "google/maps/fleet_engine/v1"
620
- #
621
- # # Create a client object. The client can be reused for multiple calls.
622
- # client = Google::Maps::FleetEngine::V1::VehicleService::Client.new
623
- #
624
- # # Create a request. To set request fields, pass in keyword arguments.
625
- # request = Google::Maps::FleetEngine::V1::UpdateVehicleLocationRequest.new
626
- #
627
- # # Call the update_vehicle_location method.
628
- # result = client.update_vehicle_location request
629
- #
630
- # # The returned object is of type Google::Maps::FleetEngine::V1::VehicleLocation.
631
- # p result
632
- #
633
- def update_vehicle_location request, options = nil
634
- raise ::ArgumentError, "request must be provided" if request.nil?
635
-
636
- request = ::Gapic::Protobuf.coerce request, to: ::Google::Maps::FleetEngine::V1::UpdateVehicleLocationRequest
637
-
638
- # Converts hash and nil to an options object
639
- options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
640
-
641
- # Customize the options with defaults
642
- metadata = @config.rpcs.update_vehicle_location.metadata.to_h
643
-
644
- # Set x-goog-api-client and x-goog-user-project headers
645
- metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
646
- lib_name: @config.lib_name, lib_version: @config.lib_version,
647
- gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
648
- metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
649
-
650
- header_params = {}
651
- if request.name &&
652
- %r{^providers/[^/]+/?$}.match?(request.name)
653
- header_params["provider_id"] = request.name
654
- end
655
-
656
- request_params_header = URI.encode_www_form header_params
657
- metadata[:"x-goog-request-params"] ||= request_params_header
658
-
659
- options.apply_defaults timeout: @config.rpcs.update_vehicle_location.timeout,
660
- metadata: metadata,
661
- retry_policy: @config.rpcs.update_vehicle_location.retry_policy
662
-
663
- options.apply_defaults timeout: @config.timeout,
664
- metadata: @config.metadata,
665
- retry_policy: @config.retry_policy
666
-
667
- @vehicle_service_stub.call_rpc :update_vehicle_location, request, options: options do |response, operation|
668
- yield response, operation if block_given?
669
- return response
670
- end
671
- rescue ::GRPC::BadStatus => e
672
- raise ::Google::Cloud::Error.from_error(e)
673
- end
674
-
675
580
  ##
676
581
  # Partially updates a vehicle's attributes.
677
582
  # Only the attributes mentioned in the request will be updated, other
@@ -739,10 +644,11 @@ module Google
739
644
  # Customize the options with defaults
740
645
  metadata = @config.rpcs.update_vehicle_attributes.metadata.to_h
741
646
 
742
- # Set x-goog-api-client and x-goog-user-project headers
647
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
743
648
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
744
649
  lib_name: @config.lib_name, lib_version: @config.lib_version,
745
650
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
651
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
746
652
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
747
653
 
748
654
  header_params = {}
@@ -946,10 +852,11 @@ module Google
946
852
  # Customize the options with defaults
947
853
  metadata = @config.rpcs.list_vehicles.metadata.to_h
948
854
 
949
- # Set x-goog-api-client and x-goog-user-project headers
855
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
950
856
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
951
857
  lib_name: @config.lib_name, lib_version: @config.lib_version,
952
858
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
859
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
953
860
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
954
861
 
955
862
  header_params = {}
@@ -1164,10 +1071,11 @@ module Google
1164
1071
  # Customize the options with defaults
1165
1072
  metadata = @config.rpcs.search_vehicles.metadata.to_h
1166
1073
 
1167
- # Set x-goog-api-client and x-goog-user-project headers
1074
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
1168
1075
  metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1169
1076
  lib_name: @config.lib_name, lib_version: @config.lib_version,
1170
1077
  gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
1078
+ metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
1171
1079
  metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1172
1080
 
1173
1081
  header_params = {}
@@ -1195,225 +1103,6 @@ module Google
1195
1103
  raise ::Google::Cloud::Error.from_error(e)
1196
1104
  end
1197
1105
 
1198
- ##
1199
- # Deprecated: Use `SearchVehicles` instead.
1200
- #
1201
- # @deprecated This method is deprecated and may be removed in the next major version update.
1202
- #
1203
- # @overload search_fuzzed_vehicles(request, options = nil)
1204
- # Pass arguments to `search_fuzzed_vehicles` via a request object, either of type
1205
- # {::Google::Maps::FleetEngine::V1::SearchVehiclesRequest} or an equivalent Hash.
1206
- #
1207
- # @param request [::Google::Maps::FleetEngine::V1::SearchVehiclesRequest, ::Hash]
1208
- # A request object representing the call parameters. Required. To specify no
1209
- # parameters, or to keep all the default parameter values, pass an empty Hash.
1210
- # @param options [::Gapic::CallOptions, ::Hash]
1211
- # Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
1212
- #
1213
- # @overload search_fuzzed_vehicles(header: nil, parent: nil, pickup_point: nil, dropoff_point: nil, pickup_radius_meters: nil, count: nil, minimum_capacity: nil, trip_types: nil, maximum_staleness: nil, vehicle_types: nil, required_attributes: nil, required_one_of_attributes: nil, required_one_of_attribute_sets: nil, order_by: nil, include_back_to_back: nil, trip_id: nil, current_trips_present: nil, filter: nil)
1214
- # Pass arguments to `search_fuzzed_vehicles` via keyword arguments. Note that at
1215
- # least one keyword argument is required. To specify no parameters, or to keep all
1216
- # the default parameter values, pass an empty Hash as a request object (see above).
1217
- #
1218
- # @param header [::Google::Maps::FleetEngine::V1::RequestHeader, ::Hash]
1219
- # The standard Fleet Engine request header.
1220
- # @param parent [::String]
1221
- # Required. Must be in the format `providers/{provider}`.
1222
- # The provider must be the Project ID (for example, `sample-cloud-project`)
1223
- # of the Google Cloud Project of which the service account making
1224
- # this call is a member.
1225
- # @param pickup_point [::Google::Maps::FleetEngine::V1::TerminalLocation, ::Hash]
1226
- # Required. The pickup point to search near.
1227
- # @param dropoff_point [::Google::Maps::FleetEngine::V1::TerminalLocation, ::Hash]
1228
- # The customer's intended dropoff location. The field is required if
1229
- # `trip_types` contains `TripType.SHARED`.
1230
- # @param pickup_radius_meters [::Integer]
1231
- # Required. Defines the vehicle search radius around the pickup point. Only
1232
- # vehicles within the search radius will be returned. Value must be between
1233
- # 400 and 10000 meters (inclusive).
1234
- # @param count [::Integer]
1235
- # Required. Specifies the maximum number of vehicles to return. The value
1236
- # must be between 1 and 50 (inclusive).
1237
- # @param minimum_capacity [::Integer]
1238
- # Required. Specifies the number of passengers being considered for a trip.
1239
- # The value must be greater than or equal to one. The driver is not
1240
- # considered in the capacity value.
1241
- # @param trip_types [::Array<::Google::Maps::FleetEngine::V1::TripType>]
1242
- # Required. Represents the type of proposed trip. Must include exactly one
1243
- # type. `UNKNOWN_TRIP_TYPE` is not allowed. Restricts the search to only
1244
- # those vehicles that can support that trip type.
1245
- # @param maximum_staleness [::Google::Protobuf::Duration, ::Hash]
1246
- # Restricts the search to only those vehicles that have sent location updates
1247
- # to Fleet Engine within the specified duration. Stationary vehicles still
1248
- # transmitting their locations are not considered stale. If this field is not
1249
- # set, the server uses five minutes as the default value.
1250
- # @param vehicle_types [::Array<::Google::Maps::FleetEngine::V1::Vehicle::VehicleType, ::Hash>]
1251
- # Required. Restricts the search to vehicles with one of the specified types.
1252
- # At least one vehicle type must be specified. VehicleTypes with a category
1253
- # of `UNKNOWN` are not allowed.
1254
- # @param required_attributes [::Array<::Google::Maps::FleetEngine::V1::VehicleAttribute, ::Hash>]
1255
- # Callers can form complex logical operations using any combination of the
1256
- # `required_attributes`, `required_one_of_attributes`, and
1257
- # `required_one_of_attribute_sets` fields.
1258
- #
1259
- # `required_attributes` is a list; `required_one_of_attributes` uses a
1260
- # message which allows a list of lists. In combination, the two fields allow
1261
- # the composition of this expression:
1262
- #
1263
- # ```
1264
- # (required_attributes[0] AND required_attributes[1] AND ...)
1265
- # AND
1266
- # (required_one_of_attributes[0][0] OR required_one_of_attributes[0][1] OR
1267
- # ...)
1268
- # AND
1269
- # (required_one_of_attributes[1][0] OR required_one_of_attributes[1][1] OR
1270
- # ...)
1271
- # ```
1272
- #
1273
- # Restricts the search to only those vehicles with the specified attributes.
1274
- # This field is a conjunction/AND operation. A max of 50 required_attributes
1275
- # is allowed. This matches the maximum number of attributes allowed on a
1276
- # vehicle.
1277
- # @param required_one_of_attributes [::Array<::Google::Maps::FleetEngine::V1::VehicleAttributeList, ::Hash>]
1278
- # Restricts the search to only those vehicles with at least one of
1279
- # the specified attributes in each `VehicleAttributeList`. Within each
1280
- # list, a vehicle must match at least one of the attributes. This field is an
1281
- # inclusive disjunction/OR operation in each `VehicleAttributeList` and a
1282
- # conjunction/AND operation across the collection of `VehicleAttributeList`.
1283
- # @param required_one_of_attribute_sets [::Array<::Google::Maps::FleetEngine::V1::VehicleAttributeList, ::Hash>]
1284
- # `required_one_of_attribute_sets` provides additional functionality.
1285
- #
1286
- # Similar to `required_one_of_attributes`, `required_one_of_attribute_sets`
1287
- # uses a message which allows a list of lists, allowing expressions such as
1288
- # this one:
1289
- #
1290
- # ```
1291
- # (required_attributes[0] AND required_attributes[1] AND ...)
1292
- # AND
1293
- # (
1294
- # (required_one_of_attribute_sets[0][0] AND
1295
- # required_one_of_attribute_sets[0][1] AND
1296
- # ...)
1297
- # OR
1298
- # (required_one_of_attribute_sets[1][0] AND
1299
- # required_one_of_attribute_sets[1][1] AND
1300
- # ...)
1301
- # )
1302
- # ```
1303
- #
1304
- # Restricts the search to only those vehicles with all the attributes in a
1305
- # `VehicleAttributeList`. Within each list, a
1306
- # vehicle must match all of the attributes. This field is a conjunction/AND
1307
- # operation in each `VehicleAttributeList` and inclusive disjunction/OR
1308
- # operation across the collection of `VehicleAttributeList`.
1309
- # @param order_by [::Google::Maps::FleetEngine::V1::SearchVehiclesRequest::VehicleMatchOrder]
1310
- # Required. Specifies the desired ordering criterion for results.
1311
- # @param include_back_to_back [::Boolean]
1312
- # This indicates if vehicles with a single active trip are eligible for this
1313
- # search. This field is only used when `current_trips_present` is
1314
- # unspecified. When `current_trips_present` is unspecified and this field
1315
- # is `false`, vehicles with assigned trips are excluded from the search
1316
- # results. When `current_trips_present` is unspecified and this field is
1317
- # `true`, search results can include vehicles with one active trip that has a
1318
- # status of `ENROUTE_TO_DROPOFF`. When `current_trips_present` is specified,
1319
- # this field cannot be set to true.
1320
- #
1321
- # The default value is `false`.
1322
- # @param trip_id [::String]
1323
- # Indicates the trip associated with this `SearchVehicleRequest`.
1324
- # @param current_trips_present [::Google::Maps::FleetEngine::V1::SearchVehiclesRequest::CurrentTripsPresent]
1325
- # This indicates if vehicles with active trips are eligible for this search.
1326
- # This must be set to something other than
1327
- # `CURRENT_TRIPS_PRESENT_UNSPECIFIED` if `trip_type` includes `SHARED`.
1328
- # @param filter [::String]
1329
- # Optional. A filter query to apply when searching vehicles. See
1330
- # http://aip.dev/160 for examples of the filter syntax.
1331
- #
1332
- # This field is designed to replace the `required_attributes`,
1333
- # `required_one_of_attributes`, and `required_one_of_attributes_sets` fields.
1334
- # If a non-empty value is specified here, the following fields must be empty:
1335
- # `required_attributes`, `required_one_of_attributes`, and
1336
- # `required_one_of_attributes_sets`.
1337
- #
1338
- # This filter functions as an AND clause with other constraints,
1339
- # such as `minimum_capacity` or `vehicle_types`.
1340
- #
1341
- # Note that the only queries supported are on vehicle attributes (for
1342
- # example, `attributes.<key> = <value>` or `attributes.<key1> = <value1> AND
1343
- # attributes.<key2> = <value2>`). The maximum number of restrictions allowed
1344
- # in a filter query is 50.
1345
- #
1346
- # Also, all attributes are stored as strings, so the only supported
1347
- # comparisons against attributes are string comparisons. In order to compare
1348
- # against number or boolean values, the values must be explicitly quoted to
1349
- # be treated as strings (for example, `attributes.<key> = "10"` or
1350
- # `attributes.<key> = "true"`).
1351
- #
1352
- # @yield [response, operation] Access the result along with the RPC operation
1353
- # @yieldparam response [::Google::Maps::FleetEngine::V1::SearchVehiclesResponse]
1354
- # @yieldparam operation [::GRPC::ActiveCall::Operation]
1355
- #
1356
- # @return [::Google::Maps::FleetEngine::V1::SearchVehiclesResponse]
1357
- #
1358
- # @raise [::Google::Cloud::Error] if the RPC is aborted.
1359
- #
1360
- # @example Basic example
1361
- # require "google/maps/fleet_engine/v1"
1362
- #
1363
- # # Create a client object. The client can be reused for multiple calls.
1364
- # client = Google::Maps::FleetEngine::V1::VehicleService::Client.new
1365
- #
1366
- # # Create a request. To set request fields, pass in keyword arguments.
1367
- # request = Google::Maps::FleetEngine::V1::SearchVehiclesRequest.new
1368
- #
1369
- # # Call the search_fuzzed_vehicles method.
1370
- # result = client.search_fuzzed_vehicles request
1371
- #
1372
- # # The returned object is of type Google::Maps::FleetEngine::V1::SearchVehiclesResponse.
1373
- # p result
1374
- #
1375
- def search_fuzzed_vehicles request, options = nil
1376
- raise ::ArgumentError, "request must be provided" if request.nil?
1377
-
1378
- request = ::Gapic::Protobuf.coerce request, to: ::Google::Maps::FleetEngine::V1::SearchVehiclesRequest
1379
-
1380
- # Converts hash and nil to an options object
1381
- options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
1382
-
1383
- # Customize the options with defaults
1384
- metadata = @config.rpcs.search_fuzzed_vehicles.metadata.to_h
1385
-
1386
- # Set x-goog-api-client and x-goog-user-project headers
1387
- metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
1388
- lib_name: @config.lib_name, lib_version: @config.lib_version,
1389
- gapic_version: ::Google::Maps::FleetEngine::V1::VERSION
1390
- metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
1391
-
1392
- header_params = {}
1393
- if request.parent &&
1394
- %r{^providers/[^/]+/?$}.match?(request.parent)
1395
- header_params["provider_id"] = request.parent
1396
- end
1397
-
1398
- request_params_header = URI.encode_www_form header_params
1399
- metadata[:"x-goog-request-params"] ||= request_params_header
1400
-
1401
- options.apply_defaults timeout: @config.rpcs.search_fuzzed_vehicles.timeout,
1402
- metadata: metadata,
1403
- retry_policy: @config.rpcs.search_fuzzed_vehicles.retry_policy
1404
-
1405
- options.apply_defaults timeout: @config.timeout,
1406
- metadata: @config.metadata,
1407
- retry_policy: @config.retry_policy
1408
-
1409
- @vehicle_service_stub.call_rpc :search_fuzzed_vehicles, request, options: options do |response, operation|
1410
- yield response, operation if block_given?
1411
- return response
1412
- end
1413
- rescue ::GRPC::BadStatus => e
1414
- raise ::Google::Cloud::Error.from_error(e)
1415
- end
1416
-
1417
1106
  ##
1418
1107
  # Configuration class for the VehicleService API.
1419
1108
  #
@@ -1583,11 +1272,6 @@ module Google
1583
1272
  #
1584
1273
  attr_reader :update_vehicle
1585
1274
  ##
1586
- # RPC-specific configuration for `update_vehicle_location`
1587
- # @return [::Gapic::Config::Method]
1588
- #
1589
- attr_reader :update_vehicle_location
1590
- ##
1591
1275
  # RPC-specific configuration for `update_vehicle_attributes`
1592
1276
  # @return [::Gapic::Config::Method]
1593
1277
  #
@@ -1602,11 +1286,6 @@ module Google
1602
1286
  # @return [::Gapic::Config::Method]
1603
1287
  #
1604
1288
  attr_reader :search_vehicles
1605
- ##
1606
- # RPC-specific configuration for `search_fuzzed_vehicles`
1607
- # @return [::Gapic::Config::Method]
1608
- #
1609
- attr_reader :search_fuzzed_vehicles
1610
1289
 
1611
1290
  # @private
1612
1291
  def initialize parent_rpcs = nil
@@ -1616,16 +1295,12 @@ module Google
1616
1295
  @get_vehicle = ::Gapic::Config::Method.new get_vehicle_config
1617
1296
  update_vehicle_config = parent_rpcs.update_vehicle if parent_rpcs.respond_to? :update_vehicle
1618
1297
  @update_vehicle = ::Gapic::Config::Method.new update_vehicle_config
1619
- update_vehicle_location_config = parent_rpcs.update_vehicle_location if parent_rpcs.respond_to? :update_vehicle_location
1620
- @update_vehicle_location = ::Gapic::Config::Method.new update_vehicle_location_config
1621
1298
  update_vehicle_attributes_config = parent_rpcs.update_vehicle_attributes if parent_rpcs.respond_to? :update_vehicle_attributes
1622
1299
  @update_vehicle_attributes = ::Gapic::Config::Method.new update_vehicle_attributes_config
1623
1300
  list_vehicles_config = parent_rpcs.list_vehicles if parent_rpcs.respond_to? :list_vehicles
1624
1301
  @list_vehicles = ::Gapic::Config::Method.new list_vehicles_config
1625
1302
  search_vehicles_config = parent_rpcs.search_vehicles if parent_rpcs.respond_to? :search_vehicles
1626
1303
  @search_vehicles = ::Gapic::Config::Method.new search_vehicles_config
1627
- search_fuzzed_vehicles_config = parent_rpcs.search_fuzzed_vehicles if parent_rpcs.respond_to? :search_fuzzed_vehicles
1628
- @search_fuzzed_vehicles = ::Gapic::Config::Method.new search_fuzzed_vehicles_config
1629
1304
 
1630
1305
  yield self if block_given?
1631
1306
  end