Exception: Elasticfusion::Search::InvalidFieldValueError

Inherits:
SearchError
  • Object
show all
Defined in:
lib/elasticfusion/search/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(field, value) ⇒ InvalidFieldValueError

Returns a new instance of InvalidFieldValueError.



16
17
18
19
# File 'lib/elasticfusion/search/errors.rb', line 16

def initialize(field, value)
  @field = field
  @value = value
end

Instance Attribute Details

#fieldObject (readonly)

Returns the value of attribute field.



14
15
16
# File 'lib/elasticfusion/search/errors.rb', line 14

def field
  @field
end

#valueObject (readonly)

Returns the value of attribute value.



14
15
16
# File 'lib/elasticfusion/search/errors.rb', line 14

def value
  @value
end

Instance Method Details

#messageObject



21
22
23
# File 'lib/elasticfusion/search/errors.rb', line 21

def message
  "\"#{value}\" is not a valid value for \"#{field}\"."
end