The highest tagged major version is
v10.
package
Version:
v8.12.0
Opens a new window with list of versions in this module.
Published: Oct 19, 2023
License: Apache-2.0
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
func DefaultStructValidator(target interface{}) error
DefaultStructValidator validates that the passed structure is valid.
HasZero checks returns true if any of the provided values is a zero value.
IsZero checks returns true if the provided value is a zero value.
func Validate(target interface{}) error
Validate validates an object if it implements the Validator interface.
Objects that do not implement the Validator interface are not validated.
type Validator interface {
Validate() error
}
Validator allows defining validation behavior for an object.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.