On this page本页内容
ObjectId.
toString
()¶Returns the string representation of the ObjectId()
. This string value has the format of ObjectId(...)
.
The following example calls the toString()
method on an ObjectId()
instance in the mongo
shell:
This will return the following string:
You can confirm the type of this object using the following operation: