Sha256: 76ea61ae4f181e0228a0f1279a21ffd9b3dde828fe822caeebe78fb2dfb3594c
Contents?: true
Size: 1.71 KB
Versions: 8
Compression:
Stored size: 1.71 KB
Contents
module Aws # Base class for all {Aws} service clients. class Client < Seahorse::Client::Base # @api private DEFAULT_PLUGINS = [ 'Seahorse::Client::Plugins::Logging', 'Seahorse::Client::Plugins::ContentLength', 'Aws::Plugins::ParamConverter', 'Aws::Plugins::ParamValidator', 'Aws::Plugins::UserAgent', 'Aws::Plugins::RetryErrors', 'Aws::Plugins::GlobalConfiguration', 'Aws::Plugins::RegionalEndpoint', 'Aws::Plugins::RequestSigner', 'Aws::Plugins::ResponsePaging', 'Aws::Plugins::StubResponses', ] # @api private PROTOCOL_PLUGINS = Hash.new(DEFAULT_PLUGINS).merge({ 'json' => DEFAULT_PLUGINS + %w(Aws::Plugins::Protocols::JsonRpc), 'rest-json' => DEFAULT_PLUGINS + %w(Aws::Plugins::Protocols::RestJson), 'rest-xml' => DEFAULT_PLUGINS + %w(Aws::Plugins::Protocols::RestXml), 'query' => DEFAULT_PLUGINS + %w(Aws::Plugins::Protocols::Query), 'ec2' => DEFAULT_PLUGINS + %w(Aws::Plugins::Protocols::EC2), }) include ClientStubs include ClientWaiters class << self # @return [Symbol] # @api private attr_accessor :identifier # @api private def define(svc_name, options) client_class = Class.new(self) client_class.identifier = svc_name.downcase.to_sym client_class.set_api(Api::Builder.build(options[:api], options)) client_class.set_waiters(options[:waiters]) protocol = client_class.api.metadata['protocol'] PROTOCOL_PLUGINS[protocol].each do |plugin| client_class.add_plugin(plugin) end Api::Customizations.apply_plugins(client_class) client_class end end end end
Version data entries
8 entries across 8 versions & 1 rubygems