funcdemo

package
v0.0.0-...-457d9f6 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddFloat

func AddFloat(f ...float64) float64

AddFloat 计算若干float值的加和

func AddInt

func AddInt(n ...int) int

AddInt 计算若干int值的加和

func AddInt64

func AddInt64(n ...int64) int64

AddInt64 计算若干int64的加和

func FromStringToTimestamp

func FromStringToTimestamp(t string) (int64, error)

FromStringToTimestamp 字符串值转为时间戳

func FromTimestampToString

func FromTimestampToString(timestamp int64) string

FromTimestampToString 时间戳转为对应时间字符串

func GetDateTimeNow

func GetDateTimeNow() string

GetDateTimeNow 返回当前日期时间字符串

func GetDaysInMonth

func GetDaysInMonth(year int, month int) int

GetDaysInMonth 获取某年某月多少天 year 年 month 月 return 天数,无效月份返回-1

func GetTimestampNow

func GetTimestampNow() int64

GetTimestampNow 获取当前时间戳

func IsLeapYear

func IsLeapYear(year int) bool

IsLeapYear 判断闰年 year 年份 return 是否闰年

Types

This section is empty.

Jump to

Keyboard shortcuts

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