Exception: Filterameter::Exceptions::UndeclaredParameterError
- Inherits:
-
FilterameterError
- Object
- StandardError
- FilterameterError
- Filterameter::Exceptions::UndeclaredParameterError
- Defined in:
- lib/filterameter/exceptions/undeclared_parameter_error.rb
Overview
# Undeclared Parameter Error
Class UndeclaredParameterError is raised when a request contains filter parameters that have not been declared. Configuration setting ‘action_on_undeclared_parameters` determines whether or not the exception is raised.
Instance Attribute Summary collapse
-
#key ⇒ Object
readonly
Returns the value of attribute key.
Instance Method Summary collapse
-
#initialize(key) ⇒ UndeclaredParameterError
constructor
A new instance of UndeclaredParameterError.
- #message ⇒ Object
Constructor Details
#initialize(key) ⇒ UndeclaredParameterError
Returns a new instance of UndeclaredParameterError.
12 13 14 15 |
# File 'lib/filterameter/exceptions/undeclared_parameter_error.rb', line 12 def initialize(key) super @key = key end |
Instance Attribute Details
#key ⇒ Object (readonly)
Returns the value of attribute key.
10 11 12 |
# File 'lib/filterameter/exceptions/undeclared_parameter_error.rb', line 10 def key @key end |
Instance Method Details
#message ⇒ Object
17 18 19 |
# File 'lib/filterameter/exceptions/undeclared_parameter_error.rb', line 17 def "The following filter parameter has not been declared: #{key}" end |