# Module oids

Nimrod OID support. An OID is a global ID that consists of a timestamp, a unique counter and a random value. This combination should suffice to produce a globally distributed unique ID. This implementation was extracted from the Mongodb interface and it thus binary compatible with a Mongo OID.

This implementation calls `math.randomize()` for the first call of `genOid`.

# Imports

times, endians

# Types

    Toid* {.pure, final.} = object
      time: int32                 ##
      fuzz: int32                 ##
      count: int32                ##

  an OID

# Procs

    proc hexbyte*(hex: char): int

    proc parseOid*(str: cstring): TOid

  parses an OID.

    proc oidToString*(oid: TOid; str: cstring)

    proc genOid*(): TOid

  generates a new OID.

    proc generatedTime*(oid: TOid): TTime

  returns the generated timestamp of the OID.

Generated: 2012-09-23 21:47:54 UTC