regex2

package
v0.3.9 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckParam

func CheckParam(params ...string) bool

检测参数

func IsIdCard

func IsIdCard(cardNo string) bool

判断是否是18或15位身份证

func IsMail

func IsMail(username string) (isMail bool)

判断用户是否是邮件用户

func IsPhone

func IsPhone(mobileNum string) bool

判断是否是手机号

func IsRunTesting

func IsRunTesting() bool

判断是否在测试环境下使用

func IsValidPort

func IsValidPort(port int) bool

0 is considered as a non valid port

func IsValidateEmail

func IsValidateEmail(email string) (err error)

验证是否是合法的邮箱

func IsValidateUsername

func IsValidateUsername(username string) error

验证用户名合法性,用户名必须由5-12位(数字、字母、_、-)组成,且必须以字母开头。

func RegexpReplace

func RegexpReplace(reg, src, temp string) string

RegexpReplace ...

Types

This section is empty.

Jump to

Keyboard shortcuts

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