azure_cognitiveservices_customsearch 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (32) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE.txt +21 -0
  3. data/lib/1.0/generated/azure_cognitiveservices_customsearch.rb +47 -0
  4. data/lib/1.0/generated/azure_cognitiveservices_customsearch/custom_instance.rb +653 -0
  5. data/lib/1.0/generated/azure_cognitiveservices_customsearch/custom_search_client.rb +127 -0
  6. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/answer.rb +90 -0
  7. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/creative_work.rb +150 -0
  8. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/error.rb +116 -0
  9. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_code.rb +20 -0
  10. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_response.rb +89 -0
  11. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_sub_code.rb +25 -0
  12. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/identifiable.rb +62 -0
  13. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/query.rb +87 -0
  14. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/query_context.rb +94 -0
  15. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/response.rb +72 -0
  16. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/response_base.rb +56 -0
  17. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/safe_search.rb +17 -0
  18. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/search_response.rb +100 -0
  19. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/search_results_answer.rb +126 -0
  20. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/text_format.rb +16 -0
  21. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/thing.rb +118 -0
  22. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_meta_tag.rb +59 -0
  23. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_page.rb +228 -0
  24. data/lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_web_answer.rb +149 -0
  25. data/lib/1.0/generated/azure_cognitiveservices_customsearch/module_definition.rb +9 -0
  26. data/lib/azure_cognitiveservices_customsearch.rb +6 -0
  27. data/lib/module_definition.rb +7 -0
  28. data/lib/profiles/latest/customsearch_latest_profile_client.rb +38 -0
  29. data/lib/profiles/latest/customsearch_module_definition.rb +8 -0
  30. data/lib/profiles/latest/modules/customsearch_profile_module.rb +135 -0
  31. data/lib/version.rb +7 -0
  32. metadata +149 -0
@@ -0,0 +1,135 @@
1
+ # encoding: utf-8
2
+ # Copyright (c) Microsoft Corporation. All rights reserved.
3
+ # Licensed under the MIT License. See License.txt in the project root for license information.
4
+
5
+ require 'azure_cognitiveservices_customsearch'
6
+
7
+ module Azure::CustomSearch::Profiles::Latest
8
+ CustomInstance = Azure::CognitiveServices::CustomSearch::V1_0::CustomInstance
9
+
10
+ module Models
11
+ ResponseBase = Azure::CognitiveServices::CustomSearch::V1_0::Models::ResponseBase
12
+ QueryContext = Azure::CognitiveServices::CustomSearch::V1_0::Models::QueryContext
13
+ Query = Azure::CognitiveServices::CustomSearch::V1_0::Models::Query
14
+ Error = Azure::CognitiveServices::CustomSearch::V1_0::Models::Error
15
+ WebMetaTag = Azure::CognitiveServices::CustomSearch::V1_0::Models::WebMetaTag
16
+ WebPage = Azure::CognitiveServices::CustomSearch::V1_0::Models::WebPage
17
+ WebWebAnswer = Azure::CognitiveServices::CustomSearch::V1_0::Models::WebWebAnswer
18
+ SearchResponse = Azure::CognitiveServices::CustomSearch::V1_0::Models::SearchResponse
19
+ SearchResultsAnswer = Azure::CognitiveServices::CustomSearch::V1_0::Models::SearchResultsAnswer
20
+ Identifiable = Azure::CognitiveServices::CustomSearch::V1_0::Models::Identifiable
21
+ Response = Azure::CognitiveServices::CustomSearch::V1_0::Models::Response
22
+ ErrorResponse = Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorResponse
23
+ Answer = Azure::CognitiveServices::CustomSearch::V1_0::Models::Answer
24
+ Thing = Azure::CognitiveServices::CustomSearch::V1_0::Models::Thing
25
+ CreativeWork = Azure::CognitiveServices::CustomSearch::V1_0::Models::CreativeWork
26
+ ErrorCode = Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorCode
27
+ ErrorSubCode = Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorSubCode
28
+ SafeSearch = Azure::CognitiveServices::CustomSearch::V1_0::Models::SafeSearch
29
+ TextFormat = Azure::CognitiveServices::CustomSearch::V1_0::Models::TextFormat
30
+ end
31
+
32
+ #
33
+ # CustomSearchDataClass
34
+ #
35
+ class CustomSearchDataClass
36
+ attr_reader :custom_instance, :configurable, :base_url, :options, :model_classes
37
+
38
+ def initialize(options = {})
39
+ if options.is_a?(Hash) && options.length == 0
40
+ @options = setup_default_options
41
+ else
42
+ @options = options
43
+ end
44
+
45
+ reset!(options)
46
+
47
+ @configurable = self
48
+ @base_url = options[:base_url].nil? ? nil:options[:base_url]
49
+ @options = options[:options].nil? ? nil:options[:options]
50
+
51
+ @client_0 = Azure::CognitiveServices::CustomSearch::V1_0::CustomSearchClient.new(configurable.credentials, base_url, options)
52
+ if(@client_0.respond_to?(:subscription_id))
53
+ @client_0.subscription_id = configurable.subscription_id
54
+ end
55
+ add_telemetry(@client_0)
56
+ @custom_instance = @client_0.custom_instance
57
+
58
+ @model_classes = ModelClasses.new
59
+ end
60
+
61
+ def add_telemetry(client)
62
+ profile_information = 'Profiles/Latest/CustomSearch'
63
+ client.add_user_agent_information(profile_information)
64
+ end
65
+
66
+ def method_missing(method, *args)
67
+ if @client_0.respond_to?method
68
+ @client_0.send(method, *args)
69
+ else
70
+ super
71
+ end
72
+ end
73
+
74
+ end
75
+
76
+ class ModelClasses
77
+ def response_base
78
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::ResponseBase
79
+ end
80
+ def query_context
81
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::QueryContext
82
+ end
83
+ def query
84
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Query
85
+ end
86
+ def error
87
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Error
88
+ end
89
+ def web_meta_tag
90
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::WebMetaTag
91
+ end
92
+ def web_page
93
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::WebPage
94
+ end
95
+ def web_web_answer
96
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::WebWebAnswer
97
+ end
98
+ def search_response
99
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::SearchResponse
100
+ end
101
+ def search_results_answer
102
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::SearchResultsAnswer
103
+ end
104
+ def identifiable
105
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Identifiable
106
+ end
107
+ def response
108
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Response
109
+ end
110
+ def error_response
111
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorResponse
112
+ end
113
+ def answer
114
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Answer
115
+ end
116
+ def thing
117
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::Thing
118
+ end
119
+ def creative_work
120
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::CreativeWork
121
+ end
122
+ def error_code
123
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorCode
124
+ end
125
+ def error_sub_code
126
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::ErrorSubCode
127
+ end
128
+ def safe_search
129
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::SafeSearch
130
+ end
131
+ def text_format
132
+ Azure::CognitiveServices::CustomSearch::V1_0::Models::TextFormat
133
+ end
134
+ end
135
+ end
data/lib/version.rb ADDED
@@ -0,0 +1,7 @@
1
+ # encoding: utf-8
2
+ # Copyright (c) Microsoft Corporation. All rights reserved.
3
+ # Licensed under the MIT License. See License.txt in the project root for license information.
4
+
5
+ module Azure::CognitiveServices::CustomSearch
6
+ VERSION = '0.16.0'
7
+ end
metadata ADDED
@@ -0,0 +1,149 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: azure_cognitiveservices_customsearch
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.16.0
5
+ platform: ruby
6
+ authors:
7
+ - Microsoft Corporation
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2018-02-12 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.9'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.9'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '10'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '10'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '3'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '3'
55
+ - !ruby/object:Gem::Dependency
56
+ name: dotenv
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '2'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '2'
69
+ - !ruby/object:Gem::Dependency
70
+ name: ms_rest_azure
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: 0.10.0
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: 0.10.0
83
+ description: Microsoft Azure Cognitive Services Custom Search Client Library for Ruby
84
+ email: azrubyteam@microsoft.com
85
+ executables: []
86
+ extensions: []
87
+ extra_rdoc_files: []
88
+ files:
89
+ - LICENSE.txt
90
+ - lib/1.0/generated/azure_cognitiveservices_customsearch.rb
91
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/custom_instance.rb
92
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/custom_search_client.rb
93
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/answer.rb
94
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/creative_work.rb
95
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/error.rb
96
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_code.rb
97
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_response.rb
98
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/error_sub_code.rb
99
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/identifiable.rb
100
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/query.rb
101
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/query_context.rb
102
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/response.rb
103
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/response_base.rb
104
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/safe_search.rb
105
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/search_response.rb
106
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/search_results_answer.rb
107
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/text_format.rb
108
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/thing.rb
109
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_meta_tag.rb
110
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_page.rb
111
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/models/web_web_answer.rb
112
+ - lib/1.0/generated/azure_cognitiveservices_customsearch/module_definition.rb
113
+ - lib/azure_cognitiveservices_customsearch.rb
114
+ - lib/module_definition.rb
115
+ - lib/profiles/latest/customsearch_latest_profile_client.rb
116
+ - lib/profiles/latest/customsearch_module_definition.rb
117
+ - lib/profiles/latest/modules/customsearch_profile_module.rb
118
+ - lib/version.rb
119
+ homepage: https://aka.ms/azure-sdk-for-ruby
120
+ licenses:
121
+ - MIT
122
+ metadata:
123
+ bug_tracker_uri: https://github.com/Azure/azure-sdk-for-ruby/issues
124
+ changelog_uri: https://github.com/Azure/azure-sdk-for-ruby/blob/master/ChangeLog.md
125
+ documentation_uri: https://azure.microsoft.com/en-us/develop/ruby/
126
+ homepage_uri: https://aka.ms/azure-sdk-for-ruby
127
+ source_code_uri: https://github.com/Azure/azure-sdk-for-ruby/tree/master/data/azure_cognitiveservices_customsearch
128
+ post_install_message:
129
+ rdoc_options: []
130
+ require_paths:
131
+ - lib
132
+ required_ruby_version: !ruby/object:Gem::Requirement
133
+ requirements:
134
+ - - ">="
135
+ - !ruby/object:Gem::Version
136
+ version: 2.0.0
137
+ required_rubygems_version: !ruby/object:Gem::Requirement
138
+ requirements:
139
+ - - ">="
140
+ - !ruby/object:Gem::Version
141
+ version: '0'
142
+ requirements: []
143
+ rubyforge_project:
144
+ rubygems_version: 2.5.1
145
+ signing_key:
146
+ specification_version: 4
147
+ summary: Official Ruby client library to consume Microsoft Azure Cognitive Services
148
+ Custom Search.
149
+ test_files: []