google-cloud-vision 1.6.0 → 2.0.0
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 +4 -4
- data/.yardopts +0 -1
- data/README.md +2 -12
- data/lib/google/cloud/vision/version.rb +1 -1
- metadata +7 -34
- data/MIGRATING.md +0 -343
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b1129130bd2c66d16a27b2b777d83077bdb67807b64d8ce719aea58b14f500e1
|
4
|
+
data.tar.gz: 950ff11ab47c8499e057508f0f173e24c41a027869f3fca7217b9a87c0c49715
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6ec715c05f0ca86057266483660a6ef5259110819daea1ba187a60a9e8b9f61a6de5dbd2f5b0a65c170fe4270c3729419ab110169b63c19d9007e1553075cb0
|
7
|
+
data.tar.gz: 5b90a4df63e34147243ccee14a1b9dac063bf8f4f7d62e93c3645c17a94dacb48ca94aa60214631af9bd3b763b778ff779335f6ba4f557f2758060999e669675
|
data/.yardopts
CHANGED
data/README.md
CHANGED
@@ -16,8 +16,7 @@ for this library, google-cloud-vision, to see the convenience methods for
|
|
16
16
|
constructing client objects. Reference documentation for the client objects
|
17
17
|
themselves can be found in the client library documentation for the versioned
|
18
18
|
client gems:
|
19
|
-
[google-cloud-vision-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest)
|
20
|
-
[google-cloud-vision-v1p3beta1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1p3beta1/latest).
|
19
|
+
[google-cloud-vision-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest).
|
21
20
|
|
22
21
|
See also the [Product Documentation](https://cloud.google.com/vision)
|
23
22
|
for more usage information.
|
@@ -35,14 +34,6 @@ In order to use this library, you first need to go through the following steps:
|
|
35
34
|
1. [Enable the API.](https://console.cloud.google.com/apis/library/vision.googleapis.com)
|
36
35
|
1. {file:AUTHENTICATION.md Set up authentication.}
|
37
36
|
|
38
|
-
## Migrating from 0.x versions
|
39
|
-
|
40
|
-
The 1.0 release of the google-cloud-vision client is a significant upgrade
|
41
|
-
based on a [next-gen code generator](https://github.com/googleapis/gapic-generator-ruby),
|
42
|
-
and includes substantial interface changes. Existing code written for earlier
|
43
|
-
versions of this library will likely require updates to use this version.
|
44
|
-
See the {file:MIGRATING.md MIGRATING.md} document for more information.
|
45
|
-
|
46
37
|
## Debug Logging
|
47
38
|
|
48
39
|
This library comes with opt-in Debug Logging that can help you troubleshoot
|
@@ -71,8 +62,7 @@ results in logs appearing alongside your application logs in the
|
|
71
62
|
Debug logging also requires that the versioned clients for this service be
|
72
63
|
sufficiently recent, released after about Dec 10, 2024. If logging is not
|
73
64
|
working, try updating the versioned clients in your bundle or installed gems:
|
74
|
-
[google-cloud-vision-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest)
|
75
|
-
[google-cloud-vision-v1p3beta1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1p3beta1/latest).
|
65
|
+
[google-cloud-vision-v1](https://cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest).
|
76
66
|
|
77
67
|
## Supported Ruby Versions
|
78
68
|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-vision
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-
|
10
|
+
date: 2025-02-13 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: google-cloud-core
|
@@ -27,42 +27,16 @@ dependencies:
|
|
27
27
|
name: google-cloud-vision-v1
|
28
28
|
requirement: !ruby/object:Gem::Requirement
|
29
29
|
requirements:
|
30
|
-
- - "
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: '0.13'
|
33
|
-
- - "<"
|
34
|
-
- !ruby/object:Gem::Version
|
35
|
-
version: 2.a
|
36
|
-
type: :runtime
|
37
|
-
prerelease: false
|
38
|
-
version_requirements: !ruby/object:Gem::Requirement
|
39
|
-
requirements:
|
40
|
-
- - ">="
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
version: '0.13'
|
43
|
-
- - "<"
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
version: 2.a
|
46
|
-
- !ruby/object:Gem::Dependency
|
47
|
-
name: google-cloud-vision-v1p3beta1
|
48
|
-
requirement: !ruby/object:Gem::Requirement
|
49
|
-
requirements:
|
50
|
-
- - ">="
|
51
|
-
- !ruby/object:Gem::Version
|
52
|
-
version: '0.12'
|
53
|
-
- - "<"
|
30
|
+
- - "~>"
|
54
31
|
- !ruby/object:Gem::Version
|
55
|
-
version: 2
|
32
|
+
version: '1.2'
|
56
33
|
type: :runtime
|
57
34
|
prerelease: false
|
58
35
|
version_requirements: !ruby/object:Gem::Requirement
|
59
36
|
requirements:
|
60
|
-
- - "
|
61
|
-
- !ruby/object:Gem::Version
|
62
|
-
version: '0.12'
|
63
|
-
- - "<"
|
37
|
+
- - "~>"
|
64
38
|
- !ruby/object:Gem::Version
|
65
|
-
version: 2
|
39
|
+
version: '1.2'
|
66
40
|
description: Cloud Vision API allows developers to easily integrate vision detection
|
67
41
|
features within applications, including image labeling, face and landmark detection,
|
68
42
|
optical character recognition (OCR), and tagging of explicit content.
|
@@ -74,7 +48,6 @@ files:
|
|
74
48
|
- ".yardopts"
|
75
49
|
- AUTHENTICATION.md
|
76
50
|
- LICENSE.md
|
77
|
-
- MIGRATING.md
|
78
51
|
- README.md
|
79
52
|
- lib/google-cloud-vision.rb
|
80
53
|
- lib/google/cloud/vision.rb
|
@@ -97,7 +70,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
97
70
|
- !ruby/object:Gem::Version
|
98
71
|
version: '0'
|
99
72
|
requirements: []
|
100
|
-
rubygems_version: 3.6.
|
73
|
+
rubygems_version: 3.6.3
|
101
74
|
specification_version: 4
|
102
75
|
summary: API Client library for the Cloud Vision API
|
103
76
|
test_files: []
|
data/MIGRATING.md
DELETED
@@ -1,343 +0,0 @@
|
|
1
|
-
## Migrating to google-cloud-vision 1.0
|
2
|
-
|
3
|
-
The 1.0 release of the google-cloud-vision client is a significant upgrade
|
4
|
-
based on a [next-gen code generator](https://github.com/googleapis/gapic-generator-ruby),
|
5
|
-
and includes substantial interface changes. Existing code written for earlier
|
6
|
-
versions of this library will likely require updates to use this version.
|
7
|
-
This document describes the changes that have been made, and what you need to
|
8
|
-
do to update your usage.
|
9
|
-
|
10
|
-
To summarize:
|
11
|
-
|
12
|
-
* The library has been broken out into multiple libraries. The new gems
|
13
|
-
`google-cloud-vision-v1` and `google-cloud-vision-v1p3beta1` contain the
|
14
|
-
actual client classes for versions V1 and V1p3beta1 of the Vision service,
|
15
|
-
and the gem `google-cloud-vision` now simply provides a convenience wrapper.
|
16
|
-
See [Library Structure](#library-structure) for more info.
|
17
|
-
* The library uses a new configuration mechanism giving you closer control
|
18
|
-
over endpoint address, network timeouts, and retry. See
|
19
|
-
[Client Configuration](#client-configuration) for more info. Furthermore,
|
20
|
-
when creating a client object, you can customize its configuration in a
|
21
|
-
block rather than passing arguments to the constructor. See
|
22
|
-
[Creating Clients](#creating-clients) for more info.
|
23
|
-
* Previously, positional arguments were used to indicate required arguments.
|
24
|
-
Now, all method arguments are keyword arguments, with documentation that
|
25
|
-
specifies whether they are required or optional. Additionally, you can pass
|
26
|
-
a proto request object instead of separate arguments. See
|
27
|
-
[Passing Arguments](#passing-arguments) for more info.
|
28
|
-
* Previously, some client classes included class methods for constructing
|
29
|
-
resource paths. These paths are now instance methods on the client objects,
|
30
|
-
and are also available in a separate paths module. See
|
31
|
-
[Resource Path Helpers](#resource-path-helpers) for more info.
|
32
|
-
* Previously, the client included a number of high-level convenience methods,
|
33
|
-
such as `face_detection`, for detecting particular types of features. These
|
34
|
-
methods are still present, but a few of the parameter types (relating to
|
35
|
-
call configuration) have changed. See
|
36
|
-
[High Level Detection Methods](#high-level-detection-methods) for more info.
|
37
|
-
* Previously, clients reported RPC errors by raising instances of
|
38
|
-
`Google::Gax::GaxError` and its subclasses. Now, RPC exceptions are of type
|
39
|
-
`Google::Cloud::Error` and its subclasses. See
|
40
|
-
[Handling Errors](#handling-errors) for more info.
|
41
|
-
* Some classes have moved into different namespaces. See
|
42
|
-
[Class Namespaces](#class-namespaces) for more info.
|
43
|
-
|
44
|
-
### Library Structure
|
45
|
-
|
46
|
-
Older 0.x releases of the `google-cloud-vision` gem were all-in-one gems
|
47
|
-
that included potentially multiple clients for multiple versions of the Vision
|
48
|
-
service. Factory methods such as `Google::Cloud::Vision::ImageAnnotator.new`
|
49
|
-
would return you instances of client classes such as
|
50
|
-
`Google::Cloud::Vision::V1::ImageAnnotatorClient` or
|
51
|
-
`Google::Cloud::Vision::V1p3beta1::ImageAnnotatorClient`, depending on which
|
52
|
-
version of the API requested. These classes were all defined in the same gem.
|
53
|
-
|
54
|
-
With the 1.0 release, the `google-cloud-vision` gem still provides factory
|
55
|
-
methods for obtaining clients. (The method signatures will have changed. See
|
56
|
-
[Creating Clients](#creating-clients) for details.) However, the actual client
|
57
|
-
classes have been moved into separate gems, one per service version. The
|
58
|
-
`Google::Cloud::Vision::V1::ImageAnnotator::Client` class, along with its
|
59
|
-
helpers and data types, is now part of the `google-cloud-vision-v1` gem.
|
60
|
-
Similarly, the `Google::Cloud::Vision::V1p3beta1::ImageAnnotator::Client`
|
61
|
-
class is part of the `google-cloud-vision-v1p3beta1` gem.
|
62
|
-
|
63
|
-
For normal usage, you can continue to install the `google-cloud-vision` gem
|
64
|
-
(which will bring in the versioned client gems as dependencies) and continue to
|
65
|
-
use factory methods to create clients. However, you may alternatively choose to
|
66
|
-
install only one of the versioned gems. For example, if you know you will only
|
67
|
-
use `V1` of the service, you can install `google-cloud-vision-v1` by
|
68
|
-
itself, and construct instances of the
|
69
|
-
`Google::Cloud::Vision::V1::ImageAnnotator::Client` client class directly.
|
70
|
-
|
71
|
-
### Client Configuration
|
72
|
-
|
73
|
-
In older releases, if you wanted to customize performance parameters or
|
74
|
-
low-level behavior of the client (such as credentials, timeouts, or
|
75
|
-
instrumentation), you would pass a variety of keyword arguments to the client
|
76
|
-
constructor. It was also extremely difficult to customize the default settings.
|
77
|
-
|
78
|
-
With the 1.0 release, a configuration interface provides control over these
|
79
|
-
parameters, including defaults for all instances of a client, and settings for
|
80
|
-
each specific client instance. For example, to set default credentials and
|
81
|
-
timeout for all Vision V1 image annotator clients:
|
82
|
-
|
83
|
-
```
|
84
|
-
Google::Cloud::Vision::V1::ImageAnnotator::Client.configure do |config|
|
85
|
-
config.credentials = "/path/to/credentials.json"
|
86
|
-
config.timeout = 10.0
|
87
|
-
end
|
88
|
-
```
|
89
|
-
|
90
|
-
Individual RPCs can also be configured independently. For example, to set the
|
91
|
-
timeout for the `batch_annotate_images` call:
|
92
|
-
|
93
|
-
```
|
94
|
-
Google::Cloud::Vision::V1::ImageAnnotator::Client.configure do |config|
|
95
|
-
config.rpcs.batch_annotate_images.timeout = 20.0
|
96
|
-
end
|
97
|
-
```
|
98
|
-
|
99
|
-
Defaults for certain configurations can be set for all Vision versions and
|
100
|
-
services globally:
|
101
|
-
|
102
|
-
```
|
103
|
-
Google::Cloud::Vision.configure do |config|
|
104
|
-
config.credentials = "/path/to/credentials.json"
|
105
|
-
config.timeout = 10.0
|
106
|
-
end
|
107
|
-
```
|
108
|
-
|
109
|
-
Finally, you can override the configuration for each client instance. See the
|
110
|
-
next section on [Creating Clients](#creating-clients) for details.
|
111
|
-
|
112
|
-
### Creating Clients
|
113
|
-
|
114
|
-
In older releases, to create a client object, you would use the `new` method
|
115
|
-
of modules under `Google::Cloud::Vision`. For example, you might call
|
116
|
-
`Google::Cloud::Vision::ImageAnnotator.new`. Keyword arguments were available to
|
117
|
-
select a service version and to configure parameters such as credentials and
|
118
|
-
timeouts.
|
119
|
-
|
120
|
-
With the 1.0 release, use named class methods of `Google::Cloud::Vision` to
|
121
|
-
create a client object. For example, `Google::Cloud::Vision.image_annotator`.
|
122
|
-
You may select a service version using the `:version` keyword argument.
|
123
|
-
However, other configuration parameters should be set in a configuration block
|
124
|
-
when you create the client.
|
125
|
-
|
126
|
-
Old:
|
127
|
-
```
|
128
|
-
client = Google::Cloud::Vision::ImageAnnotator.new credentials: "/path/to/credentials.json"
|
129
|
-
```
|
130
|
-
|
131
|
-
New:
|
132
|
-
```
|
133
|
-
client = Google::Cloud::Vision.image_annotator do |config|
|
134
|
-
config.credentials = "/path/to/credentials.json"
|
135
|
-
end
|
136
|
-
```
|
137
|
-
|
138
|
-
The configuration block is optional. If you do not provide it, or you do not
|
139
|
-
set some configuration parameters, then the default configuration is used. See
|
140
|
-
[Client Configuration](#client-configuration).
|
141
|
-
|
142
|
-
### Passing Arguments
|
143
|
-
|
144
|
-
In older releases, required arguments would be passed as positional method
|
145
|
-
arguments, while most optional arguments would be passed as keyword arguments.
|
146
|
-
|
147
|
-
With the 1.0 release, all RPC arguments are passed as keyword arguments,
|
148
|
-
regardless of whether they are required or optional. For example:
|
149
|
-
|
150
|
-
Old:
|
151
|
-
```
|
152
|
-
client = Google::Cloud::Vision::ImageAnnotator.new
|
153
|
-
|
154
|
-
requests = my_create_requests
|
155
|
-
|
156
|
-
# requests is a positional argument
|
157
|
-
response = client.batch_annotate_images requests
|
158
|
-
```
|
159
|
-
|
160
|
-
New:
|
161
|
-
```
|
162
|
-
client = Google::Cloud::Vision.image_annotator
|
163
|
-
|
164
|
-
requests = my_create_requests
|
165
|
-
|
166
|
-
# requests is a keyword argument
|
167
|
-
response = client.batch_annotate_images requests: requests
|
168
|
-
```
|
169
|
-
|
170
|
-
In the 1.0 release, it is also possible to pass a request object, either
|
171
|
-
as a hash or as a protocol buffer.
|
172
|
-
|
173
|
-
New:
|
174
|
-
```
|
175
|
-
client = Google::Cloud::Vision.image_annotator
|
176
|
-
|
177
|
-
request_object = Google::Cloud::Vision::V1::BatchAnnotateImagesRequest.new(
|
178
|
-
requests: my_create_requests
|
179
|
-
)
|
180
|
-
|
181
|
-
# Pass a request object as a positional argument:
|
182
|
-
response = client.batch_annotate_images request_object
|
183
|
-
```
|
184
|
-
|
185
|
-
Finally, in older releases, to provide call options, you would pass a
|
186
|
-
`Google::Gax::CallOptions` object with the `:options` keyword argument. In the
|
187
|
-
1.0 release, pass call options using a _second set_ of keyword arguments.
|
188
|
-
|
189
|
-
Old:
|
190
|
-
```
|
191
|
-
client = Google::Cloud::Vision::ImageAnnotator.new
|
192
|
-
|
193
|
-
requests = my_create_requests
|
194
|
-
|
195
|
-
options = Google::Gax::CallOptions.new timeout: 10.0
|
196
|
-
|
197
|
-
response = client.batch_annotate_images requests, options: options
|
198
|
-
```
|
199
|
-
|
200
|
-
New:
|
201
|
-
```
|
202
|
-
client = Google::Cloud::Vision.image_annotator
|
203
|
-
|
204
|
-
requests = my_create_requests
|
205
|
-
|
206
|
-
# Use a hash to wrap the normal call arguments (or pass a request object), and
|
207
|
-
# then add further keyword arguments for the call options.
|
208
|
-
response = client.batch_annotate_images({ requests: requests }, timeout: 10.0)
|
209
|
-
```
|
210
|
-
|
211
|
-
### Resource Path Helpers
|
212
|
-
|
213
|
-
The client library includes helper methods for generating the resource path
|
214
|
-
strings passed to many calls. These helpers have changed in two ways:
|
215
|
-
|
216
|
-
* In older releases, they are _class_ methods on the client class. In the 1.0
|
217
|
-
release, they are _instance_ methods on the client. They are also available
|
218
|
-
on a separate paths module that you can include elsewhere for convenience.
|
219
|
-
* In older releases, arguments to a resource path helper are passed as
|
220
|
-
_positional_ arguments. In the 1.0 release, they are passed as named _keyword_
|
221
|
-
arguments.
|
222
|
-
|
223
|
-
Following is an example involving using a resource path helper.
|
224
|
-
|
225
|
-
Old:
|
226
|
-
```
|
227
|
-
client = Google::Cloud::Vision::ProductSearch.new
|
228
|
-
|
229
|
-
# Call the helper on the client class
|
230
|
-
location = Google::Cloud::Vision::V1::ProductSearchClient.location_path(
|
231
|
-
"my-project", "my-location"
|
232
|
-
)
|
233
|
-
|
234
|
-
product = my_build_product
|
235
|
-
response = client.create_product location, product
|
236
|
-
```
|
237
|
-
|
238
|
-
New:
|
239
|
-
```
|
240
|
-
client = Google::Cloud::Vision.product_search
|
241
|
-
|
242
|
-
# Call the helper on the client instance, and use keyword arguments
|
243
|
-
location = client.location_path project: "my-project", location: "my-location"
|
244
|
-
|
245
|
-
product = my_build_product
|
246
|
-
response = client.create_product parent: location, product: product
|
247
|
-
```
|
248
|
-
|
249
|
-
In the 1.0 client, you can also use the paths module as a convenience module.
|
250
|
-
|
251
|
-
New:
|
252
|
-
```
|
253
|
-
# Bring the path helper methods into the current class
|
254
|
-
include Google::Cloud::Vision::V1::ProductSearch::Paths
|
255
|
-
|
256
|
-
def foo
|
257
|
-
client = Google::Cloud::Vision.product_search
|
258
|
-
|
259
|
-
# Call the included helper method
|
260
|
-
location = location_path project: "my-project", location: "my-location"
|
261
|
-
|
262
|
-
product = my_build_product
|
263
|
-
response = client.create_product parent: location, product: product
|
264
|
-
|
265
|
-
# Do something with response...
|
266
|
-
end
|
267
|
-
```
|
268
|
-
|
269
|
-
### High Level Detection Methods
|
270
|
-
|
271
|
-
The client library includes some high-level convenience methods, with names
|
272
|
-
such as `face_detection`, for detecting certain types of features. These
|
273
|
-
methods are still present, but a few of the argument types have changed.
|
274
|
-
|
275
|
-
* The `options` keyword argument is used to pass call options such as timeout
|
276
|
-
and retry. Older versions of the library took an object of type
|
277
|
-
`Google::Gax::CallOptions`. Version 1.0 takes an object of type
|
278
|
-
`Gapic::CallOptions`, which is defined in the `gapic-common` gem. Note that
|
279
|
-
you can also pass a hash with the same keys that the older library accepted.
|
280
|
-
* If `async` is set to `true`, older versions of the library returned an
|
281
|
-
object of type `Google::Gax::Operation`. Version 1.0 returns an object of
|
282
|
-
type `Gapic::Operation`, which is defined in the `gapic-common` gem. Most
|
283
|
-
methods on this object are the same as the older object.
|
284
|
-
|
285
|
-
### Handling Errors
|
286
|
-
|
287
|
-
The client reports standard
|
288
|
-
[gRPC error codes](https://github.com/grpc/grpc/blob/master/doc/statuscodes.md)
|
289
|
-
by raising exceptions. In older releases, these exceptions were located in the
|
290
|
-
`Google::Gax` namespace and were subclasses of the `Google::Gax::GaxError` base
|
291
|
-
exception class, defined in the `google-gax` gem. However, these classes were
|
292
|
-
different from the standard exceptions (subclasses of `Google::Cloud::Error`)
|
293
|
-
thrown by other client libraries such as `google-cloud-storage`.
|
294
|
-
|
295
|
-
The 1.0 client library now uses the `Google::Cloud::Error` exception hierarchy,
|
296
|
-
for consistency across all the Google Cloud client libraries. In general, these
|
297
|
-
exceptions have the same name as their counterparts from older releases, but
|
298
|
-
are located in the `Google::Cloud` namespace rather than the `Google::Gax`
|
299
|
-
namespace.
|
300
|
-
|
301
|
-
Old:
|
302
|
-
```
|
303
|
-
client = Google::Cloud::Vision::ImageAnnotator.new
|
304
|
-
|
305
|
-
requests = my_create_requests
|
306
|
-
|
307
|
-
begin
|
308
|
-
response = client.batch_annotate_images requests
|
309
|
-
rescue Google::Gax::Error => e
|
310
|
-
# Handle exceptions that subclass Google::Gax::Error
|
311
|
-
end
|
312
|
-
```
|
313
|
-
|
314
|
-
New:
|
315
|
-
```
|
316
|
-
client = Google::Cloud::Vision.image_annotator
|
317
|
-
|
318
|
-
requests = my_create_requests
|
319
|
-
|
320
|
-
begin
|
321
|
-
response = client.batch_annotate_images requests: requests
|
322
|
-
rescue Google::Cloud::Error => e
|
323
|
-
# Handle exceptions that subclass Google::Cloud::Error
|
324
|
-
end
|
325
|
-
```
|
326
|
-
|
327
|
-
### Class Namespaces
|
328
|
-
|
329
|
-
In older releases, the client object was of classes with names like:
|
330
|
-
`Google::Cloud::Vision::V1::ProductSearchClient`.
|
331
|
-
In the 1.0 release, the client object is of a different class:
|
332
|
-
`Google::Cloud::Vision::V1::ProductSearch::Client`.
|
333
|
-
Note that most users will use the factory methods such as
|
334
|
-
`Google::Cloud::Vision.product_search` to create instances of the client object,
|
335
|
-
so you may not need to reference the actual class directly.
|
336
|
-
See [Creating Clients](#creating-clients).
|
337
|
-
|
338
|
-
In older releases, the credentials object was of class
|
339
|
-
`Google::Cloud::Vision::V1::Credentials`.
|
340
|
-
In the 1.0 release, each service has its own credentials class, e.g.
|
341
|
-
`Google::Cloud::Vision::V1::ProductSearch::Credentials`.
|
342
|
-
Again, most users will not need to reference this class directly.
|
343
|
-
See [Client Configuration](#client-configuration).
|