google-cloud-vision 0.32.2 → 1.1.3

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.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +4 -2
  3. data/AUTHENTICATION.md +151 -0
  4. data/LICENSE.md +201 -0
  5. data/MIGRATING.md +343 -0
  6. data/README.md +97 -52
  7. data/lib/google/cloud/vision/{v1/doc/google/protobuf/empty.rb → version.rb} +10 -13
  8. data/lib/google/cloud/vision.rb +132 -207
  9. data/lib/{google/cloud/vision/v1p3beta1/doc/google/protobuf/empty.rb → google-cloud-vision.rb} +5 -15
  10. metadata +108 -83
  11. data/LICENSE +0 -201
  12. data/lib/google/cloud/vision/v1/credentials.rb +0 -42
  13. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/geometry.rb +0 -66
  14. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/image_annotator.rb +0 -763
  15. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/product_search.rb +0 -88
  16. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/product_search_service.rb +0 -539
  17. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/text_annotation.rb +0 -254
  18. data/lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/web_detection.rb +0 -102
  19. data/lib/google/cloud/vision/v1/doc/google/longrunning/operations.rb +0 -93
  20. data/lib/google/cloud/vision/v1/doc/google/protobuf/any.rb +0 -130
  21. data/lib/google/cloud/vision/v1/doc/google/protobuf/field_mask.rb +0 -230
  22. data/lib/google/cloud/vision/v1/doc/google/protobuf/timestamp.rb +0 -109
  23. data/lib/google/cloud/vision/v1/doc/google/protobuf/wrappers.rb +0 -90
  24. data/lib/google/cloud/vision/v1/doc/google/rpc/status.rb +0 -84
  25. data/lib/google/cloud/vision/v1/doc/google/type/color.rb +0 -156
  26. data/lib/google/cloud/vision/v1/doc/google/type/latlng.rb +0 -65
  27. data/lib/google/cloud/vision/v1/geometry_pb.rb +0 -39
  28. data/lib/google/cloud/vision/v1/helpers.rb +0 -1154
  29. data/lib/google/cloud/vision/v1/image_annotator_client.rb +0 -302
  30. data/lib/google/cloud/vision/v1/image_annotator_client_config.json +0 -36
  31. data/lib/google/cloud/vision/v1/image_annotator_pb.rb +0 -305
  32. data/lib/google/cloud/vision/v1/image_annotator_services_pb.rb +0 -56
  33. data/lib/google/cloud/vision/v1/product_search_client.rb +0 -1337
  34. data/lib/google/cloud/vision/v1/product_search_client_config.json +0 -116
  35. data/lib/google/cloud/vision/v1/product_search_pb.rb +0 -45
  36. data/lib/google/cloud/vision/v1/product_search_service_pb.rb +0 -191
  37. data/lib/google/cloud/vision/v1/product_search_service_services_pb.rb +0 -224
  38. data/lib/google/cloud/vision/v1/text_annotation_pb.rb +0 -94
  39. data/lib/google/cloud/vision/v1/web_detection_pb.rb +0 -51
  40. data/lib/google/cloud/vision/v1.rb +0 -233
  41. data/lib/google/cloud/vision/v1p3beta1/credentials.rb +0 -42
  42. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/geometry.rb +0 -72
  43. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/image_annotator.rb +0 -763
  44. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/product_search.rb +0 -154
  45. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/product_search_service.rb +0 -533
  46. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/text_annotation.rb +0 -254
  47. data/lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/web_detection.rb +0 -101
  48. data/lib/google/cloud/vision/v1p3beta1/doc/google/longrunning/operations.rb +0 -93
  49. data/lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/any.rb +0 -130
  50. data/lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/field_mask.rb +0 -230
  51. data/lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/timestamp.rb +0 -109
  52. data/lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/wrappers.rb +0 -90
  53. data/lib/google/cloud/vision/v1p3beta1/doc/google/rpc/status.rb +0 -84
  54. data/lib/google/cloud/vision/v1p3beta1/doc/google/type/color.rb +0 -156
  55. data/lib/google/cloud/vision/v1p3beta1/doc/google/type/latlng.rb +0 -65
  56. data/lib/google/cloud/vision/v1p3beta1/geometry_pb.rb +0 -43
  57. data/lib/google/cloud/vision/v1p3beta1/helpers.rb +0 -1154
  58. data/lib/google/cloud/vision/v1p3beta1/image_annotator_client.rb +0 -302
  59. data/lib/google/cloud/vision/v1p3beta1/image_annotator_client_config.json +0 -36
  60. data/lib/google/cloud/vision/v1p3beta1/image_annotator_pb.rb +0 -304
  61. data/lib/google/cloud/vision/v1p3beta1/image_annotator_services_pb.rb +0 -55
  62. data/lib/google/cloud/vision/v1p3beta1/product_search_client.rb +0 -1351
  63. data/lib/google/cloud/vision/v1p3beta1/product_search_client_config.json +0 -116
  64. data/lib/google/cloud/vision/v1p3beta1/product_search_pb.rb +0 -64
  65. data/lib/google/cloud/vision/v1p3beta1/product_search_service_pb.rb +0 -191
  66. data/lib/google/cloud/vision/v1p3beta1/product_search_service_services_pb.rb +0 -222
  67. data/lib/google/cloud/vision/v1p3beta1/text_annotation_pb.rb +0 -94
  68. data/lib/google/cloud/vision/v1p3beta1/web_detection_pb.rb +0 -51
  69. data/lib/google/cloud/vision/v1p3beta1.rb +0 -233
metadata CHANGED
@@ -1,71 +1,153 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-vision
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.32.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-12-14 00:00:00.000000000 Z
11
+ date: 2022-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: google-gax
14
+ name: google-cloud-core
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.3'
19
+ version: '1.6'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.3'
26
+ version: '1.6'
27
+ - !ruby/object:Gem::Dependency
28
+ name: google-cloud-vision-v1
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0.0'
34
+ - - "<"
35
+ - !ruby/object:Gem::Version
36
+ version: 2.a
37
+ type: :runtime
38
+ prerelease: false
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: '0.0'
44
+ - - "<"
45
+ - !ruby/object:Gem::Version
46
+ version: 2.a
47
+ - !ruby/object:Gem::Dependency
48
+ name: google-cloud-vision-v1p3beta1
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: '0.0'
54
+ - - "<"
55
+ - !ruby/object:Gem::Version
56
+ version: 2.a
57
+ type: :runtime
58
+ prerelease: false
59
+ version_requirements: !ruby/object:Gem::Requirement
60
+ requirements:
61
+ - - ">="
62
+ - !ruby/object:Gem::Version
63
+ version: '0.0'
64
+ - - "<"
65
+ - !ruby/object:Gem::Version
66
+ version: 2.a
67
+ - !ruby/object:Gem::Dependency
68
+ name: google-style
69
+ requirement: !ruby/object:Gem::Requirement
70
+ requirements:
71
+ - - "~>"
72
+ - !ruby/object:Gem::Version
73
+ version: 1.25.1
74
+ type: :development
75
+ prerelease: false
76
+ version_requirements: !ruby/object:Gem::Requirement
77
+ requirements:
78
+ - - "~>"
79
+ - !ruby/object:Gem::Version
80
+ version: 1.25.1
27
81
  - !ruby/object:Gem::Dependency
28
82
  name: minitest
29
83
  requirement: !ruby/object:Gem::Requirement
30
84
  requirements:
31
85
  - - "~>"
32
86
  - !ruby/object:Gem::Version
33
- version: '5.10'
87
+ version: '5.14'
34
88
  type: :development
35
89
  prerelease: false
36
90
  version_requirements: !ruby/object:Gem::Requirement
37
91
  requirements:
38
92
  - - "~>"
39
93
  - !ruby/object:Gem::Version
40
- version: '5.10'
94
+ version: '5.14'
41
95
  - !ruby/object:Gem::Dependency
42
- name: redcarpet
96
+ name: minitest-focus
43
97
  requirement: !ruby/object:Gem::Requirement
44
98
  requirements:
45
99
  - - "~>"
46
100
  - !ruby/object:Gem::Version
47
- version: '3.0'
101
+ version: '1.1'
48
102
  type: :development
49
103
  prerelease: false
50
104
  version_requirements: !ruby/object:Gem::Requirement
51
105
  requirements:
52
106
  - - "~>"
53
107
  - !ruby/object:Gem::Version
54
- version: '3.0'
108
+ version: '1.1'
55
109
  - !ruby/object:Gem::Dependency
56
- name: rubocop
110
+ name: minitest-rg
57
111
  requirement: !ruby/object:Gem::Requirement
58
112
  requirements:
59
113
  - - "~>"
60
114
  - !ruby/object:Gem::Version
61
- version: 0.59.2
115
+ version: '5.2'
62
116
  type: :development
63
117
  prerelease: false
64
118
  version_requirements: !ruby/object:Gem::Requirement
65
119
  requirements:
66
120
  - - "~>"
67
121
  - !ruby/object:Gem::Version
68
- version: 0.59.2
122
+ version: '5.2'
123
+ - !ruby/object:Gem::Dependency
124
+ name: rake
125
+ requirement: !ruby/object:Gem::Requirement
126
+ requirements:
127
+ - - ">="
128
+ - !ruby/object:Gem::Version
129
+ version: '12.0'
130
+ type: :development
131
+ prerelease: false
132
+ version_requirements: !ruby/object:Gem::Requirement
133
+ requirements:
134
+ - - ">="
135
+ - !ruby/object:Gem::Version
136
+ version: '12.0'
137
+ - !ruby/object:Gem::Dependency
138
+ name: redcarpet
139
+ requirement: !ruby/object:Gem::Requirement
140
+ requirements:
141
+ - - "~>"
142
+ - !ruby/object:Gem::Version
143
+ version: '3.0'
144
+ type: :development
145
+ prerelease: false
146
+ version_requirements: !ruby/object:Gem::Requirement
147
+ requirements:
148
+ - - "~>"
149
+ - !ruby/object:Gem::Version
150
+ version: '3.0'
69
151
  - !ruby/object:Gem::Dependency
70
152
  name: simplecov
71
153
  requirement: !ruby/object:Gem::Requirement
@@ -94,83 +176,27 @@ dependencies:
94
176
  - - "~>"
95
177
  - !ruby/object:Gem::Version
96
178
  version: '0.9'
97
- description: google-cloud-vision is the official library for Cloud Vision API.
179
+ description: Cloud Vision API allows developers to easily integrate vision detection
180
+ features within applications, including image labeling, face and landmark detection,
181
+ optical character recognition (OCR), and tagging of explicit content.
98
182
  email: googleapis-packages@google.com
99
183
  executables: []
100
184
  extensions: []
101
185
  extra_rdoc_files: []
102
186
  files:
103
187
  - ".yardopts"
104
- - LICENSE
188
+ - AUTHENTICATION.md
189
+ - LICENSE.md
190
+ - MIGRATING.md
105
191
  - README.md
192
+ - lib/google-cloud-vision.rb
106
193
  - lib/google/cloud/vision.rb
107
- - lib/google/cloud/vision/v1.rb
108
- - lib/google/cloud/vision/v1/credentials.rb
109
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/geometry.rb
110
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/image_annotator.rb
111
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/product_search.rb
112
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/product_search_service.rb
113
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/text_annotation.rb
114
- - lib/google/cloud/vision/v1/doc/google/cloud/vision/v1/web_detection.rb
115
- - lib/google/cloud/vision/v1/doc/google/longrunning/operations.rb
116
- - lib/google/cloud/vision/v1/doc/google/protobuf/any.rb
117
- - lib/google/cloud/vision/v1/doc/google/protobuf/empty.rb
118
- - lib/google/cloud/vision/v1/doc/google/protobuf/field_mask.rb
119
- - lib/google/cloud/vision/v1/doc/google/protobuf/timestamp.rb
120
- - lib/google/cloud/vision/v1/doc/google/protobuf/wrappers.rb
121
- - lib/google/cloud/vision/v1/doc/google/rpc/status.rb
122
- - lib/google/cloud/vision/v1/doc/google/type/color.rb
123
- - lib/google/cloud/vision/v1/doc/google/type/latlng.rb
124
- - lib/google/cloud/vision/v1/geometry_pb.rb
125
- - lib/google/cloud/vision/v1/helpers.rb
126
- - lib/google/cloud/vision/v1/image_annotator_client.rb
127
- - lib/google/cloud/vision/v1/image_annotator_client_config.json
128
- - lib/google/cloud/vision/v1/image_annotator_pb.rb
129
- - lib/google/cloud/vision/v1/image_annotator_services_pb.rb
130
- - lib/google/cloud/vision/v1/product_search_client.rb
131
- - lib/google/cloud/vision/v1/product_search_client_config.json
132
- - lib/google/cloud/vision/v1/product_search_pb.rb
133
- - lib/google/cloud/vision/v1/product_search_service_pb.rb
134
- - lib/google/cloud/vision/v1/product_search_service_services_pb.rb
135
- - lib/google/cloud/vision/v1/text_annotation_pb.rb
136
- - lib/google/cloud/vision/v1/web_detection_pb.rb
137
- - lib/google/cloud/vision/v1p3beta1.rb
138
- - lib/google/cloud/vision/v1p3beta1/credentials.rb
139
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/geometry.rb
140
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/image_annotator.rb
141
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/product_search.rb
142
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/product_search_service.rb
143
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/text_annotation.rb
144
- - lib/google/cloud/vision/v1p3beta1/doc/google/cloud/vision/v1p3beta1/web_detection.rb
145
- - lib/google/cloud/vision/v1p3beta1/doc/google/longrunning/operations.rb
146
- - lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/any.rb
147
- - lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/empty.rb
148
- - lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/field_mask.rb
149
- - lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/timestamp.rb
150
- - lib/google/cloud/vision/v1p3beta1/doc/google/protobuf/wrappers.rb
151
- - lib/google/cloud/vision/v1p3beta1/doc/google/rpc/status.rb
152
- - lib/google/cloud/vision/v1p3beta1/doc/google/type/color.rb
153
- - lib/google/cloud/vision/v1p3beta1/doc/google/type/latlng.rb
154
- - lib/google/cloud/vision/v1p3beta1/geometry_pb.rb
155
- - lib/google/cloud/vision/v1p3beta1/helpers.rb
156
- - lib/google/cloud/vision/v1p3beta1/image_annotator_client.rb
157
- - lib/google/cloud/vision/v1p3beta1/image_annotator_client_config.json
158
- - lib/google/cloud/vision/v1p3beta1/image_annotator_pb.rb
159
- - lib/google/cloud/vision/v1p3beta1/image_annotator_services_pb.rb
160
- - lib/google/cloud/vision/v1p3beta1/product_search_client.rb
161
- - lib/google/cloud/vision/v1p3beta1/product_search_client_config.json
162
- - lib/google/cloud/vision/v1p3beta1/product_search_pb.rb
163
- - lib/google/cloud/vision/v1p3beta1/product_search_service_pb.rb
164
- - lib/google/cloud/vision/v1p3beta1/product_search_service_services_pb.rb
165
- - lib/google/cloud/vision/v1p3beta1/text_annotation_pb.rb
166
- - lib/google/cloud/vision/v1p3beta1/web_detection_pb.rb
167
- homepage: https://github.com/googleapis/google-cloud-ruby/tree/master/google-cloud-vision
194
+ - lib/google/cloud/vision/version.rb
195
+ homepage: https://github.com/googleapis/google-cloud-ruby
168
196
  licenses:
169
197
  - Apache-2.0
170
198
  metadata: {}
171
- post_install_message: 'The 0.32.0 release introduced breaking changes relative to
172
- the previous release, 0.31.0. For more details and instructions to migrate your
173
- code, please visit the migration guide: https://cloud.google.com/vision/docs/ruby-client-migration.'
199
+ post_install_message:
174
200
  rdoc_options: []
175
201
  require_paths:
176
202
  - lib
@@ -178,16 +204,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
178
204
  requirements:
179
205
  - - ">="
180
206
  - !ruby/object:Gem::Version
181
- version: 2.0.0
207
+ version: '2.5'
182
208
  required_rubygems_version: !ruby/object:Gem::Requirement
183
209
  requirements:
184
210
  - - ">="
185
211
  - !ruby/object:Gem::Version
186
212
  version: '0'
187
213
  requirements: []
188
- rubyforge_project:
189
- rubygems_version: 2.7.7
214
+ rubygems_version: 3.3.4
190
215
  signing_key:
191
216
  specification_version: 4
192
- summary: API Client library for Cloud Vision API
217
+ summary: API Client library for the Cloud Vision API
193
218
  test_files: []
data/LICENSE DELETED
@@ -1,201 +0,0 @@
1
- Apache License
2
- Version 2.0, January 2004
3
- https://www.apache.org/licenses/
4
-
5
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
-
7
- 1. Definitions.
8
-
9
- "License" shall mean the terms and conditions for use, reproduction,
10
- and distribution as defined by Sections 1 through 9 of this document.
11
-
12
- "Licensor" shall mean the copyright owner or entity authorized by
13
- the copyright owner that is granting the License.
14
-
15
- "Legal Entity" shall mean the union of the acting entity and all
16
- other entities that control, are controlled by, or are under common
17
- control with that entity. For the purposes of this definition,
18
- "control" means (i) the power, direct or indirect, to cause the
19
- direction or management of such entity, whether by contract or
20
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
- outstanding shares, or (iii) beneficial ownership of such entity.
22
-
23
- "You" (or "Your") shall mean an individual or Legal Entity
24
- exercising permissions granted by this License.
25
-
26
- "Source" form shall mean the preferred form for making modifications,
27
- including but not limited to software source code, documentation
28
- source, and configuration files.
29
-
30
- "Object" form shall mean any form resulting from mechanical
31
- transformation or translation of a Source form, including but
32
- not limited to compiled object code, generated documentation,
33
- and conversions to other media types.
34
-
35
- "Work" shall mean the work of authorship, whether in Source or
36
- Object form, made available under the License, as indicated by a
37
- copyright notice that is included in or attached to the work
38
- (an example is provided in the Appendix below).
39
-
40
- "Derivative Works" shall mean any work, whether in Source or Object
41
- form, that is based on (or derived from) the Work and for which the
42
- editorial revisions, annotations, elaborations, or other modifications
43
- represent, as a whole, an original work of authorship. For the purposes
44
- of this License, Derivative Works shall not include works that remain
45
- separable from, or merely link (or bind by name) to the interfaces of,
46
- the Work and Derivative Works thereof.
47
-
48
- "Contribution" shall mean any work of authorship, including
49
- the original version of the Work and any modifications or additions
50
- to that Work or Derivative Works thereof, that is intentionally
51
- submitted to Licensor for inclusion in the Work by the copyright owner
52
- or by an individual or Legal Entity authorized to submit on behalf of
53
- the copyright owner. For the purposes of this definition, "submitted"
54
- means any form of electronic, verbal, or written communication sent
55
- to the Licensor or its representatives, including but not limited to
56
- communication on electronic mailing lists, source code control systems,
57
- and issue tracking systems that are managed by, or on behalf of, the
58
- Licensor for the purpose of discussing and improving the Work, but
59
- excluding communication that is conspicuously marked or otherwise
60
- designated in writing by the copyright owner as "Not a Contribution."
61
-
62
- "Contributor" shall mean Licensor and any individual or Legal Entity
63
- on behalf of whom a Contribution has been received by Licensor and
64
- subsequently incorporated within the Work.
65
-
66
- 2. Grant of Copyright License. Subject to the terms and conditions of
67
- this License, each Contributor hereby grants to You a perpetual,
68
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
- copyright license to reproduce, prepare Derivative Works of,
70
- publicly display, publicly perform, sublicense, and distribute the
71
- Work and such Derivative Works in Source or Object form.
72
-
73
- 3. Grant of Patent License. Subject to the terms and conditions of
74
- this License, each Contributor hereby grants to You a perpetual,
75
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
- (except as stated in this section) patent license to make, have made,
77
- use, offer to sell, sell, import, and otherwise transfer the Work,
78
- where such license applies only to those patent claims licensable
79
- by such Contributor that are necessarily infringed by their
80
- Contribution(s) alone or by combination of their Contribution(s)
81
- with the Work to which such Contribution(s) was submitted. If You
82
- institute patent litigation against any entity (including a
83
- cross-claim or counterclaim in a lawsuit) alleging that the Work
84
- or a Contribution incorporated within the Work constitutes direct
85
- or contributory patent infringement, then any patent licenses
86
- granted to You under this License for that Work shall terminate
87
- as of the date such litigation is filed.
88
-
89
- 4. Redistribution. You may reproduce and distribute copies of the
90
- Work or Derivative Works thereof in any medium, with or without
91
- modifications, and in Source or Object form, provided that You
92
- meet the following conditions:
93
-
94
- (a) You must give any other recipients of the Work or
95
- Derivative Works a copy of this License; and
96
-
97
- (b) You must cause any modified files to carry prominent notices
98
- stating that You changed the files; and
99
-
100
- (c) You must retain, in the Source form of any Derivative Works
101
- that You distribute, all copyright, patent, trademark, and
102
- attribution notices from the Source form of the Work,
103
- excluding those notices that do not pertain to any part of
104
- the Derivative Works; and
105
-
106
- (d) If the Work includes a "NOTICE" text file as part of its
107
- distribution, then any Derivative Works that You distribute must
108
- include a readable copy of the attribution notices contained
109
- within such NOTICE file, excluding those notices that do not
110
- pertain to any part of the Derivative Works, in at least one
111
- of the following places: within a NOTICE text file distributed
112
- as part of the Derivative Works; within the Source form or
113
- documentation, if provided along with the Derivative Works; or,
114
- within a display generated by the Derivative Works, if and
115
- wherever such third-party notices normally appear. The contents
116
- of the NOTICE file are for informational purposes only and
117
- do not modify the License. You may add Your own attribution
118
- notices within Derivative Works that You distribute, alongside
119
- or as an addendum to the NOTICE text from the Work, provided
120
- that such additional attribution notices cannot be construed
121
- as modifying the License.
122
-
123
- You may add Your own copyright statement to Your modifications and
124
- may provide additional or different license terms and conditions
125
- for use, reproduction, or distribution of Your modifications, or
126
- for any such Derivative Works as a whole, provided Your use,
127
- reproduction, and distribution of the Work otherwise complies with
128
- the conditions stated in this License.
129
-
130
- 5. Submission of Contributions. Unless You explicitly state otherwise,
131
- any Contribution intentionally submitted for inclusion in the Work
132
- by You to the Licensor shall be under the terms and conditions of
133
- this License, without any additional terms or conditions.
134
- Notwithstanding the above, nothing herein shall supersede or modify
135
- the terms of any separate license agreement you may have executed
136
- with Licensor regarding such Contributions.
137
-
138
- 6. Trademarks. This License does not grant permission to use the trade
139
- names, trademarks, service marks, or product names of the Licensor,
140
- except as required for reasonable and customary use in describing the
141
- origin of the Work and reproducing the content of the NOTICE file.
142
-
143
- 7. Disclaimer of Warranty. Unless required by applicable law or
144
- agreed to in writing, Licensor provides the Work (and each
145
- Contributor provides its Contributions) on an "AS IS" BASIS,
146
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
- implied, including, without limitation, any warranties or conditions
148
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
- PARTICULAR PURPOSE. You are solely responsible for determining the
150
- appropriateness of using or redistributing the Work and assume any
151
- risks associated with Your exercise of permissions under this License.
152
-
153
- 8. Limitation of Liability. In no event and under no legal theory,
154
- whether in tort (including negligence), contract, or otherwise,
155
- unless required by applicable law (such as deliberate and grossly
156
- negligent acts) or agreed to in writing, shall any Contributor be
157
- liable to You for damages, including any direct, indirect, special,
158
- incidental, or consequential damages of any character arising as a
159
- result of this License or out of the use or inability to use the
160
- Work (including but not limited to damages for loss of goodwill,
161
- work stoppage, computer failure or malfunction, or any and all
162
- other commercial damages or losses), even if such Contributor
163
- has been advised of the possibility of such damages.
164
-
165
- 9. Accepting Warranty or Additional Liability. While redistributing
166
- the Work or Derivative Works thereof, You may choose to offer,
167
- and charge a fee for, acceptance of support, warranty, indemnity,
168
- or other liability obligations and/or rights consistent with this
169
- License. However, in accepting such obligations, You may act only
170
- on Your own behalf and on Your sole responsibility, not on behalf
171
- of any other Contributor, and only if You agree to indemnify,
172
- defend, and hold each Contributor harmless for any liability
173
- incurred by, or claims asserted against, such Contributor by reason
174
- of your accepting any such warranty or additional liability.
175
-
176
- END OF TERMS AND CONDITIONS
177
-
178
- APPENDIX: How to apply the Apache License to your work.
179
-
180
- To apply the Apache License to your work, attach the following
181
- boilerplate notice, with the fields enclosed by brackets "[]"
182
- replaced with your own identifying information. (Don't include
183
- the brackets!) The text should be enclosed in the appropriate
184
- comment syntax for the file format. We also recommend that a
185
- file or class name and description of purpose be included on the
186
- same "printed page" as the copyright notice for easier
187
- identification within third-party archives.
188
-
189
- Copyright [yyyy] [name of copyright owner]
190
-
191
- Licensed under the Apache License, Version 2.0 (the "License");
192
- you may not use this file except in compliance with the License.
193
- You may obtain a copy of the License at
194
-
195
- https://www.apache.org/licenses/LICENSE-2.0
196
-
197
- Unless required by applicable law or agreed to in writing, software
198
- distributed under the License is distributed on an "AS IS" BASIS,
199
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
- See the License for the specific language governing permissions and
201
- limitations under the License.
@@ -1,42 +0,0 @@
1
- # Copyright 2018 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
- # https://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
-
16
- require "googleauth"
17
-
18
- module Google
19
- module Cloud
20
- module Vision
21
- module V1
22
- class Credentials < Google::Auth::Credentials
23
- SCOPE = [
24
- "https://www.googleapis.com/auth/cloud-platform",
25
- "https://www.googleapis.com/auth/cloud-vision"
26
- ].freeze
27
- PATH_ENV_VARS = %w(VISION_CREDENTIALS
28
- VISION_KEYFILE
29
- GOOGLE_CLOUD_CREDENTIALS
30
- GOOGLE_CLOUD_KEYFILE
31
- GCLOUD_KEYFILE)
32
- JSON_ENV_VARS = %w(VISION_CREDENTIALS_JSON
33
- VISION_KEYFILE_JSON
34
- GOOGLE_CLOUD_CREDENTIALS_JSON
35
- GOOGLE_CLOUD_KEYFILE_JSON
36
- GCLOUD_KEYFILE_JSON)
37
- DEFAULT_PATHS = ["~/.config/gcloud/application_default_credentials.json"]
38
- end
39
- end
40
- end
41
- end
42
- end
@@ -1,66 +0,0 @@
1
- # Copyright 2018 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
- # https://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
-
16
- module Google
17
- module Cloud
18
- module Vision
19
- module V1
20
- # A vertex represents a 2D point in the image.
21
- # NOTE: the vertex coordinates are in the same scale as the original image.
22
- # @!attribute [rw] x
23
- # @return [Integer]
24
- # X coordinate.
25
- # @!attribute [rw] y
26
- # @return [Integer]
27
- # Y coordinate.
28
- class Vertex; end
29
-
30
- # A vertex represents a 2D point in the image.
31
- # NOTE: the normalized vertex coordinates are relative to the original image
32
- # and range from 0 to 1.
33
- # @!attribute [rw] x
34
- # @return [Float]
35
- # X coordinate.
36
- # @!attribute [rw] y
37
- # @return [Float]
38
- # Y coordinate.
39
- class NormalizedVertex; end
40
-
41
- # A bounding polygon for the detected image annotation.
42
- # @!attribute [rw] vertices
43
- # @return [Array<Google::Cloud::Vision::V1::Vertex>]
44
- # The bounding polygon vertices.
45
- # @!attribute [rw] normalized_vertices
46
- # @return [Array<Google::Cloud::Vision::V1::NormalizedVertex>]
47
- # The bounding polygon normalized vertices.
48
- class BoundingPoly; end
49
-
50
- # A 3D position in the image, used primarily for Face detection landmarks.
51
- # A valid Position must have both x and y coordinates.
52
- # The position coordinates are in the same scale as the original image.
53
- # @!attribute [rw] x
54
- # @return [Float]
55
- # X coordinate.
56
- # @!attribute [rw] y
57
- # @return [Float]
58
- # Y coordinate.
59
- # @!attribute [rw] z
60
- # @return [Float]
61
- # Z coordinate (or depth).
62
- class Position; end
63
- end
64
- end
65
- end
66
- end