Module: Mongoid::Extensions::Time
- Defined in:
- lib/mongoid/extensions/time.rb
Defined Under Namespace
Modules: ClassMethods
Constant Summary collapse
- EPOCH =
Deprecated.
No longer used as a return value from #mongoize passed an invalid time string.
Constant for epoch - used when passing invalid times.
::Time.utc(1970, 1, 1, 0, 0, 0)
Instance Method Summary collapse
-
#mongoize ⇒ Time
Turn the object from the ruby type we deal with to a Mongo friendly type.
Instance Method Details
#mongoize ⇒ Time
Turn the object from the ruby type we deal with to a Mongo friendly type.
21 22 23 |
# File 'lib/mongoid/extensions/time.rb', line 21 def mongoize ::Time.mongoize(self) end |