azure_cognitiveservices_visualsearch 0.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +21 -0
  3. data/lib/1.0/generated/azure_cognitiveservices_visualsearch.rb +75 -0
  4. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/images.rb +639 -0
  5. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/action.rb +237 -0
  6. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/aggregate_offer.rb +211 -0
  7. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/aggregate_rating.rb +89 -0
  8. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/content_types.rb +20 -0
  9. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/creative_work.rb +190 -0
  10. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/crop_area.rb +92 -0
  11. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/currency.rb +175 -0
  12. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/error.rb +116 -0
  13. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/error_code.rb +20 -0
  14. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/error_response.rb +98 -0
  15. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/error_sub_code.rb +25 -0
  16. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/filters.rb +48 -0
  17. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/identifiable.rb +62 -0
  18. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_action.rb +234 -0
  19. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_entity_action.rb +231 -0
  20. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_info.rb +86 -0
  21. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_knowledge.rb +112 -0
  22. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_module_action.rb +244 -0
  23. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_object.rb +326 -0
  24. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_recipes_action.rb +244 -0
  25. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_related_searches_action.rb +244 -0
  26. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_shopping_sources_action.rb +245 -0
  27. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_tag.rb +182 -0
  28. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/image_tag_region.rb +61 -0
  29. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/images_image_metadata.rb +80 -0
  30. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/images_module.rb +56 -0
  31. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/intangible.rb +133 -0
  32. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/item_availability.rb +22 -0
  33. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/knowledge_request.rb +49 -0
  34. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/media_object.rb +263 -0
  35. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/normalized_quadrilateral.rb +183 -0
  36. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/offer.rb +231 -0
  37. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/organization.rb +132 -0
  38. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/person.rb +156 -0
  39. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/point2d.rb +154 -0
  40. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/properties_item.rb +59 -0
  41. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/query.rb +101 -0
  42. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/rating.rb +84 -0
  43. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/recipe.rb +219 -0
  44. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/recipes_module.rb +56 -0
  45. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/related_searches_module.rb +56 -0
  46. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/response.rb +86 -0
  47. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/response_base.rb +70 -0
  48. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/safe_search.rb +17 -0
  49. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/structured_value.rb +133 -0
  50. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/thing.rb +151 -0
  51. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/models/visual_search_request.rb +62 -0
  52. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/module_definition.rb +9 -0
  53. data/lib/1.0/generated/azure_cognitiveservices_visualsearch/visual_search_client.rb +128 -0
  54. data/lib/azure_cognitiveservices_visualsearch.rb +6 -0
  55. data/lib/module_definition.rb +7 -0
  56. data/lib/profiles/latest/modules/visualsearch_profile_module.rb +247 -0
  57. data/lib/profiles/latest/visualsearch_latest_profile_client.rb +38 -0
  58. data/lib/profiles/latest/visualsearch_module_definition.rb +8 -0
  59. data/lib/version.rb +7 -0
  60. metadata +177 -0
@@ -0,0 +1,154 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::VisualSearch::V1_0
7
+ module Models
8
+ #
9
+ # Defines a 2D point with X and Y coordinates.
10
+ #
11
+ class Point2D < StructuredValue
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ def initialize
17
+ @_type = "Point2D"
18
+ end
19
+
20
+ attr_accessor :_type
21
+
22
+ # @return [Float] The x-coordinate of the point.
23
+ attr_accessor :x
24
+
25
+ # @return [Float] The y-coordinate of the point.
26
+ attr_accessor :y
27
+
28
+
29
+ #
30
+ # Mapper for Point2D class as Ruby Hash.
31
+ # This will be used for serialization/deserialization.
32
+ #
33
+ def self.mapper()
34
+ {
35
+ client_side_validation: true,
36
+ required: false,
37
+ serialized_name: 'Point2D',
38
+ type: {
39
+ name: 'Composite',
40
+ class_name: 'Point2D',
41
+ model_properties: {
42
+ _type: {
43
+ client_side_validation: true,
44
+ required: true,
45
+ serialized_name: '_type',
46
+ type: {
47
+ name: 'String'
48
+ }
49
+ },
50
+ id: {
51
+ client_side_validation: true,
52
+ required: false,
53
+ read_only: true,
54
+ serialized_name: 'id',
55
+ type: {
56
+ name: 'String'
57
+ }
58
+ },
59
+ read_link: {
60
+ client_side_validation: true,
61
+ required: false,
62
+ read_only: true,
63
+ serialized_name: 'readLink',
64
+ type: {
65
+ name: 'String'
66
+ }
67
+ },
68
+ web_search_url: {
69
+ client_side_validation: true,
70
+ required: false,
71
+ read_only: true,
72
+ serialized_name: 'webSearchUrl',
73
+ type: {
74
+ name: 'String'
75
+ }
76
+ },
77
+ name: {
78
+ client_side_validation: true,
79
+ required: false,
80
+ read_only: true,
81
+ serialized_name: 'name',
82
+ type: {
83
+ name: 'String'
84
+ }
85
+ },
86
+ url: {
87
+ client_side_validation: true,
88
+ required: false,
89
+ read_only: true,
90
+ serialized_name: 'url',
91
+ type: {
92
+ name: 'String'
93
+ }
94
+ },
95
+ image: {
96
+ client_side_validation: true,
97
+ required: false,
98
+ read_only: true,
99
+ serialized_name: 'image',
100
+ type: {
101
+ name: 'Composite',
102
+ class_name: 'ImageObject'
103
+ }
104
+ },
105
+ description: {
106
+ client_side_validation: true,
107
+ required: false,
108
+ read_only: true,
109
+ serialized_name: 'description',
110
+ type: {
111
+ name: 'String'
112
+ }
113
+ },
114
+ alternate_name: {
115
+ client_side_validation: true,
116
+ required: false,
117
+ read_only: true,
118
+ serialized_name: 'alternateName',
119
+ type: {
120
+ name: 'String'
121
+ }
122
+ },
123
+ bing_id: {
124
+ client_side_validation: true,
125
+ required: false,
126
+ read_only: true,
127
+ serialized_name: 'bingId',
128
+ type: {
129
+ name: 'String'
130
+ }
131
+ },
132
+ x: {
133
+ client_side_validation: true,
134
+ required: true,
135
+ serialized_name: 'x',
136
+ type: {
137
+ name: 'Double'
138
+ }
139
+ },
140
+ y: {
141
+ client_side_validation: true,
142
+ required: true,
143
+ serialized_name: 'y',
144
+ type: {
145
+ name: 'Double'
146
+ }
147
+ }
148
+ }
149
+ }
150
+ }
151
+ end
152
+ end
153
+ end
154
+ end
@@ -0,0 +1,59 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::VisualSearch::V1_0
7
+ module Models
8
+ #
9
+ # Defines an item.
10
+ #
11
+ class PropertiesItem
12
+
13
+ include MsRestAzure
14
+
15
+ @@discriminatorMap = Hash.new
16
+ @@discriminatorMap["AggregateRating"] = "AggregateRating"
17
+ @@discriminatorMap["Rating"] = "Rating"
18
+
19
+ def initialize
20
+ @_type = "Properties/Item"
21
+ end
22
+
23
+ attr_accessor :_type
24
+
25
+ # @return [String] Text representation of an item.
26
+ attr_accessor :text
27
+
28
+
29
+ #
30
+ # Mapper for PropertiesItem class as Ruby Hash.
31
+ # This will be used for serialization/deserialization.
32
+ #
33
+ def self.mapper()
34
+ {
35
+ client_side_validation: true,
36
+ required: false,
37
+ serialized_name: 'Properties/Item',
38
+ type: {
39
+ name: 'Composite',
40
+ polymorphic_discriminator: '_type',
41
+ uber_parent: 'PropertiesItem',
42
+ class_name: 'PropertiesItem',
43
+ model_properties: {
44
+ text: {
45
+ client_side_validation: true,
46
+ required: false,
47
+ read_only: true,
48
+ serialized_name: 'text',
49
+ type: {
50
+ name: 'String'
51
+ }
52
+ }
53
+ }
54
+ }
55
+ }
56
+ end
57
+ end
58
+ end
59
+ end
@@ -0,0 +1,101 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::VisualSearch::V1_0
7
+ module Models
8
+ #
9
+ # Defines a search query.
10
+ #
11
+ class Query
12
+
13
+ include MsRestAzure
14
+
15
+ # @return [String] The query string. Use this string as the query term in
16
+ # a new search request.
17
+ attr_accessor :text
18
+
19
+ # @return [String] The display version of the query term.
20
+ attr_accessor :display_text
21
+
22
+ # @return [String] The URL that takes the user to the Bing search results
23
+ # page for the query.
24
+ attr_accessor :web_search_url
25
+
26
+ # @return [String] The URL that you use to get the results of the related
27
+ # search. Before using the URL, you must append query parameters as
28
+ # appropriate and include the Ocp-Apim-Subscription-Key header. Use this
29
+ # URL if you're displaying the results in your own user interface.
30
+ # Otherwise, use the webSearchUrl URL.
31
+ attr_accessor :search_link
32
+
33
+ # @return [ImageObject] The URL to a thumbnail of a related image.
34
+ attr_accessor :thumbnail
35
+
36
+
37
+ #
38
+ # Mapper for Query class as Ruby Hash.
39
+ # This will be used for serialization/deserialization.
40
+ #
41
+ def self.mapper()
42
+ {
43
+ client_side_validation: true,
44
+ required: false,
45
+ serialized_name: 'Query',
46
+ type: {
47
+ name: 'Composite',
48
+ class_name: 'Query',
49
+ model_properties: {
50
+ text: {
51
+ client_side_validation: true,
52
+ required: true,
53
+ serialized_name: 'text',
54
+ type: {
55
+ name: 'String'
56
+ }
57
+ },
58
+ display_text: {
59
+ client_side_validation: true,
60
+ required: false,
61
+ read_only: true,
62
+ serialized_name: 'displayText',
63
+ type: {
64
+ name: 'String'
65
+ }
66
+ },
67
+ web_search_url: {
68
+ client_side_validation: true,
69
+ required: false,
70
+ read_only: true,
71
+ serialized_name: 'webSearchUrl',
72
+ type: {
73
+ name: 'String'
74
+ }
75
+ },
76
+ search_link: {
77
+ client_side_validation: true,
78
+ required: false,
79
+ read_only: true,
80
+ serialized_name: 'searchLink',
81
+ type: {
82
+ name: 'String'
83
+ }
84
+ },
85
+ thumbnail: {
86
+ client_side_validation: true,
87
+ required: false,
88
+ read_only: true,
89
+ serialized_name: 'thumbnail',
90
+ type: {
91
+ name: 'Composite',
92
+ class_name: 'ImageObject'
93
+ }
94
+ }
95
+ }
96
+ }
97
+ }
98
+ end
99
+ end
100
+ end
101
+ end
@@ -0,0 +1,84 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::VisualSearch::V1_0
7
+ module Models
8
+ #
9
+ # Defines a rating.
10
+ #
11
+ class Rating < PropertiesItem
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ def initialize
17
+ @_type = "Rating"
18
+ end
19
+
20
+ attr_accessor :_type
21
+
22
+ # @return [Float] The mean (average) rating. The possible values are 1.0
23
+ # through 5.0.
24
+ attr_accessor :rating_value
25
+
26
+ # @return [Float] The highest rated review. The possible values are 1.0
27
+ # through 5.0.
28
+ attr_accessor :best_rating
29
+
30
+
31
+ #
32
+ # Mapper for Rating class as Ruby Hash.
33
+ # This will be used for serialization/deserialization.
34
+ #
35
+ def self.mapper()
36
+ {
37
+ client_side_validation: true,
38
+ required: false,
39
+ serialized_name: 'Rating',
40
+ type: {
41
+ name: 'Composite',
42
+ class_name: 'Rating',
43
+ model_properties: {
44
+ text: {
45
+ client_side_validation: true,
46
+ required: false,
47
+ read_only: true,
48
+ serialized_name: 'text',
49
+ type: {
50
+ name: 'String'
51
+ }
52
+ },
53
+ _type: {
54
+ client_side_validation: true,
55
+ required: true,
56
+ serialized_name: '_type',
57
+ type: {
58
+ name: 'String'
59
+ }
60
+ },
61
+ rating_value: {
62
+ client_side_validation: true,
63
+ required: true,
64
+ serialized_name: 'ratingValue',
65
+ type: {
66
+ name: 'Double'
67
+ }
68
+ },
69
+ best_rating: {
70
+ client_side_validation: true,
71
+ required: false,
72
+ read_only: true,
73
+ serialized_name: 'bestRating',
74
+ type: {
75
+ name: 'Double'
76
+ }
77
+ }
78
+ }
79
+ }
80
+ }
81
+ end
82
+ end
83
+ end
84
+ end
@@ -0,0 +1,219 @@
1
+ # encoding: utf-8
2
+ # Code generated by Microsoft (R) AutoRest Code Generator.
3
+ # Changes may cause incorrect behavior and will be lost if the code is
4
+ # regenerated.
5
+
6
+ module Azure::CognitiveServices::VisualSearch::V1_0
7
+ module Models
8
+ #
9
+ # Defines a cooking recipe.
10
+ #
11
+ class Recipe < CreativeWork
12
+
13
+ include MsRestAzure
14
+
15
+
16
+ def initialize
17
+ @_type = "Recipe"
18
+ end
19
+
20
+ attr_accessor :_type
21
+
22
+ # @return [String] The amount of time the food takes to cook. For
23
+ # example, PT25M. For information about the time format, see
24
+ # http://en.wikipedia.org/wiki/ISO_8601#Durations.
25
+ attr_accessor :cook_time
26
+
27
+ # @return [String] The amount of time required to prepare the
28
+ # ingredients. For example, PT15M. For information about the time format,
29
+ # see http://en.wikipedia.org/wiki/ISO_8601#Durations.
30
+ attr_accessor :prep_time
31
+
32
+ # @return [String] The total amount of time it takes to prepare and cook
33
+ # the recipe. For example, PT45M. For information about the time format,
34
+ # see http://en.wikipedia.org/wiki/ISO_8601#Durations.
35
+ attr_accessor :total_time
36
+
37
+
38
+ #
39
+ # Mapper for Recipe class as Ruby Hash.
40
+ # This will be used for serialization/deserialization.
41
+ #
42
+ def self.mapper()
43
+ {
44
+ client_side_validation: true,
45
+ required: false,
46
+ serialized_name: 'Recipe',
47
+ type: {
48
+ name: 'Composite',
49
+ class_name: 'Recipe',
50
+ model_properties: {
51
+ _type: {
52
+ client_side_validation: true,
53
+ required: true,
54
+ serialized_name: '_type',
55
+ type: {
56
+ name: 'String'
57
+ }
58
+ },
59
+ id: {
60
+ client_side_validation: true,
61
+ required: false,
62
+ read_only: true,
63
+ serialized_name: 'id',
64
+ type: {
65
+ name: 'String'
66
+ }
67
+ },
68
+ read_link: {
69
+ client_side_validation: true,
70
+ required: false,
71
+ read_only: true,
72
+ serialized_name: 'readLink',
73
+ type: {
74
+ name: 'String'
75
+ }
76
+ },
77
+ web_search_url: {
78
+ client_side_validation: true,
79
+ required: false,
80
+ read_only: true,
81
+ serialized_name: 'webSearchUrl',
82
+ type: {
83
+ name: 'String'
84
+ }
85
+ },
86
+ name: {
87
+ client_side_validation: true,
88
+ required: false,
89
+ read_only: true,
90
+ serialized_name: 'name',
91
+ type: {
92
+ name: 'String'
93
+ }
94
+ },
95
+ url: {
96
+ client_side_validation: true,
97
+ required: false,
98
+ read_only: true,
99
+ serialized_name: 'url',
100
+ type: {
101
+ name: 'String'
102
+ }
103
+ },
104
+ image: {
105
+ client_side_validation: true,
106
+ required: false,
107
+ read_only: true,
108
+ serialized_name: 'image',
109
+ type: {
110
+ name: 'Composite',
111
+ class_name: 'ImageObject'
112
+ }
113
+ },
114
+ description: {
115
+ client_side_validation: true,
116
+ required: false,
117
+ read_only: true,
118
+ serialized_name: 'description',
119
+ type: {
120
+ name: 'String'
121
+ }
122
+ },
123
+ alternate_name: {
124
+ client_side_validation: true,
125
+ required: false,
126
+ read_only: true,
127
+ serialized_name: 'alternateName',
128
+ type: {
129
+ name: 'String'
130
+ }
131
+ },
132
+ bing_id: {
133
+ client_side_validation: true,
134
+ required: false,
135
+ read_only: true,
136
+ serialized_name: 'bingId',
137
+ type: {
138
+ name: 'String'
139
+ }
140
+ },
141
+ thumbnail_url: {
142
+ client_side_validation: true,
143
+ required: false,
144
+ read_only: true,
145
+ serialized_name: 'thumbnailUrl',
146
+ type: {
147
+ name: 'String'
148
+ }
149
+ },
150
+ provider: {
151
+ client_side_validation: true,
152
+ required: false,
153
+ read_only: true,
154
+ serialized_name: 'provider',
155
+ type: {
156
+ name: 'Sequence',
157
+ element: {
158
+ client_side_validation: true,
159
+ required: false,
160
+ serialized_name: 'ThingElementType',
161
+ type: {
162
+ name: 'Composite',
163
+ class_name: 'Thing'
164
+ }
165
+ }
166
+ }
167
+ },
168
+ date_published: {
169
+ client_side_validation: true,
170
+ required: false,
171
+ read_only: true,
172
+ serialized_name: 'datePublished',
173
+ type: {
174
+ name: 'String'
175
+ }
176
+ },
177
+ text: {
178
+ client_side_validation: true,
179
+ required: false,
180
+ read_only: true,
181
+ serialized_name: 'text',
182
+ type: {
183
+ name: 'String'
184
+ }
185
+ },
186
+ cook_time: {
187
+ client_side_validation: true,
188
+ required: false,
189
+ read_only: true,
190
+ serialized_name: 'cookTime',
191
+ type: {
192
+ name: 'String'
193
+ }
194
+ },
195
+ prep_time: {
196
+ client_side_validation: true,
197
+ required: false,
198
+ read_only: true,
199
+ serialized_name: 'prepTime',
200
+ type: {
201
+ name: 'String'
202
+ }
203
+ },
204
+ total_time: {
205
+ client_side_validation: true,
206
+ required: false,
207
+ read_only: true,
208
+ serialized_name: 'totalTime',
209
+ type: {
210
+ name: 'String'
211
+ }
212
+ }
213
+ }
214
+ }
215
+ }
216
+ end
217
+ end
218
+ end
219
+ end