commons

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IpFromHostname

func IpFromHostname(enableIpV6 bool) (ip string, err error)

IpFromHostname 通过host获取ip列表中的第一个

func ParseTime

func ParseTime(value string) (result time.Time, err error)

func ValidateFieldMessage

func ValidateFieldMessage(_type reflect.Type, exp string) (key string, msg string)

func ValidateRegisterRegex

func ValidateRegisterRegex(validate *validator.Validate)

Types

type Wildcard

type Wildcard struct {
	Prefix string
	Suffix string
}

func (Wildcard) Match

func (w Wildcard) Match(s string) bool

Jump to

Keyboard shortcuts

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