validator

package
v1.11.2 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2026 License: MIT, Apache-2.0 Imports: 9 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DefaultValidate *validator.Validate
)

Functions

func FieldError

func FieldError(fieldName string, err error) error

FieldError wraps a given Validator error providing a message call stack.

func TransError

func TransError(err error, locale string) string

func ValidateStruct

func ValidateStruct(o any) error

Types

type Validator

type Validator interface {
	Validate() error
}

Validator is a general interface that allows a message to be validated.

type ValidatorAll

type ValidatorAll interface {
	Validate(all bool) error
}

Jump to

Keyboard shortcuts

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