validate

package
v1.1.3 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2023 License: MIT Imports: 7 Imported by: 2

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_proto_extTypes[0]
	// Ignore skips generation of validation methods for this message.
	//
	// optional bool ignored = 1072;
	E_Ignored = &file_validate_proto_extTypes[1]
)

Extension fields to descriptorpb.MessageOptions.

View Source
var (
	// Rules specify the validations to be performed on this field. By default,
	// no validation is performed against a field.
	//
	// optional appootb.validate.FieldRules rules = 1071;
	E_Rules = &file_validate_proto_extTypes[3]
	// Error is the custom failure message returned to client. By default,
	// internal validation message is used.
	//
	// optional string error = 1072;
	E_Error = &file_validate_proto_extTypes[4]
)

Extension fields to descriptorpb.FieldOptions.

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_proto_extTypes[2]
)

Extension fields to descriptorpb.OneofOptions.

View Source
var File_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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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 added in v1.0.2

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

func (*AnyRules) Reset

func (x *AnyRules) Reset()

func (*AnyRules) String

func (x *AnyRules) String() string

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,omitempty"`
	// 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 added in v1.0.2

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

func (*BoolRules) Reset

func (x *BoolRules) Reset()

func (*BoolRules) String

func (x *BoolRules) String() string

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,omitempty"`
	// Len specifies that this field must be the specified number of bytes
	Len *uint64 `protobuf:"varint,13,opt,name=len" json:"len,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// Pattern specifies 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// Contains specifies that this field must have the specified bytes
	// anywhere in the string.
	Contains []byte `protobuf:"bytes,7,opt,name=contains" json:"contains,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In [][]byte `protobuf:"bytes,8,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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"`
	// 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) 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 added in v1.0.2

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

func (*BytesRules) Reset

func (x *BytesRules) Reset()

func (*BytesRules) String

func (x *BytesRules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *float64 `protobuf:"fixed64,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []float64 `protobuf:"fixed64,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*DoubleRules) Reset

func (x *DoubleRules) Reset()

func (*DoubleRules) String

func (x *DoubleRules) String() string

type DurationRules

type DurationRules struct {

	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,1,opt,name=required" json:"required,omitempty"`
	// Const specifies that this field must be exactly the specified value
	Const *durationpb.Duration `protobuf:"bytes,2,opt,name=const" json:"const,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *durationpb.Duration `protobuf:"bytes,3,opt,name=lt" json:"lt,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// inclusive
	Lte *durationpb.Duration `protobuf:"bytes,4,opt,name=lte" json:"lte,omitempty"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive
	Gt *durationpb.Duration `protobuf:"bytes,5,opt,name=gt" json:"gt,omitempty"`
	// Gte specifies that this field must be greater than the specified value,
	// inclusive
	Gte *durationpb.Duration `protobuf:"bytes,6,opt,name=gte" json:"gte,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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 added in v1.0.2

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

func (*DurationRules) Reset

func (x *DurationRules) Reset()

func (*DurationRules) String

func (x *DurationRules) String() string

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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"varint,3,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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 added in v1.0.2

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

func (*EnumRules) Reset

func (x *EnumRules) Reset()

func (*EnumRules) String

func (x *EnumRules) String() string

type FieldRules

type FieldRules struct {
	Message *MessageRules `protobuf:"bytes,17,opt,name=message" json:"message,omitempty"`
	// 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 added in v1.0.2

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

func (*FieldRules) Reset

func (x *FieldRules) Reset()

func (*FieldRules) String

func (x *FieldRules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint32 `protobuf:"fixed32,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint32 `protobuf:"fixed32,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*Fixed32Rules) Reset

func (x *Fixed32Rules) Reset()

func (*Fixed32Rules) String

func (x *Fixed32Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint64 `protobuf:"fixed64,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint64 `protobuf:"fixed64,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*Fixed64Rules) Reset

func (x *Fixed64Rules) Reset()

func (*Fixed64Rules) String

func (x *Fixed64Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *float32 `protobuf:"fixed32,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []float32 `protobuf:"fixed32,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*FloatRules) Reset

func (x *FloatRules) Reset()

func (*FloatRules) String

func (x *FloatRules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"varint,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"varint,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*Int32Rules) Reset

func (x *Int32Rules) Reset()

func (*Int32Rules) String

func (x *Int32Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"varint,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"varint,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*Int64Rules) Reset

func (x *Int64Rules) Reset()

func (*Int64Rules) String

func (x *Int64Rules) String() string

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 added in v1.0.2

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 added in v1.0.2

func (x KnownRegex) Number() protoreflect.EnumNumber

func (KnownRegex) String

func (x KnownRegex) String() string

func (KnownRegex) Type added in v1.0.2

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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// Keys specifies the constraints to be applied to each key in the field.
	Keys *FieldRules `protobuf:"bytes,4,opt,name=keys" json:"keys,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*MapRules) Reset

func (x *MapRules) Reset()

func (*MapRules) String

func (x *MapRules) String() string

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,omitempty"`
	// Required specifies that this field must be set
	Required *bool `protobuf:"varint,2,opt,name=required" json:"required,omitempty"`
	// 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 added in v1.0.2

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

func (*MessageRules) Reset

func (x *MessageRules) Reset()

func (*MessageRules) String

func (x *MessageRules) String() string

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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*RepeatedRules) Reset

func (x *RepeatedRules) Reset()

func (*RepeatedRules) String

func (x *RepeatedRules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"fixed32,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"fixed32,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*SFixed32Rules) Reset

func (x *SFixed32Rules) Reset()

func (*SFixed32Rules) String

func (x *SFixed32Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"fixed64,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"fixed64,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*SFixed64Rules) Reset

func (x *SFixed64Rules) Reset()

func (*SFixed64Rules) String

func (x *SFixed64Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int32 `protobuf:"zigzag32,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int32 `protobuf:"zigzag32,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*SInt32Rules) Reset

func (x *SInt32Rules) Reset()

func (*SInt32Rules) String

func (x *SInt32Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *int64 `protobuf:"zigzag64,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []int64 `protobuf:"zigzag64,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*SInt64Rules) Reset

func (x *SInt64Rules) Reset()

func (*SInt64Rules) String

func (x *SInt64Rules) String() string

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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// Contains specifies that this field must have the specified substring
	// anywhere in the string.
	Contains *string `protobuf:"bytes,9,opt,name=contains" json:"contains,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []string `protobuf:"bytes,10,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*StringRules) Reset

func (x *StringRules) Reset()

func (*StringRules) String

func (x *StringRules) String() string

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=appootb.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,omitempty"`
	// Const specifies that this field must be exactly the specified value
	Const *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=const" json:"const,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=lt" json:"lt,omitempty"`
	// Lte specifies that this field must be less than the specified value,
	// inclusive
	Lte *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=lte" json:"lte,omitempty"`
	// Gt specifies that this field must be greater than the specified value,
	// exclusive
	Gt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=gt" json:"gt,omitempty"`
	// Gte specifies that this field must be greater than the specified value,
	// inclusive
	Gte *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=gte" json:"gte,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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 added in v1.0.2

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

func (*TimestampRules) Reset

func (x *TimestampRules) Reset()

func (*TimestampRules) String

func (x *TimestampRules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint32 `protobuf:"varint,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint32 `protobuf:"varint,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*UInt32Rules) Reset

func (x *UInt32Rules) Reset()

func (*UInt32Rules) String

func (x *UInt32Rules) String() string

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,omitempty"`
	// Lt specifies that this field must be less than the specified value,
	// exclusive
	Lt *uint64 `protobuf:"varint,2,opt,name=lt" json:"lt,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// 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,omitempty"`
	// In specifies that this field must be equal to one of the specified
	// values
	In []uint64 `protobuf:"varint,6,rep,name=in" json:"in,omitempty"`
	// 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,omitempty"`
	// 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) 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 added in v1.0.2

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

func (*UInt64Rules) Reset

func (x *UInt64Rules) Reset()

func (*UInt64Rules) String

func (x *UInt64Rules) String() string

Jump to

Keyboard shortcuts

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