Method: Representable::HashMethods#create_representation_with

Defined in:
lib/representable/hash_methods.rb

#create_representation_with(doc, options, format) ⇒ Object



10
11
12
13
14
# File 'lib/representable/hash_methods.rb', line 10

def create_representation_with(doc, options, format)
  bin   = representable_mapper(format, options).bindings.first
  hash  = filter_keys_for(represented, options)
  bin.write(doc, hash)
end