Discover Packages
github.com/ericvolp12/jetstream
pkg
monotonic
package
Version:
v0.0.0-...-7c5bcf4
Opens a new window with list of versions in this module.
Published: Sep 19, 2024
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation Source Files Overview Index Constants Variables Functions Types type Clock NewClock(precision) (c) Now()
Documentation
¶
Package monotonic provides a monotonic clock.
The clock is safe for concurrent use and can be used to generate
increasing timestamps as int64s with a given precision.
Clock is a monotonic clock that generates increasing timestamps.
NewClock creates a new Clock with the given precision.
Now returns the current timestamp as an int64 of the Clock's precision.
Now will always return a monotonically increasing value.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.