Sha256: c40d8c922c035fd90cdd40b6c6ca35f2b8bd8108de687177eddae8918f733149
Contents?: true
Size: 821 Bytes
Versions: 1
Compression:
Stored size: 821 Bytes
Contents
class Zoo include DataMapper::Resource property :id, Serial property :name, String property :description, Text property :inception, DateTime property :open, Boolean, :default => false property :size, Integer has n, :animals def to_s name end end class Species include DataMapper::Resource property :id, Serial property :name, String property :classification, String, :reader => :private has n, :animals end class Animal include DataMapper::Resource property :id, Serial property :name, String belongs_to :zoo belongs_to :species belongs_to :keeper end class Employee include DataMapper::Resource property :id, Serial property :name, String end class Keeper < Employee has n, :animals end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dm-core-0.9.3 | spec/models/zoo.rb |