Class: String

Inherits:
Object show all
Defined in:
lib/mongo_record/base.rb

Instance Method Summary collapse

Instance Method Details

#to_oidObject

Convert this String to an ObjectID.



26
27
28
# File 'lib/mongo_record/base.rb', line 26

def to_oid
  XGen::Mongo::Driver::ObjectID.from_string(self)
end