Module: Seedable::CoreExt::Array::InstanceMethods

Defined in:
lib/seedable/core_ext.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#as_seedableObject

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_seedableObject

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