Exception: Aws::Templates::Exception::ParameterMethodNameConflict

Inherits:
ParametrizedDSLError show all
Defined in:
lib/aws/templates/exception/parameter_method_name_conflict.rb

Overview

A regular method and a parameter have the same name in a class

A parameter was specified with the same name as exsiting method in the class or in an ancestor of the class.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(target_method) ⇒ ParameterMethodNameConflict

Returns a new instance of ParameterMethodNameConflict.



15
16
17
18
19
20
21
22
# File 'lib/aws/templates/exception/parameter_method_name_conflict.rb', line 15

def initialize(target_method)
  @method_object = target_method

  super(
    "Parameter name #{target_method.name} clashes with a method name in " \
    "#{target_method.owner.name}"
  )
end

Instance Attribute Details

#method_objectObject (readonly)

Method object of the method specified



13
14
15
# File 'lib/aws/templates/exception/parameter_method_name_conflict.rb', line 13

def method_object
  @method_object
end