google-cloud-commerce-consumer-procurement 1.0.1 → 1.1.0

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: a33bcb889404399005f0bafe0a400a6bafd542c59875579c56685d4c942cd03b
4
- data.tar.gz: f4989d7c977ea8b6fff99eabecae256160ace962bf629f8e3637f6bda9ee713a
3
+ metadata.gz: 58c870df8f993ada97374abb157a173920744909498929beecd19cb7d581ef1a
4
+ data.tar.gz: 87227cf3baa1565cb21df0c2e774f6ddabc799184d5f06c4f64c848843afbdff
5
5
  SHA512:
6
- metadata.gz: ac39a3724097e8ee0d3f851026f1f349f6f82a689ba116689b07be05b6c9beb0c9c8eab1788e0cec5057e9f7b183574bf0138235a79c7b4d2107f6f1a9e5a272
7
- data.tar.gz: 6e341a701a3f20607288da00c09c04973cbae806f61c376e28e60425a9b73c3ac9a6e21b35af85401bad2394b6a570d032e81cb3a5cbca7be639770b34eaede5
6
+ metadata.gz: e8d3ac8b477a1ca46bc2e06317b9142b68a84332e6811e34c47a8a3a51e6548cc0ad78772278c37fdaf81df5b03860bd1f1b32f813d5689a63c17d1e2db1f547
7
+ data.tar.gz: 4a9627cae28fb51e8f8c112ba997dc02c18e2a6c7ec1805f131db15ef9a7b44f3cecbaea56f09594b1e85615d15ed0bd8bb2ab351866a1a4cdd507ea2e6f8139
data/AUTHENTICATION.md CHANGED
@@ -56,7 +56,7 @@ To configure a credentials file for an individual client initialization:
56
56
  ```ruby
57
57
  require "google/cloud/commerce/consumer/procurement"
58
58
 
59
- client = Google::Cloud::Commerce::Consumer::Procurement.consumer_procurement_service do |config|
59
+ client = Google::Cloud::Commerce::Consumer::Procurement.license_management_service do |config|
60
60
  config.credentials = "path/to/credentialfile.json"
61
61
  end
62
62
  ```
@@ -70,7 +70,7 @@ Google::Cloud::Commerce::Consumer::Procurement.configure do |config|
70
70
  config.credentials = "path/to/credentialfile.json"
71
71
  end
72
72
 
73
- client = Google::Cloud::Commerce::Consumer::Procurement.consumer_procurement_service
73
+ client = Google::Cloud::Commerce::Consumer::Procurement.license_management_service
74
74
  ```
75
75
 
76
76
  ### Environment Variables
@@ -100,7 +100,7 @@ require "google/cloud/commerce/consumer/procurement"
100
100
 
101
101
  ENV["GOOGLE_APPLICATION_CREDENTIALS"] = "path/to/credentialfile.json"
102
102
 
103
- client = Google::Cloud::Commerce::Consumer::Procurement.consumer_procurement_service
103
+ client = Google::Cloud::Commerce::Consumer::Procurement.license_management_service
104
104
  ```
105
105
 
106
106
  ### Local ADC file
@@ -22,7 +22,7 @@ module Google
22
22
  module Commerce
23
23
  module Consumer
24
24
  module Procurement
25
- VERSION = "1.0.1"
25
+ VERSION = "1.1.0"
26
26
  end
27
27
  end
28
28
  end
@@ -47,6 +47,40 @@ module Google
47
47
  module Commerce
48
48
  module Consumer
49
49
  module Procurement
50
+ ##
51
+ # Create a new client object for LicenseManagementService.
52
+ #
53
+ # By default, this returns an instance of
54
+ # [Google::Cloud::Commerce::Consumer::Procurement::V1::LicenseManagementService::Client](https://cloud.google.com/ruby/docs/reference/google-cloud-commerce-consumer-procurement-v1/latest/Google-Cloud-Commerce-Consumer-Procurement-V1-LicenseManagementService-Client)
55
+ # for a gRPC client for version V1 of the API.
56
+ # However, you can specify a different API version by passing it in the
57
+ # `version` parameter. If the LicenseManagementService service is
58
+ # supported by that API version, and the corresponding gem is available, the
59
+ # appropriate versioned client will be returned.
60
+ # You can also specify a different transport by passing `:rest` or `:grpc` in
61
+ # the `transport` parameter.
62
+ #
63
+ # ## About LicenseManagementService
64
+ #
65
+ # Service for managing licenses.
66
+ #
67
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
68
+ # Defaults to `:v1`.
69
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
70
+ # @return [::Object] A client object for the specified version.
71
+ #
72
+ def self.license_management_service version: :v1, transport: :grpc, &block
73
+ require "google/cloud/commerce/consumer/procurement/#{version.to_s.downcase}"
74
+
75
+ package_name = Google::Cloud::Commerce::Consumer::Procurement
76
+ .constants
77
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
78
+ .first
79
+ service_module = Google::Cloud::Commerce::Consumer::Procurement.const_get(package_name).const_get(:LicenseManagementService)
80
+ service_module = service_module.const_get(:Rest) if transport == :rest
81
+ service_module.const_get(:Client).new(&block)
82
+ end
83
+
50
84
  ##
51
85
  # Create a new client object for ConsumerProcurementService.
52
86
  #
metadata CHANGED
@@ -1,35 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-commerce-consumer-procurement
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-09 00:00:00.000000000 Z
11
+ date: 2024-10-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-cloud-commerce-consumer-procurement-v1
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
18
- - !ruby/object:Gem::Version
19
- version: '0.3'
20
- - - "<"
17
+ - - "~>"
21
18
  - !ruby/object:Gem::Version
22
- version: 2.a
19
+ version: '1.1'
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
- - - ">="
28
- - !ruby/object:Gem::Version
29
- version: '0.3'
30
- - - "<"
24
+ - - "~>"
31
25
  - !ruby/object:Gem::Version
32
- version: 2.a
26
+ version: '1.1'
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: google-cloud-core
35
29
  requirement: !ruby/object:Gem::Requirement
@@ -76,7 +70,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
76
70
  - !ruby/object:Gem::Version
77
71
  version: '0'
78
72
  requirements: []
79
- rubygems_version: 3.5.6
73
+ rubygems_version: 3.5.21
80
74
  signing_key:
81
75
  specification_version: 4
82
76
  summary: Enables consumers to procure products served by Cloud Marketplace platform.