Documentation ¶
Index ¶
- Variables
- func BeginningOfDay() time.Time
- func BeginningOfHour() time.Time
- func BeginningOfMinute() time.Time
- func BeginningOfMonth() time.Time
- func BeginningOfQuarter() time.Time
- func BeginningOfWeek() time.Time
- func BeginningOfYear() time.Time
- func Between(time1, time2 string) bool
- func CheckFileIsExist(filename string) bool
- func CheckPriceFormat(fee string) error
- func ConvertFTOY(fen string) (yuan string, err error)
- func ConvertYTOF(yuan string) (fen string, err error)
- func CreateDir(dirs ...string) error
- func EndOfDay() time.Time
- func EndOfHour() time.Time
- func EndOfMinute() time.Time
- func EndOfMonth() time.Time
- func EndOfQuarter() time.Time
- func EndOfSunday() time.Time
- func EndOfWeek() time.Time
- func EndOfYear() time.Time
- func GbkToUtf8(s []byte) ([]byte, error)
- func GenNo(prefix, suffix string) string
- func GenUUID() string
- func GetLocalIp() string
- func GetNow() string
- func JsonToMap(a interface{}) map[string]interface{}
- func MD4(data string) string
- func MD5(data string) string
- func MapToStr(m map[string]interface{}) string
- func Monday() time.Time
- func MustParse(strs ...string) time.Time
- func Parse(strs ...string) (time.Time, error)
- func PathExists(path string) (bool, error)
- func PostForm(url string, params url.Values) (data []byte, err error)
- func PostJson(url string, jsonData []byte) (data []byte, err error)
- func RandomString(num int) string
- func Sha1WithRsa(data, privateKey []byte) (sign string, err error)
- func String(v interface{}) string
- func Sunday() time.Time
- func Utf8ToGbk(s []byte) ([]byte, error)
- func Valid(ptrInput interface{}) error
- type DownloadFile
- type LQueue
- type LQueues
- type LTask
- type LTaskDone
- type LTaskPrepare
- type LTaskRunning
- type Now
- func (now *Now) BeginningOfDay() time.Time
- func (now *Now) BeginningOfHour() time.Time
- func (now *Now) BeginningOfMinute() time.Time
- func (now *Now) BeginningOfMonth() time.Time
- func (now *Now) BeginningOfQuarter() time.Time
- func (now *Now) BeginningOfWeek() time.Time
- func (now *Now) BeginningOfYear() time.Time
- func (now *Now) Between(time1, time2 string) bool
- func (now *Now) EndOfDay() time.Time
- func (now *Now) EndOfHour() time.Time
- func (now *Now) EndOfMinute() time.Time
- func (now *Now) EndOfMonth() time.Time
- func (now *Now) EndOfQuarter() time.Time
- func (now *Now) EndOfSunday() time.Time
- func (now *Now) EndOfWeek() time.Time
- func (now *Now) EndOfYear() time.Time
- func (now *Now) Monday() time.Time
- func (now *Now) MustParse(strs ...string) (t time.Time)
- func (now *Now) Parse(strs ...string) (t time.Time, err error)
- func (now *Now) Sunday() time.Time
Constants ¶
This section is empty.
Variables ¶
View Source
var FirstDayMonday bool
View Source
var TimeFormats = []string{"1/2/2006", "1/2/2006 15:4:5", "2006-1-2 15:4:5", "2006-1-2 15:4", "2006-1-2", "1-2", "15:4:5", "15:4", "15", "15:4:5 Jan 2, 2006 MST", "2006-01-02 15:04:05.999999999 -0700 MST"}
Functions ¶
func BeginningOfDay ¶
func BeginningOfHour ¶
func BeginningOfMinute ¶
func BeginningOfMonth ¶
func BeginningOfQuarter ¶
func BeginningOfWeek ¶
func BeginningOfYear ¶
func CheckPriceFormat ¶
func ConvertFTOY ¶
func ConvertYTOF ¶
func CreateDir ¶
@title createDir @description 批量创建文件夹 @auth (2020/04/05 20:22) @param dirs string @return err error
func EndOfMinute ¶
func EndOfMonth ¶
func EndOfQuarter ¶
func EndOfSunday ¶
func GetLocalIp ¶
func GetLocalIp() string
func PathExists ¶
func RandomString ¶
func Sha1WithRsa ¶
Types ¶
type DownloadFile ¶ added in v1.0.9
func Download ¶
func Download(url string) (file DownloadFile, err error)
type LQueue ¶ added in v1.2.3
type LQueue struct {
// contains filtered or unexported fields
}
建立一个任务
func (*LQueue) RunningState ¶ added in v1.2.3
func (q *LQueue) RunningState() (r LTaskRunning)
运行的状态
type LTaskPrepare ¶ added in v1.2.3
type LTaskPrepare interface {
Prepare()
}
type LTaskRunning ¶ added in v1.2.3
type LTaskRunning struct { // 运行的起始时间 StartTime int64 }
type Now ¶
func (*Now) BeginningOfDay ¶
func (*Now) BeginningOfHour ¶
func (*Now) BeginningOfMinute ¶
func (*Now) BeginningOfMonth ¶
func (*Now) BeginningOfQuarter ¶
func (*Now) BeginningOfWeek ¶
func (*Now) BeginningOfYear ¶
func (*Now) EndOfMinute ¶
func (*Now) EndOfMonth ¶
func (*Now) EndOfQuarter ¶
func (*Now) EndOfSunday ¶
Click to show internal directories.
Click to hide internal directories.