NATS .NET Client  1.1.4
The NATS.io .NET C# Client
NATS.Client.NUID Class Reference

Public Member Functions

void RandomizePrefix ()
 
 NUID ()
 

Static Public Attributes

static long LENGTH = preLen + seqLen
 
static long MAXPRE = 4738381338321616896L
 
static long MAXSEQ = 3656158440062976L
 

Properties

static NUID Instance [get]
 
static string NextGlobal [get]
 
string Next [get]
 
byte[] Pre [get, set]
 
long Seq [get, set]
 
long Length [get]
 

Detailed Description

NUID needs to be very fast to generate and truly unique, all while being entropy pool friendly. We will use 12 bytes of crypto generated data (entropy draining), and 10 bytes of sequential data that is started at a pseudo random number and increments with a pseudo-random increment. Total is 22 bytes of base 36 ascii text.

Member Function Documentation

◆ RandomizePrefix()

void NATS.Client.NUID.RandomizePrefix ( )

Generates a new crypto/rand seeded prefix.

Generally not needed, this happens automatically.

Property Documentation

◆ Length

long NATS.Client.NUID.Length
get

Gets the Length of the nuid.

Not normally used outside of testing.

◆ Pre

byte [] NATS.Client.NUID.Pre
getset

Gets or sets the prefix.

Not normally used outside of testing.

◆ Seq

long NATS.Client.NUID.Seq
getset

Gets or sets the sequence. Not normally used outside of testing.

Not normally used outside of testing.


The documentation for this class was generated from the following file: