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
@@ -1,116 +0,0 @@
1
- {
2
- "interfaces": {
3
- "google.cloud.vision.v1p3beta1.ProductSearch": {
4
- "retry_codes": {
5
- "idempotent": [
6
- "DEADLINE_EXCEEDED",
7
- "UNAVAILABLE"
8
- ],
9
- "non_idempotent": []
10
- },
11
- "retry_params": {
12
- "default": {
13
- "initial_retry_delay_millis": 100,
14
- "retry_delay_multiplier": 1.3,
15
- "max_retry_delay_millis": 60000,
16
- "initial_rpc_timeout_millis": 20000,
17
- "rpc_timeout_multiplier": 1.0,
18
- "max_rpc_timeout_millis": 20000,
19
- "total_timeout_millis": 600000
20
- }
21
- },
22
- "methods": {
23
- "CreateProductSet": {
24
- "timeout_millis": 60000,
25
- "retry_codes_name": "non_idempotent",
26
- "retry_params_name": "default"
27
- },
28
- "ListProductSets": {
29
- "timeout_millis": 60000,
30
- "retry_codes_name": "idempotent",
31
- "retry_params_name": "default"
32
- },
33
- "GetProductSet": {
34
- "timeout_millis": 60000,
35
- "retry_codes_name": "idempotent",
36
- "retry_params_name": "default"
37
- },
38
- "UpdateProductSet": {
39
- "timeout_millis": 60000,
40
- "retry_codes_name": "non_idempotent",
41
- "retry_params_name": "default"
42
- },
43
- "DeleteProductSet": {
44
- "timeout_millis": 60000,
45
- "retry_codes_name": "idempotent",
46
- "retry_params_name": "default"
47
- },
48
- "CreateProduct": {
49
- "timeout_millis": 60000,
50
- "retry_codes_name": "non_idempotent",
51
- "retry_params_name": "default"
52
- },
53
- "ListProducts": {
54
- "timeout_millis": 60000,
55
- "retry_codes_name": "idempotent",
56
- "retry_params_name": "default"
57
- },
58
- "GetProduct": {
59
- "timeout_millis": 60000,
60
- "retry_codes_name": "idempotent",
61
- "retry_params_name": "default"
62
- },
63
- "UpdateProduct": {
64
- "timeout_millis": 60000,
65
- "retry_codes_name": "non_idempotent",
66
- "retry_params_name": "default"
67
- },
68
- "DeleteProduct": {
69
- "timeout_millis": 60000,
70
- "retry_codes_name": "idempotent",
71
- "retry_params_name": "default"
72
- },
73
- "CreateReferenceImage": {
74
- "timeout_millis": 60000,
75
- "retry_codes_name": "non_idempotent",
76
- "retry_params_name": "default"
77
- },
78
- "DeleteReferenceImage": {
79
- "timeout_millis": 60000,
80
- "retry_codes_name": "idempotent",
81
- "retry_params_name": "default"
82
- },
83
- "ListReferenceImages": {
84
- "timeout_millis": 60000,
85
- "retry_codes_name": "idempotent",
86
- "retry_params_name": "default"
87
- },
88
- "GetReferenceImage": {
89
- "timeout_millis": 60000,
90
- "retry_codes_name": "idempotent",
91
- "retry_params_name": "default"
92
- },
93
- "AddProductToProductSet": {
94
- "timeout_millis": 60000,
95
- "retry_codes_name": "non_idempotent",
96
- "retry_params_name": "default"
97
- },
98
- "RemoveProductFromProductSet": {
99
- "timeout_millis": 60000,
100
- "retry_codes_name": "non_idempotent",
101
- "retry_params_name": "default"
102
- },
103
- "ListProductsInProductSet": {
104
- "timeout_millis": 60000,
105
- "retry_codes_name": "idempotent",
106
- "retry_params_name": "default"
107
- },
108
- "ImportProductSets": {
109
- "timeout_millis": 60000,
110
- "retry_codes_name": "non_idempotent",
111
- "retry_params_name": "default"
112
- }
113
- }
114
- }
115
- }
116
- }
@@ -1,64 +0,0 @@
1
- # Generated by the protocol buffer compiler. DO NOT EDIT!
2
- # source: google/cloud/vision/v1p3beta1/product_search.proto
3
-
4
-
5
- require 'google/protobuf'
6
-
7
- require 'google/api/annotations_pb'
8
- require 'google/cloud/vision/v1p3beta1/geometry_pb'
9
- require 'google/cloud/vision/v1p3beta1/product_search_service_pb'
10
- require 'google/protobuf/timestamp_pb'
11
- Google::Protobuf::DescriptorPool.generated_pool.build do
12
- add_message "google.cloud.vision.v1p3beta1.ProductSearchParams" do
13
- optional :catalog_name, :string, 1
14
- optional :category, :enum, 2, "google.cloud.vision.v1p3beta1.ProductSearchCategory"
15
- optional :product_category, :string, 5
16
- optional :normalized_bounding_poly, :message, 3, "google.cloud.vision.v1p3beta1.NormalizedBoundingPoly"
17
- optional :bounding_poly, :message, 9, "google.cloud.vision.v1p3beta1.BoundingPoly"
18
- optional :view, :enum, 4, "google.cloud.vision.v1p3beta1.ProductSearchResultsView"
19
- optional :product_set, :string, 6
20
- repeated :product_categories, :string, 7
21
- optional :filter, :string, 8
22
- end
23
- add_message "google.cloud.vision.v1p3beta1.ProductSearchResults" do
24
- optional :category, :enum, 1, "google.cloud.vision.v1p3beta1.ProductSearchCategory"
25
- optional :product_category, :string, 4
26
- optional :index_time, :message, 2, "google.protobuf.Timestamp"
27
- repeated :products, :message, 3, "google.cloud.vision.v1p3beta1.ProductSearchResults.ProductInfo"
28
- repeated :results, :message, 5, "google.cloud.vision.v1p3beta1.ProductSearchResults.Result"
29
- end
30
- add_message "google.cloud.vision.v1p3beta1.ProductSearchResults.ProductInfo" do
31
- optional :product_id, :string, 1
32
- optional :image_uri, :string, 2
33
- optional :score, :float, 3
34
- end
35
- add_message "google.cloud.vision.v1p3beta1.ProductSearchResults.Result" do
36
- optional :product, :message, 1, "google.cloud.vision.v1p3beta1.Product"
37
- optional :score, :float, 2
38
- optional :image, :string, 3
39
- end
40
- add_enum "google.cloud.vision.v1p3beta1.ProductSearchCategory" do
41
- value :PRODUCT_SEARCH_CATEGORY_UNSPECIFIED, 0
42
- value :SHOES, 1
43
- value :BAGS, 2
44
- end
45
- add_enum "google.cloud.vision.v1p3beta1.ProductSearchResultsView" do
46
- value :BASIC, 0
47
- value :FULL, 1
48
- end
49
- end
50
-
51
- module Google
52
- module Cloud
53
- module Vision
54
- module V1p3beta1
55
- ProductSearchParams = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchParams").msgclass
56
- ProductSearchResults = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchResults").msgclass
57
- ProductSearchResults::ProductInfo = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchResults.ProductInfo").msgclass
58
- ProductSearchResults::Result = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchResults.Result").msgclass
59
- ProductSearchCategory = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchCategory").enummodule
60
- ProductSearchResultsView = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSearchResultsView").enummodule
61
- end
62
- end
63
- end
64
- end
@@ -1,191 +0,0 @@
1
- # Generated by the protocol buffer compiler. DO NOT EDIT!
2
- # source: google/cloud/vision/v1p3beta1/product_search_service.proto
3
-
4
-
5
- require 'google/protobuf'
6
-
7
- require 'google/api/annotations_pb'
8
- require 'google/cloud/vision/v1p3beta1/geometry_pb'
9
- require 'google/longrunning/operations_pb'
10
- require 'google/protobuf/empty_pb'
11
- require 'google/protobuf/field_mask_pb'
12
- require 'google/protobuf/timestamp_pb'
13
- require 'google/rpc/status_pb'
14
- Google::Protobuf::DescriptorPool.generated_pool.build do
15
- add_message "google.cloud.vision.v1p3beta1.Product" do
16
- optional :name, :string, 1
17
- optional :display_name, :string, 2
18
- optional :description, :string, 3
19
- optional :product_category, :string, 4
20
- repeated :product_labels, :message, 5, "google.cloud.vision.v1p3beta1.Product.KeyValue"
21
- end
22
- add_message "google.cloud.vision.v1p3beta1.Product.KeyValue" do
23
- optional :key, :string, 1
24
- optional :value, :string, 2
25
- end
26
- add_message "google.cloud.vision.v1p3beta1.ProductSet" do
27
- optional :name, :string, 1
28
- optional :display_name, :string, 2
29
- optional :index_time, :message, 3, "google.protobuf.Timestamp"
30
- optional :index_error, :message, 4, "google.rpc.Status"
31
- end
32
- add_message "google.cloud.vision.v1p3beta1.ReferenceImage" do
33
- optional :name, :string, 1
34
- optional :uri, :string, 2
35
- repeated :bounding_polys, :message, 3, "google.cloud.vision.v1p3beta1.BoundingPoly"
36
- end
37
- add_message "google.cloud.vision.v1p3beta1.CreateProductRequest" do
38
- optional :parent, :string, 1
39
- optional :product, :message, 2, "google.cloud.vision.v1p3beta1.Product"
40
- optional :product_id, :string, 3
41
- end
42
- add_message "google.cloud.vision.v1p3beta1.ListProductsRequest" do
43
- optional :parent, :string, 1
44
- optional :page_size, :int32, 2
45
- optional :page_token, :string, 3
46
- end
47
- add_message "google.cloud.vision.v1p3beta1.ListProductsResponse" do
48
- repeated :products, :message, 1, "google.cloud.vision.v1p3beta1.Product"
49
- optional :next_page_token, :string, 2
50
- end
51
- add_message "google.cloud.vision.v1p3beta1.GetProductRequest" do
52
- optional :name, :string, 1
53
- end
54
- add_message "google.cloud.vision.v1p3beta1.UpdateProductRequest" do
55
- optional :product, :message, 1, "google.cloud.vision.v1p3beta1.Product"
56
- optional :update_mask, :message, 2, "google.protobuf.FieldMask"
57
- end
58
- add_message "google.cloud.vision.v1p3beta1.DeleteProductRequest" do
59
- optional :name, :string, 1
60
- end
61
- add_message "google.cloud.vision.v1p3beta1.CreateProductSetRequest" do
62
- optional :parent, :string, 1
63
- optional :product_set, :message, 2, "google.cloud.vision.v1p3beta1.ProductSet"
64
- optional :product_set_id, :string, 3
65
- end
66
- add_message "google.cloud.vision.v1p3beta1.ListProductSetsRequest" do
67
- optional :parent, :string, 1
68
- optional :page_size, :int32, 2
69
- optional :page_token, :string, 3
70
- end
71
- add_message "google.cloud.vision.v1p3beta1.ListProductSetsResponse" do
72
- repeated :product_sets, :message, 1, "google.cloud.vision.v1p3beta1.ProductSet"
73
- optional :next_page_token, :string, 2
74
- end
75
- add_message "google.cloud.vision.v1p3beta1.GetProductSetRequest" do
76
- optional :name, :string, 1
77
- end
78
- add_message "google.cloud.vision.v1p3beta1.UpdateProductSetRequest" do
79
- optional :product_set, :message, 1, "google.cloud.vision.v1p3beta1.ProductSet"
80
- optional :update_mask, :message, 2, "google.protobuf.FieldMask"
81
- end
82
- add_message "google.cloud.vision.v1p3beta1.DeleteProductSetRequest" do
83
- optional :name, :string, 1
84
- end
85
- add_message "google.cloud.vision.v1p3beta1.CreateReferenceImageRequest" do
86
- optional :parent, :string, 1
87
- optional :reference_image, :message, 2, "google.cloud.vision.v1p3beta1.ReferenceImage"
88
- optional :reference_image_id, :string, 3
89
- end
90
- add_message "google.cloud.vision.v1p3beta1.ListReferenceImagesRequest" do
91
- optional :parent, :string, 1
92
- optional :page_size, :int32, 2
93
- optional :page_token, :string, 3
94
- end
95
- add_message "google.cloud.vision.v1p3beta1.ListReferenceImagesResponse" do
96
- repeated :reference_images, :message, 1, "google.cloud.vision.v1p3beta1.ReferenceImage"
97
- optional :page_size, :int32, 2
98
- optional :next_page_token, :string, 3
99
- end
100
- add_message "google.cloud.vision.v1p3beta1.GetReferenceImageRequest" do
101
- optional :name, :string, 1
102
- end
103
- add_message "google.cloud.vision.v1p3beta1.DeleteReferenceImageRequest" do
104
- optional :name, :string, 1
105
- end
106
- add_message "google.cloud.vision.v1p3beta1.AddProductToProductSetRequest" do
107
- optional :name, :string, 1
108
- optional :product, :string, 2
109
- end
110
- add_message "google.cloud.vision.v1p3beta1.RemoveProductFromProductSetRequest" do
111
- optional :name, :string, 1
112
- optional :product, :string, 2
113
- end
114
- add_message "google.cloud.vision.v1p3beta1.ListProductsInProductSetRequest" do
115
- optional :name, :string, 1
116
- optional :page_size, :int32, 2
117
- optional :page_token, :string, 3
118
- end
119
- add_message "google.cloud.vision.v1p3beta1.ListProductsInProductSetResponse" do
120
- repeated :products, :message, 1, "google.cloud.vision.v1p3beta1.Product"
121
- optional :next_page_token, :string, 2
122
- end
123
- add_message "google.cloud.vision.v1p3beta1.ImportProductSetsGcsSource" do
124
- optional :csv_file_uri, :string, 1
125
- end
126
- add_message "google.cloud.vision.v1p3beta1.ImportProductSetsInputConfig" do
127
- oneof :source do
128
- optional :gcs_source, :message, 1, "google.cloud.vision.v1p3beta1.ImportProductSetsGcsSource"
129
- end
130
- end
131
- add_message "google.cloud.vision.v1p3beta1.ImportProductSetsRequest" do
132
- optional :parent, :string, 1
133
- optional :input_config, :message, 2, "google.cloud.vision.v1p3beta1.ImportProductSetsInputConfig"
134
- end
135
- add_message "google.cloud.vision.v1p3beta1.ImportProductSetsResponse" do
136
- repeated :reference_images, :message, 1, "google.cloud.vision.v1p3beta1.ReferenceImage"
137
- repeated :statuses, :message, 2, "google.rpc.Status"
138
- end
139
- add_message "google.cloud.vision.v1p3beta1.BatchOperationMetadata" do
140
- optional :state, :enum, 1, "google.cloud.vision.v1p3beta1.BatchOperationMetadata.State"
141
- optional :submit_time, :message, 2, "google.protobuf.Timestamp"
142
- optional :end_time, :message, 3, "google.protobuf.Timestamp"
143
- end
144
- add_enum "google.cloud.vision.v1p3beta1.BatchOperationMetadata.State" do
145
- value :STATE_UNSPECIFIED, 0
146
- value :PROCESSING, 1
147
- value :SUCCESSFUL, 2
148
- value :FAILED, 3
149
- value :CANCELLED, 4
150
- end
151
- end
152
-
153
- module Google
154
- module Cloud
155
- module Vision
156
- module V1p3beta1
157
- Product = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.Product").msgclass
158
- Product::KeyValue = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.Product.KeyValue").msgclass
159
- ProductSet = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ProductSet").msgclass
160
- ReferenceImage = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ReferenceImage").msgclass
161
- CreateProductRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.CreateProductRequest").msgclass
162
- ListProductsRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductsRequest").msgclass
163
- ListProductsResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductsResponse").msgclass
164
- GetProductRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.GetProductRequest").msgclass
165
- UpdateProductRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.UpdateProductRequest").msgclass
166
- DeleteProductRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.DeleteProductRequest").msgclass
167
- CreateProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.CreateProductSetRequest").msgclass
168
- ListProductSetsRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductSetsRequest").msgclass
169
- ListProductSetsResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductSetsResponse").msgclass
170
- GetProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.GetProductSetRequest").msgclass
171
- UpdateProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.UpdateProductSetRequest").msgclass
172
- DeleteProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.DeleteProductSetRequest").msgclass
173
- CreateReferenceImageRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.CreateReferenceImageRequest").msgclass
174
- ListReferenceImagesRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListReferenceImagesRequest").msgclass
175
- ListReferenceImagesResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListReferenceImagesResponse").msgclass
176
- GetReferenceImageRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.GetReferenceImageRequest").msgclass
177
- DeleteReferenceImageRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.DeleteReferenceImageRequest").msgclass
178
- AddProductToProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.AddProductToProductSetRequest").msgclass
179
- RemoveProductFromProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.RemoveProductFromProductSetRequest").msgclass
180
- ListProductsInProductSetRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductsInProductSetRequest").msgclass
181
- ListProductsInProductSetResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ListProductsInProductSetResponse").msgclass
182
- ImportProductSetsGcsSource = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ImportProductSetsGcsSource").msgclass
183
- ImportProductSetsInputConfig = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ImportProductSetsInputConfig").msgclass
184
- ImportProductSetsRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ImportProductSetsRequest").msgclass
185
- ImportProductSetsResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.ImportProductSetsResponse").msgclass
186
- BatchOperationMetadata = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.BatchOperationMetadata").msgclass
187
- BatchOperationMetadata::State = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.vision.v1p3beta1.BatchOperationMetadata.State").enummodule
188
- end
189
- end
190
- end
191
- end
@@ -1,222 +0,0 @@
1
- # Generated by the protocol buffer compiler. DO NOT EDIT!
2
- # Source: google/cloud/vision/v1p3beta1/product_search_service.proto for package 'google.cloud.vision.v1p3beta1'
3
- # Original file comments:
4
- # Copyright 2018 Google Inc.
5
- #
6
- # Licensed under the Apache License, Version 2.0 (the "License");
7
- # you may not use this file except in compliance with the License.
8
- # You may obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
12
- # Unless required by applicable law or agreed to in writing, software
13
- # distributed under the License is distributed on an "AS IS" BASIS,
14
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- # See the License for the specific language governing permissions and
16
- # limitations under the License.
17
- #
18
-
19
-
20
- require 'grpc'
21
- require 'google/cloud/vision/v1p3beta1/product_search_service_pb'
22
-
23
- module Google
24
- module Cloud
25
- module Vision
26
- module V1p3beta1
27
- module ProductSearch
28
- # Manages Products and ProductSets of reference images for use in product
29
- # search. It uses the following resource model:
30
- #
31
- # - The API has a collection of [ProductSet][google.cloud.vision.v1p3beta1.ProductSet] resources, named
32
- # `projects/*/locations/*/productSets/*`, which acts as a way to put different
33
- # products into groups to limit identification.
34
- #
35
- # In parallel,
36
- #
37
- # - The API has a collection of [Product][google.cloud.vision.v1p3beta1.Product] resources, named
38
- # `projects/*/locations/*/products/*`
39
- #
40
- # - Each [Product][google.cloud.vision.v1p3beta1.Product] has a collection of [ReferenceImage][google.cloud.vision.v1p3beta1.ReferenceImage] resources, named
41
- # `projects/*/locations/*/products/*/referenceImages/*`
42
- class Service
43
-
44
- include GRPC::GenericService
45
-
46
- self.marshal_class_method = :encode
47
- self.unmarshal_class_method = :decode
48
- self.service_name = 'google.cloud.vision.v1p3beta1.ProductSearch'
49
-
50
- # Creates and returns a new ProductSet resource.
51
- #
52
- # Possible errors:
53
- #
54
- # * Returns INVALID_ARGUMENT if display_name is missing, or is longer than
55
- # 4096 characters.
56
- rpc :CreateProductSet, CreateProductSetRequest, ProductSet
57
- # Lists ProductSets in an unspecified order.
58
- #
59
- # Possible errors:
60
- #
61
- # * Returns INVALID_ARGUMENT if page_size is greater than 100, or less
62
- # than 1.
63
- rpc :ListProductSets, ListProductSetsRequest, ListProductSetsResponse
64
- # Gets information associated with a ProductSet.
65
- #
66
- # Possible errors:
67
- #
68
- # * Returns NOT_FOUND if the ProductSet does not exist.
69
- rpc :GetProductSet, GetProductSetRequest, ProductSet
70
- # Makes changes to a ProductSet resource.
71
- # Only display_name can be updated currently.
72
- #
73
- # Possible errors:
74
- #
75
- # * Returns NOT_FOUND if the ProductSet does not exist.
76
- # * Returns INVALID_ARGUMENT if display_name is present in update_mask but
77
- # missing from the request or longer than 4096 characters.
78
- rpc :UpdateProductSet, UpdateProductSetRequest, ProductSet
79
- # Permanently deletes a ProductSet. All Products and ReferenceImages in the
80
- # ProductSet will be deleted.
81
- #
82
- # The actual image files are not deleted from Google Cloud Storage.
83
- #
84
- # Possible errors:
85
- #
86
- # * Returns NOT_FOUND if the ProductSet does not exist.
87
- rpc :DeleteProductSet, DeleteProductSetRequest, Google::Protobuf::Empty
88
- # Creates and returns a new product resource.
89
- #
90
- # Possible errors:
91
- #
92
- # * Returns INVALID_ARGUMENT if display_name is missing or longer than 4096
93
- # characters.
94
- # * Returns INVALID_ARGUMENT if description is longer than 4096 characters.
95
- # * Returns INVALID_ARGUMENT if product_category is missing or invalid.
96
- rpc :CreateProduct, CreateProductRequest, Product
97
- # Lists products in an unspecified order.
98
- #
99
- # Possible errors:
100
- #
101
- # * Returns INVALID_ARGUMENT if page_size is greater than 100 or less than 1.
102
- rpc :ListProducts, ListProductsRequest, ListProductsResponse
103
- # Gets information associated with a Product.
104
- #
105
- # Possible errors:
106
- #
107
- # * Returns NOT_FOUND if the Product does not exist.
108
- rpc :GetProduct, GetProductRequest, Product
109
- # Makes changes to a Product resource.
110
- # Only display_name, description and labels can be updated right now.
111
- #
112
- # If labels are updated, the change will not be reflected in queries until
113
- # the next index time.
114
- #
115
- # Possible errors:
116
- #
117
- # * Returns NOT_FOUND if the Product does not exist.
118
- # * Returns INVALID_ARGUMENT if display_name is present in update_mask but is
119
- # missing from the request or longer than 4096 characters.
120
- # * Returns INVALID_ARGUMENT if description is present in update_mask but is
121
- # longer than 4096 characters.
122
- # * Returns INVALID_ARGUMENT if product_category is present in update_mask.
123
- rpc :UpdateProduct, UpdateProductRequest, Product
124
- # Permanently deletes a product and its reference images.
125
- #
126
- # Metadata of the product and all its images will be deleted right away, but
127
- # search queries against ProductSets containing the product may still work
128
- # until all related caches are refreshed.
129
- #
130
- # Possible errors:
131
- #
132
- # * Returns NOT_FOUND if the product does not exist.
133
- rpc :DeleteProduct, DeleteProductRequest, Google::Protobuf::Empty
134
- # Creates and returns a new ReferenceImage resource.
135
- #
136
- # The `bounding_poly` field is optional. If `bounding_poly` is not specified,
137
- # the system will try to detect regions of interest in the image that are
138
- # compatible with the product_category on the parent product. If it is
139
- # specified, detection is ALWAYS skipped. The system converts polygons into
140
- # non-rotated rectangles.
141
- #
142
- # Note that the pipeline will resize the image if the image resolution is too
143
- # large to process (above 50MP).
144
- #
145
- # Possible errors:
146
- #
147
- # * Returns INVALID_ARGUMENT if the image_uri is missing or longer than 4096
148
- # characters.
149
- # * Returns INVALID_ARGUMENT if the product does not exist.
150
- # * Returns INVALID_ARGUMENT if bounding_poly is not provided, and nothing
151
- # compatible with the parent product's product_category is detected.
152
- # * Returns INVALID_ARGUMENT if bounding_poly contains more than 10 polygons.
153
- rpc :CreateReferenceImage, CreateReferenceImageRequest, ReferenceImage
154
- # Permanently deletes a reference image.
155
- #
156
- # The image metadata will be deleted right away, but search queries
157
- # against ProductSets containing the image may still work until all related
158
- # caches are refreshed.
159
- #
160
- # The actual image files are not deleted from Google Cloud Storage.
161
- #
162
- # Possible errors:
163
- #
164
- # * Returns NOT_FOUND if the reference image does not exist.
165
- rpc :DeleteReferenceImage, DeleteReferenceImageRequest, Google::Protobuf::Empty
166
- # Lists reference images.
167
- #
168
- # Possible errors:
169
- #
170
- # * Returns NOT_FOUND if the parent product does not exist.
171
- # * Returns INVALID_ARGUMENT if the page_size is greater than 100, or less
172
- # than 1.
173
- rpc :ListReferenceImages, ListReferenceImagesRequest, ListReferenceImagesResponse
174
- # Gets information associated with a ReferenceImage.
175
- #
176
- # Possible errors:
177
- #
178
- # * Returns NOT_FOUND if the specified image does not exist.
179
- rpc :GetReferenceImage, GetReferenceImageRequest, ReferenceImage
180
- # Adds a Product to the specified ProductSet. If the Product is already
181
- # present, no change is made.
182
- #
183
- # One Product can be added to at most 100 ProductSets.
184
- #
185
- # Possible errors:
186
- #
187
- # * Returns NOT_FOUND if the Product or the ProductSet doesn't exist.
188
- rpc :AddProductToProductSet, AddProductToProductSetRequest, Google::Protobuf::Empty
189
- # Removes a Product from the specified ProductSet.
190
- #
191
- # Possible errors:
192
- #
193
- # * Returns NOT_FOUND If the Product is not found under the ProductSet.
194
- rpc :RemoveProductFromProductSet, RemoveProductFromProductSetRequest, Google::Protobuf::Empty
195
- # Lists the Products in a ProductSet, in an unspecified order. If the
196
- # ProductSet does not exist, the products field of the response will be
197
- # empty.
198
- #
199
- # Possible errors:
200
- #
201
- # * Returns INVALID_ARGUMENT if page_size is greater than 100 or less than 1.
202
- rpc :ListProductsInProductSet, ListProductsInProductSetRequest, ListProductsInProductSetResponse
203
- # Asynchronous API that imports a list of reference images to specified
204
- # product sets based on a list of image information.
205
- #
206
- # The [google.longrunning.Operation][google.longrunning.Operation] API can be used to keep track of the
207
- # progress and results of the request.
208
- # `Operation.metadata` contains `BatchOperationMetadata`. (progress)
209
- # `Operation.response` contains `ImportProductSetsResponse`. (results)
210
- #
211
- # The input source of this method is a csv file on Google Cloud Storage.
212
- # For the format of the csv file please see
213
- # [ImportProductSetsGcsSource.csv_file_uri][google.cloud.vision.v1p3beta1.ImportProductSetsGcsSource.csv_file_uri].
214
- rpc :ImportProductSets, ImportProductSetsRequest, Google::Longrunning::Operation
215
- end
216
-
217
- Stub = Service.rpc_stub_class
218
- end
219
- end
220
- end
221
- end
222
- end