validators

package
v0.0.0-...-9192568 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrCardNumberFormat = errors.New("card number must match the format xxxx xxxx xxxx xxxx")
	ErrCVVFormat        = errors.New("card's CardCVV must be a 3-digits value")
	ErrExpDateFormat    = errors.New("card's expire date must match the format mm/yy")
	ErrExpDateInPast    = errors.New("card's expire date must not be in the past")
)

Functions

func CardCVV

func CardCVV(cvv string) error

func CardExpDate

func CardExpDate(date string) error

func CardNumber

func CardNumber(num string) error

func ItemName

func ItemName(name string) error

func Max

func Max(limit int) func(v string) error

func Min

func Min(limit int) func(v string) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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