parsing

package
v0.0.0-...-116ae15 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DurationUnit

type DurationUnit struct {
	Day    int `json:"day"`
	Hour   int `json:"hour"`
	Minute int `json:"minute"`
	Second int `json:"second"`
}

DurationUnit -

type Time

type Time struct{}

func NewTime

func NewTime() *Time

func (*Time) Duration

func (c *Time) Duration(dur time.Duration) (format string)

Duration - convert golang time duration to string format DD:HH:MM:SS

func (*Time) DurationToUnit

func (c *Time) DurationToUnit(dur time.Duration) (format DurationUnit)

DurationToUnit - convert time duration to individual unit

func (*Time) TimeStringDateOnly

func (c *Time) TimeStringDateOnly(dur time.Time) (format string)

TimeStringDateOnly -

func (*Time) TimeStringTimeOnly

func (c *Time) TimeStringTimeOnly(dur time.Time) (format string)

TimeStringTimeOnly -

func (*Time) TimeStringTimeOnlyWithMilliSecond

func (c *Time) TimeStringTimeOnlyWithMilliSecond(s time.Time) (ts string)

TimeStringTimeOnlyWithMilliSecond -

func (*Time) TimeStringWitLongDate

func (c *Time) TimeStringWitLongDate(dur time.Time) (format string)

TimeStringWitLongDate -

func (*Time) TimeStringWithDate

func (c *Time) TimeStringWithDate(dur time.Time) (format string)

TimeStringWithDate -

func (*Time) UnixTime

func (c *Time) UnixTime(t int64) (ts time.Time)

UnixTime - convert unix time to golang time format

func (*Time) UnixTimeNano

func (c *Time) UnixTimeNano(t int64) (ts time.Time)

UnixTimeNano - convert unix nano time to golang time format

Jump to

Keyboard shortcuts

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