Documentation ¶
Index ¶
- func CIDRNetwork(min, max int) schema.SchemaValidateFunc
- func IntAtLeast(min int) schema.SchemaValidateFunc
- func IntAtMost(max int) schema.SchemaValidateFunc
- func IntBetween(min, max int) schema.SchemaValidateFunc
- func StringInSlice(valid []string, ignoreCase bool) schema.SchemaValidateFunc
- func StringLenBetween(min, max int) schema.SchemaValidateFunc
- func ValidateJsonString(v interface{}, k string) (ws []string, errors []error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CIDRNetwork ¶ added in v0.9.2
func CIDRNetwork(min, max int) schema.SchemaValidateFunc
CIDRNetwork returns a SchemaValidateFunc which tests if the provided value is of type string, is in valid CIDR network notation, and has significant bits between min and max (inclusive)
func IntAtLeast ¶ added in v0.10.1
func IntAtLeast(min int) schema.SchemaValidateFunc
IntAtLeast returns a SchemaValidateFunc which tests if the provided value is of type int and is at least min (inclusive)
func IntAtMost ¶ added in v0.10.1
func IntAtMost(max int) schema.SchemaValidateFunc
IntAtMost returns a SchemaValidateFunc which tests if the provided value is of type int and is at most max (inclusive)
func IntBetween ¶
func IntBetween(min, max int) schema.SchemaValidateFunc
IntBetween returns a SchemaValidateFunc which tests if the provided value is of type int and is between min and max (inclusive)
func StringInSlice ¶
func StringInSlice(valid []string, ignoreCase bool) schema.SchemaValidateFunc
StringInSlice returns a SchemaValidateFunc which tests if the provided value is of type string and matches the value of an element in the valid slice will test with in lower case if ignoreCase is true
func StringLenBetween ¶ added in v0.9.2
func StringLenBetween(min, max int) schema.SchemaValidateFunc
StringLenBetween returns a SchemaValidateFunc which tests if the provided value is of type string and has length between min and max (inclusive)
func ValidateJsonString ¶ added in v0.9.3
Types ¶
This section is empty.