validate

package
v0.0.0-...-b08fcc5 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2023 License: Apache-2.0 Imports: 21 Imported by: 0

README

Documentation

Index

Constants

View Source
const (
	Default_StringRules_Strict = bool(true)
)

Default values for StringRules fields.

Variables

View Source
var (
	KnownRegex_name = map[int32]string{
		0: "UNKNOWN",
		1: "HTTP_HEADER_NAME",
		2: "HTTP_HEADER_VALUE",
	}
	KnownRegex_value = map[string]int32{
		"UNKNOWN":           0,
		"HTTP_HEADER_NAME":  1,
		"HTTP_HEADER_VALUE": 2,
	}
)

Enum value maps for KnownRegex.

View Source
var (
	// Disabled nullifies any validation rules for this message, including any
	// message fields associated with it that do support validation.
	//
	// optional bool disabled = 1071;
	E_Disabled = &file_validate_validate_proto_extTypes[0]
	// Ignore skips generation of validation methods for this message.
	//
	// optional bool ignored = 1072;
	E_Ignored = &file_validate_validate_proto_extTypes[1]
)

Extension fields to descriptorpb.MessageOptions.

View Source
var (
	// Required ensures that exactly one the field options in a oneof is set;
	// validation fails if no fields in the oneof are set.
	//
	// optional bool required = 1071;
	E_Required = &file_validate_validate_proto_extTypes[2]
)

Extension fields to descriptorpb.OneofOptions.

View Source
var (
	// Rules specify the validations to be performed on this field. By default,
	// no validation is performed against a field.
	//
	// optional validate.FieldRules rules = 1071;
	E_Rules = &file_validate_validate_proto_extTypes[3]
)

Extension fields to descriptorpb.FieldOptions.

View Source
var File_validate_validate_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type AnyRules

type AnyRules struct {

	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,1,opt,name=required" json:"required"`
	// In specifies that this field's `type_url` must be equal to one of the
	// specified values.
	In []string `protobuf:"bytes,2,rep,name=in" json:"in"`
	// NotIn specifies that this field's `type_url` must not be equal to any of
	// the specified values.
	NotIn []string `protobuf:"bytes,3,rep,name=not_in,json=notIn" json:"not_in"`
	// contains filtered or unexported fields
}

AnyRules describe constraints applied exclusively to the `google.protobuf.Any` well-known type

func (*AnyRules) Descriptor deprecated

func (*AnyRules) Descriptor() ([]byte, []int)

Deprecated: Use AnyRules.ProtoReflect.Descriptor instead.

func (*AnyRules) GetIn

func (x *AnyRules) GetIn() []string

func (*AnyRules) GetNotIn

func (x *AnyRules) GetNotIn() []string

func (*AnyRules) GetRequired

func (x *AnyRules) GetRequired() bool

func (*AnyRules) ProtoMessage

func (*AnyRules) ProtoMessage()

func (*AnyRules) ProtoReflect

func (x *AnyRules) ProtoReflect() protoreflect.Message

func (*AnyRules) Reset

func (x *AnyRules) Reset()

func (*AnyRules) String

func (x *AnyRules) String() string

func (*AnyRules) Validate

func (m *AnyRules) Validate() error

Validate checks the field values on AnyRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*AnyRules) ValidateAll

func (m *AnyRules) ValidateAll() error

ValidateAll checks the field values on AnyRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in AnyRulesMultiError, or nil if none found.

type AnyRulesMultiError

type AnyRulesMultiError []error

AnyRulesMultiError is an error wrapping multiple validation errors returned by AnyRules.ValidateAll() if the designated constraints aren't met.

func (AnyRulesMultiError) AllErrors

func (m AnyRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (AnyRulesMultiError) Error

func (m AnyRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type AnyRulesValidationError

type AnyRulesValidationError struct {
	// contains filtered or unexported fields
}

AnyRulesValidationError is the validation error returned by AnyRules.Validate if the designated constraints aren't met.

func (AnyRulesValidationError) Cause

func (e AnyRulesValidationError) Cause() error

Cause function returns cause value.

func (AnyRulesValidationError) Error

func (e AnyRulesValidationError) Error() string

Error satisfies the builtin error interface

func (AnyRulesValidationError) ErrorName

func (e AnyRulesValidationError) ErrorName() string

ErrorName returns error name.

func (AnyRulesValidationError) Field

func (e AnyRulesValidationError) Field() string

Field function returns field value.

func (AnyRulesValidationError) Key

func (e AnyRulesValidationError) Key() bool

Key function returns key value.

func (AnyRulesValidationError) Reason

func (e AnyRulesValidationError) Reason() string

Reason function returns reason value.

type BoolRules

type BoolRules struct {

	// Const specifies that this field must be exactly the specified value
	Const *bool `protobuf:"varint,1,opt,name=const" json:"const"`
	// contains filtered or unexported fields
}

BoolRules describes the constraints applied to `bool` values

func (*BoolRules) Descriptor deprecated

func (*BoolRules) Descriptor() ([]byte, []int)

Deprecated: Use BoolRules.ProtoReflect.Descriptor instead.

func (*BoolRules) GetConst

func (x *BoolRules) GetConst() bool

func (*BoolRules) ProtoMessage

func (*BoolRules) ProtoMessage()

func (*BoolRules) ProtoReflect

func (x *BoolRules) ProtoReflect() protoreflect.Message

func (*BoolRules) Reset

func (x *BoolRules) Reset()

func (*BoolRules) String

func (x *BoolRules) String() string

func (*BoolRules) Validate

func (m *BoolRules) Validate() error

Validate checks the field values on BoolRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BoolRules) ValidateAll

func (m *BoolRules) ValidateAll() error

ValidateAll checks the field values on BoolRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BoolRulesMultiError, or nil if none found.

type BoolRulesMultiError

type BoolRulesMultiError []error

BoolRulesMultiError is an error wrapping multiple validation errors returned by BoolRules.ValidateAll() if the designated constraints aren't met.

func (BoolRulesMultiError) AllErrors

func (m BoolRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BoolRulesMultiError) Error

func (m BoolRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type BoolRulesValidationError

type BoolRulesValidationError struct {
	// contains filtered or unexported fields
}

BoolRulesValidationError is the validation error returned by BoolRules.Validate if the designated constraints aren't met.

func (BoolRulesValidationError) Cause

func (e BoolRulesValidationError) Cause() error

Cause function returns cause value.

func (BoolRulesValidationError) Error

func (e BoolRulesValidationError) Error() string

Error satisfies the builtin error interface

func (BoolRulesValidationError) ErrorName

func (e BoolRulesValidationError) ErrorName() string

ErrorName returns error name.

func (BoolRulesValidationError) Field

func (e BoolRulesValidationError) Field() string

Field function returns field value.

func (BoolRulesValidationError) Key

Key function returns key value.

func (BoolRulesValidationError) Reason

func (e BoolRulesValidationError) Reason() string

Reason function returns reason value.

type BytesRules

type BytesRules struct {

	// Const specifies that this field must be exactly the specified value
	Const []byte `protobuf:"bytes,1,opt,name=const" json:"const"`
	// Len specifies that this field must be the specified number of bytes
	Len *uint64 `protobuf:"varint,13,opt,name=len" json:"len"`
	// MinLen specifies that this field must be the specified number of bytes
	// at a minimum
	MinLen *uint64 `protobuf:"varint,2,opt,name=min_len,json=minLen" json:"min_len"`
	// MaxLen specifies that this field must be the specified number of bytes
	// at a maximum
	MaxLen *uint64 `protobuf:"varint,3,opt,name=max_len,json=maxLen" json:"max_len"`
	// Pattern specifes that this field must match against the specified
	// regular expression (RE2 syntax). The included expression should elide
	// any delimiters.
	Pattern *string `protobuf:"bytes,4,opt,name=pattern" json:"pattern"`
	// Prefix specifies that this field must have the specified bytes at the
	// beginning of the string.
	Prefix []byte `protobuf:"bytes,5,opt,name=prefix" json:"prefix"`
	// Suffix specifies that this field must have the specified bytes at the
	// end of the string.
	Suffix []byte `protobuf:"bytes,6,opt,name=suffix" json:"suffix"`
	// Contains specifies that this field must have the specified bytes
	// anywhere in the string.
	Contains []byte `protobuf:"bytes,7,opt,name=contains" json:"contains"`
	// In specifies that this field must be equal to one of the specified
	// values
	In [][]byte `protobuf:"bytes,8,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn [][]byte `protobuf:"bytes,9,rep,name=not_in,json=notIn" json:"not_in"`
	// WellKnown rules provide advanced constraints against common byte
	// patterns
	//
	// Types that are assignable to WellKnown:
	//
	//	*BytesRules_Ip
	//	*BytesRules_Ipv4
	//	*BytesRules_Ipv6
	WellKnown isBytesRules_WellKnown `protobuf_oneof:"well_known"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,14,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

BytesRules describe the constraints applied to `bytes` values

func (*BytesRules) Descriptor deprecated

func (*BytesRules) Descriptor() ([]byte, []int)

Deprecated: Use BytesRules.ProtoReflect.Descriptor instead.

func (*BytesRules) GetConst

func (x *BytesRules) GetConst() []byte

func (*BytesRules) GetContains

func (x *BytesRules) GetContains() []byte

func (*BytesRules) GetIgnoreEmpty

func (x *BytesRules) GetIgnoreEmpty() bool

func (*BytesRules) GetIn

func (x *BytesRules) GetIn() [][]byte

func (*BytesRules) GetIp

func (x *BytesRules) GetIp() bool

func (*BytesRules) GetIpv4

func (x *BytesRules) GetIpv4() bool

func (*BytesRules) GetIpv6

func (x *BytesRules) GetIpv6() bool

func (*BytesRules) GetLen

func (x *BytesRules) GetLen() uint64

func (*BytesRules) GetMaxLen

func (x *BytesRules) GetMaxLen() uint64

func (*BytesRules) GetMinLen

func (x *BytesRules) GetMinLen() uint64

func (*BytesRules) GetNotIn

func (x *BytesRules) GetNotIn() [][]byte

func (*BytesRules) GetPattern

func (x *BytesRules) GetPattern() string

func (*BytesRules) GetPrefix

func (x *BytesRules) GetPrefix() []byte

func (*BytesRules) GetSuffix

func (x *BytesRules) GetSuffix() []byte

func (*BytesRules) GetWellKnown

func (m *BytesRules) GetWellKnown() isBytesRules_WellKnown

func (*BytesRules) ProtoMessage

func (*BytesRules) ProtoMessage()

func (*BytesRules) ProtoReflect

func (x *BytesRules) ProtoReflect() protoreflect.Message

func (*BytesRules) Reset

func (x *BytesRules) Reset()

func (*BytesRules) String

func (x *BytesRules) String() string

func (*BytesRules) Validate

func (m *BytesRules) Validate() error

Validate checks the field values on BytesRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*BytesRules) ValidateAll

func (m *BytesRules) ValidateAll() error

ValidateAll checks the field values on BytesRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in BytesRulesMultiError, or nil if none found.

type BytesRulesMultiError

type BytesRulesMultiError []error

BytesRulesMultiError is an error wrapping multiple validation errors returned by BytesRules.ValidateAll() if the designated constraints aren't met.

func (BytesRulesMultiError) AllErrors

func (m BytesRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (BytesRulesMultiError) Error

func (m BytesRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type BytesRulesValidationError

type BytesRulesValidationError struct {
	// contains filtered or unexported fields
}

BytesRulesValidationError is the validation error returned by BytesRules.Validate if the designated constraints aren't met.

func (BytesRulesValidationError) Cause

func (e BytesRulesValidationError) Cause() error

Cause function returns cause value.

func (BytesRulesValidationError) Error

Error satisfies the builtin error interface

func (BytesRulesValidationError) ErrorName

func (e BytesRulesValidationError) ErrorName() string

ErrorName returns error name.

func (BytesRulesValidationError) Field

Field function returns field value.

func (BytesRulesValidationError) Key

Key function returns key value.

func (BytesRulesValidationError) Reason

func (e BytesRulesValidationError) Reason() string

Reason function returns reason value.

type BytesRules_Ip

type BytesRules_Ip struct {
	// Ip specifies that the field must be a valid IP (v4 or v6) address in
	// byte format
	Ip bool `protobuf:"varint,10,opt,name=ip,oneof"`
}

type BytesRules_Ipv4

type BytesRules_Ipv4 struct {
	// Ipv4 specifies that the field must be a valid IPv4 address in byte
	// format
	Ipv4 bool `protobuf:"varint,11,opt,name=ipv4,oneof"`
}

type BytesRules_Ipv6

type BytesRules_Ipv6 struct {
	// Ipv6 specifies that the field must be a valid IPv6 address in byte
	// format
	Ipv6 bool `protobuf:"varint,12,opt,name=ipv6,oneof"`
}

type DoubleRules

type DoubleRules struct {

	// Const specifies that this field must be exactly the specified value
	Const *float64 `protobuf:"fixed64,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *float64 `protobuf:"fixed64,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *float64 `protobuf:"fixed64,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *float64 `protobuf:"fixed64,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *float64 `protobuf:"fixed64,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []float64 `protobuf:"fixed64,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []float64 `protobuf:"fixed64,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

DoubleRules describes the constraints applied to `double` values

func (*DoubleRules) Descriptor deprecated

func (*DoubleRules) Descriptor() ([]byte, []int)

Deprecated: Use DoubleRules.ProtoReflect.Descriptor instead.

func (*DoubleRules) GetConst

func (x *DoubleRules) GetConst() float64

func (*DoubleRules) GetGt

func (x *DoubleRules) GetGt() float64

func (*DoubleRules) GetGte

func (x *DoubleRules) GetGte() float64

func (*DoubleRules) GetIgnoreEmpty

func (x *DoubleRules) GetIgnoreEmpty() bool

func (*DoubleRules) GetIn

func (x *DoubleRules) GetIn() []float64

func (*DoubleRules) GetLt

func (x *DoubleRules) GetLt() float64

func (*DoubleRules) GetLte

func (x *DoubleRules) GetLte() float64

func (*DoubleRules) GetNotIn

func (x *DoubleRules) GetNotIn() []float64

func (*DoubleRules) ProtoMessage

func (*DoubleRules) ProtoMessage()

func (*DoubleRules) ProtoReflect

func (x *DoubleRules) ProtoReflect() protoreflect.Message

func (*DoubleRules) Reset

func (x *DoubleRules) Reset()

func (*DoubleRules) String

func (x *DoubleRules) String() string

func (*DoubleRules) Validate

func (m *DoubleRules) Validate() error

Validate checks the field values on DoubleRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DoubleRules) ValidateAll

func (m *DoubleRules) ValidateAll() error

ValidateAll checks the field values on DoubleRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DoubleRulesMultiError, or nil if none found.

type DoubleRulesMultiError

type DoubleRulesMultiError []error

DoubleRulesMultiError is an error wrapping multiple validation errors returned by DoubleRules.ValidateAll() if the designated constraints aren't met.

func (DoubleRulesMultiError) AllErrors

func (m DoubleRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DoubleRulesMultiError) Error

func (m DoubleRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type DoubleRulesValidationError

type DoubleRulesValidationError struct {
	// contains filtered or unexported fields
}

DoubleRulesValidationError is the validation error returned by DoubleRules.Validate if the designated constraints aren't met.

func (DoubleRulesValidationError) Cause

Cause function returns cause value.

func (DoubleRulesValidationError) Error

Error satisfies the builtin error interface

func (DoubleRulesValidationError) ErrorName

func (e DoubleRulesValidationError) ErrorName() string

ErrorName returns error name.

func (DoubleRulesValidationError) Field

Field function returns field value.

func (DoubleRulesValidationError) Key

Key function returns key value.

func (DoubleRulesValidationError) Reason

Reason function returns reason value.

type DurationRules

type DurationRules struct {

	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,1,opt,name=required" json:"required"`
	// Const specifies that this field must be exactly the specified value
	Const *durationpb.Duration `protobuf:"bytes,2,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *durationpb.Duration `protobuf:"bytes,3,opt,name=lt" json:"lt"`
	// Lt specifies that this field must be less than the specified value,
	// inclusive
	Lte *durationpb.Duration `protobuf:"bytes,4,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive
	Gt *durationpb.Duration `protobuf:"bytes,5,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than the specified value,
	// inclusive
	Gte *durationpb.Duration `protobuf:"bytes,6,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []*durationpb.Duration `protobuf:"bytes,7,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []*durationpb.Duration `protobuf:"bytes,8,rep,name=not_in,json=notIn" json:"not_in"`
	// contains filtered or unexported fields
}

DurationRules describe the constraints applied exclusively to the `google.protobuf.Duration` well-known type

func (*DurationRules) Descriptor deprecated

func (*DurationRules) Descriptor() ([]byte, []int)

Deprecated: Use DurationRules.ProtoReflect.Descriptor instead.

func (*DurationRules) GetConst

func (x *DurationRules) GetConst() *durationpb.Duration

func (*DurationRules) GetGt

func (x *DurationRules) GetGt() *durationpb.Duration

func (*DurationRules) GetGte

func (x *DurationRules) GetGte() *durationpb.Duration

func (*DurationRules) GetIn

func (x *DurationRules) GetIn() []*durationpb.Duration

func (*DurationRules) GetLt

func (x *DurationRules) GetLt() *durationpb.Duration

func (*DurationRules) GetLte

func (x *DurationRules) GetLte() *durationpb.Duration

func (*DurationRules) GetNotIn

func (x *DurationRules) GetNotIn() []*durationpb.Duration

func (*DurationRules) GetRequired

func (x *DurationRules) GetRequired() bool

func (*DurationRules) ProtoMessage

func (*DurationRules) ProtoMessage()

func (*DurationRules) ProtoReflect

func (x *DurationRules) ProtoReflect() protoreflect.Message

func (*DurationRules) Reset

func (x *DurationRules) Reset()

func (*DurationRules) String

func (x *DurationRules) String() string

func (*DurationRules) Validate

func (m *DurationRules) Validate() error

Validate checks the field values on DurationRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*DurationRules) ValidateAll

func (m *DurationRules) ValidateAll() error

ValidateAll checks the field values on DurationRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DurationRulesMultiError, or nil if none found.

type DurationRulesMultiError

type DurationRulesMultiError []error

DurationRulesMultiError is an error wrapping multiple validation errors returned by DurationRules.ValidateAll() if the designated constraints aren't met.

func (DurationRulesMultiError) AllErrors

func (m DurationRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (DurationRulesMultiError) Error

func (m DurationRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type DurationRulesValidationError

type DurationRulesValidationError struct {
	// contains filtered or unexported fields
}

DurationRulesValidationError is the validation error returned by DurationRules.Validate if the designated constraints aren't met.

func (DurationRulesValidationError) Cause

Cause function returns cause value.

func (DurationRulesValidationError) Error

Error satisfies the builtin error interface

func (DurationRulesValidationError) ErrorName

func (e DurationRulesValidationError) ErrorName() string

ErrorName returns error name.

func (DurationRulesValidationError) Field

Field function returns field value.

func (DurationRulesValidationError) Key

Key function returns key value.

func (DurationRulesValidationError) Reason

Reason function returns reason value.

type EnumRules

type EnumRules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int32 `protobuf:"varint,1,opt,name=const" json:"const"`
	// DefinedOnly specifies that this field must be only one of the defined
	// values for this enum, failing on any undefined value.
	DefinedOnly *bool `protobuf:"varint,2,opt,name=defined_only,json=definedOnly" json:"defined_only"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"varint,3,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int32 `protobuf:"varint,4,rep,name=not_in,json=notIn" json:"not_in"`
	// contains filtered or unexported fields
}

EnumRules describe the constraints applied to enum values

func (*EnumRules) Descriptor deprecated

func (*EnumRules) Descriptor() ([]byte, []int)

Deprecated: Use EnumRules.ProtoReflect.Descriptor instead.

func (*EnumRules) GetConst

func (x *EnumRules) GetConst() int32

func (*EnumRules) GetDefinedOnly

func (x *EnumRules) GetDefinedOnly() bool

func (*EnumRules) GetIn

func (x *EnumRules) GetIn() []int32

func (*EnumRules) GetNotIn

func (x *EnumRules) GetNotIn() []int32

func (*EnumRules) ProtoMessage

func (*EnumRules) ProtoMessage()

func (*EnumRules) ProtoReflect

func (x *EnumRules) ProtoReflect() protoreflect.Message

func (*EnumRules) Reset

func (x *EnumRules) Reset()

func (*EnumRules) String

func (x *EnumRules) String() string

func (*EnumRules) Validate

func (m *EnumRules) Validate() error

Validate checks the field values on EnumRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*EnumRules) ValidateAll

func (m *EnumRules) ValidateAll() error

ValidateAll checks the field values on EnumRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in EnumRulesMultiError, or nil if none found.

type EnumRulesMultiError

type EnumRulesMultiError []error

EnumRulesMultiError is an error wrapping multiple validation errors returned by EnumRules.ValidateAll() if the designated constraints aren't met.

func (EnumRulesMultiError) AllErrors

func (m EnumRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (EnumRulesMultiError) Error

func (m EnumRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type EnumRulesValidationError

type EnumRulesValidationError struct {
	// contains filtered or unexported fields
}

EnumRulesValidationError is the validation error returned by EnumRules.Validate if the designated constraints aren't met.

func (EnumRulesValidationError) Cause

func (e EnumRulesValidationError) Cause() error

Cause function returns cause value.

func (EnumRulesValidationError) Error

func (e EnumRulesValidationError) Error() string

Error satisfies the builtin error interface

func (EnumRulesValidationError) ErrorName

func (e EnumRulesValidationError) ErrorName() string

ErrorName returns error name.

func (EnumRulesValidationError) Field

func (e EnumRulesValidationError) Field() string

Field function returns field value.

func (EnumRulesValidationError) Key

Key function returns key value.

func (EnumRulesValidationError) Reason

func (e EnumRulesValidationError) Reason() string

Reason function returns reason value.

type FieldRules

type FieldRules struct {
	Message *MessageRules `protobuf:"bytes,17,opt,name=message" json:"message"`
	// Types that are assignable to Type:
	//
	//	*FieldRules_Float
	//	*FieldRules_Double
	//	*FieldRules_Int32
	//	*FieldRules_Int64
	//	*FieldRules_Uint32
	//	*FieldRules_Uint64
	//	*FieldRules_Sint32
	//	*FieldRules_Sint64
	//	*FieldRules_Fixed32
	//	*FieldRules_Fixed64
	//	*FieldRules_Sfixed32
	//	*FieldRules_Sfixed64
	//	*FieldRules_Bool
	//	*FieldRules_String_
	//	*FieldRules_Bytes
	//	*FieldRules_Enum
	//	*FieldRules_Repeated
	//	*FieldRules_Map
	//	*FieldRules_Any
	//	*FieldRules_Duration
	//	*FieldRules_Timestamp
	Type isFieldRules_Type `protobuf_oneof:"type"`
	// contains filtered or unexported fields
}

FieldRules encapsulates the rules for each type of field. Depending on the field, the correct set should be used to ensure proper validations.

func (*FieldRules) Descriptor deprecated

func (*FieldRules) Descriptor() ([]byte, []int)

Deprecated: Use FieldRules.ProtoReflect.Descriptor instead.

func (*FieldRules) GetAny

func (x *FieldRules) GetAny() *AnyRules

func (*FieldRules) GetBool

func (x *FieldRules) GetBool() *BoolRules

func (*FieldRules) GetBytes

func (x *FieldRules) GetBytes() *BytesRules

func (*FieldRules) GetDouble

func (x *FieldRules) GetDouble() *DoubleRules

func (*FieldRules) GetDuration

func (x *FieldRules) GetDuration() *DurationRules

func (*FieldRules) GetEnum

func (x *FieldRules) GetEnum() *EnumRules

func (*FieldRules) GetFixed32

func (x *FieldRules) GetFixed32() *Fixed32Rules

func (*FieldRules) GetFixed64

func (x *FieldRules) GetFixed64() *Fixed64Rules

func (*FieldRules) GetFloat

func (x *FieldRules) GetFloat() *FloatRules

func (*FieldRules) GetInt32

func (x *FieldRules) GetInt32() *Int32Rules

func (*FieldRules) GetInt64

func (x *FieldRules) GetInt64() *Int64Rules

func (*FieldRules) GetMap

func (x *FieldRules) GetMap() *MapRules

func (*FieldRules) GetMessage

func (x *FieldRules) GetMessage() *MessageRules

func (*FieldRules) GetRepeated

func (x *FieldRules) GetRepeated() *RepeatedRules

func (*FieldRules) GetSfixed32

func (x *FieldRules) GetSfixed32() *SFixed32Rules

func (*FieldRules) GetSfixed64

func (x *FieldRules) GetSfixed64() *SFixed64Rules

func (*FieldRules) GetSint32

func (x *FieldRules) GetSint32() *SInt32Rules

func (*FieldRules) GetSint64

func (x *FieldRules) GetSint64() *SInt64Rules

func (*FieldRules) GetString_

func (x *FieldRules) GetString_() *StringRules

func (*FieldRules) GetTimestamp

func (x *FieldRules) GetTimestamp() *TimestampRules

func (*FieldRules) GetType

func (m *FieldRules) GetType() isFieldRules_Type

func (*FieldRules) GetUint32

func (x *FieldRules) GetUint32() *UInt32Rules

func (*FieldRules) GetUint64

func (x *FieldRules) GetUint64() *UInt64Rules

func (*FieldRules) ProtoMessage

func (*FieldRules) ProtoMessage()

func (*FieldRules) ProtoReflect

func (x *FieldRules) ProtoReflect() protoreflect.Message

func (*FieldRules) Reset

func (x *FieldRules) Reset()

func (*FieldRules) String

func (x *FieldRules) String() string

func (*FieldRules) Validate

func (m *FieldRules) Validate() error

Validate checks the field values on FieldRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*FieldRules) ValidateAll

func (m *FieldRules) ValidateAll() error

ValidateAll checks the field values on FieldRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in FieldRulesMultiError, or nil if none found.

type FieldRulesMultiError

type FieldRulesMultiError []error

FieldRulesMultiError is an error wrapping multiple validation errors returned by FieldRules.ValidateAll() if the designated constraints aren't met.

func (FieldRulesMultiError) AllErrors

func (m FieldRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (FieldRulesMultiError) Error

func (m FieldRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type FieldRulesValidationError

type FieldRulesValidationError struct {
	// contains filtered or unexported fields
}

FieldRulesValidationError is the validation error returned by FieldRules.Validate if the designated constraints aren't met.

func (FieldRulesValidationError) Cause

func (e FieldRulesValidationError) Cause() error

Cause function returns cause value.

func (FieldRulesValidationError) Error

Error satisfies the builtin error interface

func (FieldRulesValidationError) ErrorName

func (e FieldRulesValidationError) ErrorName() string

ErrorName returns error name.

func (FieldRulesValidationError) Field

Field function returns field value.

func (FieldRulesValidationError) Key

Key function returns key value.

func (FieldRulesValidationError) Reason

func (e FieldRulesValidationError) Reason() string

Reason function returns reason value.

type FieldRules_Any

type FieldRules_Any struct {
	// Well-Known Field Types
	Any *AnyRules `protobuf:"bytes,20,opt,name=any,oneof"`
}

type FieldRules_Bool

type FieldRules_Bool struct {
	Bool *BoolRules `protobuf:"bytes,13,opt,name=bool,oneof"`
}

type FieldRules_Bytes

type FieldRules_Bytes struct {
	Bytes *BytesRules `protobuf:"bytes,15,opt,name=bytes,oneof"`
}

type FieldRules_Double

type FieldRules_Double struct {
	Double *DoubleRules `protobuf:"bytes,2,opt,name=double,oneof"`
}

type FieldRules_Duration

type FieldRules_Duration struct {
	Duration *DurationRules `protobuf:"bytes,21,opt,name=duration,oneof"`
}

type FieldRules_Enum

type FieldRules_Enum struct {
	// Complex Field Types
	Enum *EnumRules `protobuf:"bytes,16,opt,name=enum,oneof"`
}

type FieldRules_Fixed32

type FieldRules_Fixed32 struct {
	Fixed32 *Fixed32Rules `protobuf:"bytes,9,opt,name=fixed32,oneof"`
}

type FieldRules_Fixed64

type FieldRules_Fixed64 struct {
	Fixed64 *Fixed64Rules `protobuf:"bytes,10,opt,name=fixed64,oneof"`
}

type FieldRules_Float

type FieldRules_Float struct {
	// Scalar Field Types
	Float *FloatRules `protobuf:"bytes,1,opt,name=float,oneof"`
}

type FieldRules_Int32

type FieldRules_Int32 struct {
	Int32 *Int32Rules `protobuf:"bytes,3,opt,name=int32,oneof"`
}

type FieldRules_Int64

type FieldRules_Int64 struct {
	Int64 *Int64Rules `protobuf:"bytes,4,opt,name=int64,oneof"`
}

type FieldRules_Map

type FieldRules_Map struct {
	Map *MapRules `protobuf:"bytes,19,opt,name=map,oneof"`
}

type FieldRules_Repeated

type FieldRules_Repeated struct {
	Repeated *RepeatedRules `protobuf:"bytes,18,opt,name=repeated,oneof"`
}

type FieldRules_Sfixed32

type FieldRules_Sfixed32 struct {
	Sfixed32 *SFixed32Rules `protobuf:"bytes,11,opt,name=sfixed32,oneof"`
}

type FieldRules_Sfixed64

type FieldRules_Sfixed64 struct {
	Sfixed64 *SFixed64Rules `protobuf:"bytes,12,opt,name=sfixed64,oneof"`
}

type FieldRules_Sint32

type FieldRules_Sint32 struct {
	Sint32 *SInt32Rules `protobuf:"bytes,7,opt,name=sint32,oneof"`
}

type FieldRules_Sint64

type FieldRules_Sint64 struct {
	Sint64 *SInt64Rules `protobuf:"bytes,8,opt,name=sint64,oneof"`
}

type FieldRules_String_

type FieldRules_String_ struct {
	String_ *StringRules `protobuf:"bytes,14,opt,name=string,oneof"`
}

type FieldRules_Timestamp

type FieldRules_Timestamp struct {
	Timestamp *TimestampRules `protobuf:"bytes,22,opt,name=timestamp,oneof"`
}

type FieldRules_Uint32

type FieldRules_Uint32 struct {
	Uint32 *UInt32Rules `protobuf:"bytes,5,opt,name=uint32,oneof"`
}

type FieldRules_Uint64

type FieldRules_Uint64 struct {
	Uint64 *UInt64Rules `protobuf:"bytes,6,opt,name=uint64,oneof"`
}

type Fixed32Rules

type Fixed32Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *uint32 `protobuf:"fixed32,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint32 `protobuf:"fixed32,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *uint32 `protobuf:"fixed32,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *uint32 `protobuf:"fixed32,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *uint32 `protobuf:"fixed32,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint32 `protobuf:"fixed32,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []uint32 `protobuf:"fixed32,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

Fixed32Rules describes the constraints applied to `fixed32` values

func (*Fixed32Rules) Descriptor deprecated

func (*Fixed32Rules) Descriptor() ([]byte, []int)

Deprecated: Use Fixed32Rules.ProtoReflect.Descriptor instead.

func (*Fixed32Rules) GetConst

func (x *Fixed32Rules) GetConst() uint32

func (*Fixed32Rules) GetGt

func (x *Fixed32Rules) GetGt() uint32

func (*Fixed32Rules) GetGte

func (x *Fixed32Rules) GetGte() uint32

func (*Fixed32Rules) GetIgnoreEmpty

func (x *Fixed32Rules) GetIgnoreEmpty() bool

func (*Fixed32Rules) GetIn

func (x *Fixed32Rules) GetIn() []uint32

func (*Fixed32Rules) GetLt

func (x *Fixed32Rules) GetLt() uint32

func (*Fixed32Rules) GetLte

func (x *Fixed32Rules) GetLte() uint32

func (*Fixed32Rules) GetNotIn

func (x *Fixed32Rules) GetNotIn() []uint32

func (*Fixed32Rules) ProtoMessage

func (*Fixed32Rules) ProtoMessage()

func (*Fixed32Rules) ProtoReflect

func (x *Fixed32Rules) ProtoReflect() protoreflect.Message

func (*Fixed32Rules) Reset

func (x *Fixed32Rules) Reset()

func (*Fixed32Rules) String

func (x *Fixed32Rules) String() string

func (*Fixed32Rules) Validate

func (m *Fixed32Rules) Validate() error

Validate checks the field values on Fixed32Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Fixed32Rules) ValidateAll

func (m *Fixed32Rules) ValidateAll() error

ValidateAll checks the field values on Fixed32Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Fixed32RulesMultiError, or nil if none found.

type Fixed32RulesMultiError

type Fixed32RulesMultiError []error

Fixed32RulesMultiError is an error wrapping multiple validation errors returned by Fixed32Rules.ValidateAll() if the designated constraints aren't met.

func (Fixed32RulesMultiError) AllErrors

func (m Fixed32RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Fixed32RulesMultiError) Error

func (m Fixed32RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type Fixed32RulesValidationError

type Fixed32RulesValidationError struct {
	// contains filtered or unexported fields
}

Fixed32RulesValidationError is the validation error returned by Fixed32Rules.Validate if the designated constraints aren't met.

func (Fixed32RulesValidationError) Cause

Cause function returns cause value.

func (Fixed32RulesValidationError) Error

Error satisfies the builtin error interface

func (Fixed32RulesValidationError) ErrorName

func (e Fixed32RulesValidationError) ErrorName() string

ErrorName returns error name.

func (Fixed32RulesValidationError) Field

Field function returns field value.

func (Fixed32RulesValidationError) Key

Key function returns key value.

func (Fixed32RulesValidationError) Reason

Reason function returns reason value.

type Fixed64Rules

type Fixed64Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *uint64 `protobuf:"fixed64,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint64 `protobuf:"fixed64,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *uint64 `protobuf:"fixed64,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *uint64 `protobuf:"fixed64,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *uint64 `protobuf:"fixed64,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint64 `protobuf:"fixed64,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []uint64 `protobuf:"fixed64,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

Fixed64Rules describes the constraints applied to `fixed64` values

func (*Fixed64Rules) Descriptor deprecated

func (*Fixed64Rules) Descriptor() ([]byte, []int)

Deprecated: Use Fixed64Rules.ProtoReflect.Descriptor instead.

func (*Fixed64Rules) GetConst

func (x *Fixed64Rules) GetConst() uint64

func (*Fixed64Rules) GetGt

func (x *Fixed64Rules) GetGt() uint64

func (*Fixed64Rules) GetGte

func (x *Fixed64Rules) GetGte() uint64

func (*Fixed64Rules) GetIgnoreEmpty

func (x *Fixed64Rules) GetIgnoreEmpty() bool

func (*Fixed64Rules) GetIn

func (x *Fixed64Rules) GetIn() []uint64

func (*Fixed64Rules) GetLt

func (x *Fixed64Rules) GetLt() uint64

func (*Fixed64Rules) GetLte

func (x *Fixed64Rules) GetLte() uint64

func (*Fixed64Rules) GetNotIn

func (x *Fixed64Rules) GetNotIn() []uint64

func (*Fixed64Rules) ProtoMessage

func (*Fixed64Rules) ProtoMessage()

func (*Fixed64Rules) ProtoReflect

func (x *Fixed64Rules) ProtoReflect() protoreflect.Message

func (*Fixed64Rules) Reset

func (x *Fixed64Rules) Reset()

func (*Fixed64Rules) String

func (x *Fixed64Rules) String() string

func (*Fixed64Rules) Validate

func (m *Fixed64Rules) Validate() error

Validate checks the field values on Fixed64Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Fixed64Rules) ValidateAll

func (m *Fixed64Rules) ValidateAll() error

ValidateAll checks the field values on Fixed64Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Fixed64RulesMultiError, or nil if none found.

type Fixed64RulesMultiError

type Fixed64RulesMultiError []error

Fixed64RulesMultiError is an error wrapping multiple validation errors returned by Fixed64Rules.ValidateAll() if the designated constraints aren't met.

func (Fixed64RulesMultiError) AllErrors

func (m Fixed64RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Fixed64RulesMultiError) Error

func (m Fixed64RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type Fixed64RulesValidationError

type Fixed64RulesValidationError struct {
	// contains filtered or unexported fields
}

Fixed64RulesValidationError is the validation error returned by Fixed64Rules.Validate if the designated constraints aren't met.

func (Fixed64RulesValidationError) Cause

Cause function returns cause value.

func (Fixed64RulesValidationError) Error

Error satisfies the builtin error interface

func (Fixed64RulesValidationError) ErrorName

func (e Fixed64RulesValidationError) ErrorName() string

ErrorName returns error name.

func (Fixed64RulesValidationError) Field

Field function returns field value.

func (Fixed64RulesValidationError) Key

Key function returns key value.

func (Fixed64RulesValidationError) Reason

Reason function returns reason value.

type FloatRules

type FloatRules struct {

	// Const specifies that this field must be exactly the specified value
	Const *float32 `protobuf:"fixed32,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *float32 `protobuf:"fixed32,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *float32 `protobuf:"fixed32,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *float32 `protobuf:"fixed32,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *float32 `protobuf:"fixed32,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []float32 `protobuf:"fixed32,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []float32 `protobuf:"fixed32,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

FloatRules describes the constraints applied to `float` values

func (*FloatRules) Descriptor deprecated

func (*FloatRules) Descriptor() ([]byte, []int)

Deprecated: Use FloatRules.ProtoReflect.Descriptor instead.

func (*FloatRules) GetConst

func (x *FloatRules) GetConst() float32

func (*FloatRules) GetGt

func (x *FloatRules) GetGt() float32

func (*FloatRules) GetGte

func (x *FloatRules) GetGte() float32

func (*FloatRules) GetIgnoreEmpty

func (x *FloatRules) GetIgnoreEmpty() bool

func (*FloatRules) GetIn

func (x *FloatRules) GetIn() []float32

func (*FloatRules) GetLt

func (x *FloatRules) GetLt() float32

func (*FloatRules) GetLte

func (x *FloatRules) GetLte() float32

func (*FloatRules) GetNotIn

func (x *FloatRules) GetNotIn() []float32

func (*FloatRules) ProtoMessage

func (*FloatRules) ProtoMessage()

func (*FloatRules) ProtoReflect

func (x *FloatRules) ProtoReflect() protoreflect.Message

func (*FloatRules) Reset

func (x *FloatRules) Reset()

func (*FloatRules) String

func (x *FloatRules) String() string

func (*FloatRules) Validate

func (m *FloatRules) Validate() error

Validate checks the field values on FloatRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*FloatRules) ValidateAll

func (m *FloatRules) ValidateAll() error

ValidateAll checks the field values on FloatRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in FloatRulesMultiError, or nil if none found.

type FloatRulesMultiError

type FloatRulesMultiError []error

FloatRulesMultiError is an error wrapping multiple validation errors returned by FloatRules.ValidateAll() if the designated constraints aren't met.

func (FloatRulesMultiError) AllErrors

func (m FloatRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (FloatRulesMultiError) Error

func (m FloatRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type FloatRulesValidationError

type FloatRulesValidationError struct {
	// contains filtered or unexported fields
}

FloatRulesValidationError is the validation error returned by FloatRules.Validate if the designated constraints aren't met.

func (FloatRulesValidationError) Cause

func (e FloatRulesValidationError) Cause() error

Cause function returns cause value.

func (FloatRulesValidationError) Error

Error satisfies the builtin error interface

func (FloatRulesValidationError) ErrorName

func (e FloatRulesValidationError) ErrorName() string

ErrorName returns error name.

func (FloatRulesValidationError) Field

Field function returns field value.

func (FloatRulesValidationError) Key

Key function returns key value.

func (FloatRulesValidationError) Reason

func (e FloatRulesValidationError) Reason() string

Reason function returns reason value.

type Int32Rules

type Int32Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int32 `protobuf:"varint,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"varint,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int32 `protobuf:"varint,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int32 `protobuf:"varint,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int32 `protobuf:"varint,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"varint,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int32 `protobuf:"varint,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

Int32Rules describes the constraints applied to `int32` values

func (*Int32Rules) Descriptor deprecated

func (*Int32Rules) Descriptor() ([]byte, []int)

Deprecated: Use Int32Rules.ProtoReflect.Descriptor instead.

func (*Int32Rules) GetConst

func (x *Int32Rules) GetConst() int32

func (*Int32Rules) GetGt

func (x *Int32Rules) GetGt() int32

func (*Int32Rules) GetGte

func (x *Int32Rules) GetGte() int32

func (*Int32Rules) GetIgnoreEmpty

func (x *Int32Rules) GetIgnoreEmpty() bool

func (*Int32Rules) GetIn

func (x *Int32Rules) GetIn() []int32

func (*Int32Rules) GetLt

func (x *Int32Rules) GetLt() int32

func (*Int32Rules) GetLte

func (x *Int32Rules) GetLte() int32

func (*Int32Rules) GetNotIn

func (x *Int32Rules) GetNotIn() []int32

func (*Int32Rules) ProtoMessage

func (*Int32Rules) ProtoMessage()

func (*Int32Rules) ProtoReflect

func (x *Int32Rules) ProtoReflect() protoreflect.Message

func (*Int32Rules) Reset

func (x *Int32Rules) Reset()

func (*Int32Rules) String

func (x *Int32Rules) String() string

func (*Int32Rules) Validate

func (m *Int32Rules) Validate() error

Validate checks the field values on Int32Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Int32Rules) ValidateAll

func (m *Int32Rules) ValidateAll() error

ValidateAll checks the field values on Int32Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Int32RulesMultiError, or nil if none found.

type Int32RulesMultiError

type Int32RulesMultiError []error

Int32RulesMultiError is an error wrapping multiple validation errors returned by Int32Rules.ValidateAll() if the designated constraints aren't met.

func (Int32RulesMultiError) AllErrors

func (m Int32RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Int32RulesMultiError) Error

func (m Int32RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type Int32RulesValidationError

type Int32RulesValidationError struct {
	// contains filtered or unexported fields
}

Int32RulesValidationError is the validation error returned by Int32Rules.Validate if the designated constraints aren't met.

func (Int32RulesValidationError) Cause

func (e Int32RulesValidationError) Cause() error

Cause function returns cause value.

func (Int32RulesValidationError) Error

Error satisfies the builtin error interface

func (Int32RulesValidationError) ErrorName

func (e Int32RulesValidationError) ErrorName() string

ErrorName returns error name.

func (Int32RulesValidationError) Field

Field function returns field value.

func (Int32RulesValidationError) Key

Key function returns key value.

func (Int32RulesValidationError) Reason

func (e Int32RulesValidationError) Reason() string

Reason function returns reason value.

type Int64Rules

type Int64Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int64 `protobuf:"varint,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"varint,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int64 `protobuf:"varint,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int64 `protobuf:"varint,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int64 `protobuf:"varint,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"varint,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int64 `protobuf:"varint,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

Int64Rules describes the constraints applied to `int64` values

func (*Int64Rules) Descriptor deprecated

func (*Int64Rules) Descriptor() ([]byte, []int)

Deprecated: Use Int64Rules.ProtoReflect.Descriptor instead.

func (*Int64Rules) GetConst

func (x *Int64Rules) GetConst() int64

func (*Int64Rules) GetGt

func (x *Int64Rules) GetGt() int64

func (*Int64Rules) GetGte

func (x *Int64Rules) GetGte() int64

func (*Int64Rules) GetIgnoreEmpty

func (x *Int64Rules) GetIgnoreEmpty() bool

func (*Int64Rules) GetIn

func (x *Int64Rules) GetIn() []int64

func (*Int64Rules) GetLt

func (x *Int64Rules) GetLt() int64

func (*Int64Rules) GetLte

func (x *Int64Rules) GetLte() int64

func (*Int64Rules) GetNotIn

func (x *Int64Rules) GetNotIn() []int64

func (*Int64Rules) ProtoMessage

func (*Int64Rules) ProtoMessage()

func (*Int64Rules) ProtoReflect

func (x *Int64Rules) ProtoReflect() protoreflect.Message

func (*Int64Rules) Reset

func (x *Int64Rules) Reset()

func (*Int64Rules) String

func (x *Int64Rules) String() string

func (*Int64Rules) Validate

func (m *Int64Rules) Validate() error

Validate checks the field values on Int64Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Int64Rules) ValidateAll

func (m *Int64Rules) ValidateAll() error

ValidateAll checks the field values on Int64Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Int64RulesMultiError, or nil if none found.

type Int64RulesMultiError

type Int64RulesMultiError []error

Int64RulesMultiError is an error wrapping multiple validation errors returned by Int64Rules.ValidateAll() if the designated constraints aren't met.

func (Int64RulesMultiError) AllErrors

func (m Int64RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Int64RulesMultiError) Error

func (m Int64RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type Int64RulesValidationError

type Int64RulesValidationError struct {
	// contains filtered or unexported fields
}

Int64RulesValidationError is the validation error returned by Int64Rules.Validate if the designated constraints aren't met.

func (Int64RulesValidationError) Cause

func (e Int64RulesValidationError) Cause() error

Cause function returns cause value.

func (Int64RulesValidationError) Error

Error satisfies the builtin error interface

func (Int64RulesValidationError) ErrorName

func (e Int64RulesValidationError) ErrorName() string

ErrorName returns error name.

func (Int64RulesValidationError) Field

Field function returns field value.

func (Int64RulesValidationError) Key

Key function returns key value.

func (Int64RulesValidationError) Reason

func (e Int64RulesValidationError) Reason() string

Reason function returns reason value.

type KnownRegex

type KnownRegex int32

WellKnownRegex contain some well-known patterns.

const (
	KnownRegex_UNKNOWN KnownRegex = 0
	// HTTP header name as defined by RFC 7230.
	KnownRegex_HTTP_HEADER_NAME KnownRegex = 1
	// HTTP header value as defined by RFC 7230.
	KnownRegex_HTTP_HEADER_VALUE KnownRegex = 2
)

func (KnownRegex) Descriptor

func (KnownRegex) Descriptor() protoreflect.EnumDescriptor

func (KnownRegex) Enum

func (x KnownRegex) Enum() *KnownRegex

func (KnownRegex) EnumDescriptor deprecated

func (KnownRegex) EnumDescriptor() ([]byte, []int)

Deprecated: Use KnownRegex.Descriptor instead.

func (KnownRegex) Number

func (x KnownRegex) Number() protoreflect.EnumNumber

func (KnownRegex) String

func (x KnownRegex) String() string

func (KnownRegex) Type

func (*KnownRegex) UnmarshalJSON deprecated

func (x *KnownRegex) UnmarshalJSON(b []byte) error

Deprecated: Do not use.

type MapRules

type MapRules struct {

	// MinPairs specifies that this field must have the specified number of
	// KVs at a minimum
	MinPairs *uint64 `protobuf:"varint,1,opt,name=min_pairs,json=minPairs" json:"min_pairs"`
	// MaxPairs specifies that this field must have the specified number of
	// KVs at a maximum
	MaxPairs *uint64 `protobuf:"varint,2,opt,name=max_pairs,json=maxPairs" json:"max_pairs"`
	// NoSparse specifies values in this field cannot be unset. This only
	// applies to map's with message value types.
	NoSparse *bool `protobuf:"varint,3,opt,name=no_sparse,json=noSparse" json:"no_sparse"`
	// Keys specifies the constraints to be applied to each key in the field.
	Keys *FieldRules `protobuf:"bytes,4,opt,name=keys" json:"keys"`
	// Values specifies the constraints to be applied to the value of each key
	// in the field. Message values will still have their validations evaluated
	// unless skip is specified here.
	Values *FieldRules `protobuf:"bytes,5,opt,name=values" json:"values"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,6,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

MapRules describe the constraints applied to `map` values

func (*MapRules) Descriptor deprecated

func (*MapRules) Descriptor() ([]byte, []int)

Deprecated: Use MapRules.ProtoReflect.Descriptor instead.

func (*MapRules) GetIgnoreEmpty

func (x *MapRules) GetIgnoreEmpty() bool

func (*MapRules) GetKeys

func (x *MapRules) GetKeys() *FieldRules

func (*MapRules) GetMaxPairs

func (x *MapRules) GetMaxPairs() uint64

func (*MapRules) GetMinPairs

func (x *MapRules) GetMinPairs() uint64

func (*MapRules) GetNoSparse

func (x *MapRules) GetNoSparse() bool

func (*MapRules) GetValues

func (x *MapRules) GetValues() *FieldRules

func (*MapRules) ProtoMessage

func (*MapRules) ProtoMessage()

func (*MapRules) ProtoReflect

func (x *MapRules) ProtoReflect() protoreflect.Message

func (*MapRules) Reset

func (x *MapRules) Reset()

func (*MapRules) String

func (x *MapRules) String() string

func (*MapRules) Validate

func (m *MapRules) Validate() error

Validate checks the field values on MapRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*MapRules) ValidateAll

func (m *MapRules) ValidateAll() error

ValidateAll checks the field values on MapRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in MapRulesMultiError, or nil if none found.

type MapRulesMultiError

type MapRulesMultiError []error

MapRulesMultiError is an error wrapping multiple validation errors returned by MapRules.ValidateAll() if the designated constraints aren't met.

func (MapRulesMultiError) AllErrors

func (m MapRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (MapRulesMultiError) Error

func (m MapRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type MapRulesValidationError

type MapRulesValidationError struct {
	// contains filtered or unexported fields
}

MapRulesValidationError is the validation error returned by MapRules.Validate if the designated constraints aren't met.

func (MapRulesValidationError) Cause

func (e MapRulesValidationError) Cause() error

Cause function returns cause value.

func (MapRulesValidationError) Error

func (e MapRulesValidationError) Error() string

Error satisfies the builtin error interface

func (MapRulesValidationError) ErrorName

func (e MapRulesValidationError) ErrorName() string

ErrorName returns error name.

func (MapRulesValidationError) Field

func (e MapRulesValidationError) Field() string

Field function returns field value.

func (MapRulesValidationError) Key

func (e MapRulesValidationError) Key() bool

Key function returns key value.

func (MapRulesValidationError) Reason

func (e MapRulesValidationError) Reason() string

Reason function returns reason value.

type MessageRules

type MessageRules struct {

	// Skip specifies that the validation rules of this field should not be
	// evaluated
	Skip *bool `protobuf:"varint,1,opt,name=skip" json:"skip"`
	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,2,opt,name=required" json:"required"`
	// contains filtered or unexported fields
}

MessageRules describe the constraints applied to embedded message values. For message-type fields, validation is performed recursively.

func (*MessageRules) Descriptor deprecated

func (*MessageRules) Descriptor() ([]byte, []int)

Deprecated: Use MessageRules.ProtoReflect.Descriptor instead.

func (*MessageRules) GetRequired

func (x *MessageRules) GetRequired() bool

func (*MessageRules) GetSkip

func (x *MessageRules) GetSkip() bool

func (*MessageRules) ProtoMessage

func (*MessageRules) ProtoMessage()

func (*MessageRules) ProtoReflect

func (x *MessageRules) ProtoReflect() protoreflect.Message

func (*MessageRules) Reset

func (x *MessageRules) Reset()

func (*MessageRules) String

func (x *MessageRules) String() string

func (*MessageRules) Validate

func (m *MessageRules) Validate() error

Validate checks the field values on MessageRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*MessageRules) ValidateAll

func (m *MessageRules) ValidateAll() error

ValidateAll checks the field values on MessageRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in MessageRulesMultiError, or nil if none found.

type MessageRulesMultiError

type MessageRulesMultiError []error

MessageRulesMultiError is an error wrapping multiple validation errors returned by MessageRules.ValidateAll() if the designated constraints aren't met.

func (MessageRulesMultiError) AllErrors

func (m MessageRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (MessageRulesMultiError) Error

func (m MessageRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type MessageRulesValidationError

type MessageRulesValidationError struct {
	// contains filtered or unexported fields
}

MessageRulesValidationError is the validation error returned by MessageRules.Validate if the designated constraints aren't met.

func (MessageRulesValidationError) Cause

Cause function returns cause value.

func (MessageRulesValidationError) Error

Error satisfies the builtin error interface

func (MessageRulesValidationError) ErrorName

func (e MessageRulesValidationError) ErrorName() string

ErrorName returns error name.

func (MessageRulesValidationError) Field

Field function returns field value.

func (MessageRulesValidationError) Key

Key function returns key value.

func (MessageRulesValidationError) Reason

Reason function returns reason value.

type RepeatedRules

type RepeatedRules struct {

	// MinItems specifies that this field must have the specified number of
	// items at a minimum
	MinItems *uint64 `protobuf:"varint,1,opt,name=min_items,json=minItems" json:"min_items"`
	// MaxItems specifies that this field must have the specified number of
	// items at a maximum
	MaxItems *uint64 `protobuf:"varint,2,opt,name=max_items,json=maxItems" json:"max_items"`
	// Unique specifies that all elements in this field must be unique. This
	// contraint is only applicable to scalar and enum types (messages are not
	// supported).
	Unique *bool `protobuf:"varint,3,opt,name=unique" json:"unique"`
	// Items specifies the contraints to be applied to each item in the field.
	// Repeated message fields will still execute validation against each item
	// unless skip is specified here.
	Items *FieldRules `protobuf:"bytes,4,opt,name=items" json:"items"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,5,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

RepeatedRules describe the constraints applied to `repeated` values

func (*RepeatedRules) Descriptor deprecated

func (*RepeatedRules) Descriptor() ([]byte, []int)

Deprecated: Use RepeatedRules.ProtoReflect.Descriptor instead.

func (*RepeatedRules) GetIgnoreEmpty

func (x *RepeatedRules) GetIgnoreEmpty() bool

func (*RepeatedRules) GetItems

func (x *RepeatedRules) GetItems() *FieldRules

func (*RepeatedRules) GetMaxItems

func (x *RepeatedRules) GetMaxItems() uint64

func (*RepeatedRules) GetMinItems

func (x *RepeatedRules) GetMinItems() uint64

func (*RepeatedRules) GetUnique

func (x *RepeatedRules) GetUnique() bool

func (*RepeatedRules) ProtoMessage

func (*RepeatedRules) ProtoMessage()

func (*RepeatedRules) ProtoReflect

func (x *RepeatedRules) ProtoReflect() protoreflect.Message

func (*RepeatedRules) Reset

func (x *RepeatedRules) Reset()

func (*RepeatedRules) String

func (x *RepeatedRules) String() string

func (*RepeatedRules) Validate

func (m *RepeatedRules) Validate() error

Validate checks the field values on RepeatedRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*RepeatedRules) ValidateAll

func (m *RepeatedRules) ValidateAll() error

ValidateAll checks the field values on RepeatedRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in RepeatedRulesMultiError, or nil if none found.

type RepeatedRulesMultiError

type RepeatedRulesMultiError []error

RepeatedRulesMultiError is an error wrapping multiple validation errors returned by RepeatedRules.ValidateAll() if the designated constraints aren't met.

func (RepeatedRulesMultiError) AllErrors

func (m RepeatedRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (RepeatedRulesMultiError) Error

func (m RepeatedRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type RepeatedRulesValidationError

type RepeatedRulesValidationError struct {
	// contains filtered or unexported fields
}

RepeatedRulesValidationError is the validation error returned by RepeatedRules.Validate if the designated constraints aren't met.

func (RepeatedRulesValidationError) Cause

Cause function returns cause value.

func (RepeatedRulesValidationError) Error

Error satisfies the builtin error interface

func (RepeatedRulesValidationError) ErrorName

func (e RepeatedRulesValidationError) ErrorName() string

ErrorName returns error name.

func (RepeatedRulesValidationError) Field

Field function returns field value.

func (RepeatedRulesValidationError) Key

Key function returns key value.

func (RepeatedRulesValidationError) Reason

Reason function returns reason value.

type SFixed32Rules

type SFixed32Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int32 `protobuf:"fixed32,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"fixed32,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int32 `protobuf:"fixed32,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int32 `protobuf:"fixed32,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int32 `protobuf:"fixed32,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"fixed32,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int32 `protobuf:"fixed32,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

SFixed32Rules describes the constraints applied to `sfixed32` values

func (*SFixed32Rules) Descriptor deprecated

func (*SFixed32Rules) Descriptor() ([]byte, []int)

Deprecated: Use SFixed32Rules.ProtoReflect.Descriptor instead.

func (*SFixed32Rules) GetConst

func (x *SFixed32Rules) GetConst() int32

func (*SFixed32Rules) GetGt

func (x *SFixed32Rules) GetGt() int32

func (*SFixed32Rules) GetGte

func (x *SFixed32Rules) GetGte() int32

func (*SFixed32Rules) GetIgnoreEmpty

func (x *SFixed32Rules) GetIgnoreEmpty() bool

func (*SFixed32Rules) GetIn

func (x *SFixed32Rules) GetIn() []int32

func (*SFixed32Rules) GetLt

func (x *SFixed32Rules) GetLt() int32

func (*SFixed32Rules) GetLte

func (x *SFixed32Rules) GetLte() int32

func (*SFixed32Rules) GetNotIn

func (x *SFixed32Rules) GetNotIn() []int32

func (*SFixed32Rules) ProtoMessage

func (*SFixed32Rules) ProtoMessage()

func (*SFixed32Rules) ProtoReflect

func (x *SFixed32Rules) ProtoReflect() protoreflect.Message

func (*SFixed32Rules) Reset

func (x *SFixed32Rules) Reset()

func (*SFixed32Rules) String

func (x *SFixed32Rules) String() string

func (*SFixed32Rules) Validate

func (m *SFixed32Rules) Validate() error

Validate checks the field values on SFixed32Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SFixed32Rules) ValidateAll

func (m *SFixed32Rules) ValidateAll() error

ValidateAll checks the field values on SFixed32Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SFixed32RulesMultiError, or nil if none found.

type SFixed32RulesMultiError

type SFixed32RulesMultiError []error

SFixed32RulesMultiError is an error wrapping multiple validation errors returned by SFixed32Rules.ValidateAll() if the designated constraints aren't met.

func (SFixed32RulesMultiError) AllErrors

func (m SFixed32RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SFixed32RulesMultiError) Error

func (m SFixed32RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SFixed32RulesValidationError

type SFixed32RulesValidationError struct {
	// contains filtered or unexported fields
}

SFixed32RulesValidationError is the validation error returned by SFixed32Rules.Validate if the designated constraints aren't met.

func (SFixed32RulesValidationError) Cause

Cause function returns cause value.

func (SFixed32RulesValidationError) Error

Error satisfies the builtin error interface

func (SFixed32RulesValidationError) ErrorName

func (e SFixed32RulesValidationError) ErrorName() string

ErrorName returns error name.

func (SFixed32RulesValidationError) Field

Field function returns field value.

func (SFixed32RulesValidationError) Key

Key function returns key value.

func (SFixed32RulesValidationError) Reason

Reason function returns reason value.

type SFixed64Rules

type SFixed64Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int64 `protobuf:"fixed64,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"fixed64,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int64 `protobuf:"fixed64,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int64 `protobuf:"fixed64,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int64 `protobuf:"fixed64,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"fixed64,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int64 `protobuf:"fixed64,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

SFixed64Rules describes the constraints applied to `sfixed64` values

func (*SFixed64Rules) Descriptor deprecated

func (*SFixed64Rules) Descriptor() ([]byte, []int)

Deprecated: Use SFixed64Rules.ProtoReflect.Descriptor instead.

func (*SFixed64Rules) GetConst

func (x *SFixed64Rules) GetConst() int64

func (*SFixed64Rules) GetGt

func (x *SFixed64Rules) GetGt() int64

func (*SFixed64Rules) GetGte

func (x *SFixed64Rules) GetGte() int64

func (*SFixed64Rules) GetIgnoreEmpty

func (x *SFixed64Rules) GetIgnoreEmpty() bool

func (*SFixed64Rules) GetIn

func (x *SFixed64Rules) GetIn() []int64

func (*SFixed64Rules) GetLt

func (x *SFixed64Rules) GetLt() int64

func (*SFixed64Rules) GetLte

func (x *SFixed64Rules) GetLte() int64

func (*SFixed64Rules) GetNotIn

func (x *SFixed64Rules) GetNotIn() []int64

func (*SFixed64Rules) ProtoMessage

func (*SFixed64Rules) ProtoMessage()

func (*SFixed64Rules) ProtoReflect

func (x *SFixed64Rules) ProtoReflect() protoreflect.Message

func (*SFixed64Rules) Reset

func (x *SFixed64Rules) Reset()

func (*SFixed64Rules) String

func (x *SFixed64Rules) String() string

func (*SFixed64Rules) Validate

func (m *SFixed64Rules) Validate() error

Validate checks the field values on SFixed64Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SFixed64Rules) ValidateAll

func (m *SFixed64Rules) ValidateAll() error

ValidateAll checks the field values on SFixed64Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SFixed64RulesMultiError, or nil if none found.

type SFixed64RulesMultiError

type SFixed64RulesMultiError []error

SFixed64RulesMultiError is an error wrapping multiple validation errors returned by SFixed64Rules.ValidateAll() if the designated constraints aren't met.

func (SFixed64RulesMultiError) AllErrors

func (m SFixed64RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SFixed64RulesMultiError) Error

func (m SFixed64RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SFixed64RulesValidationError

type SFixed64RulesValidationError struct {
	// contains filtered or unexported fields
}

SFixed64RulesValidationError is the validation error returned by SFixed64Rules.Validate if the designated constraints aren't met.

func (SFixed64RulesValidationError) Cause

Cause function returns cause value.

func (SFixed64RulesValidationError) Error

Error satisfies the builtin error interface

func (SFixed64RulesValidationError) ErrorName

func (e SFixed64RulesValidationError) ErrorName() string

ErrorName returns error name.

func (SFixed64RulesValidationError) Field

Field function returns field value.

func (SFixed64RulesValidationError) Key

Key function returns key value.

func (SFixed64RulesValidationError) Reason

Reason function returns reason value.

type SInt32Rules

type SInt32Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int32 `protobuf:"zigzag32,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"zigzag32,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int32 `protobuf:"zigzag32,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int32 `protobuf:"zigzag32,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int32 `protobuf:"zigzag32,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"zigzag32,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int32 `protobuf:"zigzag32,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

SInt32Rules describes the constraints applied to `sint32` values

func (*SInt32Rules) Descriptor deprecated

func (*SInt32Rules) Descriptor() ([]byte, []int)

Deprecated: Use SInt32Rules.ProtoReflect.Descriptor instead.

func (*SInt32Rules) GetConst

func (x *SInt32Rules) GetConst() int32

func (*SInt32Rules) GetGt

func (x *SInt32Rules) GetGt() int32

func (*SInt32Rules) GetGte

func (x *SInt32Rules) GetGte() int32

func (*SInt32Rules) GetIgnoreEmpty

func (x *SInt32Rules) GetIgnoreEmpty() bool

func (*SInt32Rules) GetIn

func (x *SInt32Rules) GetIn() []int32

func (*SInt32Rules) GetLt

func (x *SInt32Rules) GetLt() int32

func (*SInt32Rules) GetLte

func (x *SInt32Rules) GetLte() int32

func (*SInt32Rules) GetNotIn

func (x *SInt32Rules) GetNotIn() []int32

func (*SInt32Rules) ProtoMessage

func (*SInt32Rules) ProtoMessage()

func (*SInt32Rules) ProtoReflect

func (x *SInt32Rules) ProtoReflect() protoreflect.Message

func (*SInt32Rules) Reset

func (x *SInt32Rules) Reset()

func (*SInt32Rules) String

func (x *SInt32Rules) String() string

func (*SInt32Rules) Validate

func (m *SInt32Rules) Validate() error

Validate checks the field values on SInt32Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SInt32Rules) ValidateAll

func (m *SInt32Rules) ValidateAll() error

ValidateAll checks the field values on SInt32Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SInt32RulesMultiError, or nil if none found.

type SInt32RulesMultiError

type SInt32RulesMultiError []error

SInt32RulesMultiError is an error wrapping multiple validation errors returned by SInt32Rules.ValidateAll() if the designated constraints aren't met.

func (SInt32RulesMultiError) AllErrors

func (m SInt32RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SInt32RulesMultiError) Error

func (m SInt32RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SInt32RulesValidationError

type SInt32RulesValidationError struct {
	// contains filtered or unexported fields
}

SInt32RulesValidationError is the validation error returned by SInt32Rules.Validate if the designated constraints aren't met.

func (SInt32RulesValidationError) Cause

Cause function returns cause value.

func (SInt32RulesValidationError) Error

Error satisfies the builtin error interface

func (SInt32RulesValidationError) ErrorName

func (e SInt32RulesValidationError) ErrorName() string

ErrorName returns error name.

func (SInt32RulesValidationError) Field

Field function returns field value.

func (SInt32RulesValidationError) Key

Key function returns key value.

func (SInt32RulesValidationError) Reason

Reason function returns reason value.

type SInt64Rules

type SInt64Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *int64 `protobuf:"zigzag64,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"zigzag64,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *int64 `protobuf:"zigzag64,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *int64 `protobuf:"zigzag64,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *int64 `protobuf:"zigzag64,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"zigzag64,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []int64 `protobuf:"zigzag64,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

SInt64Rules describes the constraints applied to `sint64` values

func (*SInt64Rules) Descriptor deprecated

func (*SInt64Rules) Descriptor() ([]byte, []int)

Deprecated: Use SInt64Rules.ProtoReflect.Descriptor instead.

func (*SInt64Rules) GetConst

func (x *SInt64Rules) GetConst() int64

func (*SInt64Rules) GetGt

func (x *SInt64Rules) GetGt() int64

func (*SInt64Rules) GetGte

func (x *SInt64Rules) GetGte() int64

func (*SInt64Rules) GetIgnoreEmpty

func (x *SInt64Rules) GetIgnoreEmpty() bool

func (*SInt64Rules) GetIn

func (x *SInt64Rules) GetIn() []int64

func (*SInt64Rules) GetLt

func (x *SInt64Rules) GetLt() int64

func (*SInt64Rules) GetLte

func (x *SInt64Rules) GetLte() int64

func (*SInt64Rules) GetNotIn

func (x *SInt64Rules) GetNotIn() []int64

func (*SInt64Rules) ProtoMessage

func (*SInt64Rules) ProtoMessage()

func (*SInt64Rules) ProtoReflect

func (x *SInt64Rules) ProtoReflect() protoreflect.Message

func (*SInt64Rules) Reset

func (x *SInt64Rules) Reset()

func (*SInt64Rules) String

func (x *SInt64Rules) String() string

func (*SInt64Rules) Validate

func (m *SInt64Rules) Validate() error

Validate checks the field values on SInt64Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*SInt64Rules) ValidateAll

func (m *SInt64Rules) ValidateAll() error

ValidateAll checks the field values on SInt64Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SInt64RulesMultiError, or nil if none found.

type SInt64RulesMultiError

type SInt64RulesMultiError []error

SInt64RulesMultiError is an error wrapping multiple validation errors returned by SInt64Rules.ValidateAll() if the designated constraints aren't met.

func (SInt64RulesMultiError) AllErrors

func (m SInt64RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SInt64RulesMultiError) Error

func (m SInt64RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SInt64RulesValidationError

type SInt64RulesValidationError struct {
	// contains filtered or unexported fields
}

SInt64RulesValidationError is the validation error returned by SInt64Rules.Validate if the designated constraints aren't met.

func (SInt64RulesValidationError) Cause

Cause function returns cause value.

func (SInt64RulesValidationError) Error

Error satisfies the builtin error interface

func (SInt64RulesValidationError) ErrorName

func (e SInt64RulesValidationError) ErrorName() string

ErrorName returns error name.

func (SInt64RulesValidationError) Field

Field function returns field value.

func (SInt64RulesValidationError) Key

Key function returns key value.

func (SInt64RulesValidationError) Reason

Reason function returns reason value.

type StringRules

type StringRules struct {

	// Const specifies that this field must be exactly the specified value
	Const *string `protobuf:"bytes,1,opt,name=const" json:"const"`
	// Len specifies that this field must be the specified number of
	// characters (Unicode code points). Note that the number of
	// characters may differ from the number of bytes in the string.
	Len *uint64 `protobuf:"varint,19,opt,name=len" json:"len"`
	// MinLen specifies that this field must be the specified number of
	// characters (Unicode code points) at a minimum. Note that the number of
	// characters may differ from the number of bytes in the string.
	MinLen *uint64 `protobuf:"varint,2,opt,name=min_len,json=minLen" json:"min_len"`
	// MaxLen specifies that this field must be the specified number of
	// characters (Unicode code points) at a maximum. Note that the number of
	// characters may differ from the number of bytes in the string.
	MaxLen *uint64 `protobuf:"varint,3,opt,name=max_len,json=maxLen" json:"max_len"`
	// LenBytes specifies that this field must be the specified number of bytes
	// at a minimum
	LenBytes *uint64 `protobuf:"varint,20,opt,name=len_bytes,json=lenBytes" json:"len_bytes"`
	// MinBytes specifies that this field must be the specified number of bytes
	// at a minimum
	MinBytes *uint64 `protobuf:"varint,4,opt,name=min_bytes,json=minBytes" json:"min_bytes"`
	// MaxBytes specifies that this field must be the specified number of bytes
	// at a maximum
	MaxBytes *uint64 `protobuf:"varint,5,opt,name=max_bytes,json=maxBytes" json:"max_bytes"`
	// Pattern specifes that this field must match against the specified
	// regular expression (RE2 syntax). The included expression should elide
	// any delimiters.
	Pattern *string `protobuf:"bytes,6,opt,name=pattern" json:"pattern"`
	// Prefix specifies that this field must have the specified substring at
	// the beginning of the string.
	Prefix *string `protobuf:"bytes,7,opt,name=prefix" json:"prefix"`
	// Suffix specifies that this field must have the specified substring at
	// the end of the string.
	Suffix *string `protobuf:"bytes,8,opt,name=suffix" json:"suffix"`
	// Contains specifies that this field must have the specified substring
	// anywhere in the string.
	Contains *string `protobuf:"bytes,9,opt,name=contains" json:"contains"`
	// NotContains specifies that this field cannot have the specified substring
	// anywhere in the string.
	NotContains *string `protobuf:"bytes,23,opt,name=not_contains,json=notContains" json:"not_contains"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []string `protobuf:"bytes,10,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []string `protobuf:"bytes,11,rep,name=not_in,json=notIn" json:"not_in"`
	// WellKnown rules provide advanced constraints against common string
	// patterns
	//
	// Types that are assignable to WellKnown:
	//
	//	*StringRules_Email
	//	*StringRules_Hostname
	//	*StringRules_Ip
	//	*StringRules_Ipv4
	//	*StringRules_Ipv6
	//	*StringRules_Uri
	//	*StringRules_UriRef
	//	*StringRules_Address
	//	*StringRules_Uuid
	//	*StringRules_WellKnownRegex
	WellKnown isStringRules_WellKnown `protobuf_oneof:"well_known"`
	// This applies to regexes HTTP_HEADER_NAME and HTTP_HEADER_VALUE to enable
	// strict header validation.
	// By default, this is true, and HTTP header validations are RFC-compliant.
	// Setting to false will enable a looser validations that only disallows
	// \r\n\0 characters, which can be used to bypass header matching rules.
	Strict *bool `protobuf:"varint,25,opt,name=strict,def=1" json:"strict"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,26,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

StringRules describe the constraints applied to `string` values

func (*StringRules) Descriptor deprecated

func (*StringRules) Descriptor() ([]byte, []int)

Deprecated: Use StringRules.ProtoReflect.Descriptor instead.

func (*StringRules) GetAddress

func (x *StringRules) GetAddress() bool

func (*StringRules) GetConst

func (x *StringRules) GetConst() string

func (*StringRules) GetContains

func (x *StringRules) GetContains() string

func (*StringRules) GetEmail

func (x *StringRules) GetEmail() bool

func (*StringRules) GetHostname

func (x *StringRules) GetHostname() bool

func (*StringRules) GetIgnoreEmpty

func (x *StringRules) GetIgnoreEmpty() bool

func (*StringRules) GetIn

func (x *StringRules) GetIn() []string

func (*StringRules) GetIp

func (x *StringRules) GetIp() bool

func (*StringRules) GetIpv4

func (x *StringRules) GetIpv4() bool

func (*StringRules) GetIpv6

func (x *StringRules) GetIpv6() bool

func (*StringRules) GetLen

func (x *StringRules) GetLen() uint64

func (*StringRules) GetLenBytes

func (x *StringRules) GetLenBytes() uint64

func (*StringRules) GetMaxBytes

func (x *StringRules) GetMaxBytes() uint64

func (*StringRules) GetMaxLen

func (x *StringRules) GetMaxLen() uint64

func (*StringRules) GetMinBytes

func (x *StringRules) GetMinBytes() uint64

func (*StringRules) GetMinLen

func (x *StringRules) GetMinLen() uint64

func (*StringRules) GetNotContains

func (x *StringRules) GetNotContains() string

func (*StringRules) GetNotIn

func (x *StringRules) GetNotIn() []string

func (*StringRules) GetPattern

func (x *StringRules) GetPattern() string

func (*StringRules) GetPrefix

func (x *StringRules) GetPrefix() string

func (*StringRules) GetStrict

func (x *StringRules) GetStrict() bool

func (*StringRules) GetSuffix

func (x *StringRules) GetSuffix() string

func (*StringRules) GetUri

func (x *StringRules) GetUri() bool

func (*StringRules) GetUriRef

func (x *StringRules) GetUriRef() bool

func (*StringRules) GetUuid

func (x *StringRules) GetUuid() bool

func (*StringRules) GetWellKnown

func (m *StringRules) GetWellKnown() isStringRules_WellKnown

func (*StringRules) GetWellKnownRegex

func (x *StringRules) GetWellKnownRegex() KnownRegex

func (*StringRules) ProtoMessage

func (*StringRules) ProtoMessage()

func (*StringRules) ProtoReflect

func (x *StringRules) ProtoReflect() protoreflect.Message

func (*StringRules) Reset

func (x *StringRules) Reset()

func (*StringRules) String

func (x *StringRules) String() string

func (*StringRules) Validate

func (m *StringRules) Validate() error

Validate checks the field values on StringRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*StringRules) ValidateAll

func (m *StringRules) ValidateAll() error

ValidateAll checks the field values on StringRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in StringRulesMultiError, or nil if none found.

type StringRulesMultiError

type StringRulesMultiError []error

StringRulesMultiError is an error wrapping multiple validation errors returned by StringRules.ValidateAll() if the designated constraints aren't met.

func (StringRulesMultiError) AllErrors

func (m StringRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (StringRulesMultiError) Error

func (m StringRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type StringRulesValidationError

type StringRulesValidationError struct {
	// contains filtered or unexported fields
}

StringRulesValidationError is the validation error returned by StringRules.Validate if the designated constraints aren't met.

func (StringRulesValidationError) Cause

Cause function returns cause value.

func (StringRulesValidationError) Error

Error satisfies the builtin error interface

func (StringRulesValidationError) ErrorName

func (e StringRulesValidationError) ErrorName() string

ErrorName returns error name.

func (StringRulesValidationError) Field

Field function returns field value.

func (StringRulesValidationError) Key

Key function returns key value.

func (StringRulesValidationError) Reason

Reason function returns reason value.

type StringRules_Address

type StringRules_Address struct {
	// Address specifies that the field must be either a valid hostname as
	// defined by RFC 1034 (which does not support internationalized domain
	// names or IDNs), or it can be a valid IP (v4 or v6).
	Address bool `protobuf:"varint,21,opt,name=address,oneof"`
}

type StringRules_Email

type StringRules_Email struct {
	// Email specifies that the field must be a valid email address as
	// defined by RFC 5322
	Email bool `protobuf:"varint,12,opt,name=email,oneof"`
}

type StringRules_Hostname

type StringRules_Hostname struct {
	// Hostname specifies that the field must be a valid hostname as
	// defined by RFC 1034. This constraint does not support
	// internationalized domain names (IDNs).
	Hostname bool `protobuf:"varint,13,opt,name=hostname,oneof"`
}

type StringRules_Ip

type StringRules_Ip struct {
	// Ip specifies that the field must be a valid IP (v4 or v6) address.
	// Valid IPv6 addresses should not include surrounding square brackets.
	Ip bool `protobuf:"varint,14,opt,name=ip,oneof"`
}

type StringRules_Ipv4

type StringRules_Ipv4 struct {
	// Ipv4 specifies that the field must be a valid IPv4 address.
	Ipv4 bool `protobuf:"varint,15,opt,name=ipv4,oneof"`
}

type StringRules_Ipv6

type StringRules_Ipv6 struct {
	// Ipv6 specifies that the field must be a valid IPv6 address. Valid
	// IPv6 addresses should not include surrounding square brackets.
	Ipv6 bool `protobuf:"varint,16,opt,name=ipv6,oneof"`
}

type StringRules_Uri

type StringRules_Uri struct {
	// Uri specifies that the field must be a valid, absolute URI as defined
	// by RFC 3986
	Uri bool `protobuf:"varint,17,opt,name=uri,oneof"`
}

type StringRules_UriRef

type StringRules_UriRef struct {
	// UriRef specifies that the field must be a valid URI as defined by RFC
	// 3986 and may be relative or absolute.
	UriRef bool `protobuf:"varint,18,opt,name=uri_ref,json=uriRef,oneof"`
}

type StringRules_Uuid

type StringRules_Uuid struct {
	// Uuid specifies that the field must be a valid UUID as defined by
	// RFC 4122
	Uuid bool `protobuf:"varint,22,opt,name=uuid,oneof"`
}

type StringRules_WellKnownRegex

type StringRules_WellKnownRegex struct {
	// WellKnownRegex specifies a common well known pattern defined as a regex.
	WellKnownRegex KnownRegex `protobuf:"varint,24,opt,name=well_known_regex,json=wellKnownRegex,enum=validate.KnownRegex,oneof"`
}

type TimestampRules

type TimestampRules struct {

	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,1,opt,name=required" json:"required"`
	// Const specifies that this field must be exactly the specified value
	Const *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than the specified value,
	// inclusive
	Lte *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive
	Gt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than the specified value,
	// inclusive
	Gte *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=gte" json:"gte"`
	// LtNow specifies that this must be less than the current time. LtNow
	// can only be used with the Within rule.
	LtNow *bool `protobuf:"varint,7,opt,name=lt_now,json=ltNow" json:"lt_now"`
	// GtNow specifies that this must be greater than the current time. GtNow
	// can only be used with the Within rule.
	GtNow *bool `protobuf:"varint,8,opt,name=gt_now,json=gtNow" json:"gt_now"`
	// Within specifies that this field must be within this duration of the
	// current time. This constraint can be used alone or with the LtNow and
	// GtNow rules.
	Within *durationpb.Duration `protobuf:"bytes,9,opt,name=within" json:"within"`
	// contains filtered or unexported fields
}

TimestampRules describe the constraints applied exclusively to the `google.protobuf.Timestamp` well-known type

func (*TimestampRules) Descriptor deprecated

func (*TimestampRules) Descriptor() ([]byte, []int)

Deprecated: Use TimestampRules.ProtoReflect.Descriptor instead.

func (*TimestampRules) GetConst

func (x *TimestampRules) GetConst() *timestamppb.Timestamp

func (*TimestampRules) GetGt

func (x *TimestampRules) GetGt() *timestamppb.Timestamp

func (*TimestampRules) GetGtNow

func (x *TimestampRules) GetGtNow() bool

func (*TimestampRules) GetGte

func (x *TimestampRules) GetGte() *timestamppb.Timestamp

func (*TimestampRules) GetLt

func (x *TimestampRules) GetLt() *timestamppb.Timestamp

func (*TimestampRules) GetLtNow

func (x *TimestampRules) GetLtNow() bool

func (*TimestampRules) GetLte

func (x *TimestampRules) GetLte() *timestamppb.Timestamp

func (*TimestampRules) GetRequired

func (x *TimestampRules) GetRequired() bool

func (*TimestampRules) GetWithin

func (x *TimestampRules) GetWithin() *durationpb.Duration

func (*TimestampRules) ProtoMessage

func (*TimestampRules) ProtoMessage()

func (*TimestampRules) ProtoReflect

func (x *TimestampRules) ProtoReflect() protoreflect.Message

func (*TimestampRules) Reset

func (x *TimestampRules) Reset()

func (*TimestampRules) String

func (x *TimestampRules) String() string

func (*TimestampRules) Validate

func (m *TimestampRules) Validate() error

Validate checks the field values on TimestampRules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*TimestampRules) ValidateAll

func (m *TimestampRules) ValidateAll() error

ValidateAll checks the field values on TimestampRules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TimestampRulesMultiError, or nil if none found.

type TimestampRulesMultiError

type TimestampRulesMultiError []error

TimestampRulesMultiError is an error wrapping multiple validation errors returned by TimestampRules.ValidateAll() if the designated constraints aren't met.

func (TimestampRulesMultiError) AllErrors

func (m TimestampRulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (TimestampRulesMultiError) Error

func (m TimestampRulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type TimestampRulesValidationError

type TimestampRulesValidationError struct {
	// contains filtered or unexported fields
}

TimestampRulesValidationError is the validation error returned by TimestampRules.Validate if the designated constraints aren't met.

func (TimestampRulesValidationError) Cause

Cause function returns cause value.

func (TimestampRulesValidationError) Error

Error satisfies the builtin error interface

func (TimestampRulesValidationError) ErrorName

func (e TimestampRulesValidationError) ErrorName() string

ErrorName returns error name.

func (TimestampRulesValidationError) Field

Field function returns field value.

func (TimestampRulesValidationError) Key

Key function returns key value.

func (TimestampRulesValidationError) Reason

Reason function returns reason value.

type UInt32Rules

type UInt32Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *uint32 `protobuf:"varint,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint32 `protobuf:"varint,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *uint32 `protobuf:"varint,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *uint32 `protobuf:"varint,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *uint32 `protobuf:"varint,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint32 `protobuf:"varint,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []uint32 `protobuf:"varint,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

UInt32Rules describes the constraints applied to `uint32` values

func (*UInt32Rules) Descriptor deprecated

func (*UInt32Rules) Descriptor() ([]byte, []int)

Deprecated: Use UInt32Rules.ProtoReflect.Descriptor instead.

func (*UInt32Rules) GetConst

func (x *UInt32Rules) GetConst() uint32

func (*UInt32Rules) GetGt

func (x *UInt32Rules) GetGt() uint32

func (*UInt32Rules) GetGte

func (x *UInt32Rules) GetGte() uint32

func (*UInt32Rules) GetIgnoreEmpty

func (x *UInt32Rules) GetIgnoreEmpty() bool

func (*UInt32Rules) GetIn

func (x *UInt32Rules) GetIn() []uint32

func (*UInt32Rules) GetLt

func (x *UInt32Rules) GetLt() uint32

func (*UInt32Rules) GetLte

func (x *UInt32Rules) GetLte() uint32

func (*UInt32Rules) GetNotIn

func (x *UInt32Rules) GetNotIn() []uint32

func (*UInt32Rules) ProtoMessage

func (*UInt32Rules) ProtoMessage()

func (*UInt32Rules) ProtoReflect

func (x *UInt32Rules) ProtoReflect() protoreflect.Message

func (*UInt32Rules) Reset

func (x *UInt32Rules) Reset()

func (*UInt32Rules) String

func (x *UInt32Rules) String() string

func (*UInt32Rules) Validate

func (m *UInt32Rules) Validate() error

Validate checks the field values on UInt32Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UInt32Rules) ValidateAll

func (m *UInt32Rules) ValidateAll() error

ValidateAll checks the field values on UInt32Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UInt32RulesMultiError, or nil if none found.

type UInt32RulesMultiError

type UInt32RulesMultiError []error

UInt32RulesMultiError is an error wrapping multiple validation errors returned by UInt32Rules.ValidateAll() if the designated constraints aren't met.

func (UInt32RulesMultiError) AllErrors

func (m UInt32RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UInt32RulesMultiError) Error

func (m UInt32RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type UInt32RulesValidationError

type UInt32RulesValidationError struct {
	// contains filtered or unexported fields
}

UInt32RulesValidationError is the validation error returned by UInt32Rules.Validate if the designated constraints aren't met.

func (UInt32RulesValidationError) Cause

Cause function returns cause value.

func (UInt32RulesValidationError) Error

Error satisfies the builtin error interface

func (UInt32RulesValidationError) ErrorName

func (e UInt32RulesValidationError) ErrorName() string

ErrorName returns error name.

func (UInt32RulesValidationError) Field

Field function returns field value.

func (UInt32RulesValidationError) Key

Key function returns key value.

func (UInt32RulesValidationError) Reason

Reason function returns reason value.

type UInt64Rules

type UInt64Rules struct {

	// Const specifies that this field must be exactly the specified value
	Const *uint64 `protobuf:"varint,1,opt,name=const" json:"const"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint64 `protobuf:"varint,2,opt,name=lt" json:"lt"`
	// Lte specifies that this field must be less than or equal to the
	// specified value, inclusive
	Lte *uint64 `protobuf:"varint,3,opt,name=lte" json:"lte"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive. If the value of Gt is larger than a specified Lt or Lte, the
	// range is reversed.
	Gt *uint64 `protobuf:"varint,4,opt,name=gt" json:"gt"`
	// Gte specifies that this field must be greater than or equal to the
	// specified value, inclusive. If the value of Gte is larger than a
	// specified Lt or Lte, the range is reversed.
	Gte *uint64 `protobuf:"varint,5,opt,name=gte" json:"gte"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint64 `protobuf:"varint,6,rep,name=in" json:"in"`
	// NotIn specifies that this field cannot be equal to one of the specified
	// values
	NotIn []uint64 `protobuf:"varint,7,rep,name=not_in,json=notIn" json:"not_in"`
	// IgnoreEmpty specifies that the validation rules of this field should be
	// evaluated only if the field is not empty
	IgnoreEmpty *bool `protobuf:"varint,8,opt,name=ignore_empty,json=ignoreEmpty" json:"ignore_empty"`
	// contains filtered or unexported fields
}

UInt64Rules describes the constraints applied to `uint64` values

func (*UInt64Rules) Descriptor deprecated

func (*UInt64Rules) Descriptor() ([]byte, []int)

Deprecated: Use UInt64Rules.ProtoReflect.Descriptor instead.

func (*UInt64Rules) GetConst

func (x *UInt64Rules) GetConst() uint64

func (*UInt64Rules) GetGt

func (x *UInt64Rules) GetGt() uint64

func (*UInt64Rules) GetGte

func (x *UInt64Rules) GetGte() uint64

func (*UInt64Rules) GetIgnoreEmpty

func (x *UInt64Rules) GetIgnoreEmpty() bool

func (*UInt64Rules) GetIn

func (x *UInt64Rules) GetIn() []uint64

func (*UInt64Rules) GetLt

func (x *UInt64Rules) GetLt() uint64

func (*UInt64Rules) GetLte

func (x *UInt64Rules) GetLte() uint64

func (*UInt64Rules) GetNotIn

func (x *UInt64Rules) GetNotIn() []uint64

func (*UInt64Rules) ProtoMessage

func (*UInt64Rules) ProtoMessage()

func (*UInt64Rules) ProtoReflect

func (x *UInt64Rules) ProtoReflect() protoreflect.Message

func (*UInt64Rules) Reset

func (x *UInt64Rules) Reset()

func (*UInt64Rules) String

func (x *UInt64Rules) String() string

func (*UInt64Rules) Validate

func (m *UInt64Rules) Validate() error

Validate checks the field values on UInt64Rules with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*UInt64Rules) ValidateAll

func (m *UInt64Rules) ValidateAll() error

ValidateAll checks the field values on UInt64Rules with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in UInt64RulesMultiError, or nil if none found.

type UInt64RulesMultiError

type UInt64RulesMultiError []error

UInt64RulesMultiError is an error wrapping multiple validation errors returned by UInt64Rules.ValidateAll() if the designated constraints aren't met.

func (UInt64RulesMultiError) AllErrors

func (m UInt64RulesMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (UInt64RulesMultiError) Error

func (m UInt64RulesMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type UInt64RulesValidationError

type UInt64RulesValidationError struct {
	// contains filtered or unexported fields
}

UInt64RulesValidationError is the validation error returned by UInt64Rules.Validate if the designated constraints aren't met.

func (UInt64RulesValidationError) Cause

Cause function returns cause value.

func (UInt64RulesValidationError) Error

Error satisfies the builtin error interface

func (UInt64RulesValidationError) ErrorName

func (e UInt64RulesValidationError) ErrorName() string

ErrorName returns error name.

func (UInt64RulesValidationError) Field

Field function returns field value.

func (UInt64RulesValidationError) Key

Key function returns key value.

func (UInt64RulesValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

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