Exception: Analytica::Computation::InvalidInputException
- Inherits:
-
Exception
- Object
- Exception
- Analytica::Computation::InvalidInputException
- Defined in:
- lib/computation.rb
Instance Method Summary collapse
-
#initialize(comp, size, params, constraints) ⇒ InvalidInputException
constructor
A new instance of InvalidInputException.
- #inspect ⇒ Object
Constructor Details
#initialize(comp, size, params, constraints) ⇒ InvalidInputException
Returns a new instance of InvalidInputException.
8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/computation.rb', line 8 def initialize(comp, size, params, constraints) enforce!([:average_filter, :moving_average], comp) enforce_primitive!(Hash, params) enforce!(:string_array, constraints) @msg = "Unable to calculate #{comp.inspect} on DataSet size #{size} with input #{params.inspect}" @msg += "\nConstraints:\n" constraints.each do |c| @msg += c+"\n" end end |
Instance Method Details
#inspect ⇒ Object
21 22 23 |
# File 'lib/computation.rb', line 21 def inspect @msg end |