Sha256: 1be16de3d00aad9b4d5227f297cc1c00be444ca67d3130b5e2285ee3f561c0fa

Contents?: true

Size: 271 Bytes

Versions: 2

Compression:

Stored size: 271 Bytes

Contents

$:.push 'lib'; require 'transcriber'

class Root < Transcriber::Resource
  embeds_one :item
end

class Item < Transcriber::Resource
  property :id
end

root = Root.parse({"item" => {"id" => 2000}}).first

puts "root:     #{root.inspect}"
puts "resource: #{root.resource}"

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
transcriber-0.0.3 examples/embeds_one/simple.rb
transcriber-0.0.2 examples/embeds_one/simple.rb