Module: Seedable::CoreExt::Array::InstanceMethods
- Defined in:
- lib/seedable/core_ext.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#as_seedable ⇒ Object
Serialize an array of heterogeneous objects.
-
#to_seedable ⇒ Object
Serialize an array of heterogeneous objects and output as JSON.
Instance Method Details
#as_seedable ⇒ Object
Serialize an array of heterogeneous objects.
12 13 14 |
# File 'lib/seedable/core_ext.rb', line 12 def as_seedable map { |o| o.as_seedable } end |
#to_seedable ⇒ Object
Serialize an array of heterogeneous objects and output as JSON.
19 20 21 |
# File 'lib/seedable/core_ext.rb', line 19 def to_seedable as_seedable.to_json end |