package
6.4.2+incompatible
Repository: https://github.com/junxie6/beats.git
Documentation: pkg.go.dev

# Functions

Compose combines multiple SchemaValidators into a single one.
Is creates a named IsDef with the given checker.
IsEqual tests that the given object is equal to the actual object.
IsEqualToValue tests that the given value is equal to the actual value.
IsIntGt tests that a value is an int greater than.
Optional wraps an IsDef to mark the field's presence as optional.
Schema takes a Map and returns an executable Validator function.
Strict is used when you want any unspecified keys that are encountered to be considered errors.

# Variables

IsDuration tests that the given value is a duration.
IsNil tests that a value is nil.
KeyMissing checks that the given key is not present defined.
KeyMissingVR is emitted when a key was expected, but was not present.
KeyPresent checks that the given key is in the map, even if it has a nil value.
StrictFailureVR is emitted when Strict() is used, and an unexpected field is found.
ValidVR is a convenience value for Valid results.

# Structs

An IsDef defines the type of check to do.
ValueResult represents the result of checking a leaf value.
ValueResultError is used to represent an error validating an individual value.

# Type aliases

Map is the type used to define schema definitions for Schema.
Results the results of executing a schema.
Validator is the result of Schema and is run against the map you'd like to test.
A ValueValidator is used to validate a value in a Map.