timeutc

package
v0.2.4 Latest Latest
Warning

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

Go to latest
Published: Sep 10, 2020 License: Apache-2.0 Imports: 1 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustParse

func MustParse(layout, value string) time.Time

MustParse call time.Parse and returns value in UTC. It panics on time.Parse error.

func Now

func Now() time.Time

Now returns current time in UTC.

func Parse

func Parse(layout, value string) (time.Time, error)

Parse calls time.Parse and returns value in UTC.

func Since

func Since(t time.Time) time.Duration

Since returns the time elapsed since t.

func TodayMidnight

func TodayMidnight() time.Time

TodayMidnight returns local midnight time in UTC.

Types

This section is empty.

Jump to

Keyboard shortcuts

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