Constructor
new TimestampGenerator()
Creates a new instance of TimestampGenerator.
- Source:
Methods
(abstract) next(client) → {Long|Number|null}
Returns the next timestamp.
Implementors should enforce increasing monotonicity of timestamps, that is, a timestamp returned should always be strictly greater that any previously returned timestamp.
Implementors should strive to achieve microsecond precision in the best possible way, which is usually largely dependent on the underlying operating system's capabilities.
Parameters:
Name | Type | Description |
---|---|---|
client |
Client | The Client instance to generate timestamps to. |
- Source:
Returns:
the next timestamp (in microseconds). If it's equals to null
, it won't be
sent by the driver, letting the server to generate the timestamp.
- Type
- Long | Number | null