aws-sdk-rekognition 1.70.0 → 1.71.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,194 @@
1
+ # frozen_string_literal: true
2
+
3
+ # WARNING ABOUT GENERATED CODE
4
+ #
5
+ # This file is generated. See the contributing guide for more information:
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
7
+ #
8
+ # WARNING ABOUT GENERATED CODE
9
+
10
+
11
+ module Aws::Rekognition
12
+ module Plugins
13
+ class Endpoints < Seahorse::Client::Plugin
14
+ option(
15
+ :endpoint_provider,
16
+ doc_type: 'Aws::Rekognition::EndpointProvider',
17
+ docstring: 'The endpoint provider used to resolve endpoints. Any '\
18
+ 'object that responds to `#resolve_endpoint(parameters)` '\
19
+ 'where `parameters` is a Struct similar to '\
20
+ '`Aws::Rekognition::EndpointParameters`'
21
+ ) do |cfg|
22
+ Aws::Rekognition::EndpointProvider.new
23
+ end
24
+
25
+ # @api private
26
+ class Handler < Seahorse::Client::Handler
27
+ def call(context)
28
+ # If endpoint was discovered, do not resolve or apply the endpoint.
29
+ unless context[:discovered_endpoint]
30
+ params = parameters_for_operation(context)
31
+ endpoint = context.config.endpoint_provider.resolve_endpoint(params)
32
+
33
+ context.http_request.endpoint = endpoint.url
34
+ apply_endpoint_headers(context, endpoint.headers)
35
+ end
36
+
37
+ context[:endpoint_params] = params
38
+ context[:auth_scheme] =
39
+ Aws::Endpoints.resolve_auth_scheme(context, endpoint)
40
+
41
+ @handler.call(context)
42
+ end
43
+
44
+ private
45
+
46
+ def apply_endpoint_headers(context, headers)
47
+ headers.each do |key, values|
48
+ value = values
49
+ .compact
50
+ .map { |s| Seahorse::Util.escape_header_list_string(s.to_s) }
51
+ .join(',')
52
+
53
+ context.http_request.headers[key] = value
54
+ end
55
+ end
56
+
57
+ def parameters_for_operation(context)
58
+ case context.operation_name
59
+ when :compare_faces
60
+ Aws::Rekognition::Endpoints::CompareFaces.build(context)
61
+ when :copy_project_version
62
+ Aws::Rekognition::Endpoints::CopyProjectVersion.build(context)
63
+ when :create_collection
64
+ Aws::Rekognition::Endpoints::CreateCollection.build(context)
65
+ when :create_dataset
66
+ Aws::Rekognition::Endpoints::CreateDataset.build(context)
67
+ when :create_project
68
+ Aws::Rekognition::Endpoints::CreateProject.build(context)
69
+ when :create_project_version
70
+ Aws::Rekognition::Endpoints::CreateProjectVersion.build(context)
71
+ when :create_stream_processor
72
+ Aws::Rekognition::Endpoints::CreateStreamProcessor.build(context)
73
+ when :delete_collection
74
+ Aws::Rekognition::Endpoints::DeleteCollection.build(context)
75
+ when :delete_dataset
76
+ Aws::Rekognition::Endpoints::DeleteDataset.build(context)
77
+ when :delete_faces
78
+ Aws::Rekognition::Endpoints::DeleteFaces.build(context)
79
+ when :delete_project
80
+ Aws::Rekognition::Endpoints::DeleteProject.build(context)
81
+ when :delete_project_policy
82
+ Aws::Rekognition::Endpoints::DeleteProjectPolicy.build(context)
83
+ when :delete_project_version
84
+ Aws::Rekognition::Endpoints::DeleteProjectVersion.build(context)
85
+ when :delete_stream_processor
86
+ Aws::Rekognition::Endpoints::DeleteStreamProcessor.build(context)
87
+ when :describe_collection
88
+ Aws::Rekognition::Endpoints::DescribeCollection.build(context)
89
+ when :describe_dataset
90
+ Aws::Rekognition::Endpoints::DescribeDataset.build(context)
91
+ when :describe_project_versions
92
+ Aws::Rekognition::Endpoints::DescribeProjectVersions.build(context)
93
+ when :describe_projects
94
+ Aws::Rekognition::Endpoints::DescribeProjects.build(context)
95
+ when :describe_stream_processor
96
+ Aws::Rekognition::Endpoints::DescribeStreamProcessor.build(context)
97
+ when :detect_custom_labels
98
+ Aws::Rekognition::Endpoints::DetectCustomLabels.build(context)
99
+ when :detect_faces
100
+ Aws::Rekognition::Endpoints::DetectFaces.build(context)
101
+ when :detect_labels
102
+ Aws::Rekognition::Endpoints::DetectLabels.build(context)
103
+ when :detect_moderation_labels
104
+ Aws::Rekognition::Endpoints::DetectModerationLabels.build(context)
105
+ when :detect_protective_equipment
106
+ Aws::Rekognition::Endpoints::DetectProtectiveEquipment.build(context)
107
+ when :detect_text
108
+ Aws::Rekognition::Endpoints::DetectText.build(context)
109
+ when :distribute_dataset_entries
110
+ Aws::Rekognition::Endpoints::DistributeDatasetEntries.build(context)
111
+ when :get_celebrity_info
112
+ Aws::Rekognition::Endpoints::GetCelebrityInfo.build(context)
113
+ when :get_celebrity_recognition
114
+ Aws::Rekognition::Endpoints::GetCelebrityRecognition.build(context)
115
+ when :get_content_moderation
116
+ Aws::Rekognition::Endpoints::GetContentModeration.build(context)
117
+ when :get_face_detection
118
+ Aws::Rekognition::Endpoints::GetFaceDetection.build(context)
119
+ when :get_face_search
120
+ Aws::Rekognition::Endpoints::GetFaceSearch.build(context)
121
+ when :get_label_detection
122
+ Aws::Rekognition::Endpoints::GetLabelDetection.build(context)
123
+ when :get_person_tracking
124
+ Aws::Rekognition::Endpoints::GetPersonTracking.build(context)
125
+ when :get_segment_detection
126
+ Aws::Rekognition::Endpoints::GetSegmentDetection.build(context)
127
+ when :get_text_detection
128
+ Aws::Rekognition::Endpoints::GetTextDetection.build(context)
129
+ when :index_faces
130
+ Aws::Rekognition::Endpoints::IndexFaces.build(context)
131
+ when :list_collections
132
+ Aws::Rekognition::Endpoints::ListCollections.build(context)
133
+ when :list_dataset_entries
134
+ Aws::Rekognition::Endpoints::ListDatasetEntries.build(context)
135
+ when :list_dataset_labels
136
+ Aws::Rekognition::Endpoints::ListDatasetLabels.build(context)
137
+ when :list_faces
138
+ Aws::Rekognition::Endpoints::ListFaces.build(context)
139
+ when :list_project_policies
140
+ Aws::Rekognition::Endpoints::ListProjectPolicies.build(context)
141
+ when :list_stream_processors
142
+ Aws::Rekognition::Endpoints::ListStreamProcessors.build(context)
143
+ when :list_tags_for_resource
144
+ Aws::Rekognition::Endpoints::ListTagsForResource.build(context)
145
+ when :put_project_policy
146
+ Aws::Rekognition::Endpoints::PutProjectPolicy.build(context)
147
+ when :recognize_celebrities
148
+ Aws::Rekognition::Endpoints::RecognizeCelebrities.build(context)
149
+ when :search_faces
150
+ Aws::Rekognition::Endpoints::SearchFaces.build(context)
151
+ when :search_faces_by_image
152
+ Aws::Rekognition::Endpoints::SearchFacesByImage.build(context)
153
+ when :start_celebrity_recognition
154
+ Aws::Rekognition::Endpoints::StartCelebrityRecognition.build(context)
155
+ when :start_content_moderation
156
+ Aws::Rekognition::Endpoints::StartContentModeration.build(context)
157
+ when :start_face_detection
158
+ Aws::Rekognition::Endpoints::StartFaceDetection.build(context)
159
+ when :start_face_search
160
+ Aws::Rekognition::Endpoints::StartFaceSearch.build(context)
161
+ when :start_label_detection
162
+ Aws::Rekognition::Endpoints::StartLabelDetection.build(context)
163
+ when :start_person_tracking
164
+ Aws::Rekognition::Endpoints::StartPersonTracking.build(context)
165
+ when :start_project_version
166
+ Aws::Rekognition::Endpoints::StartProjectVersion.build(context)
167
+ when :start_segment_detection
168
+ Aws::Rekognition::Endpoints::StartSegmentDetection.build(context)
169
+ when :start_stream_processor
170
+ Aws::Rekognition::Endpoints::StartStreamProcessor.build(context)
171
+ when :start_text_detection
172
+ Aws::Rekognition::Endpoints::StartTextDetection.build(context)
173
+ when :stop_project_version
174
+ Aws::Rekognition::Endpoints::StopProjectVersion.build(context)
175
+ when :stop_stream_processor
176
+ Aws::Rekognition::Endpoints::StopStreamProcessor.build(context)
177
+ when :tag_resource
178
+ Aws::Rekognition::Endpoints::TagResource.build(context)
179
+ when :untag_resource
180
+ Aws::Rekognition::Endpoints::UntagResource.build(context)
181
+ when :update_dataset_entries
182
+ Aws::Rekognition::Endpoints::UpdateDatasetEntries.build(context)
183
+ when :update_stream_processor
184
+ Aws::Rekognition::Endpoints::UpdateStreamProcessor.build(context)
185
+ end
186
+ end
187
+ end
188
+
189
+ def add_handlers(handlers, _config)
190
+ handlers.add(Handler, step: :build, priority: 75)
191
+ end
192
+ end
193
+ end
194
+ end
@@ -13,10 +13,14 @@ require 'aws-sigv4'
13
13
 
14
14
  require_relative 'aws-sdk-rekognition/types'
15
15
  require_relative 'aws-sdk-rekognition/client_api'
16
+ require_relative 'aws-sdk-rekognition/plugins/endpoints.rb'
16
17
  require_relative 'aws-sdk-rekognition/client'
17
18
  require_relative 'aws-sdk-rekognition/errors'
18
19
  require_relative 'aws-sdk-rekognition/waiters'
19
20
  require_relative 'aws-sdk-rekognition/resource'
21
+ require_relative 'aws-sdk-rekognition/endpoint_parameters'
22
+ require_relative 'aws-sdk-rekognition/endpoint_provider'
23
+ require_relative 'aws-sdk-rekognition/endpoints'
20
24
  require_relative 'aws-sdk-rekognition/customizations'
21
25
 
22
26
  # This module provides support for Amazon Rekognition. This module is available in the
@@ -49,6 +53,6 @@ require_relative 'aws-sdk-rekognition/customizations'
49
53
  # @!group service
50
54
  module Aws::Rekognition
51
55
 
52
- GEM_VERSION = '1.70.0'
56
+ GEM_VERSION = '1.71.0'
53
57
 
54
58
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-rekognition
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.70.0
4
+ version: 1.71.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-16 00:00:00.000000000 Z
11
+ date: 2022-10-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '3'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 3.127.0
22
+ version: 3.165.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: '3'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 3.127.0
32
+ version: 3.165.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -59,7 +59,11 @@ files:
59
59
  - lib/aws-sdk-rekognition/client.rb
60
60
  - lib/aws-sdk-rekognition/client_api.rb
61
61
  - lib/aws-sdk-rekognition/customizations.rb
62
+ - lib/aws-sdk-rekognition/endpoint_parameters.rb
63
+ - lib/aws-sdk-rekognition/endpoint_provider.rb
64
+ - lib/aws-sdk-rekognition/endpoints.rb
62
65
  - lib/aws-sdk-rekognition/errors.rb
66
+ - lib/aws-sdk-rekognition/plugins/endpoints.rb
63
67
  - lib/aws-sdk-rekognition/resource.rb
64
68
  - lib/aws-sdk-rekognition/types.rb
65
69
  - lib/aws-sdk-rekognition/waiters.rb