Exception: Simple::Service::MissingArgumentError
- Inherits:
-
ArgumentError
- Object
- ArgumentError
- ArgumentError
- Simple::Service::MissingArgumentError
- Defined in:
- lib/simple/service/errors.rb
Instance Attribute Summary collapse
-
#action ⇒ Object
readonly
Returns the value of attribute action.
-
#parameters ⇒ Object
readonly
Returns the value of attribute parameters.
Instance Method Summary collapse
-
#initialize(action, parameters) ⇒ MissingArgumentError
constructor
A new instance of MissingArgumentError.
- #to_s ⇒ Object
Constructor Details
#initialize(action, parameters) ⇒ MissingArgumentError
Returns a new instance of MissingArgumentError.
25 26 27 28 |
# File 'lib/simple/service/errors.rb', line 25 def initialize(action, parameters) @action, @parameters = action, parameters super() end |
Instance Attribute Details
#action ⇒ Object (readonly)
Returns the value of attribute action.
22 23 24 |
# File 'lib/simple/service/errors.rb', line 22 def action @action end |
#parameters ⇒ Object (readonly)
Returns the value of attribute parameters.
23 24 25 |
# File 'lib/simple/service/errors.rb', line 23 def parameters @parameters end |
Instance Method Details
#to_s ⇒ Object
30 31 32 |
# File 'lib/simple/service/errors.rb', line 30 def to_s "#{action}: missing argument(s): #{parameters.map(&:to_s).join(", ")}" end |