Class: Serializer::HashValue

Inherits:
Value
  • Object
show all
Defined in:
lib/serializer/value.rb

Instance Method Summary collapse

Methods inherited from Value

#extraction_key, #initialize

Constructor Details

This class inherits a constructor from Serializer::Value

Instance Method Details

#precondition?Boolean

Returns:

  • (Boolean)


42
43
44
# File 'lib/serializer/value.rb', line 42

def precondition?
  @scope.is_a?(Hash)
end

#valueObject



46
47
48
# File 'lib/serializer/value.rb', line 46

def value
  @scope[extraction_key]
end