google-cloud-vision-v1p4beta1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +169 -0
  4. data/LICENSE.md +201 -0
  5. data/README.md +139 -0
  6. data/lib/google/cloud/vision/v1p4beta1/face_pb.rb +35 -0
  7. data/lib/google/cloud/vision/v1p4beta1/geometry_pb.rb +40 -0
  8. data/lib/google/cloud/vision/v1p4beta1/image_annotator/client.rb +629 -0
  9. data/lib/google/cloud/vision/v1p4beta1/image_annotator/credentials.rb +52 -0
  10. data/lib/google/cloud/vision/v1p4beta1/image_annotator/helpers.rb +1228 -0
  11. data/lib/google/cloud/vision/v1p4beta1/image_annotator/operations.rb +664 -0
  12. data/lib/google/cloud/vision/v1p4beta1/image_annotator/paths.rb +52 -0
  13. data/lib/google/cloud/vision/v1p4beta1/image_annotator.rb +52 -0
  14. data/lib/google/cloud/vision/v1p4beta1/image_annotator_pb.rb +343 -0
  15. data/lib/google/cloud/vision/v1p4beta1/image_annotator_services_pb.rb +73 -0
  16. data/lib/google/cloud/vision/v1p4beta1/product_search/client.rb +2106 -0
  17. data/lib/google/cloud/vision/v1p4beta1/product_search/credentials.rb +52 -0
  18. data/lib/google/cloud/vision/v1p4beta1/product_search/operations.rb +664 -0
  19. data/lib/google/cloud/vision/v1p4beta1/product_search/paths.rb +109 -0
  20. data/lib/google/cloud/vision/v1p4beta1/product_search.rb +67 -0
  21. data/lib/google/cloud/vision/v1p4beta1/product_search_pb.rb +55 -0
  22. data/lib/google/cloud/vision/v1p4beta1/product_search_service_pb.rb +208 -0
  23. data/lib/google/cloud/vision/v1p4beta1/product_search_service_services_pb.rb +236 -0
  24. data/lib/google/cloud/vision/v1p4beta1/text_annotation_pb.rb +95 -0
  25. data/lib/google/cloud/vision/v1p4beta1/version.rb +28 -0
  26. data/lib/google/cloud/vision/v1p4beta1/web_detection_pb.rb +52 -0
  27. data/lib/google/cloud/vision/v1p4beta1.rb +39 -0
  28. data/lib/google-cloud-vision-v1p4beta1.rb +21 -0
  29. data/proto_docs/README.md +4 -0
  30. data/proto_docs/google/api/field_behavior.rb +71 -0
  31. data/proto_docs/google/api/resource.rb +283 -0
  32. data/proto_docs/google/cloud/vision/v1p4beta1/face.rb +68 -0
  33. data/proto_docs/google/cloud/vision/v1p4beta1/geometry.rb +82 -0
  34. data/proto_docs/google/cloud/vision/v1p4beta1/image_annotator.rb +989 -0
  35. data/proto_docs/google/cloud/vision/v1p4beta1/product_search.rb +136 -0
  36. data/proto_docs/google/cloud/vision/v1p4beta1/product_search_service.rb +676 -0
  37. data/proto_docs/google/cloud/vision/v1p4beta1/text_annotation.rb +286 -0
  38. data/proto_docs/google/cloud/vision/v1p4beta1/web_detection.rb +121 -0
  39. data/proto_docs/google/longrunning/operations.rb +164 -0
  40. data/proto_docs/google/protobuf/any.rb +141 -0
  41. data/proto_docs/google/protobuf/duration.rb +98 -0
  42. data/proto_docs/google/protobuf/empty.rb +36 -0
  43. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  44. data/proto_docs/google/protobuf/timestamp.rb +129 -0
  45. data/proto_docs/google/protobuf/wrappers.rb +121 -0
  46. data/proto_docs/google/rpc/status.rb +46 -0
  47. data/proto_docs/google/type/color.rb +173 -0
  48. data/proto_docs/google/type/latlng.rb +38 -0
  49. metadata +240 -0
@@ -0,0 +1,676 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module Vision
23
+ module V1p4beta1
24
+ # A Product contains ReferenceImages.
25
+ # @!attribute [rw] name
26
+ # @return [::String]
27
+ # The resource name of the product.
28
+ #
29
+ # Format is:
30
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`.
31
+ #
32
+ # This field is ignored when creating a product.
33
+ # @!attribute [rw] display_name
34
+ # @return [::String]
35
+ # The user-provided name for this Product. Must not be empty. Must be at most
36
+ # 4096 characters long.
37
+ # @!attribute [rw] description
38
+ # @return [::String]
39
+ # User-provided metadata to be stored with this product. Must be at most 4096
40
+ # characters long.
41
+ # @!attribute [rw] product_category
42
+ # @return [::String]
43
+ # Immutable. The category for the product identified by the reference image.
44
+ # This should be either "homegoods-v2", "apparel-v2", or "toys-v2". The
45
+ # legacy categories "homegoods", "apparel", and "toys" are still supported,
46
+ # but these should not be used for new products.
47
+ # @!attribute [rw] product_labels
48
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::Product::KeyValue>]
49
+ # Key-value pairs that can be attached to a product. At query time,
50
+ # constraints can be specified based on the product_labels.
51
+ #
52
+ # Note that integer values can be provided as strings, e.g. "1199". Only
53
+ # strings with integer values can match a range-based restriction which is
54
+ # to be supported soon.
55
+ #
56
+ # Multiple values can be assigned to the same key. One product may have up to
57
+ # 500 product_labels.
58
+ #
59
+ # Notice that the total number of distinct product_labels over all products
60
+ # in one ProductSet cannot exceed 1M, otherwise the product search pipeline
61
+ # will refuse to work for that ProductSet.
62
+ class Product
63
+ include ::Google::Protobuf::MessageExts
64
+ extend ::Google::Protobuf::MessageExts::ClassMethods
65
+
66
+ # A product label represented as a key-value pair.
67
+ # @!attribute [rw] key
68
+ # @return [::String]
69
+ # The key of the label attached to the product. Cannot be empty and cannot
70
+ # exceed 128 bytes.
71
+ # @!attribute [rw] value
72
+ # @return [::String]
73
+ # The value of the label attached to the product. Cannot be empty and
74
+ # cannot exceed 128 bytes.
75
+ class KeyValue
76
+ include ::Google::Protobuf::MessageExts
77
+ extend ::Google::Protobuf::MessageExts::ClassMethods
78
+ end
79
+ end
80
+
81
+ # A ProductSet contains Products. A ProductSet can contain a maximum of 1
82
+ # million reference images. If the limit is exceeded, periodic indexing will
83
+ # fail.
84
+ # @!attribute [rw] name
85
+ # @return [::String]
86
+ # The resource name of the ProductSet.
87
+ #
88
+ # Format is:
89
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`.
90
+ #
91
+ # This field is ignored when creating a ProductSet.
92
+ # @!attribute [rw] display_name
93
+ # @return [::String]
94
+ # The user-provided name for this ProductSet. Must not be empty. Must be at
95
+ # most 4096 characters long.
96
+ # @!attribute [r] index_time
97
+ # @return [::Google::Protobuf::Timestamp]
98
+ # Output only. The time at which this ProductSet was last indexed. Query
99
+ # results will reflect all updates before this time. If this ProductSet has
100
+ # never been indexed, this timestamp is the default value
101
+ # "1970-01-01T00:00:00Z".
102
+ #
103
+ # This field is ignored when creating a ProductSet.
104
+ # @!attribute [r] index_error
105
+ # @return [::Google::Rpc::Status]
106
+ # Output only. If there was an error with indexing the product set, the field
107
+ # is populated.
108
+ #
109
+ # This field is ignored when creating a ProductSet.
110
+ class ProductSet
111
+ include ::Google::Protobuf::MessageExts
112
+ extend ::Google::Protobuf::MessageExts::ClassMethods
113
+ end
114
+
115
+ # A `ReferenceImage` represents a product image and its associated metadata,
116
+ # such as bounding boxes.
117
+ # @!attribute [rw] name
118
+ # @return [::String]
119
+ # The resource name of the reference image.
120
+ #
121
+ # Format is:
122
+ #
123
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`.
124
+ #
125
+ # This field is ignored when creating a reference image.
126
+ # @!attribute [rw] uri
127
+ # @return [::String]
128
+ # Required. The Google Cloud Storage URI of the reference image.
129
+ #
130
+ # The URI must start with `gs://`.
131
+ # @!attribute [rw] bounding_polys
132
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::BoundingPoly>]
133
+ # Optional. Bounding polygons around the areas of interest in the reference
134
+ # image. If this field is empty, the system will try to detect regions of
135
+ # interest. At most 10 bounding polygons will be used.
136
+ #
137
+ # The provided shape is converted into a non-rotated rectangle. Once
138
+ # converted, the small edge of the rectangle must be greater than or equal
139
+ # to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5
140
+ # is not).
141
+ class ReferenceImage
142
+ include ::Google::Protobuf::MessageExts
143
+ extend ::Google::Protobuf::MessageExts::ClassMethods
144
+ end
145
+
146
+ # Request message for the `CreateProduct` method.
147
+ # @!attribute [rw] parent
148
+ # @return [::String]
149
+ # Required. The project in which the Product should be created.
150
+ #
151
+ # Format is
152
+ # `projects/PROJECT_ID/locations/LOC_ID`.
153
+ # @!attribute [rw] product
154
+ # @return [::Google::Cloud::Vision::V1p4beta1::Product]
155
+ # Required. The product to create.
156
+ # @!attribute [rw] product_id
157
+ # @return [::String]
158
+ # A user-supplied resource id for this Product. If set, the server will
159
+ # attempt to use this value as the resource id. If it is already in use, an
160
+ # error is returned with code ALREADY_EXISTS. Must be at most 128 characters
161
+ # long. It cannot contain the character `/`.
162
+ class CreateProductRequest
163
+ include ::Google::Protobuf::MessageExts
164
+ extend ::Google::Protobuf::MessageExts::ClassMethods
165
+ end
166
+
167
+ # Request message for the `ListProducts` method.
168
+ # @!attribute [rw] parent
169
+ # @return [::String]
170
+ # Required. The project OR ProductSet from which Products should be listed.
171
+ #
172
+ # Format:
173
+ # `projects/PROJECT_ID/locations/LOC_ID`
174
+ # @!attribute [rw] page_size
175
+ # @return [::Integer]
176
+ # The maximum number of items to return. Default 10, maximum 100.
177
+ # @!attribute [rw] page_token
178
+ # @return [::String]
179
+ # The next_page_token returned from a previous List request, if any.
180
+ class ListProductsRequest
181
+ include ::Google::Protobuf::MessageExts
182
+ extend ::Google::Protobuf::MessageExts::ClassMethods
183
+ end
184
+
185
+ # Response message for the `ListProducts` method.
186
+ # @!attribute [rw] products
187
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::Product>]
188
+ # List of products.
189
+ # @!attribute [rw] next_page_token
190
+ # @return [::String]
191
+ # Token to retrieve the next page of results, or empty if there are no more
192
+ # results in the list.
193
+ class ListProductsResponse
194
+ include ::Google::Protobuf::MessageExts
195
+ extend ::Google::Protobuf::MessageExts::ClassMethods
196
+ end
197
+
198
+ # Request message for the `GetProduct` method.
199
+ # @!attribute [rw] name
200
+ # @return [::String]
201
+ # Required. Resource name of the Product to get.
202
+ #
203
+ # Format is:
204
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`
205
+ class GetProductRequest
206
+ include ::Google::Protobuf::MessageExts
207
+ extend ::Google::Protobuf::MessageExts::ClassMethods
208
+ end
209
+
210
+ # Request message for the `UpdateProduct` method.
211
+ # @!attribute [rw] product
212
+ # @return [::Google::Cloud::Vision::V1p4beta1::Product]
213
+ # Required. The Product resource which replaces the one on the server.
214
+ # product.name is immutable.
215
+ # @!attribute [rw] update_mask
216
+ # @return [::Google::Protobuf::FieldMask]
217
+ # The {::Google::Protobuf::FieldMask FieldMask} that specifies which fields
218
+ # to update.
219
+ # If update_mask isn't specified, all mutable fields are to be updated.
220
+ # Valid mask paths include `product_labels`, `display_name`, and
221
+ # `description`.
222
+ class UpdateProductRequest
223
+ include ::Google::Protobuf::MessageExts
224
+ extend ::Google::Protobuf::MessageExts::ClassMethods
225
+ end
226
+
227
+ # Request message for the `DeleteProduct` method.
228
+ # @!attribute [rw] name
229
+ # @return [::String]
230
+ # Required. Resource name of product to delete.
231
+ #
232
+ # Format is:
233
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`
234
+ class DeleteProductRequest
235
+ include ::Google::Protobuf::MessageExts
236
+ extend ::Google::Protobuf::MessageExts::ClassMethods
237
+ end
238
+
239
+ # Request message for the `CreateProductSet` method.
240
+ # @!attribute [rw] parent
241
+ # @return [::String]
242
+ # Required. The project in which the ProductSet should be created.
243
+ #
244
+ # Format is `projects/PROJECT_ID/locations/LOC_ID`.
245
+ # @!attribute [rw] product_set
246
+ # @return [::Google::Cloud::Vision::V1p4beta1::ProductSet]
247
+ # Required. The ProductSet to create.
248
+ # @!attribute [rw] product_set_id
249
+ # @return [::String]
250
+ # A user-supplied resource id for this ProductSet. If set, the server will
251
+ # attempt to use this value as the resource id. If it is already in use, an
252
+ # error is returned with code ALREADY_EXISTS. Must be at most 128 characters
253
+ # long. It cannot contain the character `/`.
254
+ class CreateProductSetRequest
255
+ include ::Google::Protobuf::MessageExts
256
+ extend ::Google::Protobuf::MessageExts::ClassMethods
257
+ end
258
+
259
+ # Request message for the `ListProductSets` method.
260
+ # @!attribute [rw] parent
261
+ # @return [::String]
262
+ # Required. The project from which ProductSets should be listed.
263
+ #
264
+ # Format is `projects/PROJECT_ID/locations/LOC_ID`.
265
+ # @!attribute [rw] page_size
266
+ # @return [::Integer]
267
+ # The maximum number of items to return. Default 10, maximum 100.
268
+ # @!attribute [rw] page_token
269
+ # @return [::String]
270
+ # The next_page_token returned from a previous List request, if any.
271
+ class ListProductSetsRequest
272
+ include ::Google::Protobuf::MessageExts
273
+ extend ::Google::Protobuf::MessageExts::ClassMethods
274
+ end
275
+
276
+ # Response message for the `ListProductSets` method.
277
+ # @!attribute [rw] product_sets
278
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::ProductSet>]
279
+ # List of ProductSets.
280
+ # @!attribute [rw] next_page_token
281
+ # @return [::String]
282
+ # Token to retrieve the next page of results, or empty if there are no more
283
+ # results in the list.
284
+ class ListProductSetsResponse
285
+ include ::Google::Protobuf::MessageExts
286
+ extend ::Google::Protobuf::MessageExts::ClassMethods
287
+ end
288
+
289
+ # Request message for the `GetProductSet` method.
290
+ # @!attribute [rw] name
291
+ # @return [::String]
292
+ # Required. Resource name of the ProductSet to get.
293
+ #
294
+ # Format is:
295
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`
296
+ class GetProductSetRequest
297
+ include ::Google::Protobuf::MessageExts
298
+ extend ::Google::Protobuf::MessageExts::ClassMethods
299
+ end
300
+
301
+ # Request message for the `UpdateProductSet` method.
302
+ # @!attribute [rw] product_set
303
+ # @return [::Google::Cloud::Vision::V1p4beta1::ProductSet]
304
+ # Required. The ProductSet resource which replaces the one on the server.
305
+ # @!attribute [rw] update_mask
306
+ # @return [::Google::Protobuf::FieldMask]
307
+ # The {::Google::Protobuf::FieldMask FieldMask} that specifies which fields to
308
+ # update.
309
+ # If update_mask isn't specified, all mutable fields are to be updated.
310
+ # Valid mask path is `display_name`.
311
+ class UpdateProductSetRequest
312
+ include ::Google::Protobuf::MessageExts
313
+ extend ::Google::Protobuf::MessageExts::ClassMethods
314
+ end
315
+
316
+ # Request message for the `DeleteProductSet` method.
317
+ # @!attribute [rw] name
318
+ # @return [::String]
319
+ # Required. Resource name of the ProductSet to delete.
320
+ #
321
+ # Format is:
322
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`
323
+ class DeleteProductSetRequest
324
+ include ::Google::Protobuf::MessageExts
325
+ extend ::Google::Protobuf::MessageExts::ClassMethods
326
+ end
327
+
328
+ # Request message for the `CreateReferenceImage` method.
329
+ # @!attribute [rw] parent
330
+ # @return [::String]
331
+ # Required. Resource name of the product in which to create the reference
332
+ # image.
333
+ #
334
+ # Format is
335
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`.
336
+ # @!attribute [rw] reference_image
337
+ # @return [::Google::Cloud::Vision::V1p4beta1::ReferenceImage]
338
+ # Required. The reference image to create.
339
+ # If an image ID is specified, it is ignored.
340
+ # @!attribute [rw] reference_image_id
341
+ # @return [::String]
342
+ # A user-supplied resource id for the ReferenceImage to be added. If set,
343
+ # the server will attempt to use this value as the resource id. If it is
344
+ # already in use, an error is returned with code ALREADY_EXISTS. Must be at
345
+ # most 128 characters long. It cannot contain the character `/`.
346
+ class CreateReferenceImageRequest
347
+ include ::Google::Protobuf::MessageExts
348
+ extend ::Google::Protobuf::MessageExts::ClassMethods
349
+ end
350
+
351
+ # Request message for the `ListReferenceImages` method.
352
+ # @!attribute [rw] parent
353
+ # @return [::String]
354
+ # Required. Resource name of the product containing the reference images.
355
+ #
356
+ # Format is
357
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`.
358
+ # @!attribute [rw] page_size
359
+ # @return [::Integer]
360
+ # The maximum number of items to return. Default 10, maximum 100.
361
+ # @!attribute [rw] page_token
362
+ # @return [::String]
363
+ # A token identifying a page of results to be returned. This is the value
364
+ # of `nextPageToken` returned in a previous reference image list request.
365
+ #
366
+ # Defaults to the first page if not specified.
367
+ class ListReferenceImagesRequest
368
+ include ::Google::Protobuf::MessageExts
369
+ extend ::Google::Protobuf::MessageExts::ClassMethods
370
+ end
371
+
372
+ # Response message for the `ListReferenceImages` method.
373
+ # @!attribute [rw] reference_images
374
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::ReferenceImage>]
375
+ # The list of reference images.
376
+ # @!attribute [rw] page_size
377
+ # @return [::Integer]
378
+ # The maximum number of items to return. Default 10, maximum 100.
379
+ # @!attribute [rw] next_page_token
380
+ # @return [::String]
381
+ # The next_page_token returned from a previous List request, if any.
382
+ class ListReferenceImagesResponse
383
+ include ::Google::Protobuf::MessageExts
384
+ extend ::Google::Protobuf::MessageExts::ClassMethods
385
+ end
386
+
387
+ # Request message for the `GetReferenceImage` method.
388
+ # @!attribute [rw] name
389
+ # @return [::String]
390
+ # Required. The resource name of the ReferenceImage to get.
391
+ #
392
+ # Format is:
393
+ #
394
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`.
395
+ class GetReferenceImageRequest
396
+ include ::Google::Protobuf::MessageExts
397
+ extend ::Google::Protobuf::MessageExts::ClassMethods
398
+ end
399
+
400
+ # Request message for the `DeleteReferenceImage` method.
401
+ # @!attribute [rw] name
402
+ # @return [::String]
403
+ # Required. The resource name of the reference image to delete.
404
+ #
405
+ # Format is:
406
+ #
407
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`
408
+ class DeleteReferenceImageRequest
409
+ include ::Google::Protobuf::MessageExts
410
+ extend ::Google::Protobuf::MessageExts::ClassMethods
411
+ end
412
+
413
+ # Request message for the `AddProductToProductSet` method.
414
+ # @!attribute [rw] name
415
+ # @return [::String]
416
+ # Required. The resource name for the ProductSet to modify.
417
+ #
418
+ # Format is:
419
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`
420
+ # @!attribute [rw] product
421
+ # @return [::String]
422
+ # Required. The resource name for the Product to be added to this ProductSet.
423
+ #
424
+ # Format is:
425
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`
426
+ class AddProductToProductSetRequest
427
+ include ::Google::Protobuf::MessageExts
428
+ extend ::Google::Protobuf::MessageExts::ClassMethods
429
+ end
430
+
431
+ # Request message for the `RemoveProductFromProductSet` method.
432
+ # @!attribute [rw] name
433
+ # @return [::String]
434
+ # Required. The resource name for the ProductSet to modify.
435
+ #
436
+ # Format is:
437
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`
438
+ # @!attribute [rw] product
439
+ # @return [::String]
440
+ # Required. The resource name for the Product to be removed from this
441
+ # ProductSet.
442
+ #
443
+ # Format is:
444
+ # `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID`
445
+ class RemoveProductFromProductSetRequest
446
+ include ::Google::Protobuf::MessageExts
447
+ extend ::Google::Protobuf::MessageExts::ClassMethods
448
+ end
449
+
450
+ # Request message for the `ListProductsInProductSet` method.
451
+ # @!attribute [rw] name
452
+ # @return [::String]
453
+ # Required. The ProductSet resource for which to retrieve Products.
454
+ #
455
+ # Format is:
456
+ # `projects/PROJECT_ID/locations/LOC_ID/productSets/PRODUCT_SET_ID`
457
+ # @!attribute [rw] page_size
458
+ # @return [::Integer]
459
+ # The maximum number of items to return. Default 10, maximum 100.
460
+ # @!attribute [rw] page_token
461
+ # @return [::String]
462
+ # The next_page_token returned from a previous List request, if any.
463
+ class ListProductsInProductSetRequest
464
+ include ::Google::Protobuf::MessageExts
465
+ extend ::Google::Protobuf::MessageExts::ClassMethods
466
+ end
467
+
468
+ # Response message for the `ListProductsInProductSet` method.
469
+ # @!attribute [rw] products
470
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::Product>]
471
+ # The list of Products.
472
+ # @!attribute [rw] next_page_token
473
+ # @return [::String]
474
+ # Token to retrieve the next page of results, or empty if there are no more
475
+ # results in the list.
476
+ class ListProductsInProductSetResponse
477
+ include ::Google::Protobuf::MessageExts
478
+ extend ::Google::Protobuf::MessageExts::ClassMethods
479
+ end
480
+
481
+ # The Google Cloud Storage location for a csv file which preserves a list of
482
+ # ImportProductSetRequests in each line.
483
+ # @!attribute [rw] csv_file_uri
484
+ # @return [::String]
485
+ # The Google Cloud Storage URI of the input csv file.
486
+ #
487
+ # The URI must start with `gs://`.
488
+ #
489
+ # The format of the input csv file should be one image per line.
490
+ # In each line, there are 8 columns.
491
+ #
492
+ # 1. image-uri
493
+ # 2. image-id
494
+ # 3. product-set-id
495
+ # 4. product-id
496
+ # 5. product-category
497
+ # 6. product-display-name
498
+ # 7. labels
499
+ # 8. bounding-poly
500
+ #
501
+ # The `image-uri`, `product-set-id`, `product-id`, and `product-category`
502
+ # columns are required. All other columns are optional.
503
+ #
504
+ # If the `ProductSet` or `Product` specified by the `product-set-id` and
505
+ # `product-id` values does not exist, then the system will create a new
506
+ # `ProductSet` or `Product` for the image. In this case, the
507
+ # `product-display-name` column refers to
508
+ # {::Google::Cloud::Vision::V1p4beta1::Product#display_name display_name}, the
509
+ # `product-category` column refers to
510
+ # {::Google::Cloud::Vision::V1p4beta1::Product#product_category product_category},
511
+ # and the `labels` column refers to
512
+ # {::Google::Cloud::Vision::V1p4beta1::Product#product_labels product_labels}.
513
+ #
514
+ # The `image-id` column is optional but must be unique if provided. If it is
515
+ # empty, the system will automatically assign a unique id to the image.
516
+ #
517
+ # The `product-display-name` column is optional. If it is empty, the system
518
+ # sets the {::Google::Cloud::Vision::V1p4beta1::Product#display_name display_name}
519
+ # field for the product to a space (" "). You can update the `display_name`
520
+ # later by using the API.
521
+ #
522
+ # If a `Product` with the specified `product-id` already exists, then the
523
+ # system ignores the `product-display-name`, `product-category`, and `labels`
524
+ # columns.
525
+ #
526
+ # The `labels` column (optional) is a line containing a list of
527
+ # comma-separated key-value pairs, in the following format:
528
+ #
529
+ # "key_1=value_1,key_2=value_2,...,key_n=value_n"
530
+ #
531
+ # The `bounding-poly` column (optional) identifies one region of
532
+ # interest from the image in the same manner as `CreateReferenceImage`. If
533
+ # you do not specify the `bounding-poly` column, then the system will try to
534
+ # detect regions of interest automatically.
535
+ #
536
+ # At most one `bounding-poly` column is allowed per line. If the image
537
+ # contains multiple regions of interest, add a line to the CSV file that
538
+ # includes the same product information, and the `bounding-poly` values for
539
+ # each region of interest.
540
+ #
541
+ # The `bounding-poly` column must contain an even number of comma-separated
542
+ # numbers, in the format "p1_x,p1_y,p2_x,p2_y,...,pn_x,pn_y". Use
543
+ # non-negative integers for absolute bounding polygons, and float values
544
+ # in [0, 1] for normalized bounding polygons.
545
+ #
546
+ # The system will resize the image if the image resolution is too
547
+ # large to process (larger than 20MP).
548
+ class ImportProductSetsGcsSource
549
+ include ::Google::Protobuf::MessageExts
550
+ extend ::Google::Protobuf::MessageExts::ClassMethods
551
+ end
552
+
553
+ # The input content for the `ImportProductSets` method.
554
+ # @!attribute [rw] gcs_source
555
+ # @return [::Google::Cloud::Vision::V1p4beta1::ImportProductSetsGcsSource]
556
+ # The Google Cloud Storage location for a csv file which preserves a list
557
+ # of ImportProductSetRequests in each line.
558
+ class ImportProductSetsInputConfig
559
+ include ::Google::Protobuf::MessageExts
560
+ extend ::Google::Protobuf::MessageExts::ClassMethods
561
+ end
562
+
563
+ # Request message for the `ImportProductSets` method.
564
+ # @!attribute [rw] parent
565
+ # @return [::String]
566
+ # Required. The project in which the ProductSets should be imported.
567
+ #
568
+ # Format is `projects/PROJECT_ID/locations/LOC_ID`.
569
+ # @!attribute [rw] input_config
570
+ # @return [::Google::Cloud::Vision::V1p4beta1::ImportProductSetsInputConfig]
571
+ # Required. The input content for the list of requests.
572
+ class ImportProductSetsRequest
573
+ include ::Google::Protobuf::MessageExts
574
+ extend ::Google::Protobuf::MessageExts::ClassMethods
575
+ end
576
+
577
+ # Response message for the `ImportProductSets` method.
578
+ #
579
+ # This message is returned by the
580
+ # google.longrunning.Operations.GetOperation
581
+ # method in the returned
582
+ # {::Google::Longrunning::Operation#response google.longrunning.Operation.response}
583
+ # field.
584
+ # @!attribute [rw] reference_images
585
+ # @return [::Array<::Google::Cloud::Vision::V1p4beta1::ReferenceImage>]
586
+ # The list of reference_images that are imported successfully.
587
+ # @!attribute [rw] statuses
588
+ # @return [::Array<::Google::Rpc::Status>]
589
+ # The rpc status for each ImportProductSet request, including both successes
590
+ # and errors.
591
+ #
592
+ # The number of statuses here matches the number of lines in the csv file,
593
+ # and statuses[i] stores the success or failure status of processing the i-th
594
+ # line of the csv, starting from line 0.
595
+ class ImportProductSetsResponse
596
+ include ::Google::Protobuf::MessageExts
597
+ extend ::Google::Protobuf::MessageExts::ClassMethods
598
+ end
599
+
600
+ # Metadata for the batch operations such as the current state.
601
+ #
602
+ # This is included in the `metadata` field of the `Operation` returned by the
603
+ # `GetOperation` call of the `google::longrunning::Operations` service.
604
+ # @!attribute [rw] state
605
+ # @return [::Google::Cloud::Vision::V1p4beta1::BatchOperationMetadata::State]
606
+ # The current state of the batch operation.
607
+ # @!attribute [rw] submit_time
608
+ # @return [::Google::Protobuf::Timestamp]
609
+ # The time when the batch request was submitted to the server.
610
+ # @!attribute [rw] end_time
611
+ # @return [::Google::Protobuf::Timestamp]
612
+ # The time when the batch request is finished and
613
+ # {::Google::Longrunning::Operation#done google.longrunning.Operation.done} is
614
+ # set to true.
615
+ class BatchOperationMetadata
616
+ include ::Google::Protobuf::MessageExts
617
+ extend ::Google::Protobuf::MessageExts::ClassMethods
618
+
619
+ # Enumerates the possible states that the batch request can be in.
620
+ module State
621
+ # Invalid.
622
+ STATE_UNSPECIFIED = 0
623
+
624
+ # Request is actively being processed.
625
+ PROCESSING = 1
626
+
627
+ # The request is done and at least one item has been successfully
628
+ # processed.
629
+ SUCCESSFUL = 2
630
+
631
+ # The request is done and no item has been successfully processed.
632
+ FAILED = 3
633
+
634
+ # The request is done after the longrunning.Operations.CancelOperation has
635
+ # been called by the user. Any records that were processed before the
636
+ # cancel command are output as specified in the request.
637
+ CANCELLED = 4
638
+ end
639
+ end
640
+
641
+ # Config to control which ProductSet contains the Products to be deleted.
642
+ # @!attribute [rw] product_set_id
643
+ # @return [::String]
644
+ # The ProductSet that contains the Products to delete. If a Product is a
645
+ # member of product_set_id in addition to other ProductSets, the Product will
646
+ # still be deleted.
647
+ class ProductSetPurgeConfig
648
+ include ::Google::Protobuf::MessageExts
649
+ extend ::Google::Protobuf::MessageExts::ClassMethods
650
+ end
651
+
652
+ # Request message for the `PurgeProducts` method.
653
+ # @!attribute [rw] product_set_purge_config
654
+ # @return [::Google::Cloud::Vision::V1p4beta1::ProductSetPurgeConfig]
655
+ # Specify which ProductSet contains the Products to be deleted.
656
+ # @!attribute [rw] delete_orphan_products
657
+ # @return [::Boolean]
658
+ # If delete_orphan_products is true, all Products that are not in any
659
+ # ProductSet will be deleted.
660
+ # @!attribute [rw] parent
661
+ # @return [::String]
662
+ # Required. The project and location in which the Products should be deleted.
663
+ #
664
+ # Format is `projects/PROJECT_ID/locations/LOC_ID`.
665
+ # @!attribute [rw] force
666
+ # @return [::Boolean]
667
+ # The default value is false. Override this value to true to actually perform
668
+ # the purge.
669
+ class PurgeProductsRequest
670
+ include ::Google::Protobuf::MessageExts
671
+ extend ::Google::Protobuf::MessageExts::ClassMethods
672
+ end
673
+ end
674
+ end
675
+ end
676
+ end