package
Version:
v1.9.9
Opens a new window with list of versions in this module.
Published: Apr 9, 2020
License: Apache-2.0
Opens a new window with license information.
Imports: 1
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
func AllNum(val interface{}) bool
func CNMobile(val interface{}) bool
CNMobile 验证中国大陆的手机号码
func CNPhone(val interface{}) bool
CNPhone 验证中国大陆的电话号码。支持如下格式:
0578-12345678-1234
057812345678-1234
若存在分机号,则分机号的连接符不能省略。
func CNTel(val interface{}) bool
CNTel 验证手机和电话类型
func Email(val interface{}) bool
Email 验证一个值是否匹配一个邮箱。
func IP(val interface{}) bool
IP 验证一个值是否为IP,可验证IP4和IP6
func IP4(val interface{}) bool
IP4 验证一个值是滞为IP4
func IP6(val interface{}) bool
IP6 验证一个值是否为IP6
func URL(val interface{}) bool
URL 验证一个值是否标准的URL格式。支持IP和域名等格式
Source Files
¶
Click to show internal directories.
Click to hide internal directories.