Class: MongoModel::Types::Set

Inherits:
Array show all
Defined in:
lib/mongomodel/support/types/set.rb

Instance Method Summary collapse

Methods inherited from Array

#to_mongo, #to_query

Methods inherited from Object

#boolean, #from_mongo, #to_mongo, #to_query

Instance Method Details

#cast(obj) ⇒ Object


6
7
8
# File 'lib/mongomodel/support/types/set.rb', line 6

def cast(obj)
  ::Set.new(::Array.wrap(obj))
end