server/lib/cimi/models/schema.rb
# Convert a Hash or Array to an instance of the collection class
Convert a Hash or Array to an instance of the collection class
Convert a Hash or Array to an instance of the collection class
def convert(value)
      if value.is_a?(::Array)
        @collection_class.new(:entries => value)
      else
        @collection_class.new(value || {})
      end
    end
def convert ( value ) if value . is_a? ( :: Array ) @collection_class . new ( :entries => value ) else @collection_class . new ( value || { } ) end end
Convert a Hash or Array to an instance of the collection class
Convert a Hash or Array to an instance of the collection class
value
<not_specific>