azure_cognitiveservices_websearch 0.16.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch.rb +69 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/answer.rb +90 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/answer_type.rb +22 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/article.rb +163 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/computation.rb +119 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/creative_work.rb +160 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/error.rb +116 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/error_code.rb +20 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/error_response.rb +89 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/error_sub_code.rb +25 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/freshness.rb +17 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/identifiable.rb +62 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/image_object.rb +199 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/images.rb +210 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/intangible.rb +115 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/media_object.rb +200 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/news.rb +148 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/news_article.rb +159 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/places.rb +135 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/query.rb +100 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/query_context.rb +126 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/ranking_ranking_group.rb +56 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/ranking_ranking_item.rb +116 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/ranking_ranking_response.rb +79 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/related_searches_related_search_answer.rb +135 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/response.rb +72 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/response_base.rb +71 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/safe_search.rb +17 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/search_response.rb +212 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/search_results_answer.rb +126 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/spell_suggestions.rb +141 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/structured_value.rb +115 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/text_format.rb +16 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/thing.rb +131 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/time_zone.rb +157 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/time_zone_time_zone_information.rb +70 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/video_object.rb +295 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/videos.rb +189 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/web_meta_tag.rb +59 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/web_page.rb +251 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/web_web_answer.rb +149 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/models/web_web_grouping.rb +66 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/module_definition.rb +9 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/web.rb +775 -0
- data/lib/1.0/generated/azure_cognitiveservices_websearch/web_search_client.rb +127 -0
- data/lib/azure_cognitiveservices_websearch.rb +6 -0
- data/lib/module_definition.rb +7 -0
- data/lib/profiles/latest/modules/websearch_profile_module.rb +223 -0
- data/lib/profiles/latest/websearch_latest_profile_client.rb +38 -0
- data/lib/profiles/latest/websearch_module_definition.rb +8 -0
- data/lib/version.rb +7 -0
- metadata +171 -0
@@ -0,0 +1,200 @@
|
|
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::WebSearch::V1_0
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Model object.
|
10
|
+
#
|
11
|
+
#
|
12
|
+
class MediaObject < CreativeWork
|
13
|
+
|
14
|
+
include MsRestAzure
|
15
|
+
|
16
|
+
|
17
|
+
def initialize
|
18
|
+
@_type = "MediaObject"
|
19
|
+
end
|
20
|
+
|
21
|
+
attr_accessor :_type
|
22
|
+
|
23
|
+
# @return [String] Original URL to retrieve the source (file) for the
|
24
|
+
# media object (e.g the source URL for the image).
|
25
|
+
attr_accessor :content_url
|
26
|
+
|
27
|
+
# @return [String] URL of the page that hosts the media object.
|
28
|
+
attr_accessor :host_page_url
|
29
|
+
|
30
|
+
# @return [Integer] The width of the source media object, in pixels.
|
31
|
+
attr_accessor :width
|
32
|
+
|
33
|
+
# @return [Integer] The height of the source media object, in pixels.
|
34
|
+
attr_accessor :height
|
35
|
+
|
36
|
+
|
37
|
+
#
|
38
|
+
# Mapper for MediaObject 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: 'MediaObject',
|
46
|
+
type: {
|
47
|
+
name: 'Composite',
|
48
|
+
class_name: 'MediaObject',
|
49
|
+
model_properties: {
|
50
|
+
_type: {
|
51
|
+
client_side_validation: true,
|
52
|
+
required: true,
|
53
|
+
serialized_name: '_type',
|
54
|
+
type: {
|
55
|
+
name: 'String'
|
56
|
+
}
|
57
|
+
},
|
58
|
+
id: {
|
59
|
+
client_side_validation: true,
|
60
|
+
required: false,
|
61
|
+
read_only: true,
|
62
|
+
serialized_name: 'id',
|
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
|
+
name: {
|
77
|
+
client_side_validation: true,
|
78
|
+
required: false,
|
79
|
+
read_only: true,
|
80
|
+
serialized_name: 'name',
|
81
|
+
type: {
|
82
|
+
name: 'String'
|
83
|
+
}
|
84
|
+
},
|
85
|
+
url: {
|
86
|
+
client_side_validation: true,
|
87
|
+
required: false,
|
88
|
+
read_only: true,
|
89
|
+
serialized_name: 'url',
|
90
|
+
type: {
|
91
|
+
name: 'String'
|
92
|
+
}
|
93
|
+
},
|
94
|
+
image: {
|
95
|
+
client_side_validation: true,
|
96
|
+
required: false,
|
97
|
+
read_only: true,
|
98
|
+
serialized_name: 'image',
|
99
|
+
type: {
|
100
|
+
name: 'Composite',
|
101
|
+
class_name: 'ImageObject'
|
102
|
+
}
|
103
|
+
},
|
104
|
+
description: {
|
105
|
+
client_side_validation: true,
|
106
|
+
required: false,
|
107
|
+
read_only: true,
|
108
|
+
serialized_name: 'description',
|
109
|
+
type: {
|
110
|
+
name: 'String'
|
111
|
+
}
|
112
|
+
},
|
113
|
+
bing_id: {
|
114
|
+
client_side_validation: true,
|
115
|
+
required: false,
|
116
|
+
read_only: true,
|
117
|
+
serialized_name: 'bingId',
|
118
|
+
type: {
|
119
|
+
name: 'String'
|
120
|
+
}
|
121
|
+
},
|
122
|
+
thumbnail_url: {
|
123
|
+
client_side_validation: true,
|
124
|
+
required: false,
|
125
|
+
read_only: true,
|
126
|
+
serialized_name: 'thumbnailUrl',
|
127
|
+
type: {
|
128
|
+
name: 'String'
|
129
|
+
}
|
130
|
+
},
|
131
|
+
provider: {
|
132
|
+
client_side_validation: true,
|
133
|
+
required: false,
|
134
|
+
read_only: true,
|
135
|
+
serialized_name: 'provider',
|
136
|
+
type: {
|
137
|
+
name: 'Sequence',
|
138
|
+
element: {
|
139
|
+
client_side_validation: true,
|
140
|
+
required: false,
|
141
|
+
serialized_name: 'ThingElementType',
|
142
|
+
type: {
|
143
|
+
name: 'Composite',
|
144
|
+
class_name: 'Thing'
|
145
|
+
}
|
146
|
+
}
|
147
|
+
}
|
148
|
+
},
|
149
|
+
text: {
|
150
|
+
client_side_validation: true,
|
151
|
+
required: false,
|
152
|
+
read_only: true,
|
153
|
+
serialized_name: 'text',
|
154
|
+
type: {
|
155
|
+
name: 'String'
|
156
|
+
}
|
157
|
+
},
|
158
|
+
content_url: {
|
159
|
+
client_side_validation: true,
|
160
|
+
required: false,
|
161
|
+
read_only: true,
|
162
|
+
serialized_name: 'contentUrl',
|
163
|
+
type: {
|
164
|
+
name: 'String'
|
165
|
+
}
|
166
|
+
},
|
167
|
+
host_page_url: {
|
168
|
+
client_side_validation: true,
|
169
|
+
required: false,
|
170
|
+
read_only: true,
|
171
|
+
serialized_name: 'hostPageUrl',
|
172
|
+
type: {
|
173
|
+
name: 'String'
|
174
|
+
}
|
175
|
+
},
|
176
|
+
width: {
|
177
|
+
client_side_validation: true,
|
178
|
+
required: false,
|
179
|
+
read_only: true,
|
180
|
+
serialized_name: 'width',
|
181
|
+
type: {
|
182
|
+
name: 'Number'
|
183
|
+
}
|
184
|
+
},
|
185
|
+
height: {
|
186
|
+
client_side_validation: true,
|
187
|
+
required: false,
|
188
|
+
read_only: true,
|
189
|
+
serialized_name: 'height',
|
190
|
+
type: {
|
191
|
+
name: 'Number'
|
192
|
+
}
|
193
|
+
}
|
194
|
+
}
|
195
|
+
}
|
196
|
+
}
|
197
|
+
end
|
198
|
+
end
|
199
|
+
end
|
200
|
+
end
|
@@ -0,0 +1,148 @@
|
|
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::WebSearch::V1_0
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Defines a news answer.
|
10
|
+
#
|
11
|
+
class News < SearchResultsAnswer
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
|
16
|
+
def initialize
|
17
|
+
@_type = "News"
|
18
|
+
end
|
19
|
+
|
20
|
+
attr_accessor :_type
|
21
|
+
|
22
|
+
# @return [Array<NewsArticle>] An array of NewsArticle objects that
|
23
|
+
# contain information about news articles that are relevant to the query.
|
24
|
+
# If there are no results to return for the request, the array is empty.
|
25
|
+
attr_accessor :value
|
26
|
+
|
27
|
+
# @return [String]
|
28
|
+
attr_accessor :location
|
29
|
+
|
30
|
+
|
31
|
+
#
|
32
|
+
# Mapper for News 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: 'News',
|
40
|
+
type: {
|
41
|
+
name: 'Composite',
|
42
|
+
class_name: 'News',
|
43
|
+
model_properties: {
|
44
|
+
_type: {
|
45
|
+
client_side_validation: true,
|
46
|
+
required: true,
|
47
|
+
serialized_name: '_type',
|
48
|
+
type: {
|
49
|
+
name: 'String'
|
50
|
+
}
|
51
|
+
},
|
52
|
+
id: {
|
53
|
+
client_side_validation: true,
|
54
|
+
required: false,
|
55
|
+
read_only: true,
|
56
|
+
serialized_name: 'id',
|
57
|
+
type: {
|
58
|
+
name: 'String'
|
59
|
+
}
|
60
|
+
},
|
61
|
+
web_search_url: {
|
62
|
+
client_side_validation: true,
|
63
|
+
required: false,
|
64
|
+
read_only: true,
|
65
|
+
serialized_name: 'webSearchUrl',
|
66
|
+
type: {
|
67
|
+
name: 'String'
|
68
|
+
}
|
69
|
+
},
|
70
|
+
follow_up_queries: {
|
71
|
+
client_side_validation: true,
|
72
|
+
required: false,
|
73
|
+
read_only: true,
|
74
|
+
serialized_name: 'followUpQueries',
|
75
|
+
type: {
|
76
|
+
name: 'Sequence',
|
77
|
+
element: {
|
78
|
+
client_side_validation: true,
|
79
|
+
required: false,
|
80
|
+
serialized_name: 'QueryElementType',
|
81
|
+
type: {
|
82
|
+
name: 'Composite',
|
83
|
+
class_name: 'Query'
|
84
|
+
}
|
85
|
+
}
|
86
|
+
}
|
87
|
+
},
|
88
|
+
query_context: {
|
89
|
+
client_side_validation: true,
|
90
|
+
required: false,
|
91
|
+
read_only: true,
|
92
|
+
serialized_name: 'queryContext',
|
93
|
+
type: {
|
94
|
+
name: 'Composite',
|
95
|
+
class_name: 'QueryContext'
|
96
|
+
}
|
97
|
+
},
|
98
|
+
total_estimated_matches: {
|
99
|
+
client_side_validation: true,
|
100
|
+
required: false,
|
101
|
+
read_only: true,
|
102
|
+
serialized_name: 'totalEstimatedMatches',
|
103
|
+
type: {
|
104
|
+
name: 'Number'
|
105
|
+
}
|
106
|
+
},
|
107
|
+
is_family_friendly: {
|
108
|
+
client_side_validation: true,
|
109
|
+
required: false,
|
110
|
+
read_only: true,
|
111
|
+
serialized_name: 'isFamilyFriendly',
|
112
|
+
type: {
|
113
|
+
name: 'Boolean'
|
114
|
+
}
|
115
|
+
},
|
116
|
+
value: {
|
117
|
+
client_side_validation: true,
|
118
|
+
required: true,
|
119
|
+
serialized_name: 'value',
|
120
|
+
type: {
|
121
|
+
name: 'Sequence',
|
122
|
+
element: {
|
123
|
+
client_side_validation: true,
|
124
|
+
required: false,
|
125
|
+
serialized_name: 'NewsArticleElementType',
|
126
|
+
type: {
|
127
|
+
name: 'Composite',
|
128
|
+
class_name: 'NewsArticle'
|
129
|
+
}
|
130
|
+
}
|
131
|
+
}
|
132
|
+
},
|
133
|
+
location: {
|
134
|
+
client_side_validation: true,
|
135
|
+
required: false,
|
136
|
+
read_only: true,
|
137
|
+
serialized_name: 'location',
|
138
|
+
type: {
|
139
|
+
name: 'String'
|
140
|
+
}
|
141
|
+
}
|
142
|
+
}
|
143
|
+
}
|
144
|
+
}
|
145
|
+
end
|
146
|
+
end
|
147
|
+
end
|
148
|
+
end
|
@@ -0,0 +1,159 @@
|
|
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::WebSearch::V1_0
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Defines a news article.
|
10
|
+
#
|
11
|
+
class NewsArticle < Article
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
|
16
|
+
def initialize
|
17
|
+
@_type = "NewsArticle"
|
18
|
+
end
|
19
|
+
|
20
|
+
attr_accessor :_type
|
21
|
+
|
22
|
+
|
23
|
+
#
|
24
|
+
# Mapper for NewsArticle class as Ruby Hash.
|
25
|
+
# This will be used for serialization/deserialization.
|
26
|
+
#
|
27
|
+
def self.mapper()
|
28
|
+
{
|
29
|
+
client_side_validation: true,
|
30
|
+
required: false,
|
31
|
+
serialized_name: 'NewsArticle',
|
32
|
+
type: {
|
33
|
+
name: 'Composite',
|
34
|
+
class_name: 'NewsArticle',
|
35
|
+
model_properties: {
|
36
|
+
_type: {
|
37
|
+
client_side_validation: true,
|
38
|
+
required: true,
|
39
|
+
serialized_name: '_type',
|
40
|
+
type: {
|
41
|
+
name: 'String'
|
42
|
+
}
|
43
|
+
},
|
44
|
+
id: {
|
45
|
+
client_side_validation: true,
|
46
|
+
required: false,
|
47
|
+
read_only: true,
|
48
|
+
serialized_name: 'id',
|
49
|
+
type: {
|
50
|
+
name: 'String'
|
51
|
+
}
|
52
|
+
},
|
53
|
+
web_search_url: {
|
54
|
+
client_side_validation: true,
|
55
|
+
required: false,
|
56
|
+
read_only: true,
|
57
|
+
serialized_name: 'webSearchUrl',
|
58
|
+
type: {
|
59
|
+
name: 'String'
|
60
|
+
}
|
61
|
+
},
|
62
|
+
name: {
|
63
|
+
client_side_validation: true,
|
64
|
+
required: false,
|
65
|
+
read_only: true,
|
66
|
+
serialized_name: 'name',
|
67
|
+
type: {
|
68
|
+
name: 'String'
|
69
|
+
}
|
70
|
+
},
|
71
|
+
url: {
|
72
|
+
client_side_validation: true,
|
73
|
+
required: false,
|
74
|
+
read_only: true,
|
75
|
+
serialized_name: 'url',
|
76
|
+
type: {
|
77
|
+
name: 'String'
|
78
|
+
}
|
79
|
+
},
|
80
|
+
image: {
|
81
|
+
client_side_validation: true,
|
82
|
+
required: false,
|
83
|
+
read_only: true,
|
84
|
+
serialized_name: 'image',
|
85
|
+
type: {
|
86
|
+
name: 'Composite',
|
87
|
+
class_name: 'ImageObject'
|
88
|
+
}
|
89
|
+
},
|
90
|
+
description: {
|
91
|
+
client_side_validation: true,
|
92
|
+
required: false,
|
93
|
+
read_only: true,
|
94
|
+
serialized_name: 'description',
|
95
|
+
type: {
|
96
|
+
name: 'String'
|
97
|
+
}
|
98
|
+
},
|
99
|
+
bing_id: {
|
100
|
+
client_side_validation: true,
|
101
|
+
required: false,
|
102
|
+
read_only: true,
|
103
|
+
serialized_name: 'bingId',
|
104
|
+
type: {
|
105
|
+
name: 'String'
|
106
|
+
}
|
107
|
+
},
|
108
|
+
thumbnail_url: {
|
109
|
+
client_side_validation: true,
|
110
|
+
required: false,
|
111
|
+
read_only: true,
|
112
|
+
serialized_name: 'thumbnailUrl',
|
113
|
+
type: {
|
114
|
+
name: 'String'
|
115
|
+
}
|
116
|
+
},
|
117
|
+
provider: {
|
118
|
+
client_side_validation: true,
|
119
|
+
required: false,
|
120
|
+
read_only: true,
|
121
|
+
serialized_name: 'provider',
|
122
|
+
type: {
|
123
|
+
name: 'Sequence',
|
124
|
+
element: {
|
125
|
+
client_side_validation: true,
|
126
|
+
required: false,
|
127
|
+
serialized_name: 'ThingElementType',
|
128
|
+
type: {
|
129
|
+
name: 'Composite',
|
130
|
+
class_name: 'Thing'
|
131
|
+
}
|
132
|
+
}
|
133
|
+
}
|
134
|
+
},
|
135
|
+
text: {
|
136
|
+
client_side_validation: true,
|
137
|
+
required: false,
|
138
|
+
read_only: true,
|
139
|
+
serialized_name: 'text',
|
140
|
+
type: {
|
141
|
+
name: 'String'
|
142
|
+
}
|
143
|
+
},
|
144
|
+
word_count: {
|
145
|
+
client_side_validation: true,
|
146
|
+
required: false,
|
147
|
+
read_only: true,
|
148
|
+
serialized_name: 'wordCount',
|
149
|
+
type: {
|
150
|
+
name: 'Number'
|
151
|
+
}
|
152
|
+
}
|
153
|
+
}
|
154
|
+
}
|
155
|
+
}
|
156
|
+
end
|
157
|
+
end
|
158
|
+
end
|
159
|
+
end
|