Documentation ¶
Index ¶
- Constants
- func BytesToString(b []byte) string
- func IsDate(s string) bool
- func IsDigit(s string) bool
- func IsTime(s string) bool
- func IsWeekEnd(d time.Weekday) bool
- func Random(n int) string
- func StrFmtTime(s, fmt string) (t time.Time, err error)
- func StrLen(s string) int
- func StrMax(s string, max int) bool
- func StrMin(s string, min int) bool
- func StrRange(s string, min, max int) bool
- func StrToDate(s string) (t time.Time, err error)
- func StrToTime(s string) (t time.Time, err error)
- func StringToBytes(s string) []byte
- func TimeFmtStr(t time.Time, fmt string) string
- func TimeToStr(t time.Time) string
Constants ¶
View Source
const ( // TimeFmtLong yyyy-MM-dd hh:mm:ss TimeFmtLong = `2006-01-02 15:04:05` // TimeFmtNumeric yyyyMMddhhmmss TimeFmtNumeric = `20060102150405` // DateFmtLong yyyy-MM-dd DateFmtLong = `2006-01-02` // DateFmtNumeric yyyyMMdd DateFmtNumeric = `20060102` )
Variables ¶
This section is empty.
Functions ¶
func BytesToString ¶
BytesToString converts byte slice to string without a memory allocation.
func StringToBytes ¶
StringToBytes converts string to byte slice without a memory allocation.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.