Documentation ¶
Index ¶
- Constants
- func BoolInt(b bool) int
- func ByteToString(b []byte) string
- func DataMasking(data string) string
- func Duration(invocation time.Time, name string)
- func ExtractUUID(path string) string
- func FirstToUpper(str string) string
- func GeneratePassword(length int, containChars string) string
- func GenerateUUID() (string, error)
- func GetAvailablePort() int
- func GetFDCount() uint64
- func GetLocalIP4() (ip string)
- func GetSocketCount() uint64
- func ImageToBase64(b []byte) string
- func Inject(obj interface{}, data map[string]interface{})
- func IsAnnually(check, last, now string) (bool, error)
- func IsApartDay(check, last, now string, day int) (bool, error)
- func IsDaily(check, last, now string) (bool, error)
- func IsIPv4(host string) bool
- func IsMonthly(check, last, now string) (bool, error)
- func IsUrl(text string) bool
- func IsWeekly(check, last, now string) (bool, error)
- func Now() string
- func Round(val float64, precision int) float64
- func SHA1(url string) string
- func StringSliceDiff(s1, s2 []string) []string
- func StringToByte(s string) (b []byte)
- func ToBase64(b []byte) string
Constants ¶
View Source
const ( UrlRegex = `https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)` EmailRegex = `[a-z0-9_\.-]+\@[\da-z\.-]+\.[a-z\.]{2,6}` )
View Source
const HourLayout = "2006-01-02 15:04"
Variables ¶
This section is empty.
Functions ¶
func ByteToString ¶
func FirstToUpper ¶ added in v0.0.26
func GeneratePassword ¶
GeneratePassword containChars : "lowercase|uppercase|numbers|hyphen|underline|space|specials|brackets|no_similar"
func GenerateUUID ¶
GenerateUUID generates a random ID for a message
func GetFDCount ¶
func GetFDCount() uint64
func GetSocketCount ¶
func GetSocketCount() uint64
func ImageToBase64 ¶ added in v0.0.25
ImageToBase64 image base64 encoding
func IsAnnually ¶ added in v0.0.25
func StringSliceDiff ¶
func StringToByte ¶
Types ¶
This section is empty.
Source Files ¶
Click to show internal directories.
Click to hide internal directories.