utime

package
v0.6.35 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FixedZone added in v0.2.55

func FixedZone(offset time.Duration) *time.Location

func Max added in v0.6.22

func Max(a, b time.Time) time.Time

func Min added in v0.6.22

func Min(a, b time.Time) time.Time

func MinNonZero added in v0.6.22

func MinNonZero(a, b time.Time) time.Time

func Now added in v0.6.11

func Now() time.Time

func Option added in v0.6.22

func Option(v time.Time) *time.Time

func ParseDuration

func ParseDuration(s string) (r time.Duration, err error)

func Pretty added in v0.6.21

func Pretty(t time.Duration) string

func PrettyTruncate added in v0.3.31

func PrettyTruncate(t time.Duration) time.Duration

func SetLocation added in v0.5.8

func SetLocation(v time.Time, loc *time.Location) time.Time

func TimeToDuration

func TimeToDuration(t time.Time) time.Duration

Types

type Stopwatch added in v0.3.33

type Stopwatch struct {
	// contains filtered or unexported fields
}

func NewStopwatch added in v0.3.33

func NewStopwatch() *Stopwatch

func (*Stopwatch) PrettyTime added in v0.3.33

func (o *Stopwatch) PrettyTime() time.Duration

func (*Stopwatch) Reset added in v0.3.33

func (o *Stopwatch) Reset()

func (Stopwatch) String added in v0.3.33

func (o Stopwatch) String() string

func (*Stopwatch) Time added in v0.3.33

func (o *Stopwatch) Time() time.Duration

Jump to

Keyboard shortcuts

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