util

package
v0.0.0-...-98b6310 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2015 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

util

Index

Constants

This section is empty.

Variables

View Source
var (
	StringBlankPattern *regexp.Regexp
)

Functions

func GetCaptchaString

func GetCaptchaString(bytes []byte) string

func HashAndSalt

func HashAndSalt(text, salt string) string

func HashPid

func HashPid(phone, email string, timestamp int64) string

func IsBlank

func IsBlank(originStr string) bool

func LogError

func LogError(err error, msg ...string)

func MD5

func MD5(text string) string

将传入的字符串md5后输出

func MD5AndSalt

func MD5AndSalt(text, salt string) string

MD5并加盐

func PanicError

func PanicError(err error)

panic ,如果err不是nil,则panic

func SHA512

func SHA512(text string) string

Types

type JsonResult

type JsonResult struct {
	Success bool
	Msg     string
	Data    interface{}
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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