Class: Aws::Plugins::EC2RegionValidation Private
- Inherits:
-
Seahorse::Client::Plugin
- Object
- Seahorse::Client::Plugin
- Aws::Plugins::EC2RegionValidation
- Defined in:
- lib/aws-sdk-core/plugins/ec2_region_validation.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
Methods inherited from Seahorse::Client::Plugin
#add_handlers, #add_options, after_initialize, after_initialize_hooks, before_initialize, #before_initialize, before_initialize_hooks, handlers, option, options
Methods included from Seahorse::Client::HandlerBuilder
#handle, #handle_request, #handle_response, #handler_for, #new_handler
Instance Method Details
#after_initialize(client) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 9 10 11 12 13 14 |
# File 'lib/aws-sdk-core/plugins/ec2_region_validation.rb', line 6 def after_initialize(client) if region = client.config.region if matches = region.match(/^(\w+-\w+-\d+)[a-z]$/) msg = ":region option must a region name, not an availability " msg << "zone name; try `#{matches[1]}' instead of `#{matches[0]}'" raise ArgumentError, msg end end end |