lib/aws-sdk-acm/errors.rb in aws-sdk-acm-1.27.0 vs lib/aws-sdk-acm/errors.rb in aws-sdk-acm-1.28.0
- old
+ new
@@ -4,10 +4,44 @@
# https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
#
# WARNING ABOUT GENERATED CODE
module Aws::ACM
+
+ # When ACM returns an error response, the Ruby SDK constructs and raises an error.
+ # These errors all extend Aws::ACM::Errors::ServiceError < {Aws::Errors::ServiceError}
+ #
+ # You can rescue all ACM errors using ServiceError:
+ #
+ # begin
+ # # do stuff
+ # rescue Aws::ACM::Errors::ServiceError
+ # # rescues all ACM API errors
+ # end
+ #
+ #
+ # ## Request Context
+ # ServiceError objects have a {Aws::Errors::ServiceError#context #context} method that returns
+ # information about the request that generated the error.
+ # See {Seahorse::Client::RequestContext} for more information.
+ #
+ # ## Error Classes
+ # * {InvalidArgsException}
+ # * {InvalidArnException}
+ # * {InvalidDomainValidationOptionsException}
+ # * {InvalidParameterException}
+ # * {InvalidStateException}
+ # * {InvalidTagException}
+ # * {LimitExceededException}
+ # * {RequestInProgressException}
+ # * {ResourceInUseException}
+ # * {ResourceNotFoundException}
+ # * {TagPolicyException}
+ # * {TooManyTagsException}
+ #
+ # Additionally, error classes are dynamically generated for service errors based on the error code
+ # if they are not defined above.
module Errors
extend Aws::Errors::DynamicErrors
class InvalidArgsException < ServiceError
@@ -21,11 +55,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class InvalidArnException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -37,11 +70,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class InvalidDomainValidationOptionsException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -53,11 +85,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class InvalidParameterException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -69,11 +100,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class InvalidStateException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -85,11 +115,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class InvalidTagException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -101,11 +130,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class LimitExceededException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -117,11 +145,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class RequestInProgressException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -133,11 +160,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class ResourceInUseException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -149,11 +175,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class ResourceNotFoundException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -165,11 +190,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class TagPolicyException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -181,11 +205,10 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
class TooManyTagsException < ServiceError
# @param [Seahorse::Client::RequestContext] context
@@ -197,10 +220,9 @@
# @return [String]
def message
@message || @data[:message]
end
-
end
end
end