Class: HalInterpretation::InvalidRepresentationError
- Defined in:
- lib/hal_interpretation/errors.rb
Instance Attribute Summary collapse
-
#problems ⇒ Object
readonly
Returns the value of attribute problems.
Instance Method Summary collapse
-
#initialize(problems) ⇒ InvalidRepresentationError
constructor
Initializes a new instance of this error.
Constructor Details
#initialize(problems) ⇒ InvalidRepresentationError
Initializes a new instance of this error
problems - list of problems detected with the representation.
8 9 10 11 12 13 14 15 |
# File 'lib/hal_interpretation/errors.rb', line 8 def initialize(problems) @problems = problems = Array(problems) msg = problems.first msg += " and #{problems.count - 1} more problems" if problems.count > 1 super msg end |
Instance Attribute Details
#problems ⇒ Object (readonly)
Returns the value of attribute problems.
17 18 19 |
# File 'lib/hal_interpretation/errors.rb', line 17 def problems @problems end |