Exception: Lutaml::Model::InvalidChoiceRangeError
- Defined in:
- lib/lutaml/model/error/invalid_choice_range_error.rb
Instance Method Summary collapse
-
#initialize(min, max) ⇒ InvalidChoiceRangeError
constructor
A new instance of InvalidChoiceRangeError.
- #to_s ⇒ Object
Constructor Details
#initialize(min, max) ⇒ InvalidChoiceRangeError
4 5 6 7 8 9 |
# File 'lib/lutaml/model/error/invalid_choice_range_error.rb', line 4 def initialize(min, max) @min = min @max = max super() end |
Instance Method Details
#to_s ⇒ Object
11 12 13 14 15 |
# File 'lib/lutaml/model/error/invalid_choice_range_error.rb', line 11 def to_s bound_name, value = @min.negative? ? ["lower", @min] : ["upper", @max] "Choice #{bound_name} bound `#{value}` must be positive" end |