LocalTime

package
v0.0.0-...-b701592 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LocalTime

type LocalTime struct {
	time.Time
}

func (*LocalTime) DateTimeToStamp

func (t *LocalTime) DateTimeToStamp(data string) int64

DateTimeToStamp 任意日期格式转换成 时间戳

func (LocalTime) FormatDateString

func (t LocalTime) FormatDateString(MyDateString string) string

FormatDateString 将指定格式的日期,转成 YYYY-MM-DD HH:ii:ss

func (LocalTime) FormatString

func (t LocalTime) FormatString(Format string) string

FormatString 当前时间转换成日期格式

func (LocalTime) MarshalJSON

func (t LocalTime) MarshalJSON() []byte

MarshalJSON 获取当前时间 返回时间戳

func (*LocalTime) Scan

func (t *LocalTime) Scan(v interface{}) error

func (LocalTime) SpecifiedDate

func (t LocalTime) SpecifiedDate(year, month, day int) string

SpecifiedDate 获取指定 年、月、日

func (LocalTime) SpecifiedTimeForDayAfter

func (t LocalTime) SpecifiedTimeForDayAfter(LastTime string) string

SpecifiedTimeForDayAfter 获取指定日期的后一天

func (LocalTime) SpecifiedTimeForDayBefore

func (t LocalTime) SpecifiedTimeForDayBefore(LastTime string) string

SpecifiedTimeForDayBefore 获取指定日期的前一天

func (LocalTime) String

func (t LocalTime) String() string

当前时间转换成日期格式

func (LocalTime) Value

func (t LocalTime) Value() driver.Value

Jump to

Keyboard shortcuts

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