Method: Decanter::Core::ClassMethods#strict

Defined in:
lib/decanter/core.rb

#strict(mode) ⇒ Object

Raises:

  • (ArgumentError)


51
52
53
54
# File 'lib/decanter/core.rb', line 51

def strict(mode)
  raise(ArgumentError, "#{self.name}: Unknown strict value #{mode}") unless [:with_exception, true, false].include? mode
  @strict_mode = mode
end