Method: ROM::Mapping::Definition#map
- Defined in:
- lib/rom/mapping/definition.rb
#map(*args) ⇒ Definition
Configure attribute mappings
105 106 107 108 109 110 111 112 113 |
# File 'lib/rom/mapping/definition.rb', line 105 def map(*args) = args.last if .kind_of?(Hash) mapping.update(args.first => [:to]) else @attributes += Set[*args] end end |