Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var V *validator.Validate
Functions ¶
func Struct ¶ added in v0.4.4
func Struct(s interface{}) error
Struct validates a structs exposed fields, and automatically validates nested structs, unless otherwise specified.
It returns InvalidValidationError for bad values passed in and nil or ValidationErrors as error otherwise. You will need to assert the error if it's not nil eg. err.(validator.ValidationErrors) to access the array of errors.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.