clock

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 9, 2025 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Clock

type Clock interface {
	Now() time.Time
}

Clock is an interface that abstracts time.Now() for testability.

type SystemClock

type SystemClock struct{}

SystemClock is the real implementation of the Clock interface.

func NewSystemClock

func NewSystemClock() *SystemClock

NewSystemClock creates a new SystemClock.

func (*SystemClock) Now

func (c *SystemClock) Now() time.Time

Now returns the current time.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL