Core/CafeLib.Core/Support/ObjectId.cs
/// <summary>
/// Generates a new ObjectId with a unique value (with the given timestamp).
/// </summary>
/// <param name="timestamp">The timestamp component.</param>
/// <returns>An ObjectId.</returns>
Generates a new ObjectId with a unique value (with the given timestamp).
Generates a new ObjectId with a unique value ( with the given timestamp ) .
public static ObjectId GenerateNewId(int timestamp)
        {
            int increment = Interlocked.Increment(ref _staticIncrement) & 0x00ffffff; 
            return new ObjectId(timestamp, StaticMachine, StaticPid, increment);
        }
public static ObjectId GenerateNewId ( int timestamp ) { int increment = Interlocked . Increment ( ref _staticIncrement ) & 0x00ffffff ; return new ObjectId ( timestamp , StaticMachine , StaticPid , increment ) ; }
Generates a new ObjectId with a unique value (with the given timestamp).
Generates a new ObjectId with a unique value ( with the given timestamp ) .
// only use low order 3 bytes
None
timestamp
int
The timestamp component.
The timestamp component .