Version: v0.0.0-...-ea67977 Latest Latest

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

Go to latest
Published: Feb 6, 2021 License: Apache-2.0 Imports: 4 Imported by: 0




This section is empty.


This section is empty.


func Alphanumeric

func Alphanumeric(s string) bool

Alphanumeric validates whether a string is an alphanumeric string.

func AlphanumericExt

func AlphanumericExt(s string) bool

AlphanumericExt validates whether a string is an alphanumeric string, but a small set of extra characters allowed

func Integer

func Integer(n string) bool

Integer validates whether a string is an integer string.

func URL

func URL(url string) bool

URL validates whether a string is an URL string.

func UnixPath

func UnixPath(path string) bool

UnixPath validates whether a string is an unix path string.


type Argument

type Argument struct {
	Name     string
	Validate String

Argument contains the name of the validation type and the validation function.

type String

type String func(string) bool

String is the validation function used for checking whether a string is valid or not.

func (String) TypeName

func (s String) TypeName() string

TypeName returns the type expected to be validated by the validate.String function.


Path Synopsis

Jump to

Keyboard shortcuts

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