Method GenerateNewId
GenerateNewId()
Generates a new ObjectId with a unique value.
Returns
- Object
Id An ObjectId.
GenerateNewId(DateTime)
Generates a new ObjectId with a unique value (with the timestamp component based on a given DateTime).
Parameters
timestamp
DateTime The timestamp component (expressed as a DateTime).
Returns
- Object
Id An ObjectId.
GenerateNewId(int)
Generates a new ObjectId with a unique value (with the given timestamp).
Parameters
timestamp
intThe timestamp component.
Returns
- Object
Id An ObjectId.