now

package
v0.11.5 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2024 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 MockNow

type MockNow struct{}

MockNow is a mock implementation of the Now interface

func NewMockNow

func NewMockNow() *MockNow

NewMockNow returns a new instance of the MockNow

func (*MockNow) NowFunc

func (t *MockNow) NowFunc() func(string) string

NowFunc returns a function that return the same string passed as argument

type Now

type Now struct{}

Now returns the current local time formated

func NewNow

func NewNow() *Now

NewNow returns a new instance of the Now

func (*Now) NowFunc

func (n *Now) NowFunc() func(string) string

NowFunc returns a function that return the current local time formated

Jump to

Keyboard shortcuts

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