Class: Dynamoid::Undumping::CustomTypeUndumper

Inherits:
Base
  • Object
show all
Defined in:
lib/dynamoid/undumping.rb

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Dynamoid::Undumping::Base

Instance Method Details

#process(value) ⇒ Object



292
293
294
295
296
297
298
299
300
# File 'lib/dynamoid/undumping.rb', line 292

def process(value)
  field_class = @options[:type]

  unless field_class.respond_to?(:dynamoid_load)
    raise ArgumentError, "#{field_class} does not support serialization for Dynamoid."
  end

  field_class.dynamoid_load(value)
end