Module: Ditto::DSL
- Defined in:
- lib/ditto/dsl.rb
Instance Method Summary collapse
- #add(version, &block) ⇒ Object
- #delete(version, &block) ⇒ Object
- #entity(name, version, opts, *methods) ⇒ Object
Instance Method Details
#add(version, &block) ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/ditto/dsl.rb', line 8 def add (version, &block) unless block src = Thread.current.backtrace[1].split(':')[0..1] raise Error.new(src), "add method missing block (use {} not do/end)" end [:add, version, block] end |