barcodes/validation/charsets.go

14 lines
388 B
Go
Raw Normal View History

2023-09-01 19:08:59 +01:00
package validation
import "regexp"
var (
ASCII = regexp.MustCompile(`^[\x00-\x7F]+$`)
ANY = regexp.MustCompile(`.`)
2023-09-01 20:50:47 +01:00
CODABAR = regexp.MustCompile(`^[0-9-$:/.+]+$`)
2023-09-01 19:08:59 +01:00
CODE39 = regexp.MustCompile(`^[0-9A-Z\-\.\ $%*+/]+$`)
2023-09-01 20:50:47 +01:00
CODE93 = regexp.MustCompile(`^[A-Za-z0-9\-.\$/\+%\s]+$`)
2023-09-01 19:08:59 +01:00
NUMERAL = regexp.MustCompile(`^[0-9]+$`)
ISO88591 = regexp.MustCompile(`^[\x00-\xFF]+$`)
)