Exception: Toys::Settings::FieldError

Inherits:
StandardError
  • Object
show all
Defined in:
toys-core/lib/toys/settings.rb

Overview

Defined in the toys-core gem

Error raised when a value does not match the type constraint.

Instance Attribute Summary collapse

Instance Attribute Details

#field_nameSymbol (readonly)

The field that rejected the value

Returns:

  • (Symbol)


342
343
344
# File 'toys-core/lib/toys/settings.rb', line 342

def field_name
  @field_name
end

#settings_classClass (readonly)

The settings class that rejected the value

Returns:

  • (Class)


336
337
338
# File 'toys-core/lib/toys/settings.rb', line 336

def settings_class
  @settings_class
end

#type_descriptionString? (readonly)

A description of the type constraint, or nil if the field didn't exist.

Returns:

  • (String, nil)


348
349
350
# File 'toys-core/lib/toys/settings.rb', line 348

def type_description
  @type_description
end

#valueObject (readonly)

The value that did not match

Returns:

  • (Object)


330
331
332
# File 'toys-core/lib/toys/settings.rb', line 330

def value
  @value
end