diff --git a/Makefile b/Makefile index f1e8565b..38b3d7bc 100644 --- a/Makefile +++ b/Makefile @@ -18,7 +18,7 @@ GOLANGCI_LINT_VERSION ?= v2.4.0 # Set to use a different version of protovalidate-conformance. # Should be kept in sync with the version referenced in buf.yaml and # 'buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go' in go.mod. -CONFORMANCE_VERSION ?= v1.0.0 +CONFORMANCE_VERSION ?= v1.1.0 .PHONY: help help: ## Describe useful make targets diff --git a/ast.go b/ast.go index e22b2f3b..76f22b0d 100644 --- a/ast.go +++ b/ast.go @@ -19,7 +19,6 @@ import ( "slices" "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" - pvcel "buf.build/go/protovalidate/cel" "github.com/google/cel-go/cel" "google.golang.org/protobuf/reflect/protoreflect" ) @@ -90,6 +89,7 @@ func (set astSet) ReduceResiduals(rules protoreflect.Message, opts ...cel.Progra residuals = append(residuals, compiledAST{ AST: residual, Env: ast.Env, + Rules: ast.Rules, Source: ast.Source, Path: ast.Path, Value: ast.Value, @@ -116,23 +116,15 @@ func (set astSet) ToProgramSet(opts ...cel.ProgramOption) (out programSet, err e return out, nil } -// SetRuleValue sets the rule value for the programs in the ASTSet. -func (set astSet) WithRuleValue( +// SetRuleValue sets the rule and rules value for the programs in the ASTSet. +func (set astSet) WithRuleValues( + rules protoreflect.Message, ruleValue protoreflect.Value, ruleDescriptor protoreflect.FieldDescriptor, ) (out astSet, err error) { out = slices.Clone(set) for i := range set { - out[i].Env, err = out[i].Env.Extend( - cel.Constant( - "rule", - pvcel.ProtoFieldToType(ruleDescriptor, true, false), - pvcel.ProtoFieldToValue(ruleDescriptor, ruleValue, false), - ), - ) - if err != nil { - return nil, err - } + out[i].Rules = rules out[i].Value = ruleValue out[i].Descriptor = ruleDescriptor } @@ -142,6 +134,7 @@ func (set astSet) WithRuleValue( type compiledAST struct { AST *cel.Ast Env *cel.Env + Rules protoreflect.Message Source *validate.Rule Path []*validate.FieldPathElement Value protoreflect.Value @@ -155,6 +148,7 @@ func (ast compiledAST) toProgram(env *cel.Env, opts ...cel.ProgramOption) (out c } return compiledProgram{ Program: prog, + Rules: ast.Rules, Source: ast.Source, Path: ast.Path, Value: ast.Value, diff --git a/buf.lock b/buf.lock index 0a534951..9c3bbf60 100644 --- a/buf.lock +++ b/buf.lock @@ -2,8 +2,8 @@ version: v2 deps: - name: buf.build/bufbuild/protovalidate - commit: 52f32327d4b045a79293a6ad4e7e1236 - digest: b5:cbabc98d4b7b7b0447c9b15f68eeb8a7a44ef8516cb386ac5f66e7fd4062cd6723ed3f452ad8c384b851f79e33d26e7f8a94e2b807282b3def1cd966c7eace97 + commit: 2a1774d888024a9b93ce7eb4b59f6a83 + digest: b5:6b7f9bc919b65e5b79d7b726ffc03d6f815a412d6b792970fa6f065cae162107bd0a9d47272c8ab1a2c9514e87b13d3fbf71df614374d62d2183afb64be2d30a - name: buf.build/rodaine/protogofakeit commit: 9caf0fc578d3413590962a1764b81b94 digest: b5:eeead7373f2f598ebc8f91aa3a68d6b50630076341d875b22dc6760126bc56c82cf1e98f5a2eff9815ba55fa48ab81745c93a5aeefd5e4697bf43c9ea4694735 diff --git a/buf.yaml b/buf.yaml index defc5fd9..6a0e842a 100644 --- a/buf.yaml +++ b/buf.yaml @@ -2,7 +2,7 @@ version: v2 modules: - path: proto deps: - - buf.build/bufbuild/protovalidate:v1.0.0 + - buf.build/bufbuild/protovalidate:v1.1.0 - buf.build/rodaine/protogofakeit lint: use: diff --git a/builder.go b/builder.go index f843f488..25d909b8 100644 --- a/builder.go +++ b/builder.go @@ -32,8 +32,10 @@ import ( //nolint:gochecknoglobals var ( - celRuleDescriptor = (&validate.FieldRules{}).ProtoReflect().Descriptor().Fields().ByName("cel") - celRuleField = fieldPathElement(celRuleDescriptor) + celExpressionDescriptor = (&validate.FieldRules{}).ProtoReflect().Descriptor().Fields().ByName("cel_expression") + celExpressionField = fieldPathElement(celExpressionDescriptor) + celRuleDescriptor = (&validate.FieldRules{}).ProtoReflect().Descriptor().Fields().ByName("cel") + celRuleField = fieldPathElement(celRuleDescriptor) ) // builder is a build-through cache of message evaluators keyed off the provided @@ -149,7 +151,7 @@ func (bldr *builder) processMessageExpressions( _ messageCache, ) { exprs := expressions{ - Rules: msgRules.GetCel(), + Rules: append(expressionsToRules(msgRules.GetCelExpression()), msgRules.GetCel()...), } compiledExprs, err := compile( exprs, @@ -323,30 +325,50 @@ func (bldr *builder) processFieldExpressions( eval *value, _ messageCache, ) error { - exprs := expressions{ - Rules: fieldRules.GetCel(), - } - celTyp := pvcel.ProtoFieldToType(fieldDesc, false, eval.NestedRule != nil) opts := append( pvcel.RequiredEnvOptions(fieldDesc), cel.Variable("this", celTyp), ) - compiledExpressions, err := compile(exprs, bldr.env, opts...) + compileWithPath := func(exprs expressions, fieldPathElement *validate.FieldPathElement, descriptor protoreflect.FieldDescriptor) (programSet, error) { + compiledExpressions, err := compile(exprs, bldr.env, opts...) + if err != nil { + return nil, err + } + for i := range compiledExpressions { + compiledExpressions[i].Path = []*validate.FieldPathElement{ + validate.FieldPathElement_builder{ + FieldNumber: proto.Int32(fieldPathElement.GetFieldNumber()), + FieldType: fieldPathElement.GetFieldType().Enum(), + FieldName: proto.String(fieldPathElement.GetFieldName()), + Index: proto.Uint64(uint64(i)), //nolint:gosec // indices are guaranteed to be non-negative + }.Build(), + } + compiledExpressions[i].Descriptor = descriptor + } + return compiledExpressions, nil + } + compiledExpressions, err := compileWithPath( + expressions{ + Rules: expressionsToRules(fieldRules.GetCelExpression()), + }, + celExpressionField, + celExpressionDescriptor, + ) if err != nil { return err } - for i := range compiledExpressions { - compiledExpressions[i].Path = []*validate.FieldPathElement{ - validate.FieldPathElement_builder{ - FieldNumber: proto.Int32(celRuleField.GetFieldNumber()), - FieldType: celRuleField.GetFieldType().Enum(), - FieldName: proto.String(celRuleField.GetFieldName()), - Index: proto.Uint64(uint64(i)), //nolint:gosec // indices are guaranteed to be non-negative - }.Build(), - } - compiledExpressions[i].Descriptor = celRuleDescriptor + celRuleCompiledExpressions, err := compileWithPath( + expressions{ + Rules: fieldRules.GetCel(), + }, + celRuleField, + celRuleDescriptor, + ) + if err != nil { + return err } + compiledExpressions = append(compiledExpressions, celRuleCompiledExpressions...) if len(compiledExpressions) > 0 { eval.Rules = append(eval.Rules, celPrograms{ @@ -613,3 +635,14 @@ func isPartOfMessageOneof(msgRules *validate.MessageRules, field protoreflect.Fi return slices.Contains(oneof.GetFields(), string(field.Name())) }) } + +func expressionsToRules(expressions []string) []*validate.Rule { + rules := make([]*validate.Rule, 0, len(expressions)) + for _, expr := range expressions { + rules = append(rules, validate.Rule_builder{ + Id: proto.String(expr), + Expression: proto.String(expr), + }.Build()) + } + return rules +} diff --git a/cache.go b/cache.go index eb37174b..d15754cd 100644 --- a/cache.go +++ b/cache.go @@ -88,7 +88,7 @@ func (c *cache) Build( return false } } - precomputedASTs, compileErr = precomputedASTs.WithRuleValue(rule, desc) + precomputedASTs, compileErr = precomputedASTs.WithRuleValues(rules, rule, desc) if compileErr != nil { err = compileErr return false diff --git a/cache_test.go b/cache_test.go index dfd39eab..04e6ab34 100644 --- a/cache_test.go +++ b/cache_test.go @@ -183,6 +183,10 @@ func TestCache_GetExpectedRuleDescriptor(t *testing.T) { desc: getFieldDesc(t, &cases.DurationNone{}, "val"), ex: expectedWKTRules["google.protobuf.Duration"], }, + { + desc: getFieldDesc(t, &cases.FieldMaskNone{}, "val"), + ex: expectedWKTRules["google.protobuf.FieldMask"], + }, { desc: getFieldDesc(t, &cases.StringNone{}, "val"), ex: expectedStandardRules[protoreflect.StringKind], diff --git a/go.mod b/go.mod index d72aa323..6f662dfa 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module buf.build/go/protovalidate go 1.24.0 require ( - buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20250912141014-52f32327d4b0.1 + buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20251209175733-2a1774d88802.1 buf.build/go/hyperpb v0.1.3 github.com/brianvoe/gofakeit/v6 v6.28.0 github.com/google/cel-go v0.26.1 diff --git a/go.sum b/go.sum index 717adca6..bf9d1ad0 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ buf.build/gen/go/bufbuild/hyperpb-examples/protocolbuffers/go v1.36.7-20250725192734-0dd56aa9cbbc.1 h1:bFnppdLYActzr2F0iomSrkjUnGgVufb0DtZxjKgTLGc= buf.build/gen/go/bufbuild/hyperpb-examples/protocolbuffers/go v1.36.7-20250725192734-0dd56aa9cbbc.1/go.mod h1:x7jYNX5/7EPnsKHEq596krkOGzvR97/MsZw2fw3Mrq0= -buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20250912141014-52f32327d4b0.1 h1:31on4W/yPcV4nZHL4+UCiCvLPsMqe/vJcNg8Rci0scc= -buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20250912141014-52f32327d4b0.1/go.mod h1:fUl8CEN/6ZAMk6bP8ahBJPUJw7rbp+j4x+wCcYi2IG4= +buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20251209175733-2a1774d88802.1 h1:ZnX3qpF/pDiYrf+Q3p+/zCzZ5ELSpszy5hdVarDMSV4= +buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go v1.36.10-20251209175733-2a1774d88802.1/go.mod h1:fUl8CEN/6ZAMk6bP8ahBJPUJw7rbp+j4x+wCcYi2IG4= buf.build/go/hyperpb v0.1.3 h1:wiw2F7POvAe2VA2kkB0TAsFwj91lXbFrKM41D3ZgU1w= buf.build/go/hyperpb v0.1.3/go.mod h1:IHXAM5qnS0/Fsnd7/HGDghFNvUET646WoHmq1FDZXIE= cel.dev/expr v0.24.0 h1:56OvJKSH3hDGL0ml5uSxZmz3/3Pq4tJ+fb1unVLAFcY= diff --git a/internal/gen/buf/validate/conformance/cases/bytes.pb.go b/internal/gen/buf/validate/conformance/cases/bytes.pb.go index f2de1271..51c32b67 100644 --- a/internal/gen/buf/validate/conformance/cases/bytes.pb.go +++ b/internal/gen/buf/validate/conformance/cases/bytes.pb.go @@ -1237,6 +1237,186 @@ func (b0 BytesIPv6Ignore_builder) Build() *BytesIPv6Ignore { return m0 } +type BytesUUID struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val []byte `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesUUID) Reset() { + *x = BytesUUID{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesUUID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesUUID) ProtoMessage() {} + +func (x *BytesUUID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesUUID) GetVal() []byte { + if x != nil { + return x.Val + } + return nil +} + +func (x *BytesUUID) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.Val = v +} + +type BytesUUID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesUUID_builder) Build() *BytesUUID { + m0 := &BytesUUID{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type BytesNotUUID struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val []byte `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesNotUUID) Reset() { + *x = BytesNotUUID{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesNotUUID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesNotUUID) ProtoMessage() {} + +func (x *BytesNotUUID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[21] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesNotUUID) GetVal() []byte { + if x != nil { + return x.Val + } + return nil +} + +func (x *BytesNotUUID) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.Val = v +} + +type BytesNotUUID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesNotUUID_builder) Build() *BytesNotUUID { + m0 := &BytesNotUUID{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type BytesUUIDIgnore struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val []byte `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesUUIDIgnore) Reset() { + *x = BytesUUIDIgnore{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesUUIDIgnore) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesUUIDIgnore) ProtoMessage() {} + +func (x *BytesUUIDIgnore) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[22] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesUUIDIgnore) GetVal() []byte { + if x != nil { + return x.Val + } + return nil +} + +func (x *BytesUUIDIgnore) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.Val = v +} + +type BytesUUIDIgnore_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesUUIDIgnore_builder) Build() *BytesUUIDIgnore { + m0 := &BytesUUIDIgnore{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + type BytesExample struct { state protoimpl.MessageState `protogen:"hybrid.v1"` Val []byte `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` @@ -1246,7 +1426,7 @@ type BytesExample struct { func (x *BytesExample) Reset() { *x = BytesExample{} - mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1258,7 +1438,7 @@ func (x *BytesExample) String() string { func (*BytesExample) ProtoMessage() {} func (x *BytesExample) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1349,13 +1529,20 @@ const file_buf_validate_conformance_cases_bytes_proto_rawDesc = "" + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02`\x00R\x03val\"/\n" + "\x0fBytesIPv6Ignore\x12\x1c\n" + "\x03val\x18\x01 \x01(\fB\n" + - "\xbaH\a\xd8\x01\x01z\x02`\x01R\x03val\"*\n" + + "\xbaH\a\xd8\x01\x01z\x02`\x01R\x03val\"&\n" + + "\tBytesUUID\x12\x19\n" + + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02x\x01R\x03val\")\n" + + "\fBytesNotUUID\x12\x19\n" + + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02x\x00R\x03val\"/\n" + + "\x0fBytesUUIDIgnore\x12\x1c\n" + + "\x03val\x18\x01 \x01(\fB\n" + + "\xbaH\a\xd8\x01\x01z\x02x\x01R\x03val\"*\n" + "\fBytesExample\x12\x1a\n" + "\x03val\x18\x01 \x01(\fB\b\xbaH\x05z\x03r\x01\x99R\x03valB\x94\x02\n" + "\"com.buf.validate.conformance.casesB\n" + "BytesProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_bytes_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_buf_validate_conformance_cases_bytes_proto_msgTypes = make([]protoimpl.MessageInfo, 24) var file_buf_validate_conformance_cases_bytes_proto_goTypes = []any{ (*BytesNone)(nil), // 0: buf.validate.conformance.cases.BytesNone (*BytesConst)(nil), // 1: buf.validate.conformance.cases.BytesConst @@ -1377,7 +1564,10 @@ var file_buf_validate_conformance_cases_bytes_proto_goTypes = []any{ (*BytesIPv6)(nil), // 17: buf.validate.conformance.cases.BytesIPv6 (*BytesNotIPv6)(nil), // 18: buf.validate.conformance.cases.BytesNotIPv6 (*BytesIPv6Ignore)(nil), // 19: buf.validate.conformance.cases.BytesIPv6Ignore - (*BytesExample)(nil), // 20: buf.validate.conformance.cases.BytesExample + (*BytesUUID)(nil), // 20: buf.validate.conformance.cases.BytesUUID + (*BytesNotUUID)(nil), // 21: buf.validate.conformance.cases.BytesNotUUID + (*BytesUUIDIgnore)(nil), // 22: buf.validate.conformance.cases.BytesUUIDIgnore + (*BytesExample)(nil), // 23: buf.validate.conformance.cases.BytesExample } var file_buf_validate_conformance_cases_bytes_proto_depIdxs = []int32{ 0, // [0:0] is the sub-list for method output_type @@ -1398,7 +1588,7 @@ func file_buf_validate_conformance_cases_bytes_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_bytes_proto_rawDesc), len(file_buf_validate_conformance_cases_bytes_proto_rawDesc)), NumEnums: 0, - NumMessages: 21, + NumMessages: 24, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/bytes_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/bytes_protoopaque.pb.go index 4101292b..d9982569 100644 --- a/internal/gen/buf/validate/conformance/cases/bytes_protoopaque.pb.go +++ b/internal/gen/buf/validate/conformance/cases/bytes_protoopaque.pb.go @@ -1237,6 +1237,186 @@ func (b0 BytesIPv6Ignore_builder) Build() *BytesIPv6Ignore { return m0 } +type BytesUUID struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val []byte `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesUUID) Reset() { + *x = BytesUUID{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesUUID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesUUID) ProtoMessage() {} + +func (x *BytesUUID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesUUID) GetVal() []byte { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *BytesUUID) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.xxx_hidden_Val = v +} + +type BytesUUID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesUUID_builder) Build() *BytesUUID { + m0 := &BytesUUID{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type BytesNotUUID struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val []byte `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesNotUUID) Reset() { + *x = BytesNotUUID{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesNotUUID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesNotUUID) ProtoMessage() {} + +func (x *BytesNotUUID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[21] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesNotUUID) GetVal() []byte { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *BytesNotUUID) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.xxx_hidden_Val = v +} + +type BytesNotUUID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesNotUUID_builder) Build() *BytesNotUUID { + m0 := &BytesNotUUID{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type BytesUUIDIgnore struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val []byte `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *BytesUUIDIgnore) Reset() { + *x = BytesUUIDIgnore{} + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *BytesUUIDIgnore) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*BytesUUIDIgnore) ProtoMessage() {} + +func (x *BytesUUIDIgnore) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[22] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *BytesUUIDIgnore) GetVal() []byte { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *BytesUUIDIgnore) SetVal(v []byte) { + if v == nil { + v = []byte{} + } + x.xxx_hidden_Val = v +} + +type BytesUUIDIgnore_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []byte +} + +func (b0 BytesUUIDIgnore_builder) Build() *BytesUUIDIgnore { + m0 := &BytesUUIDIgnore{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + type BytesExample struct { state protoimpl.MessageState `protogen:"opaque.v1"` xxx_hidden_Val []byte `protobuf:"bytes,1,opt,name=val,proto3"` @@ -1246,7 +1426,7 @@ type BytesExample struct { func (x *BytesExample) Reset() { *x = BytesExample{} - mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1258,7 +1438,7 @@ func (x *BytesExample) String() string { func (*BytesExample) ProtoMessage() {} func (x *BytesExample) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_bytes_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1349,13 +1529,20 @@ const file_buf_validate_conformance_cases_bytes_proto_rawDesc = "" + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02`\x00R\x03val\"/\n" + "\x0fBytesIPv6Ignore\x12\x1c\n" + "\x03val\x18\x01 \x01(\fB\n" + - "\xbaH\a\xd8\x01\x01z\x02`\x01R\x03val\"*\n" + + "\xbaH\a\xd8\x01\x01z\x02`\x01R\x03val\"&\n" + + "\tBytesUUID\x12\x19\n" + + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02x\x01R\x03val\")\n" + + "\fBytesNotUUID\x12\x19\n" + + "\x03val\x18\x01 \x01(\fB\a\xbaH\x04z\x02x\x00R\x03val\"/\n" + + "\x0fBytesUUIDIgnore\x12\x1c\n" + + "\x03val\x18\x01 \x01(\fB\n" + + "\xbaH\a\xd8\x01\x01z\x02x\x01R\x03val\"*\n" + "\fBytesExample\x12\x1a\n" + "\x03val\x18\x01 \x01(\fB\b\xbaH\x05z\x03r\x01\x99R\x03valB\x94\x02\n" + "\"com.buf.validate.conformance.casesB\n" + "BytesProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_bytes_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_buf_validate_conformance_cases_bytes_proto_msgTypes = make([]protoimpl.MessageInfo, 24) var file_buf_validate_conformance_cases_bytes_proto_goTypes = []any{ (*BytesNone)(nil), // 0: buf.validate.conformance.cases.BytesNone (*BytesConst)(nil), // 1: buf.validate.conformance.cases.BytesConst @@ -1377,7 +1564,10 @@ var file_buf_validate_conformance_cases_bytes_proto_goTypes = []any{ (*BytesIPv6)(nil), // 17: buf.validate.conformance.cases.BytesIPv6 (*BytesNotIPv6)(nil), // 18: buf.validate.conformance.cases.BytesNotIPv6 (*BytesIPv6Ignore)(nil), // 19: buf.validate.conformance.cases.BytesIPv6Ignore - (*BytesExample)(nil), // 20: buf.validate.conformance.cases.BytesExample + (*BytesUUID)(nil), // 20: buf.validate.conformance.cases.BytesUUID + (*BytesNotUUID)(nil), // 21: buf.validate.conformance.cases.BytesNotUUID + (*BytesUUIDIgnore)(nil), // 22: buf.validate.conformance.cases.BytesUUIDIgnore + (*BytesExample)(nil), // 23: buf.validate.conformance.cases.BytesExample } var file_buf_validate_conformance_cases_bytes_proto_depIdxs = []int32{ 0, // [0:0] is the sub-list for method output_type @@ -1398,7 +1588,7 @@ func file_buf_validate_conformance_cases_bytes_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_bytes_proto_rawDesc), len(file_buf_validate_conformance_cases_bytes_proto_rawDesc)), NumEnums: 0, - NumMessages: 21, + NumMessages: 24, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules.pb.go b/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules.pb.go index f5909c43..f523a062 100644 --- a/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules.pb.go +++ b/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules.pb.go @@ -325,6 +325,63 @@ func (b0 MessageExpressions_builder) Build() *MessageExpressions { return m0 } +type MessageExpressionOnly struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + A int32 `protobuf:"varint,1,opt,name=a,proto3" json:"a,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *MessageExpressionOnly) Reset() { + *x = MessageExpressionOnly{} + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *MessageExpressionOnly) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MessageExpressionOnly) ProtoMessage() {} + +func (x *MessageExpressionOnly) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *MessageExpressionOnly) GetA() int32 { + if x != nil { + return x.A + } + return 0 +} + +func (x *MessageExpressionOnly) SetA(v int32) { + x.A = v +} + +type MessageExpressionOnly_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + A int32 +} + +func (b0 MessageExpressionOnly_builder) Build() *MessageExpressionOnly { + m0 := &MessageExpressionOnly{} + b, x := &b0, m0 + _, _ = b, x + x.A = b.A + return m0 +} + type MissingField struct { state protoimpl.MessageState `protogen:"hybrid.v1"` A int32 `protobuf:"varint,1,opt,name=a,proto3" json:"a,omitempty"` @@ -334,7 +391,7 @@ type MissingField struct { func (x *MissingField) Reset() { *x = MissingField{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -346,7 +403,7 @@ func (x *MissingField) String() string { func (*MissingField) ProtoMessage() {} func (x *MissingField) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -391,7 +448,7 @@ type IncorrectType struct { func (x *IncorrectType) Reset() { *x = IncorrectType{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -403,7 +460,7 @@ func (x *IncorrectType) String() string { func (*IncorrectType) ProtoMessage() {} func (x *IncorrectType) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -448,7 +505,7 @@ type DynRuntimeError struct { func (x *DynRuntimeError) Reset() { *x = DynRuntimeError{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -460,7 +517,7 @@ func (x *DynRuntimeError) String() string { func (*DynRuntimeError) ProtoMessage() {} func (x *DynRuntimeError) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -504,7 +561,7 @@ type NowEqualsNow struct { func (x *NowEqualsNow) Reset() { *x = NowEqualsNow{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -516,7 +573,7 @@ func (x *NowEqualsNow) String() string { func (*NowEqualsNow) ProtoMessage() {} func (x *NowEqualsNow) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -539,6 +596,63 @@ func (b0 NowEqualsNow_builder) Build() *NowEqualsNow { return m0 } +type FieldExpressionOnly struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val int32 `protobuf:"varint,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldExpressionOnly) Reset() { + *x = FieldExpressionOnly{} + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldExpressionOnly) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldExpressionOnly) ProtoMessage() {} + +func (x *FieldExpressionOnly) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldExpressionOnly) GetVal() int32 { + if x != nil { + return x.Val + } + return 0 +} + +func (x *FieldExpressionOnly) SetVal(v int32) { + x.Val = v +} + +type FieldExpressionOnly_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val int32 +} + +func (b0 FieldExpressionOnly_builder) Build() *FieldExpressionOnly { + m0 := &FieldExpressionOnly{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + type FieldExpressionMultipleScalar struct { state protoimpl.MessageState `protogen:"hybrid.v1"` Val int32 `protobuf:"varint,1,opt,name=val,proto3" json:"val,omitempty"` @@ -548,7 +662,7 @@ type FieldExpressionMultipleScalar struct { func (x *FieldExpressionMultipleScalar) Reset() { *x = FieldExpressionMultipleScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -560,7 +674,7 @@ func (x *FieldExpressionMultipleScalar) String() string { func (*FieldExpressionMultipleScalar) ProtoMessage() {} func (x *FieldExpressionMultipleScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -605,7 +719,7 @@ type FieldExpressionNestedScalar struct { func (x *FieldExpressionNestedScalar) Reset() { *x = FieldExpressionNestedScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -617,7 +731,7 @@ func (x *FieldExpressionNestedScalar) String() string { func (*FieldExpressionNestedScalar) ProtoMessage() {} func (x *FieldExpressionNestedScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -673,7 +787,7 @@ type FieldExpressionOptionalScalar struct { func (x *FieldExpressionOptionalScalar) Reset() { *x = FieldExpressionOptionalScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -685,7 +799,7 @@ func (x *FieldExpressionOptionalScalar) String() string { func (*FieldExpressionOptionalScalar) ProtoMessage() {} func (x *FieldExpressionOptionalScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -741,7 +855,7 @@ type FieldExpressionScalar struct { func (x *FieldExpressionScalar) Reset() { *x = FieldExpressionScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -753,7 +867,7 @@ func (x *FieldExpressionScalar) String() string { func (*FieldExpressionScalar) ProtoMessage() {} func (x *FieldExpressionScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -798,7 +912,7 @@ type FieldExpressionEnum struct { func (x *FieldExpressionEnum) Reset() { *x = FieldExpressionEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -810,7 +924,7 @@ func (x *FieldExpressionEnum) String() string { func (*FieldExpressionEnum) ProtoMessage() {} func (x *FieldExpressionEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -855,7 +969,7 @@ type FieldExpressionMessage struct { func (x *FieldExpressionMessage) Reset() { *x = FieldExpressionMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -867,7 +981,7 @@ func (x *FieldExpressionMessage) String() string { func (*FieldExpressionMessage) ProtoMessage() {} func (x *FieldExpressionMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -923,7 +1037,7 @@ type FieldExpressionMapInt32 struct { func (x *FieldExpressionMapInt32) Reset() { *x = FieldExpressionMapInt32{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -935,7 +1049,7 @@ func (x *FieldExpressionMapInt32) String() string { func (*FieldExpressionMapInt32) ProtoMessage() {} func (x *FieldExpressionMapInt32) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -980,7 +1094,7 @@ type FieldExpressionMapInt64 struct { func (x *FieldExpressionMapInt64) Reset() { *x = FieldExpressionMapInt64{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -992,7 +1106,7 @@ func (x *FieldExpressionMapInt64) String() string { func (*FieldExpressionMapInt64) ProtoMessage() {} func (x *FieldExpressionMapInt64) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1037,7 +1151,7 @@ type FieldExpressionMapUint32 struct { func (x *FieldExpressionMapUint32) Reset() { *x = FieldExpressionMapUint32{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1049,7 +1163,7 @@ func (x *FieldExpressionMapUint32) String() string { func (*FieldExpressionMapUint32) ProtoMessage() {} func (x *FieldExpressionMapUint32) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1094,7 +1208,7 @@ type FieldExpressionMapUint64 struct { func (x *FieldExpressionMapUint64) Reset() { *x = FieldExpressionMapUint64{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1106,7 +1220,7 @@ func (x *FieldExpressionMapUint64) String() string { func (*FieldExpressionMapUint64) ProtoMessage() {} func (x *FieldExpressionMapUint64) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1151,7 +1265,7 @@ type FieldExpressionMapBool struct { func (x *FieldExpressionMapBool) Reset() { *x = FieldExpressionMapBool{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1163,7 +1277,7 @@ func (x *FieldExpressionMapBool) String() string { func (*FieldExpressionMapBool) ProtoMessage() {} func (x *FieldExpressionMapBool) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1208,7 +1322,7 @@ type FieldExpressionMapString struct { func (x *FieldExpressionMapString) Reset() { *x = FieldExpressionMapString{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1220,7 +1334,7 @@ func (x *FieldExpressionMapString) String() string { func (*FieldExpressionMapString) ProtoMessage() {} func (x *FieldExpressionMapString) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1265,7 +1379,7 @@ type FieldExpressionMapEnum struct { func (x *FieldExpressionMapEnum) Reset() { *x = FieldExpressionMapEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1277,7 +1391,7 @@ func (x *FieldExpressionMapEnum) String() string { func (*FieldExpressionMapEnum) ProtoMessage() {} func (x *FieldExpressionMapEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1322,7 +1436,7 @@ type FieldExpressionMapMessage struct { func (x *FieldExpressionMapMessage) Reset() { *x = FieldExpressionMapMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1334,7 +1448,7 @@ func (x *FieldExpressionMapMessage) String() string { func (*FieldExpressionMapMessage) ProtoMessage() {} func (x *FieldExpressionMapMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1379,7 +1493,7 @@ type FieldExpressionMapKeys struct { func (x *FieldExpressionMapKeys) Reset() { *x = FieldExpressionMapKeys{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1391,7 +1505,7 @@ func (x *FieldExpressionMapKeys) String() string { func (*FieldExpressionMapKeys) ProtoMessage() {} func (x *FieldExpressionMapKeys) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1436,7 +1550,7 @@ type FieldExpressionMapScalarValues struct { func (x *FieldExpressionMapScalarValues) Reset() { *x = FieldExpressionMapScalarValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1448,7 +1562,7 @@ func (x *FieldExpressionMapScalarValues) String() string { func (*FieldExpressionMapScalarValues) ProtoMessage() {} func (x *FieldExpressionMapScalarValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1493,7 +1607,7 @@ type FieldExpressionMapEnumValues struct { func (x *FieldExpressionMapEnumValues) Reset() { *x = FieldExpressionMapEnumValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1505,7 +1619,7 @@ func (x *FieldExpressionMapEnumValues) String() string { func (*FieldExpressionMapEnumValues) ProtoMessage() {} func (x *FieldExpressionMapEnumValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1550,7 +1664,7 @@ type FieldExpressionMapMessageValues struct { func (x *FieldExpressionMapMessageValues) Reset() { *x = FieldExpressionMapMessageValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1562,7 +1676,7 @@ func (x *FieldExpressionMapMessageValues) String() string { func (*FieldExpressionMapMessageValues) ProtoMessage() {} func (x *FieldExpressionMapMessageValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1607,7 +1721,7 @@ type FieldExpressionRepeatedScalar struct { func (x *FieldExpressionRepeatedScalar) Reset() { *x = FieldExpressionRepeatedScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1619,7 +1733,7 @@ func (x *FieldExpressionRepeatedScalar) String() string { func (*FieldExpressionRepeatedScalar) ProtoMessage() {} func (x *FieldExpressionRepeatedScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1664,7 +1778,7 @@ type FieldExpressionRepeatedEnum struct { func (x *FieldExpressionRepeatedEnum) Reset() { *x = FieldExpressionRepeatedEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1676,7 +1790,7 @@ func (x *FieldExpressionRepeatedEnum) String() string { func (*FieldExpressionRepeatedEnum) ProtoMessage() {} func (x *FieldExpressionRepeatedEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1721,7 +1835,7 @@ type FieldExpressionRepeatedMessage struct { func (x *FieldExpressionRepeatedMessage) Reset() { *x = FieldExpressionRepeatedMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1733,7 +1847,7 @@ func (x *FieldExpressionRepeatedMessage) String() string { func (*FieldExpressionRepeatedMessage) ProtoMessage() {} func (x *FieldExpressionRepeatedMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1778,7 +1892,7 @@ type FieldExpressionRepeatedScalarItems struct { func (x *FieldExpressionRepeatedScalarItems) Reset() { *x = FieldExpressionRepeatedScalarItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1790,7 +1904,7 @@ func (x *FieldExpressionRepeatedScalarItems) String() string { func (*FieldExpressionRepeatedScalarItems) ProtoMessage() {} func (x *FieldExpressionRepeatedScalarItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1835,7 +1949,7 @@ type FieldExpressionRepeatedEnumItems struct { func (x *FieldExpressionRepeatedEnumItems) Reset() { *x = FieldExpressionRepeatedEnumItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1847,7 +1961,7 @@ func (x *FieldExpressionRepeatedEnumItems) String() string { func (*FieldExpressionRepeatedEnumItems) ProtoMessage() {} func (x *FieldExpressionRepeatedEnumItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1892,7 +2006,7 @@ type FieldExpressionRepeatedMessageItems struct { func (x *FieldExpressionRepeatedMessageItems) Reset() { *x = FieldExpressionRepeatedMessageItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1904,7 +2018,7 @@ func (x *FieldExpressionRepeatedMessageItems) String() string { func (*FieldExpressionRepeatedMessageItems) ProtoMessage() {} func (x *FieldExpressionRepeatedMessageItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1948,7 +2062,7 @@ type NoExpressions_Nested struct { func (x *NoExpressions_Nested) Reset() { *x = NoExpressions_Nested{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1960,7 +2074,7 @@ func (x *NoExpressions_Nested) String() string { func (*NoExpressions_Nested) ProtoMessage() {} func (x *NoExpressions_Nested) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1993,7 +2107,7 @@ type MessageExpressions_Nested struct { func (x *MessageExpressions_Nested) Reset() { *x = MessageExpressions_Nested{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2005,7 +2119,7 @@ func (x *MessageExpressions_Nested) String() string { func (*MessageExpressions_Nested) ProtoMessage() {} func (x *MessageExpressions_Nested) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[33] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2063,7 +2177,7 @@ type FieldExpressionMessage_Msg struct { func (x *FieldExpressionMessage_Msg) Reset() { *x = FieldExpressionMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2075,7 +2189,7 @@ func (x *FieldExpressionMessage_Msg) String() string { func (*FieldExpressionMessage_Msg) ProtoMessage() {} func (x *FieldExpressionMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[34] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2120,7 +2234,7 @@ type FieldExpressionMapMessage_Msg struct { func (x *FieldExpressionMapMessage_Msg) Reset() { *x = FieldExpressionMapMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[41] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2132,7 +2246,7 @@ func (x *FieldExpressionMapMessage_Msg) String() string { func (*FieldExpressionMapMessage_Msg) ProtoMessage() {} func (x *FieldExpressionMapMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[41] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[43] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2177,7 +2291,7 @@ type FieldExpressionMapMessageValues_Msg struct { func (x *FieldExpressionMapMessageValues_Msg) Reset() { *x = FieldExpressionMapMessageValues_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[46] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2189,7 +2303,7 @@ func (x *FieldExpressionMapMessageValues_Msg) String() string { func (*FieldExpressionMapMessageValues_Msg) ProtoMessage() {} func (x *FieldExpressionMapMessageValues_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[46] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2234,7 +2348,7 @@ type FieldExpressionRepeatedMessage_Msg struct { func (x *FieldExpressionRepeatedMessage_Msg) Reset() { *x = FieldExpressionRepeatedMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[47] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[49] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2246,7 +2360,7 @@ func (x *FieldExpressionRepeatedMessage_Msg) String() string { func (*FieldExpressionRepeatedMessage_Msg) ProtoMessage() {} func (x *FieldExpressionRepeatedMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[47] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[49] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2291,7 +2405,7 @@ type FieldExpressionRepeatedMessageItems_Msg struct { func (x *FieldExpressionRepeatedMessageItems_Msg) Reset() { *x = FieldExpressionRepeatedMessageItems_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[50] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2303,7 +2417,7 @@ func (x *FieldExpressionRepeatedMessageItems_Msg) String() string { func (*FieldExpressionRepeatedMessageItems_Msg) ProtoMessage() {} func (x *FieldExpressionRepeatedMessageItems_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[50] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2362,7 +2476,10 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "\x19message_expression_nested\x1a0this.a > this.b ? '': 'a must be greater than b':\xd0\x01\xbaH\xcc\x01\x1aC\n" + "\x19message_expression_scalar\x12\x15a must be less than b\x1a\x0fthis.a < this.b\x1a?\n" + "\x17message_expression_enum\x12\x12c must not equal d\x1a\x10this.c != this.d\x1aD\n" + - "\x18message_expression_embed\x12\x12e.a must equal f.a\x1a\x14this.e.a == this.f.a\"R\n" + + "\x18message_expression_embed\x12\x12e.a must equal f.a\x1a\x14this.e.a == this.f.a\"6\n" + + "\x15MessageExpressionOnly\x12\f\n" + + "\x01a\x18\x01 \x01(\x05R\x01a:\x0f\xbaH\f*\n" + + "this.a > 0\"R\n" + "\fMissingField\x12\f\n" + "\x01a\x18\x01 \x01(\x05R\x01a:4\xbaH1\x1a/\n" + "\rmissing_field\x12\x12b must be positive\x1a\n" + @@ -2375,7 +2492,9 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "\x0fdyn_runtime_err\x12.dynamic type tries to use a non-existent field\x1a\x14dyn(this).b == 'foo'\"\\\n" + "\fNowEqualsNow:L\xbaHI\x1aG\n" + "\x0enow_equals_now\x12)now should equal now within an expression\x1a\n" + - "now == now\"\xdf\x02\n" + + "now == now\"8\n" + + "\x13FieldExpressionOnly\x12!\n" + + "\x03val\x18\x01 \x01(\x05B\x0f\xbaH\f\xea\x01\tthis > 42R\x03val\"\xdf\x02\n" + "\x1dFieldExpressionMultipleScalar\x12\xbd\x02\n" + "\x03val\x18\x01 \x01(\x05B\xaa\x02\xbaH\xa6\x02\xba\x01_\n" + "\"field_expression.multiple.scalar.1\x12/test message field_expression.multiple.scalar.1\x1a\bthis > 0\xba\x01_\n" + @@ -2502,89 +2621,91 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "/com.buf.validate.conformance.cases.custom_rulesB\x10CustomRulesProtoP\x01ZSbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases/custom_rules\xa2\x02\x05BVCCC\xaa\x02*Buf.Validate.Conformance.Cases.CustomRules\xca\x02*Buf\\Validate\\Conformance\\Cases\\CustomRules\xe2\x026Buf\\Validate\\Conformance\\Cases\\CustomRules\\GPBMetadata\xea\x02.Buf::Validate::Conformance::Cases::CustomRulesb\x06proto3" var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes = make([]protoimpl.MessageInfo, 49) +var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes = make([]protoimpl.MessageInfo, 51) var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_goTypes = []any{ (Enum)(0), // 0: buf.validate.conformance.cases.custom_rules.Enum (*NoExpressions)(nil), // 1: buf.validate.conformance.cases.custom_rules.NoExpressions (*MessageExpressions)(nil), // 2: buf.validate.conformance.cases.custom_rules.MessageExpressions - (*MissingField)(nil), // 3: buf.validate.conformance.cases.custom_rules.MissingField - (*IncorrectType)(nil), // 4: buf.validate.conformance.cases.custom_rules.IncorrectType - (*DynRuntimeError)(nil), // 5: buf.validate.conformance.cases.custom_rules.DynRuntimeError - (*NowEqualsNow)(nil), // 6: buf.validate.conformance.cases.custom_rules.NowEqualsNow - (*FieldExpressionMultipleScalar)(nil), // 7: buf.validate.conformance.cases.custom_rules.FieldExpressionMultipleScalar - (*FieldExpressionNestedScalar)(nil), // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar - (*FieldExpressionOptionalScalar)(nil), // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionOptionalScalar - (*FieldExpressionScalar)(nil), // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionScalar - (*FieldExpressionEnum)(nil), // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum - (*FieldExpressionMessage)(nil), // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage - (*FieldExpressionMapInt32)(nil), // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32 - (*FieldExpressionMapInt64)(nil), // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64 - (*FieldExpressionMapUint32)(nil), // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32 - (*FieldExpressionMapUint64)(nil), // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64 - (*FieldExpressionMapBool)(nil), // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool - (*FieldExpressionMapString)(nil), // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString - (*FieldExpressionMapEnum)(nil), // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum - (*FieldExpressionMapMessage)(nil), // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage - (*FieldExpressionMapKeys)(nil), // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys - (*FieldExpressionMapScalarValues)(nil), // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues - (*FieldExpressionMapEnumValues)(nil), // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues - (*FieldExpressionMapMessageValues)(nil), // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues - (*FieldExpressionRepeatedScalar)(nil), // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalar - (*FieldExpressionRepeatedEnum)(nil), // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum - (*FieldExpressionRepeatedMessage)(nil), // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage - (*FieldExpressionRepeatedScalarItems)(nil), // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalarItems - (*FieldExpressionRepeatedEnumItems)(nil), // 29: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems - (*FieldExpressionRepeatedMessageItems)(nil), // 30: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems - (*NoExpressions_Nested)(nil), // 31: buf.validate.conformance.cases.custom_rules.NoExpressions.Nested - (*MessageExpressions_Nested)(nil), // 32: buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - (*FieldExpressionMessage_Msg)(nil), // 33: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg - nil, // 34: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry - nil, // 35: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry - nil, // 36: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry - nil, // 37: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry - nil, // 38: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry - nil, // 39: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry - nil, // 40: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry - nil, // 41: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry - (*FieldExpressionMapMessage_Msg)(nil), // 42: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg - nil, // 43: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry - nil, // 44: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry - nil, // 45: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry - nil, // 46: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry - (*FieldExpressionMapMessageValues_Msg)(nil), // 47: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg - (*FieldExpressionRepeatedMessage_Msg)(nil), // 48: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg - (*FieldExpressionRepeatedMessageItems_Msg)(nil), // 49: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg + (*MessageExpressionOnly)(nil), // 3: buf.validate.conformance.cases.custom_rules.MessageExpressionOnly + (*MissingField)(nil), // 4: buf.validate.conformance.cases.custom_rules.MissingField + (*IncorrectType)(nil), // 5: buf.validate.conformance.cases.custom_rules.IncorrectType + (*DynRuntimeError)(nil), // 6: buf.validate.conformance.cases.custom_rules.DynRuntimeError + (*NowEqualsNow)(nil), // 7: buf.validate.conformance.cases.custom_rules.NowEqualsNow + (*FieldExpressionOnly)(nil), // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionOnly + (*FieldExpressionMultipleScalar)(nil), // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMultipleScalar + (*FieldExpressionNestedScalar)(nil), // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar + (*FieldExpressionOptionalScalar)(nil), // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionOptionalScalar + (*FieldExpressionScalar)(nil), // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionScalar + (*FieldExpressionEnum)(nil), // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum + (*FieldExpressionMessage)(nil), // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage + (*FieldExpressionMapInt32)(nil), // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32 + (*FieldExpressionMapInt64)(nil), // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64 + (*FieldExpressionMapUint32)(nil), // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32 + (*FieldExpressionMapUint64)(nil), // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64 + (*FieldExpressionMapBool)(nil), // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool + (*FieldExpressionMapString)(nil), // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString + (*FieldExpressionMapEnum)(nil), // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum + (*FieldExpressionMapMessage)(nil), // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage + (*FieldExpressionMapKeys)(nil), // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys + (*FieldExpressionMapScalarValues)(nil), // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues + (*FieldExpressionMapEnumValues)(nil), // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues + (*FieldExpressionMapMessageValues)(nil), // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues + (*FieldExpressionRepeatedScalar)(nil), // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalar + (*FieldExpressionRepeatedEnum)(nil), // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum + (*FieldExpressionRepeatedMessage)(nil), // 29: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage + (*FieldExpressionRepeatedScalarItems)(nil), // 30: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalarItems + (*FieldExpressionRepeatedEnumItems)(nil), // 31: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems + (*FieldExpressionRepeatedMessageItems)(nil), // 32: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems + (*NoExpressions_Nested)(nil), // 33: buf.validate.conformance.cases.custom_rules.NoExpressions.Nested + (*MessageExpressions_Nested)(nil), // 34: buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + (*FieldExpressionMessage_Msg)(nil), // 35: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg + nil, // 36: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry + nil, // 37: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry + nil, // 38: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry + nil, // 39: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry + nil, // 40: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry + nil, // 41: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry + nil, // 42: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry + nil, // 43: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry + (*FieldExpressionMapMessage_Msg)(nil), // 44: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg + nil, // 45: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry + nil, // 46: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry + nil, // 47: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry + nil, // 48: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry + (*FieldExpressionMapMessageValues_Msg)(nil), // 49: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg + (*FieldExpressionRepeatedMessage_Msg)(nil), // 50: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg + (*FieldExpressionRepeatedMessageItems_Msg)(nil), // 51: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg } var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_depIdxs = []int32{ 0, // 0: buf.validate.conformance.cases.custom_rules.NoExpressions.b:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 31, // 1: buf.validate.conformance.cases.custom_rules.NoExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.NoExpressions.Nested + 33, // 1: buf.validate.conformance.cases.custom_rules.NoExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.NoExpressions.Nested 0, // 2: buf.validate.conformance.cases.custom_rules.MessageExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.Enum 0, // 3: buf.validate.conformance.cases.custom_rules.MessageExpressions.d:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 32, // 4: buf.validate.conformance.cases.custom_rules.MessageExpressions.e:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - 32, // 5: buf.validate.conformance.cases.custom_rules.MessageExpressions.f:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - 10, // 6: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar.nested:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionScalar + 34, // 4: buf.validate.conformance.cases.custom_rules.MessageExpressions.e:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + 34, // 5: buf.validate.conformance.cases.custom_rules.MessageExpressions.f:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + 12, // 6: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar.nested:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionScalar 0, // 7: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 33, // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg - 34, // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry - 35, // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry - 36, // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry - 37, // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry - 38, // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry - 39, // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry - 40, // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry - 41, // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry - 43, // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry - 44, // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry - 45, // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry - 46, // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry + 35, // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg + 36, // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry + 37, // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry + 38, // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry + 39, // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry + 40, // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry + 41, // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry + 42, // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry + 43, // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry + 45, // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry + 46, // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry + 47, // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry + 48, // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry 0, // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 48, // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg + 50, // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg 0, // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 49, // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg + 51, // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg 0, // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 42, // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg + 44, // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg 0, // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 47, // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg + 49, // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg 29, // [29:29] is the sub-list for method output_type 29, // [29:29] is the sub-list for method input_type 29, // [29:29] is the sub-list for extension type_name @@ -2597,14 +2718,14 @@ func file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_init() if File_buf_validate_conformance_cases_custom_rules_custom_rules_proto != nil { return } - file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8].OneofWrappers = []any{} + file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDesc), len(file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDesc)), NumEnums: 1, - NumMessages: 49, + NumMessages: 51, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules_protoopaque.pb.go index c4d807c7..2e1a28c5 100644 --- a/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules_protoopaque.pb.go +++ b/internal/gen/buf/validate/conformance/cases/custom_rules/custom_rules_protoopaque.pb.go @@ -325,6 +325,63 @@ func (b0 MessageExpressions_builder) Build() *MessageExpressions { return m0 } +type MessageExpressionOnly struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_A int32 `protobuf:"varint,1,opt,name=a,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *MessageExpressionOnly) Reset() { + *x = MessageExpressionOnly{} + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *MessageExpressionOnly) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MessageExpressionOnly) ProtoMessage() {} + +func (x *MessageExpressionOnly) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *MessageExpressionOnly) GetA() int32 { + if x != nil { + return x.xxx_hidden_A + } + return 0 +} + +func (x *MessageExpressionOnly) SetA(v int32) { + x.xxx_hidden_A = v +} + +type MessageExpressionOnly_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + A int32 +} + +func (b0 MessageExpressionOnly_builder) Build() *MessageExpressionOnly { + m0 := &MessageExpressionOnly{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_A = b.A + return m0 +} + type MissingField struct { state protoimpl.MessageState `protogen:"opaque.v1"` xxx_hidden_A int32 `protobuf:"varint,1,opt,name=a,proto3"` @@ -334,7 +391,7 @@ type MissingField struct { func (x *MissingField) Reset() { *x = MissingField{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -346,7 +403,7 @@ func (x *MissingField) String() string { func (*MissingField) ProtoMessage() {} func (x *MissingField) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[2] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -391,7 +448,7 @@ type IncorrectType struct { func (x *IncorrectType) Reset() { *x = IncorrectType{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -403,7 +460,7 @@ func (x *IncorrectType) String() string { func (*IncorrectType) ProtoMessage() {} func (x *IncorrectType) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[3] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -448,7 +505,7 @@ type DynRuntimeError struct { func (x *DynRuntimeError) Reset() { *x = DynRuntimeError{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -460,7 +517,7 @@ func (x *DynRuntimeError) String() string { func (*DynRuntimeError) ProtoMessage() {} func (x *DynRuntimeError) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[4] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -504,7 +561,7 @@ type NowEqualsNow struct { func (x *NowEqualsNow) Reset() { *x = NowEqualsNow{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -516,7 +573,7 @@ func (x *NowEqualsNow) String() string { func (*NowEqualsNow) ProtoMessage() {} func (x *NowEqualsNow) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[5] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -539,6 +596,63 @@ func (b0 NowEqualsNow_builder) Build() *NowEqualsNow { return m0 } +type FieldExpressionOnly struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val int32 `protobuf:"varint,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldExpressionOnly) Reset() { + *x = FieldExpressionOnly{} + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldExpressionOnly) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldExpressionOnly) ProtoMessage() {} + +func (x *FieldExpressionOnly) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldExpressionOnly) GetVal() int32 { + if x != nil { + return x.xxx_hidden_Val + } + return 0 +} + +func (x *FieldExpressionOnly) SetVal(v int32) { + x.xxx_hidden_Val = v +} + +type FieldExpressionOnly_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val int32 +} + +func (b0 FieldExpressionOnly_builder) Build() *FieldExpressionOnly { + m0 := &FieldExpressionOnly{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + type FieldExpressionMultipleScalar struct { state protoimpl.MessageState `protogen:"opaque.v1"` xxx_hidden_Val int32 `protobuf:"varint,1,opt,name=val,proto3"` @@ -548,7 +662,7 @@ type FieldExpressionMultipleScalar struct { func (x *FieldExpressionMultipleScalar) Reset() { *x = FieldExpressionMultipleScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -560,7 +674,7 @@ func (x *FieldExpressionMultipleScalar) String() string { func (*FieldExpressionMultipleScalar) ProtoMessage() {} func (x *FieldExpressionMultipleScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[6] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -605,7 +719,7 @@ type FieldExpressionNestedScalar struct { func (x *FieldExpressionNestedScalar) Reset() { *x = FieldExpressionNestedScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -617,7 +731,7 @@ func (x *FieldExpressionNestedScalar) String() string { func (*FieldExpressionNestedScalar) ProtoMessage() {} func (x *FieldExpressionNestedScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[7] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -675,7 +789,7 @@ type FieldExpressionOptionalScalar struct { func (x *FieldExpressionOptionalScalar) Reset() { *x = FieldExpressionOptionalScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -687,7 +801,7 @@ func (x *FieldExpressionOptionalScalar) String() string { func (*FieldExpressionOptionalScalar) ProtoMessage() {} func (x *FieldExpressionOptionalScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -748,7 +862,7 @@ type FieldExpressionScalar struct { func (x *FieldExpressionScalar) Reset() { *x = FieldExpressionScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -760,7 +874,7 @@ func (x *FieldExpressionScalar) String() string { func (*FieldExpressionScalar) ProtoMessage() {} func (x *FieldExpressionScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[9] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -805,7 +919,7 @@ type FieldExpressionEnum struct { func (x *FieldExpressionEnum) Reset() { *x = FieldExpressionEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -817,7 +931,7 @@ func (x *FieldExpressionEnum) String() string { func (*FieldExpressionEnum) ProtoMessage() {} func (x *FieldExpressionEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -862,7 +976,7 @@ type FieldExpressionMessage struct { func (x *FieldExpressionMessage) Reset() { *x = FieldExpressionMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -874,7 +988,7 @@ func (x *FieldExpressionMessage) String() string { func (*FieldExpressionMessage) ProtoMessage() {} func (x *FieldExpressionMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[11] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -930,7 +1044,7 @@ type FieldExpressionMapInt32 struct { func (x *FieldExpressionMapInt32) Reset() { *x = FieldExpressionMapInt32{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -942,7 +1056,7 @@ func (x *FieldExpressionMapInt32) String() string { func (*FieldExpressionMapInt32) ProtoMessage() {} func (x *FieldExpressionMapInt32) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[12] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -987,7 +1101,7 @@ type FieldExpressionMapInt64 struct { func (x *FieldExpressionMapInt64) Reset() { *x = FieldExpressionMapInt64{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -999,7 +1113,7 @@ func (x *FieldExpressionMapInt64) String() string { func (*FieldExpressionMapInt64) ProtoMessage() {} func (x *FieldExpressionMapInt64) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[13] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1044,7 +1158,7 @@ type FieldExpressionMapUint32 struct { func (x *FieldExpressionMapUint32) Reset() { *x = FieldExpressionMapUint32{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1056,7 +1170,7 @@ func (x *FieldExpressionMapUint32) String() string { func (*FieldExpressionMapUint32) ProtoMessage() {} func (x *FieldExpressionMapUint32) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[14] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1101,7 +1215,7 @@ type FieldExpressionMapUint64 struct { func (x *FieldExpressionMapUint64) Reset() { *x = FieldExpressionMapUint64{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1113,7 +1227,7 @@ func (x *FieldExpressionMapUint64) String() string { func (*FieldExpressionMapUint64) ProtoMessage() {} func (x *FieldExpressionMapUint64) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1158,7 +1272,7 @@ type FieldExpressionMapBool struct { func (x *FieldExpressionMapBool) Reset() { *x = FieldExpressionMapBool{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1170,7 +1284,7 @@ func (x *FieldExpressionMapBool) String() string { func (*FieldExpressionMapBool) ProtoMessage() {} func (x *FieldExpressionMapBool) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1215,7 +1329,7 @@ type FieldExpressionMapString struct { func (x *FieldExpressionMapString) Reset() { *x = FieldExpressionMapString{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1227,7 +1341,7 @@ func (x *FieldExpressionMapString) String() string { func (*FieldExpressionMapString) ProtoMessage() {} func (x *FieldExpressionMapString) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[17] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1272,7 +1386,7 @@ type FieldExpressionMapEnum struct { func (x *FieldExpressionMapEnum) Reset() { *x = FieldExpressionMapEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1284,7 +1398,7 @@ func (x *FieldExpressionMapEnum) String() string { func (*FieldExpressionMapEnum) ProtoMessage() {} func (x *FieldExpressionMapEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[18] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1329,7 +1443,7 @@ type FieldExpressionMapMessage struct { func (x *FieldExpressionMapMessage) Reset() { *x = FieldExpressionMapMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1341,7 +1455,7 @@ func (x *FieldExpressionMapMessage) String() string { func (*FieldExpressionMapMessage) ProtoMessage() {} func (x *FieldExpressionMapMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[19] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1386,7 +1500,7 @@ type FieldExpressionMapKeys struct { func (x *FieldExpressionMapKeys) Reset() { *x = FieldExpressionMapKeys{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1398,7 +1512,7 @@ func (x *FieldExpressionMapKeys) String() string { func (*FieldExpressionMapKeys) ProtoMessage() {} func (x *FieldExpressionMapKeys) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[20] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1443,7 +1557,7 @@ type FieldExpressionMapScalarValues struct { func (x *FieldExpressionMapScalarValues) Reset() { *x = FieldExpressionMapScalarValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1455,7 +1569,7 @@ func (x *FieldExpressionMapScalarValues) String() string { func (*FieldExpressionMapScalarValues) ProtoMessage() {} func (x *FieldExpressionMapScalarValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[21] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1500,7 +1614,7 @@ type FieldExpressionMapEnumValues struct { func (x *FieldExpressionMapEnumValues) Reset() { *x = FieldExpressionMapEnumValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1512,7 +1626,7 @@ func (x *FieldExpressionMapEnumValues) String() string { func (*FieldExpressionMapEnumValues) ProtoMessage() {} func (x *FieldExpressionMapEnumValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[22] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1557,7 +1671,7 @@ type FieldExpressionMapMessageValues struct { func (x *FieldExpressionMapMessageValues) Reset() { *x = FieldExpressionMapMessageValues{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1569,7 +1683,7 @@ func (x *FieldExpressionMapMessageValues) String() string { func (*FieldExpressionMapMessageValues) ProtoMessage() {} func (x *FieldExpressionMapMessageValues) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[23] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1614,7 +1728,7 @@ type FieldExpressionRepeatedScalar struct { func (x *FieldExpressionRepeatedScalar) Reset() { *x = FieldExpressionRepeatedScalar{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1626,7 +1740,7 @@ func (x *FieldExpressionRepeatedScalar) String() string { func (*FieldExpressionRepeatedScalar) ProtoMessage() {} func (x *FieldExpressionRepeatedScalar) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[24] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1671,7 +1785,7 @@ type FieldExpressionRepeatedEnum struct { func (x *FieldExpressionRepeatedEnum) Reset() { *x = FieldExpressionRepeatedEnum{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1683,7 +1797,7 @@ func (x *FieldExpressionRepeatedEnum) String() string { func (*FieldExpressionRepeatedEnum) ProtoMessage() {} func (x *FieldExpressionRepeatedEnum) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[25] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1728,7 +1842,7 @@ type FieldExpressionRepeatedMessage struct { func (x *FieldExpressionRepeatedMessage) Reset() { *x = FieldExpressionRepeatedMessage{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1740,7 +1854,7 @@ func (x *FieldExpressionRepeatedMessage) String() string { func (*FieldExpressionRepeatedMessage) ProtoMessage() {} func (x *FieldExpressionRepeatedMessage) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[26] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1787,7 +1901,7 @@ type FieldExpressionRepeatedScalarItems struct { func (x *FieldExpressionRepeatedScalarItems) Reset() { *x = FieldExpressionRepeatedScalarItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1799,7 +1913,7 @@ func (x *FieldExpressionRepeatedScalarItems) String() string { func (*FieldExpressionRepeatedScalarItems) ProtoMessage() {} func (x *FieldExpressionRepeatedScalarItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[27] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1844,7 +1958,7 @@ type FieldExpressionRepeatedEnumItems struct { func (x *FieldExpressionRepeatedEnumItems) Reset() { *x = FieldExpressionRepeatedEnumItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1856,7 +1970,7 @@ func (x *FieldExpressionRepeatedEnumItems) String() string { func (*FieldExpressionRepeatedEnumItems) ProtoMessage() {} func (x *FieldExpressionRepeatedEnumItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[28] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1901,7 +2015,7 @@ type FieldExpressionRepeatedMessageItems struct { func (x *FieldExpressionRepeatedMessageItems) Reset() { *x = FieldExpressionRepeatedMessageItems{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1913,7 +2027,7 @@ func (x *FieldExpressionRepeatedMessageItems) String() string { func (*FieldExpressionRepeatedMessageItems) ProtoMessage() {} func (x *FieldExpressionRepeatedMessageItems) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[29] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1959,7 +2073,7 @@ type NoExpressions_Nested struct { func (x *NoExpressions_Nested) Reset() { *x = NoExpressions_Nested{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1971,7 +2085,7 @@ func (x *NoExpressions_Nested) String() string { func (*NoExpressions_Nested) ProtoMessage() {} func (x *NoExpressions_Nested) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[30] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2004,7 +2118,7 @@ type MessageExpressions_Nested struct { func (x *MessageExpressions_Nested) Reset() { *x = MessageExpressions_Nested{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2016,7 +2130,7 @@ func (x *MessageExpressions_Nested) String() string { func (*MessageExpressions_Nested) ProtoMessage() {} func (x *MessageExpressions_Nested) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[31] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[33] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2074,7 +2188,7 @@ type FieldExpressionMessage_Msg struct { func (x *FieldExpressionMessage_Msg) Reset() { *x = FieldExpressionMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2086,7 +2200,7 @@ func (x *FieldExpressionMessage_Msg) String() string { func (*FieldExpressionMessage_Msg) ProtoMessage() {} func (x *FieldExpressionMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[32] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[34] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2131,7 +2245,7 @@ type FieldExpressionMapMessage_Msg struct { func (x *FieldExpressionMapMessage_Msg) Reset() { *x = FieldExpressionMapMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[41] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2143,7 +2257,7 @@ func (x *FieldExpressionMapMessage_Msg) String() string { func (*FieldExpressionMapMessage_Msg) ProtoMessage() {} func (x *FieldExpressionMapMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[41] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[43] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2188,7 +2302,7 @@ type FieldExpressionMapMessageValues_Msg struct { func (x *FieldExpressionMapMessageValues_Msg) Reset() { *x = FieldExpressionMapMessageValues_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[46] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2200,7 +2314,7 @@ func (x *FieldExpressionMapMessageValues_Msg) String() string { func (*FieldExpressionMapMessageValues_Msg) ProtoMessage() {} func (x *FieldExpressionMapMessageValues_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[46] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2245,7 +2359,7 @@ type FieldExpressionRepeatedMessage_Msg struct { func (x *FieldExpressionRepeatedMessage_Msg) Reset() { *x = FieldExpressionRepeatedMessage_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[47] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[49] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2257,7 +2371,7 @@ func (x *FieldExpressionRepeatedMessage_Msg) String() string { func (*FieldExpressionRepeatedMessage_Msg) ProtoMessage() {} func (x *FieldExpressionRepeatedMessage_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[47] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[49] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2302,7 +2416,7 @@ type FieldExpressionRepeatedMessageItems_Msg struct { func (x *FieldExpressionRepeatedMessageItems_Msg) Reset() { *x = FieldExpressionRepeatedMessageItems_Msg{} - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[50] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2314,7 +2428,7 @@ func (x *FieldExpressionRepeatedMessageItems_Msg) String() string { func (*FieldExpressionRepeatedMessageItems_Msg) ProtoMessage() {} func (x *FieldExpressionRepeatedMessageItems_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[48] + mi := &file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[50] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2373,7 +2487,10 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "\x19message_expression_nested\x1a0this.a > this.b ? '': 'a must be greater than b':\xd0\x01\xbaH\xcc\x01\x1aC\n" + "\x19message_expression_scalar\x12\x15a must be less than b\x1a\x0fthis.a < this.b\x1a?\n" + "\x17message_expression_enum\x12\x12c must not equal d\x1a\x10this.c != this.d\x1aD\n" + - "\x18message_expression_embed\x12\x12e.a must equal f.a\x1a\x14this.e.a == this.f.a\"R\n" + + "\x18message_expression_embed\x12\x12e.a must equal f.a\x1a\x14this.e.a == this.f.a\"6\n" + + "\x15MessageExpressionOnly\x12\f\n" + + "\x01a\x18\x01 \x01(\x05R\x01a:\x0f\xbaH\f*\n" + + "this.a > 0\"R\n" + "\fMissingField\x12\f\n" + "\x01a\x18\x01 \x01(\x05R\x01a:4\xbaH1\x1a/\n" + "\rmissing_field\x12\x12b must be positive\x1a\n" + @@ -2386,7 +2503,9 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "\x0fdyn_runtime_err\x12.dynamic type tries to use a non-existent field\x1a\x14dyn(this).b == 'foo'\"\\\n" + "\fNowEqualsNow:L\xbaHI\x1aG\n" + "\x0enow_equals_now\x12)now should equal now within an expression\x1a\n" + - "now == now\"\xdf\x02\n" + + "now == now\"8\n" + + "\x13FieldExpressionOnly\x12!\n" + + "\x03val\x18\x01 \x01(\x05B\x0f\xbaH\f\xea\x01\tthis > 42R\x03val\"\xdf\x02\n" + "\x1dFieldExpressionMultipleScalar\x12\xbd\x02\n" + "\x03val\x18\x01 \x01(\x05B\xaa\x02\xbaH\xa6\x02\xba\x01_\n" + "\"field_expression.multiple.scalar.1\x12/test message field_expression.multiple.scalar.1\x1a\bthis > 0\xba\x01_\n" + @@ -2513,89 +2632,91 @@ const file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDes "/com.buf.validate.conformance.cases.custom_rulesB\x10CustomRulesProtoP\x01ZSbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases/custom_rules\xa2\x02\x05BVCCC\xaa\x02*Buf.Validate.Conformance.Cases.CustomRules\xca\x02*Buf\\Validate\\Conformance\\Cases\\CustomRules\xe2\x026Buf\\Validate\\Conformance\\Cases\\CustomRules\\GPBMetadata\xea\x02.Buf::Validate::Conformance::Cases::CustomRulesb\x06proto3" var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes = make([]protoimpl.MessageInfo, 49) +var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes = make([]protoimpl.MessageInfo, 51) var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_goTypes = []any{ (Enum)(0), // 0: buf.validate.conformance.cases.custom_rules.Enum (*NoExpressions)(nil), // 1: buf.validate.conformance.cases.custom_rules.NoExpressions (*MessageExpressions)(nil), // 2: buf.validate.conformance.cases.custom_rules.MessageExpressions - (*MissingField)(nil), // 3: buf.validate.conformance.cases.custom_rules.MissingField - (*IncorrectType)(nil), // 4: buf.validate.conformance.cases.custom_rules.IncorrectType - (*DynRuntimeError)(nil), // 5: buf.validate.conformance.cases.custom_rules.DynRuntimeError - (*NowEqualsNow)(nil), // 6: buf.validate.conformance.cases.custom_rules.NowEqualsNow - (*FieldExpressionMultipleScalar)(nil), // 7: buf.validate.conformance.cases.custom_rules.FieldExpressionMultipleScalar - (*FieldExpressionNestedScalar)(nil), // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar - (*FieldExpressionOptionalScalar)(nil), // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionOptionalScalar - (*FieldExpressionScalar)(nil), // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionScalar - (*FieldExpressionEnum)(nil), // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum - (*FieldExpressionMessage)(nil), // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage - (*FieldExpressionMapInt32)(nil), // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32 - (*FieldExpressionMapInt64)(nil), // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64 - (*FieldExpressionMapUint32)(nil), // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32 - (*FieldExpressionMapUint64)(nil), // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64 - (*FieldExpressionMapBool)(nil), // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool - (*FieldExpressionMapString)(nil), // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString - (*FieldExpressionMapEnum)(nil), // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum - (*FieldExpressionMapMessage)(nil), // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage - (*FieldExpressionMapKeys)(nil), // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys - (*FieldExpressionMapScalarValues)(nil), // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues - (*FieldExpressionMapEnumValues)(nil), // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues - (*FieldExpressionMapMessageValues)(nil), // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues - (*FieldExpressionRepeatedScalar)(nil), // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalar - (*FieldExpressionRepeatedEnum)(nil), // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum - (*FieldExpressionRepeatedMessage)(nil), // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage - (*FieldExpressionRepeatedScalarItems)(nil), // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalarItems - (*FieldExpressionRepeatedEnumItems)(nil), // 29: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems - (*FieldExpressionRepeatedMessageItems)(nil), // 30: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems - (*NoExpressions_Nested)(nil), // 31: buf.validate.conformance.cases.custom_rules.NoExpressions.Nested - (*MessageExpressions_Nested)(nil), // 32: buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - (*FieldExpressionMessage_Msg)(nil), // 33: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg - nil, // 34: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry - nil, // 35: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry - nil, // 36: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry - nil, // 37: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry - nil, // 38: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry - nil, // 39: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry - nil, // 40: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry - nil, // 41: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry - (*FieldExpressionMapMessage_Msg)(nil), // 42: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg - nil, // 43: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry - nil, // 44: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry - nil, // 45: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry - nil, // 46: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry - (*FieldExpressionMapMessageValues_Msg)(nil), // 47: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg - (*FieldExpressionRepeatedMessage_Msg)(nil), // 48: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg - (*FieldExpressionRepeatedMessageItems_Msg)(nil), // 49: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg + (*MessageExpressionOnly)(nil), // 3: buf.validate.conformance.cases.custom_rules.MessageExpressionOnly + (*MissingField)(nil), // 4: buf.validate.conformance.cases.custom_rules.MissingField + (*IncorrectType)(nil), // 5: buf.validate.conformance.cases.custom_rules.IncorrectType + (*DynRuntimeError)(nil), // 6: buf.validate.conformance.cases.custom_rules.DynRuntimeError + (*NowEqualsNow)(nil), // 7: buf.validate.conformance.cases.custom_rules.NowEqualsNow + (*FieldExpressionOnly)(nil), // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionOnly + (*FieldExpressionMultipleScalar)(nil), // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMultipleScalar + (*FieldExpressionNestedScalar)(nil), // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar + (*FieldExpressionOptionalScalar)(nil), // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionOptionalScalar + (*FieldExpressionScalar)(nil), // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionScalar + (*FieldExpressionEnum)(nil), // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum + (*FieldExpressionMessage)(nil), // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage + (*FieldExpressionMapInt32)(nil), // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32 + (*FieldExpressionMapInt64)(nil), // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64 + (*FieldExpressionMapUint32)(nil), // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32 + (*FieldExpressionMapUint64)(nil), // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64 + (*FieldExpressionMapBool)(nil), // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool + (*FieldExpressionMapString)(nil), // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString + (*FieldExpressionMapEnum)(nil), // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum + (*FieldExpressionMapMessage)(nil), // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage + (*FieldExpressionMapKeys)(nil), // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys + (*FieldExpressionMapScalarValues)(nil), // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues + (*FieldExpressionMapEnumValues)(nil), // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues + (*FieldExpressionMapMessageValues)(nil), // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues + (*FieldExpressionRepeatedScalar)(nil), // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalar + (*FieldExpressionRepeatedEnum)(nil), // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum + (*FieldExpressionRepeatedMessage)(nil), // 29: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage + (*FieldExpressionRepeatedScalarItems)(nil), // 30: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedScalarItems + (*FieldExpressionRepeatedEnumItems)(nil), // 31: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems + (*FieldExpressionRepeatedMessageItems)(nil), // 32: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems + (*NoExpressions_Nested)(nil), // 33: buf.validate.conformance.cases.custom_rules.NoExpressions.Nested + (*MessageExpressions_Nested)(nil), // 34: buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + (*FieldExpressionMessage_Msg)(nil), // 35: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg + nil, // 36: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry + nil, // 37: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry + nil, // 38: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry + nil, // 39: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry + nil, // 40: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry + nil, // 41: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry + nil, // 42: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry + nil, // 43: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry + (*FieldExpressionMapMessage_Msg)(nil), // 44: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg + nil, // 45: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry + nil, // 46: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry + nil, // 47: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry + nil, // 48: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry + (*FieldExpressionMapMessageValues_Msg)(nil), // 49: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg + (*FieldExpressionRepeatedMessage_Msg)(nil), // 50: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg + (*FieldExpressionRepeatedMessageItems_Msg)(nil), // 51: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg } var file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_depIdxs = []int32{ 0, // 0: buf.validate.conformance.cases.custom_rules.NoExpressions.b:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 31, // 1: buf.validate.conformance.cases.custom_rules.NoExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.NoExpressions.Nested + 33, // 1: buf.validate.conformance.cases.custom_rules.NoExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.NoExpressions.Nested 0, // 2: buf.validate.conformance.cases.custom_rules.MessageExpressions.c:type_name -> buf.validate.conformance.cases.custom_rules.Enum 0, // 3: buf.validate.conformance.cases.custom_rules.MessageExpressions.d:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 32, // 4: buf.validate.conformance.cases.custom_rules.MessageExpressions.e:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - 32, // 5: buf.validate.conformance.cases.custom_rules.MessageExpressions.f:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested - 10, // 6: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar.nested:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionScalar + 34, // 4: buf.validate.conformance.cases.custom_rules.MessageExpressions.e:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + 34, // 5: buf.validate.conformance.cases.custom_rules.MessageExpressions.f:type_name -> buf.validate.conformance.cases.custom_rules.MessageExpressions.Nested + 12, // 6: buf.validate.conformance.cases.custom_rules.FieldExpressionNestedScalar.nested:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionScalar 0, // 7: buf.validate.conformance.cases.custom_rules.FieldExpressionEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 33, // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg - 34, // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry - 35, // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry - 36, // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry - 37, // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry - 38, // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry - 39, // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry - 40, // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry - 41, // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry - 43, // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry - 44, // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry - 45, // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry - 46, // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry + 35, // 8: buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMessage.Msg + 36, // 9: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt32.ValEntry + 37, // 10: buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapInt64.ValEntry + 38, // 11: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint32.ValEntry + 39, // 12: buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapUint64.ValEntry + 40, // 13: buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapBool.ValEntry + 41, // 14: buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapString.ValEntry + 42, // 15: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry + 43, // 16: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry + 45, // 17: buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapKeys.ValEntry + 46, // 18: buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapScalarValues.ValEntry + 47, // 19: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry + 48, // 20: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry 0, // 21: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnum.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 48, // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg + 50, // 22: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessage.Msg 0, // 23: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedEnumItems.val:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 49, // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg + 51, // 24: buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.val:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionRepeatedMessageItems.Msg 0, // 25: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnum.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 42, // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg + 44, // 26: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessage.Msg 0, // 27: buf.validate.conformance.cases.custom_rules.FieldExpressionMapEnumValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.Enum - 47, // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg + 49, // 28: buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.ValEntry.value:type_name -> buf.validate.conformance.cases.custom_rules.FieldExpressionMapMessageValues.Msg 29, // [29:29] is the sub-list for method output_type 29, // [29:29] is the sub-list for method input_type 29, // [29:29] is the sub-list for extension type_name @@ -2608,14 +2729,14 @@ func file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_init() if File_buf_validate_conformance_cases_custom_rules_custom_rules_proto != nil { return } - file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[8].OneofWrappers = []any{} + file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_msgTypes[10].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDesc), len(file_buf_validate_conformance_cases_custom_rules_custom_rules_proto_rawDesc)), NumEnums: 1, - NumMessages: 49, + NumMessages: 51, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/groups_editions.pb.go b/internal/gen/buf/validate/conformance/cases/groups_editions.pb.go new file mode 100644 index 00000000..b721dfa1 --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/groups_editions.pb.go @@ -0,0 +1,223 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/groups_editions.proto + +//go:build !protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type GroupDelimited struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Value *GroupDelimited_Value `protobuf:"group,1,opt,name=Value,json=value" json:"value,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupDelimited) Reset() { + *x = GroupDelimited{} + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupDelimited) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupDelimited) ProtoMessage() {} + +func (x *GroupDelimited) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupDelimited) GetValue() *GroupDelimited_Value { + if x != nil { + return x.Value + } + return nil +} + +func (x *GroupDelimited) SetValue(v *GroupDelimited_Value) { + x.Value = v +} + +func (x *GroupDelimited) HasValue() bool { + if x == nil { + return false + } + return x.Value != nil +} + +func (x *GroupDelimited) ClearValue() { + x.Value = nil +} + +type GroupDelimited_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *GroupDelimited_Value +} + +func (b0 GroupDelimited_builder) Build() *GroupDelimited { + m0 := &GroupDelimited{} + b, x := &b0, m0 + _, _ = b, x + x.Value = b.Value + return m0 +} + +type GroupDelimited_Value struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + X *bool `protobuf:"varint,1,opt,name=x" json:"x,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupDelimited_Value) Reset() { + *x = GroupDelimited_Value{} + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupDelimited_Value) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupDelimited_Value) ProtoMessage() {} + +func (x *GroupDelimited_Value) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupDelimited_Value) GetX() bool { + if x != nil && x.X != nil { + return *x.X + } + return false +} + +func (x *GroupDelimited_Value) SetX(v bool) { + x.X = &v +} + +func (x *GroupDelimited_Value) HasX() bool { + if x == nil { + return false + } + return x.X != nil +} + +func (x *GroupDelimited_Value) ClearX() { + x.X = nil +} + +type GroupDelimited_Value_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + X *bool +} + +func (b0 GroupDelimited_Value_builder) Build() *GroupDelimited_Value { + m0 := &GroupDelimited_Value{} + b, x := &b0, m0 + _, _ = b, x + x.X = b.X + return m0 +} + +var File_buf_validate_conformance_cases_groups_editions_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_groups_editions_proto_rawDesc = "" + + "\n" + + "4buf/validate/conformance/cases/groups_editions.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\"\x83\x01\n" + + "\x0eGroupDelimited\x12Q\n" + + "\x05value\x18\x01 \x01(\v24.buf.validate.conformance.cases.GroupDelimited.ValueB\x05\xaa\x01\x02(\x02R\x05value\x1a\x1e\n" + + "\x05Value\x12\x15\n" + + "\x01x\x18\x01 \x01(\bB\a\xbaH\x04j\x02\b\x01R\x01xB\x9d\x02\n" + + "\"com.buf.validate.conformance.casesB\x13GroupsEditionsProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\beditionsp\xe8\a" + +var file_buf_validate_conformance_cases_groups_editions_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_buf_validate_conformance_cases_groups_editions_proto_goTypes = []any{ + (*GroupDelimited)(nil), // 0: buf.validate.conformance.cases.GroupDelimited + (*GroupDelimited_Value)(nil), // 1: buf.validate.conformance.cases.GroupDelimited.Value +} +var file_buf_validate_conformance_cases_groups_editions_proto_depIdxs = []int32{ + 1, // 0: buf.validate.conformance.cases.GroupDelimited.value:type_name -> buf.validate.conformance.cases.GroupDelimited.Value + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_groups_editions_proto_init() } +func file_buf_validate_conformance_cases_groups_editions_proto_init() { + if File_buf_validate_conformance_cases_groups_editions_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_groups_editions_proto_rawDesc), len(file_buf_validate_conformance_cases_groups_editions_proto_rawDesc)), + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_groups_editions_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_groups_editions_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_groups_editions_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_groups_editions_proto = out.File + file_buf_validate_conformance_cases_groups_editions_proto_goTypes = nil + file_buf_validate_conformance_cases_groups_editions_proto_depIdxs = nil +} diff --git a/internal/gen/buf/validate/conformance/cases/groups_editions_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/groups_editions_protoopaque.pb.go new file mode 100644 index 00000000..bc68fb7a --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/groups_editions_protoopaque.pb.go @@ -0,0 +1,230 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/groups_editions.proto + +//go:build protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type GroupDelimited struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Value *GroupDelimited_Value `protobuf:"group,1,opt,name=Value,json=value"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupDelimited) Reset() { + *x = GroupDelimited{} + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupDelimited) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupDelimited) ProtoMessage() {} + +func (x *GroupDelimited) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupDelimited) GetValue() *GroupDelimited_Value { + if x != nil { + return x.xxx_hidden_Value + } + return nil +} + +func (x *GroupDelimited) SetValue(v *GroupDelimited_Value) { + x.xxx_hidden_Value = v +} + +func (x *GroupDelimited) HasValue() bool { + if x == nil { + return false + } + return x.xxx_hidden_Value != nil +} + +func (x *GroupDelimited) ClearValue() { + x.xxx_hidden_Value = nil +} + +type GroupDelimited_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *GroupDelimited_Value +} + +func (b0 GroupDelimited_builder) Build() *GroupDelimited { + m0 := &GroupDelimited{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Value = b.Value + return m0 +} + +type GroupDelimited_Value struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_X bool `protobuf:"varint,1,opt,name=x"` + XXX_raceDetectHookData protoimpl.RaceDetectHookData + XXX_presence [1]uint32 + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupDelimited_Value) Reset() { + *x = GroupDelimited_Value{} + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupDelimited_Value) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupDelimited_Value) ProtoMessage() {} + +func (x *GroupDelimited_Value) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_editions_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupDelimited_Value) GetX() bool { + if x != nil { + return x.xxx_hidden_X + } + return false +} + +func (x *GroupDelimited_Value) SetX(v bool) { + x.xxx_hidden_X = v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 0, 1) +} + +func (x *GroupDelimited_Value) HasX() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 0) +} + +func (x *GroupDelimited_Value) ClearX() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 0) + x.xxx_hidden_X = false +} + +type GroupDelimited_Value_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + X *bool +} + +func (b0 GroupDelimited_Value_builder) Build() *GroupDelimited_Value { + m0 := &GroupDelimited_Value{} + b, x := &b0, m0 + _, _ = b, x + if b.X != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 0, 1) + x.xxx_hidden_X = *b.X + } + return m0 +} + +var File_buf_validate_conformance_cases_groups_editions_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_groups_editions_proto_rawDesc = "" + + "\n" + + "4buf/validate/conformance/cases/groups_editions.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\"\x83\x01\n" + + "\x0eGroupDelimited\x12Q\n" + + "\x05value\x18\x01 \x01(\v24.buf.validate.conformance.cases.GroupDelimited.ValueB\x05\xaa\x01\x02(\x02R\x05value\x1a\x1e\n" + + "\x05Value\x12\x15\n" + + "\x01x\x18\x01 \x01(\bB\a\xbaH\x04j\x02\b\x01R\x01xB\x9d\x02\n" + + "\"com.buf.validate.conformance.casesB\x13GroupsEditionsProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\beditionsp\xe8\a" + +var file_buf_validate_conformance_cases_groups_editions_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_buf_validate_conformance_cases_groups_editions_proto_goTypes = []any{ + (*GroupDelimited)(nil), // 0: buf.validate.conformance.cases.GroupDelimited + (*GroupDelimited_Value)(nil), // 1: buf.validate.conformance.cases.GroupDelimited.Value +} +var file_buf_validate_conformance_cases_groups_editions_proto_depIdxs = []int32{ + 1, // 0: buf.validate.conformance.cases.GroupDelimited.value:type_name -> buf.validate.conformance.cases.GroupDelimited.Value + 1, // [1:1] is the sub-list for method output_type + 1, // [1:1] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_groups_editions_proto_init() } +func file_buf_validate_conformance_cases_groups_editions_proto_init() { + if File_buf_validate_conformance_cases_groups_editions_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_groups_editions_proto_rawDesc), len(file_buf_validate_conformance_cases_groups_editions_proto_rawDesc)), + NumEnums: 0, + NumMessages: 2, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_groups_editions_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_groups_editions_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_groups_editions_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_groups_editions_proto = out.File + file_buf_validate_conformance_cases_groups_editions_proto_goTypes = nil + file_buf_validate_conformance_cases_groups_editions_proto_depIdxs = nil +} diff --git a/internal/gen/buf/validate/conformance/cases/groups_proto2.pb.go b/internal/gen/buf/validate/conformance/cases/groups_proto2.pb.go new file mode 100644 index 00000000..a1e09d9e --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/groups_proto2.pb.go @@ -0,0 +1,674 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/groups_proto2.proto + +//go:build !protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type GroupOptional struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Optional *GroupOptional_Optional `protobuf:"group,1,opt,name=Optional,json=optional" json:"optional,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupOptional) Reset() { + *x = GroupOptional{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupOptional) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupOptional) ProtoMessage() {} + +func (x *GroupOptional) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupOptional) GetOptional() *GroupOptional_Optional { + if x != nil { + return x.Optional + } + return nil +} + +func (x *GroupOptional) SetOptional(v *GroupOptional_Optional) { + x.Optional = v +} + +func (x *GroupOptional) HasOptional() bool { + if x == nil { + return false + } + return x.Optional != nil +} + +func (x *GroupOptional) ClearOptional() { + x.Optional = nil +} + +type GroupOptional_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Optional *GroupOptional_Optional +} + +func (b0 GroupOptional_builder) Build() *GroupOptional { + m0 := &GroupOptional{} + b, x := &b0, m0 + _, _ = b, x + x.Optional = b.Optional + return m0 +} + +type GroupRepeated struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Repeated []*GroupRepeated_Repeated `protobuf:"group,1,rep,name=Repeated,json=repeated" json:"repeated,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRepeated) Reset() { + *x = GroupRepeated{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRepeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRepeated) ProtoMessage() {} + +func (x *GroupRepeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRepeated) GetRepeated() []*GroupRepeated_Repeated { + if x != nil { + return x.Repeated + } + return nil +} + +func (x *GroupRepeated) SetRepeated(v []*GroupRepeated_Repeated) { + x.Repeated = v +} + +type GroupRepeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Repeated []*GroupRepeated_Repeated +} + +func (b0 GroupRepeated_builder) Build() *GroupRepeated { + m0 := &GroupRepeated{} + b, x := &b0, m0 + _, _ = b, x + x.Repeated = b.Repeated + return m0 +} + +type GroupRequired struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Required *GroupRequired_Required `protobuf:"group,1,req,name=Required,json=required" json:"required,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRequired) Reset() { + *x = GroupRequired{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRequired) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRequired) ProtoMessage() {} + +func (x *GroupRequired) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRequired) GetRequired() *GroupRequired_Required { + if x != nil { + return x.Required + } + return nil +} + +func (x *GroupRequired) SetRequired(v *GroupRequired_Required) { + x.Required = v +} + +func (x *GroupRequired) HasRequired() bool { + if x == nil { + return false + } + return x.Required != nil +} + +func (x *GroupRequired) ClearRequired() { + x.Required = nil +} + +type GroupRequired_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Required *GroupRequired_Required +} + +func (b0 GroupRequired_builder) Build() *GroupRequired { + m0 := &GroupRequired{} + b, x := &b0, m0 + _, _ = b, x + x.Required = b.Required + return m0 +} + +type GroupCustom struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Custom *GroupCustom_Custom `protobuf:"group,1,opt,name=Custom,json=custom" json:"custom,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupCustom) Reset() { + *x = GroupCustom{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupCustom) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupCustom) ProtoMessage() {} + +func (x *GroupCustom) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[3] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupCustom) GetCustom() *GroupCustom_Custom { + if x != nil { + return x.Custom + } + return nil +} + +func (x *GroupCustom) SetCustom(v *GroupCustom_Custom) { + x.Custom = v +} + +func (x *GroupCustom) HasCustom() bool { + if x == nil { + return false + } + return x.Custom != nil +} + +func (x *GroupCustom) ClearCustom() { + x.Custom = nil +} + +type GroupCustom_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Custom *GroupCustom_Custom +} + +func (b0 GroupCustom_builder) Build() *GroupCustom { + m0 := &GroupCustom{} + b, x := &b0, m0 + _, _ = b, x + x.Custom = b.Custom + return m0 +} + +type GroupOptional_Optional struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Value *string `protobuf:"bytes,1,opt,name=value" json:"value,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupOptional_Optional) Reset() { + *x = GroupOptional_Optional{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupOptional_Optional) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupOptional_Optional) ProtoMessage() {} + +func (x *GroupOptional_Optional) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[4] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupOptional_Optional) GetValue() string { + if x != nil && x.Value != nil { + return *x.Value + } + return "" +} + +func (x *GroupOptional_Optional) SetValue(v string) { + x.Value = &v +} + +func (x *GroupOptional_Optional) HasValue() bool { + if x == nil { + return false + } + return x.Value != nil +} + +func (x *GroupOptional_Optional) ClearValue() { + x.Value = nil +} + +type GroupOptional_Optional_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *string +} + +func (b0 GroupOptional_Optional_builder) Build() *GroupOptional_Optional { + m0 := &GroupOptional_Optional{} + b, x := &b0, m0 + _, _ = b, x + x.Value = b.Value + return m0 +} + +type GroupRepeated_Repeated struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Value *int32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRepeated_Repeated) Reset() { + *x = GroupRepeated_Repeated{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRepeated_Repeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRepeated_Repeated) ProtoMessage() {} + +func (x *GroupRepeated_Repeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[5] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRepeated_Repeated) GetValue() int32 { + if x != nil && x.Value != nil { + return *x.Value + } + return 0 +} + +func (x *GroupRepeated_Repeated) SetValue(v int32) { + x.Value = &v +} + +func (x *GroupRepeated_Repeated) HasValue() bool { + if x == nil { + return false + } + return x.Value != nil +} + +func (x *GroupRepeated_Repeated) ClearValue() { + x.Value = nil +} + +type GroupRepeated_Repeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *int32 +} + +func (b0 GroupRepeated_Repeated_builder) Build() *GroupRepeated_Repeated { + m0 := &GroupRepeated_Repeated{} + b, x := &b0, m0 + _, _ = b, x + x.Value = b.Value + return m0 +} + +type GroupRequired_Required struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Value *bool `protobuf:"varint,1,opt,name=value" json:"value,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRequired_Required) Reset() { + *x = GroupRequired_Required{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRequired_Required) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRequired_Required) ProtoMessage() {} + +func (x *GroupRequired_Required) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[6] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRequired_Required) GetValue() bool { + if x != nil && x.Value != nil { + return *x.Value + } + return false +} + +func (x *GroupRequired_Required) SetValue(v bool) { + x.Value = &v +} + +func (x *GroupRequired_Required) HasValue() bool { + if x == nil { + return false + } + return x.Value != nil +} + +func (x *GroupRequired_Required) ClearValue() { + x.Value = nil +} + +type GroupRequired_Required_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *bool +} + +func (b0 GroupRequired_Required_builder) Build() *GroupRequired_Required { + m0 := &GroupRequired_Required{} + b, x := &b0, m0 + _, _ = b, x + x.Value = b.Value + return m0 +} + +type GroupCustom_Custom struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Value *int32 `protobuf:"varint,1,opt,name=value" json:"value,omitempty"` + Div *int32 `protobuf:"varint,2,opt,name=div" json:"div,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupCustom_Custom) Reset() { + *x = GroupCustom_Custom{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupCustom_Custom) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupCustom_Custom) ProtoMessage() {} + +func (x *GroupCustom_Custom) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[7] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupCustom_Custom) GetValue() int32 { + if x != nil && x.Value != nil { + return *x.Value + } + return 0 +} + +func (x *GroupCustom_Custom) GetDiv() int32 { + if x != nil && x.Div != nil { + return *x.Div + } + return 0 +} + +func (x *GroupCustom_Custom) SetValue(v int32) { + x.Value = &v +} + +func (x *GroupCustom_Custom) SetDiv(v int32) { + x.Div = &v +} + +func (x *GroupCustom_Custom) HasValue() bool { + if x == nil { + return false + } + return x.Value != nil +} + +func (x *GroupCustom_Custom) HasDiv() bool { + if x == nil { + return false + } + return x.Div != nil +} + +func (x *GroupCustom_Custom) ClearValue() { + x.Value = nil +} + +func (x *GroupCustom_Custom) ClearDiv() { + x.Div = nil +} + +type GroupCustom_Custom_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *int32 + Div *int32 +} + +func (b0 GroupCustom_Custom_builder) Build() *GroupCustom_Custom { + m0 := &GroupCustom_Custom{} + b, x := &b0, m0 + _, _ = b, x + x.Value = b.Value + x.Div = b.Div + return m0 +} + +var File_buf_validate_conformance_cases_groups_proto2_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc = "" + + "\n" + + "2buf/validate/conformance/cases/groups_proto2.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\"\x91\x01\n" + + "\rGroupOptional\x12R\n" + + "\boptional\x18\x01 \x01(\n" + + "26.buf.validate.conformance.cases.GroupOptional.OptionalR\boptional\x1a,\n" + + "\bOptional\x12 \n" + + "\x05value\x18\x01 \x01(\tB\n" + + "\xbaH\ar\x05\n" + + "\x03fooR\x05value\"\x8e\x01\n" + + "\rGroupRepeated\x12R\n" + + "\brepeated\x18\x01 \x03(\n" + + "26.buf.validate.conformance.cases.GroupRepeated.RepeatedR\brepeated\x1a)\n" + + "\bRepeated\x12\x1d\n" + + "\x05value\x18\x01 \x01(\x05B\a\xbaH\x04\x1a\x02 \x00R\x05value\"\x8e\x01\n" + + "\rGroupRequired\x12R\n" + + "\brequired\x18\x01 \x02(\n" + + "26.buf.validate.conformance.cases.GroupRequired.RequiredR\brequired\x1a)\n" + + "\bRequired\x12\x1d\n" + + "\x05value\x18\x01 \x01(\bB\a\xbaH\x04j\x02\b\x01R\x05value\"\xe1\x01\n" + + "\vGroupCustom\x12J\n" + + "\x06custom\x18\x01 \x01(\n" + + "22.buf.validate.conformance.cases.GroupCustom.CustomR\x06custom\x1a\x85\x01\n" + + "\x06Custom\x12\x14\n" + + "\x05value\x18\x01 \x01(\x05R\x05value\x12\x10\n" + + "\x03div\x18\x02 \x01(\x05R\x03div:S\xbaHP\x1aN\n" + + "\x10group.custom.div\x12\x1evalue must be divisible by div\x1a\x1athis.value % this.div == 0B\x9b\x02\n" + + "\"com.buf.validate.conformance.casesB\x11GroupsProto2ProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Cases" + +var file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_buf_validate_conformance_cases_groups_proto2_proto_goTypes = []any{ + (*GroupOptional)(nil), // 0: buf.validate.conformance.cases.GroupOptional + (*GroupRepeated)(nil), // 1: buf.validate.conformance.cases.GroupRepeated + (*GroupRequired)(nil), // 2: buf.validate.conformance.cases.GroupRequired + (*GroupCustom)(nil), // 3: buf.validate.conformance.cases.GroupCustom + (*GroupOptional_Optional)(nil), // 4: buf.validate.conformance.cases.GroupOptional.Optional + (*GroupRepeated_Repeated)(nil), // 5: buf.validate.conformance.cases.GroupRepeated.Repeated + (*GroupRequired_Required)(nil), // 6: buf.validate.conformance.cases.GroupRequired.Required + (*GroupCustom_Custom)(nil), // 7: buf.validate.conformance.cases.GroupCustom.Custom +} +var file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs = []int32{ + 4, // 0: buf.validate.conformance.cases.GroupOptional.optional:type_name -> buf.validate.conformance.cases.GroupOptional.Optional + 5, // 1: buf.validate.conformance.cases.GroupRepeated.repeated:type_name -> buf.validate.conformance.cases.GroupRepeated.Repeated + 6, // 2: buf.validate.conformance.cases.GroupRequired.required:type_name -> buf.validate.conformance.cases.GroupRequired.Required + 7, // 3: buf.validate.conformance.cases.GroupCustom.custom:type_name -> buf.validate.conformance.cases.GroupCustom.Custom + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_groups_proto2_proto_init() } +func file_buf_validate_conformance_cases_groups_proto2_proto_init() { + if File_buf_validate_conformance_cases_groups_proto2_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc), len(file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc)), + NumEnums: 0, + NumMessages: 8, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_groups_proto2_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_groups_proto2_proto = out.File + file_buf_validate_conformance_cases_groups_proto2_proto_goTypes = nil + file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs = nil +} diff --git a/internal/gen/buf/validate/conformance/cases/groups_proto2_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/groups_proto2_protoopaque.pb.go new file mode 100644 index 00000000..6aadb24f --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/groups_proto2_protoopaque.pb.go @@ -0,0 +1,712 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/groups_proto2.proto + +//go:build protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type GroupOptional struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Optional *GroupOptional_Optional `protobuf:"group,1,opt,name=Optional,json=optional"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupOptional) Reset() { + *x = GroupOptional{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupOptional) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupOptional) ProtoMessage() {} + +func (x *GroupOptional) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupOptional) GetOptional() *GroupOptional_Optional { + if x != nil { + return x.xxx_hidden_Optional + } + return nil +} + +func (x *GroupOptional) SetOptional(v *GroupOptional_Optional) { + x.xxx_hidden_Optional = v +} + +func (x *GroupOptional) HasOptional() bool { + if x == nil { + return false + } + return x.xxx_hidden_Optional != nil +} + +func (x *GroupOptional) ClearOptional() { + x.xxx_hidden_Optional = nil +} + +type GroupOptional_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Optional *GroupOptional_Optional +} + +func (b0 GroupOptional_builder) Build() *GroupOptional { + m0 := &GroupOptional{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Optional = b.Optional + return m0 +} + +type GroupRepeated struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Repeated *[]*GroupRepeated_Repeated `protobuf:"group,1,rep,name=Repeated,json=repeated"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRepeated) Reset() { + *x = GroupRepeated{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRepeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRepeated) ProtoMessage() {} + +func (x *GroupRepeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRepeated) GetRepeated() []*GroupRepeated_Repeated { + if x != nil { + if x.xxx_hidden_Repeated != nil { + return *x.xxx_hidden_Repeated + } + } + return nil +} + +func (x *GroupRepeated) SetRepeated(v []*GroupRepeated_Repeated) { + x.xxx_hidden_Repeated = &v +} + +type GroupRepeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Repeated []*GroupRepeated_Repeated +} + +func (b0 GroupRepeated_builder) Build() *GroupRepeated { + m0 := &GroupRepeated{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Repeated = &b.Repeated + return m0 +} + +type GroupRequired struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Required *GroupRequired_Required `protobuf:"group,1,req,name=Required,json=required"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRequired) Reset() { + *x = GroupRequired{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRequired) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRequired) ProtoMessage() {} + +func (x *GroupRequired) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRequired) GetRequired() *GroupRequired_Required { + if x != nil { + return x.xxx_hidden_Required + } + return nil +} + +func (x *GroupRequired) SetRequired(v *GroupRequired_Required) { + x.xxx_hidden_Required = v +} + +func (x *GroupRequired) HasRequired() bool { + if x == nil { + return false + } + return x.xxx_hidden_Required != nil +} + +func (x *GroupRequired) ClearRequired() { + x.xxx_hidden_Required = nil +} + +type GroupRequired_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Required *GroupRequired_Required +} + +func (b0 GroupRequired_builder) Build() *GroupRequired { + m0 := &GroupRequired{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Required = b.Required + return m0 +} + +type GroupCustom struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Custom *GroupCustom_Custom `protobuf:"group,1,opt,name=Custom,json=custom"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupCustom) Reset() { + *x = GroupCustom{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupCustom) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupCustom) ProtoMessage() {} + +func (x *GroupCustom) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[3] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupCustom) GetCustom() *GroupCustom_Custom { + if x != nil { + return x.xxx_hidden_Custom + } + return nil +} + +func (x *GroupCustom) SetCustom(v *GroupCustom_Custom) { + x.xxx_hidden_Custom = v +} + +func (x *GroupCustom) HasCustom() bool { + if x == nil { + return false + } + return x.xxx_hidden_Custom != nil +} + +func (x *GroupCustom) ClearCustom() { + x.xxx_hidden_Custom = nil +} + +type GroupCustom_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Custom *GroupCustom_Custom +} + +func (b0 GroupCustom_builder) Build() *GroupCustom { + m0 := &GroupCustom{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Custom = b.Custom + return m0 +} + +type GroupOptional_Optional struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Value *string `protobuf:"bytes,1,opt,name=value"` + XXX_raceDetectHookData protoimpl.RaceDetectHookData + XXX_presence [1]uint32 + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupOptional_Optional) Reset() { + *x = GroupOptional_Optional{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupOptional_Optional) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupOptional_Optional) ProtoMessage() {} + +func (x *GroupOptional_Optional) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[4] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupOptional_Optional) GetValue() string { + if x != nil { + if x.xxx_hidden_Value != nil { + return *x.xxx_hidden_Value + } + return "" + } + return "" +} + +func (x *GroupOptional_Optional) SetValue(v string) { + x.xxx_hidden_Value = &v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 0, 1) +} + +func (x *GroupOptional_Optional) HasValue() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 0) +} + +func (x *GroupOptional_Optional) ClearValue() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 0) + x.xxx_hidden_Value = nil +} + +type GroupOptional_Optional_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *string +} + +func (b0 GroupOptional_Optional_builder) Build() *GroupOptional_Optional { + m0 := &GroupOptional_Optional{} + b, x := &b0, m0 + _, _ = b, x + if b.Value != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 0, 1) + x.xxx_hidden_Value = b.Value + } + return m0 +} + +type GroupRepeated_Repeated struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Value int32 `protobuf:"varint,1,opt,name=value"` + XXX_raceDetectHookData protoimpl.RaceDetectHookData + XXX_presence [1]uint32 + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRepeated_Repeated) Reset() { + *x = GroupRepeated_Repeated{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRepeated_Repeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRepeated_Repeated) ProtoMessage() {} + +func (x *GroupRepeated_Repeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[5] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRepeated_Repeated) GetValue() int32 { + if x != nil { + return x.xxx_hidden_Value + } + return 0 +} + +func (x *GroupRepeated_Repeated) SetValue(v int32) { + x.xxx_hidden_Value = v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 0, 1) +} + +func (x *GroupRepeated_Repeated) HasValue() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 0) +} + +func (x *GroupRepeated_Repeated) ClearValue() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 0) + x.xxx_hidden_Value = 0 +} + +type GroupRepeated_Repeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *int32 +} + +func (b0 GroupRepeated_Repeated_builder) Build() *GroupRepeated_Repeated { + m0 := &GroupRepeated_Repeated{} + b, x := &b0, m0 + _, _ = b, x + if b.Value != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 0, 1) + x.xxx_hidden_Value = *b.Value + } + return m0 +} + +type GroupRequired_Required struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Value bool `protobuf:"varint,1,opt,name=value"` + XXX_raceDetectHookData protoimpl.RaceDetectHookData + XXX_presence [1]uint32 + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupRequired_Required) Reset() { + *x = GroupRequired_Required{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupRequired_Required) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupRequired_Required) ProtoMessage() {} + +func (x *GroupRequired_Required) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[6] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupRequired_Required) GetValue() bool { + if x != nil { + return x.xxx_hidden_Value + } + return false +} + +func (x *GroupRequired_Required) SetValue(v bool) { + x.xxx_hidden_Value = v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 0, 1) +} + +func (x *GroupRequired_Required) HasValue() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 0) +} + +func (x *GroupRequired_Required) ClearValue() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 0) + x.xxx_hidden_Value = false +} + +type GroupRequired_Required_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *bool +} + +func (b0 GroupRequired_Required_builder) Build() *GroupRequired_Required { + m0 := &GroupRequired_Required{} + b, x := &b0, m0 + _, _ = b, x + if b.Value != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 0, 1) + x.xxx_hidden_Value = *b.Value + } + return m0 +} + +type GroupCustom_Custom struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Value int32 `protobuf:"varint,1,opt,name=value"` + xxx_hidden_Div int32 `protobuf:"varint,2,opt,name=div"` + XXX_raceDetectHookData protoimpl.RaceDetectHookData + XXX_presence [1]uint32 + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *GroupCustom_Custom) Reset() { + *x = GroupCustom_Custom{} + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *GroupCustom_Custom) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GroupCustom_Custom) ProtoMessage() {} + +func (x *GroupCustom_Custom) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes[7] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *GroupCustom_Custom) GetValue() int32 { + if x != nil { + return x.xxx_hidden_Value + } + return 0 +} + +func (x *GroupCustom_Custom) GetDiv() int32 { + if x != nil { + return x.xxx_hidden_Div + } + return 0 +} + +func (x *GroupCustom_Custom) SetValue(v int32) { + x.xxx_hidden_Value = v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 0, 2) +} + +func (x *GroupCustom_Custom) SetDiv(v int32) { + x.xxx_hidden_Div = v + protoimpl.X.SetPresent(&(x.XXX_presence[0]), 1, 2) +} + +func (x *GroupCustom_Custom) HasValue() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 0) +} + +func (x *GroupCustom_Custom) HasDiv() bool { + if x == nil { + return false + } + return protoimpl.X.Present(&(x.XXX_presence[0]), 1) +} + +func (x *GroupCustom_Custom) ClearValue() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 0) + x.xxx_hidden_Value = 0 +} + +func (x *GroupCustom_Custom) ClearDiv() { + protoimpl.X.ClearPresent(&(x.XXX_presence[0]), 1) + x.xxx_hidden_Div = 0 +} + +type GroupCustom_Custom_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Value *int32 + Div *int32 +} + +func (b0 GroupCustom_Custom_builder) Build() *GroupCustom_Custom { + m0 := &GroupCustom_Custom{} + b, x := &b0, m0 + _, _ = b, x + if b.Value != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 0, 2) + x.xxx_hidden_Value = *b.Value + } + if b.Div != nil { + protoimpl.X.SetPresentNonAtomic(&(x.XXX_presence[0]), 1, 2) + x.xxx_hidden_Div = *b.Div + } + return m0 +} + +var File_buf_validate_conformance_cases_groups_proto2_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc = "" + + "\n" + + "2buf/validate/conformance/cases/groups_proto2.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\"\x91\x01\n" + + "\rGroupOptional\x12R\n" + + "\boptional\x18\x01 \x01(\n" + + "26.buf.validate.conformance.cases.GroupOptional.OptionalR\boptional\x1a,\n" + + "\bOptional\x12 \n" + + "\x05value\x18\x01 \x01(\tB\n" + + "\xbaH\ar\x05\n" + + "\x03fooR\x05value\"\x8e\x01\n" + + "\rGroupRepeated\x12R\n" + + "\brepeated\x18\x01 \x03(\n" + + "26.buf.validate.conformance.cases.GroupRepeated.RepeatedR\brepeated\x1a)\n" + + "\bRepeated\x12\x1d\n" + + "\x05value\x18\x01 \x01(\x05B\a\xbaH\x04\x1a\x02 \x00R\x05value\"\x8e\x01\n" + + "\rGroupRequired\x12R\n" + + "\brequired\x18\x01 \x02(\n" + + "26.buf.validate.conformance.cases.GroupRequired.RequiredR\brequired\x1a)\n" + + "\bRequired\x12\x1d\n" + + "\x05value\x18\x01 \x01(\bB\a\xbaH\x04j\x02\b\x01R\x05value\"\xe1\x01\n" + + "\vGroupCustom\x12J\n" + + "\x06custom\x18\x01 \x01(\n" + + "22.buf.validate.conformance.cases.GroupCustom.CustomR\x06custom\x1a\x85\x01\n" + + "\x06Custom\x12\x14\n" + + "\x05value\x18\x01 \x01(\x05R\x05value\x12\x10\n" + + "\x03div\x18\x02 \x01(\x05R\x03div:S\xbaHP\x1aN\n" + + "\x10group.custom.div\x12\x1evalue must be divisible by div\x1a\x1athis.value % this.div == 0B\x9b\x02\n" + + "\"com.buf.validate.conformance.casesB\x11GroupsProto2ProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Cases" + +var file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_buf_validate_conformance_cases_groups_proto2_proto_goTypes = []any{ + (*GroupOptional)(nil), // 0: buf.validate.conformance.cases.GroupOptional + (*GroupRepeated)(nil), // 1: buf.validate.conformance.cases.GroupRepeated + (*GroupRequired)(nil), // 2: buf.validate.conformance.cases.GroupRequired + (*GroupCustom)(nil), // 3: buf.validate.conformance.cases.GroupCustom + (*GroupOptional_Optional)(nil), // 4: buf.validate.conformance.cases.GroupOptional.Optional + (*GroupRepeated_Repeated)(nil), // 5: buf.validate.conformance.cases.GroupRepeated.Repeated + (*GroupRequired_Required)(nil), // 6: buf.validate.conformance.cases.GroupRequired.Required + (*GroupCustom_Custom)(nil), // 7: buf.validate.conformance.cases.GroupCustom.Custom +} +var file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs = []int32{ + 4, // 0: buf.validate.conformance.cases.GroupOptional.optional:type_name -> buf.validate.conformance.cases.GroupOptional.Optional + 5, // 1: buf.validate.conformance.cases.GroupRepeated.repeated:type_name -> buf.validate.conformance.cases.GroupRepeated.Repeated + 6, // 2: buf.validate.conformance.cases.GroupRequired.required:type_name -> buf.validate.conformance.cases.GroupRequired.Required + 7, // 3: buf.validate.conformance.cases.GroupCustom.custom:type_name -> buf.validate.conformance.cases.GroupCustom.Custom + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_groups_proto2_proto_init() } +func file_buf_validate_conformance_cases_groups_proto2_proto_init() { + if File_buf_validate_conformance_cases_groups_proto2_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc), len(file_buf_validate_conformance_cases_groups_proto2_proto_rawDesc)), + NumEnums: 0, + NumMessages: 8, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_groups_proto2_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_groups_proto2_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_groups_proto2_proto = out.File + file_buf_validate_conformance_cases_groups_proto2_proto_goTypes = nil + file_buf_validate_conformance_cases_groups_proto2_proto_depIdxs = nil +} diff --git a/internal/gen/buf/validate/conformance/cases/required_field_proto3.pb.go b/internal/gen/buf/validate/conformance/cases/required_field_proto3.pb.go index 29d14d49..f077c2c4 100644 --- a/internal/gen/buf/validate/conformance/cases/required_field_proto3.pb.go +++ b/internal/gen/buf/validate/conformance/cases/required_field_proto3.pb.go @@ -1170,6 +1170,177 @@ func (b0 RequiredProto3RepeatedItem_builder) Build() *RequiredProto3RepeatedItem return m0 } +type RequiredImplicitProto3Scalar struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Scalar) Reset() { + *x = RequiredImplicitProto3Scalar{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Scalar) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Scalar) ProtoMessage() {} + +func (x *RequiredImplicitProto3Scalar) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Scalar) GetVal() string { + if x != nil { + return x.Val + } + return "" +} + +func (x *RequiredImplicitProto3Scalar) SetVal(v string) { + x.Val = v +} + +type RequiredImplicitProto3Scalar_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 RequiredImplicitProto3Scalar_builder) Build() *RequiredImplicitProto3Scalar { + m0 := &RequiredImplicitProto3Scalar{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type RequiredImplicitProto3Repeated struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val []string `protobuf:"bytes,1,rep,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Repeated) Reset() { + *x = RequiredImplicitProto3Repeated{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Repeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Repeated) ProtoMessage() {} + +func (x *RequiredImplicitProto3Repeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Repeated) GetVal() []string { + if x != nil { + return x.Val + } + return nil +} + +func (x *RequiredImplicitProto3Repeated) SetVal(v []string) { + x.Val = v +} + +type RequiredImplicitProto3Repeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []string +} + +func (b0 RequiredImplicitProto3Repeated_builder) Build() *RequiredImplicitProto3Repeated { + m0 := &RequiredImplicitProto3Repeated{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type RequiredImplicitProto3Map struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val map[string]string `protobuf:"bytes,1,rep,name=val,proto3" json:"val,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Map) Reset() { + *x = RequiredImplicitProto3Map{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Map) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Map) ProtoMessage() {} + +func (x *RequiredImplicitProto3Map) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[17] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Map) GetVal() map[string]string { + if x != nil { + return x.Val + } + return nil +} + +func (x *RequiredImplicitProto3Map) SetVal(v map[string]string) { + x.Val = v +} + +type RequiredImplicitProto3Map_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val map[string]string +} + +func (b0 RequiredImplicitProto3Map_builder) Build() *RequiredImplicitProto3Map { + m0 := &RequiredImplicitProto3Map{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + type RequiredProto3Message_Msg struct { state protoimpl.MessageState `protogen:"hybrid.v1"` Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` @@ -1179,7 +1350,7 @@ type RequiredProto3Message_Msg struct { func (x *RequiredProto3Message_Msg) Reset() { *x = RequiredProto3Message_Msg{} - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1191,7 +1362,7 @@ func (x *RequiredProto3Message_Msg) String() string { func (*RequiredProto3Message_Msg) ProtoMessage() {} func (x *RequiredProto3Message_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[18] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1236,7 +1407,7 @@ type RequiredProto3MessageIgnoreAlways_Msg struct { func (x *RequiredProto3MessageIgnoreAlways_Msg) Reset() { *x = RequiredProto3MessageIgnoreAlways_Msg{} - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1248,7 +1419,7 @@ func (x *RequiredProto3MessageIgnoreAlways_Msg) String() string { func (*RequiredProto3MessageIgnoreAlways_Msg) ProtoMessage() {} func (x *RequiredProto3MessageIgnoreAlways_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1340,10 +1511,21 @@ const file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc = "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\";\n" + "\x1aRequiredProto3RepeatedItem\x12\x1d\n" + - "\x03val\x18\x01 \x03(\tB\v\xbaH\b\x92\x01\x05\"\x03\xc8\x01\x01R\x03valB\xa2\x02\n" + + "\x03val\x18\x01 \x03(\tB\v\xbaH\b\x92\x01\x05\"\x03\xc8\x01\x01R\x03val\">\n" + + "\x1cRequiredImplicitProto3Scalar\x12\x1e\n" + + "\x03val\x18\x01 \x01(\tB\f\xbaH\t\xc8\x01\x01r\x04\x10\x01\x18\x02R\x03val\"A\n" + + "\x1eRequiredImplicitProto3Repeated\x12\x1f\n" + + "\x03val\x18\x01 \x03(\tB\r\xbaH\n" + + "\xc8\x01\x01\x92\x01\x04\b\x01\x10\x02R\x03val\"\xb8\x01\n" + + "\x19RequiredImplicitProto3Map\x12c\n" + + "\x03val\x18\x01 \x03(\v2B.buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntryB\r\xbaH\n" + + "\xc8\x01\x01\x9a\x01\x04\b\x01\x10\x02R\x03val\x1a6\n" + + "\bValEntry\x12\x10\n" + + "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\xa2\x02\n" + "\"com.buf.validate.conformance.casesB\x18RequiredFieldProto3ProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes = make([]protoimpl.MessageInfo, 25) var file_buf_validate_conformance_cases_required_field_proto3_proto_goTypes = []any{ (*RequiredProto3Scalar)(nil), // 0: buf.validate.conformance.cases.RequiredProto3Scalar (*RequiredProto3ScalarIgnoreAlways)(nil), // 1: buf.validate.conformance.cases.RequiredProto3ScalarIgnoreAlways @@ -1360,25 +1542,30 @@ var file_buf_validate_conformance_cases_required_field_proto3_proto_goTypes = [] (*RequiredProto3MapKey)(nil), // 12: buf.validate.conformance.cases.RequiredProto3MapKey (*RequiredProto3MapValue)(nil), // 13: buf.validate.conformance.cases.RequiredProto3MapValue (*RequiredProto3RepeatedItem)(nil), // 14: buf.validate.conformance.cases.RequiredProto3RepeatedItem - (*RequiredProto3Message_Msg)(nil), // 15: buf.validate.conformance.cases.RequiredProto3Message.Msg - (*RequiredProto3MessageIgnoreAlways_Msg)(nil), // 16: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg - nil, // 17: buf.validate.conformance.cases.RequiredProto3Map.ValEntry - nil, // 18: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry - nil, // 19: buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry - nil, // 20: buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + (*RequiredImplicitProto3Scalar)(nil), // 15: buf.validate.conformance.cases.RequiredImplicitProto3Scalar + (*RequiredImplicitProto3Repeated)(nil), // 16: buf.validate.conformance.cases.RequiredImplicitProto3Repeated + (*RequiredImplicitProto3Map)(nil), // 17: buf.validate.conformance.cases.RequiredImplicitProto3Map + (*RequiredProto3Message_Msg)(nil), // 18: buf.validate.conformance.cases.RequiredProto3Message.Msg + (*RequiredProto3MessageIgnoreAlways_Msg)(nil), // 19: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg + nil, // 20: buf.validate.conformance.cases.RequiredProto3Map.ValEntry + nil, // 21: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry + nil, // 22: buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry + nil, // 23: buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + nil, // 24: buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntry } var file_buf_validate_conformance_cases_required_field_proto3_proto_depIdxs = []int32{ - 15, // 0: buf.validate.conformance.cases.RequiredProto3Message.val:type_name -> buf.validate.conformance.cases.RequiredProto3Message.Msg - 16, // 1: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg - 17, // 2: buf.validate.conformance.cases.RequiredProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredProto3Map.ValEntry - 18, // 3: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry - 19, // 4: buf.validate.conformance.cases.RequiredProto3MapKey.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry - 20, // 5: buf.validate.conformance.cases.RequiredProto3MapValue.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry - 6, // [6:6] is the sub-list for method output_type - 6, // [6:6] is the sub-list for method input_type - 6, // [6:6] is the sub-list for extension type_name - 6, // [6:6] is the sub-list for extension extendee - 0, // [0:6] is the sub-list for field type_name + 18, // 0: buf.validate.conformance.cases.RequiredProto3Message.val:type_name -> buf.validate.conformance.cases.RequiredProto3Message.Msg + 19, // 1: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg + 20, // 2: buf.validate.conformance.cases.RequiredProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredProto3Map.ValEntry + 21, // 3: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry + 22, // 4: buf.validate.conformance.cases.RequiredProto3MapKey.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry + 23, // 5: buf.validate.conformance.cases.RequiredProto3MapValue.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + 24, // 6: buf.validate.conformance.cases.RequiredImplicitProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntry + 7, // [7:7] is the sub-list for method output_type + 7, // [7:7] is the sub-list for method input_type + 7, // [7:7] is the sub-list for extension type_name + 7, // [7:7] is the sub-list for extension extendee + 0, // [0:7] is the sub-list for field type_name } func init() { file_buf_validate_conformance_cases_required_field_proto3_proto_init() } @@ -1402,7 +1589,7 @@ func file_buf_validate_conformance_cases_required_field_proto3_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc), len(file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc)), NumEnums: 0, - NumMessages: 21, + NumMessages: 25, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/required_field_proto3_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/required_field_proto3_protoopaque.pb.go index 825138fa..a30f4332 100644 --- a/internal/gen/buf/validate/conformance/cases/required_field_proto3_protoopaque.pb.go +++ b/internal/gen/buf/validate/conformance/cases/required_field_proto3_protoopaque.pb.go @@ -1168,6 +1168,177 @@ func (b0 RequiredProto3RepeatedItem_builder) Build() *RequiredProto3RepeatedItem return m0 } +type RequiredImplicitProto3Scalar struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Scalar) Reset() { + *x = RequiredImplicitProto3Scalar{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Scalar) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Scalar) ProtoMessage() {} + +func (x *RequiredImplicitProto3Scalar) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Scalar) GetVal() string { + if x != nil { + return x.xxx_hidden_Val + } + return "" +} + +func (x *RequiredImplicitProto3Scalar) SetVal(v string) { + x.xxx_hidden_Val = v +} + +type RequiredImplicitProto3Scalar_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 RequiredImplicitProto3Scalar_builder) Build() *RequiredImplicitProto3Scalar { + m0 := &RequiredImplicitProto3Scalar{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type RequiredImplicitProto3Repeated struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val []string `protobuf:"bytes,1,rep,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Repeated) Reset() { + *x = RequiredImplicitProto3Repeated{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Repeated) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Repeated) ProtoMessage() {} + +func (x *RequiredImplicitProto3Repeated) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Repeated) GetVal() []string { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *RequiredImplicitProto3Repeated) SetVal(v []string) { + x.xxx_hidden_Val = v +} + +type RequiredImplicitProto3Repeated_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val []string +} + +func (b0 RequiredImplicitProto3Repeated_builder) Build() *RequiredImplicitProto3Repeated { + m0 := &RequiredImplicitProto3Repeated{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type RequiredImplicitProto3Map struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val map[string]string `protobuf:"bytes,1,rep,name=val,proto3" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *RequiredImplicitProto3Map) Reset() { + *x = RequiredImplicitProto3Map{} + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *RequiredImplicitProto3Map) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequiredImplicitProto3Map) ProtoMessage() {} + +func (x *RequiredImplicitProto3Map) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[17] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *RequiredImplicitProto3Map) GetVal() map[string]string { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *RequiredImplicitProto3Map) SetVal(v map[string]string) { + x.xxx_hidden_Val = v +} + +type RequiredImplicitProto3Map_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val map[string]string +} + +func (b0 RequiredImplicitProto3Map_builder) Build() *RequiredImplicitProto3Map { + m0 := &RequiredImplicitProto3Map{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + type RequiredProto3Message_Msg struct { state protoimpl.MessageState `protogen:"opaque.v1"` xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` @@ -1177,7 +1348,7 @@ type RequiredProto3Message_Msg struct { func (x *RequiredProto3Message_Msg) Reset() { *x = RequiredProto3Message_Msg{} - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1189,7 +1360,7 @@ func (x *RequiredProto3Message_Msg) String() string { func (*RequiredProto3Message_Msg) ProtoMessage() {} func (x *RequiredProto3Message_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[15] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[18] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1234,7 +1405,7 @@ type RequiredProto3MessageIgnoreAlways_Msg struct { func (x *RequiredProto3MessageIgnoreAlways_Msg) Reset() { *x = RequiredProto3MessageIgnoreAlways_Msg{} - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1246,7 +1417,7 @@ func (x *RequiredProto3MessageIgnoreAlways_Msg) String() string { func (*RequiredProto3MessageIgnoreAlways_Msg) ProtoMessage() {} func (x *RequiredProto3MessageIgnoreAlways_Msg) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[16] + mi := &file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1338,10 +1509,21 @@ const file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc = "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\";\n" + "\x1aRequiredProto3RepeatedItem\x12\x1d\n" + - "\x03val\x18\x01 \x03(\tB\v\xbaH\b\x92\x01\x05\"\x03\xc8\x01\x01R\x03valB\xa2\x02\n" + + "\x03val\x18\x01 \x03(\tB\v\xbaH\b\x92\x01\x05\"\x03\xc8\x01\x01R\x03val\">\n" + + "\x1cRequiredImplicitProto3Scalar\x12\x1e\n" + + "\x03val\x18\x01 \x01(\tB\f\xbaH\t\xc8\x01\x01r\x04\x10\x01\x18\x02R\x03val\"A\n" + + "\x1eRequiredImplicitProto3Repeated\x12\x1f\n" + + "\x03val\x18\x01 \x03(\tB\r\xbaH\n" + + "\xc8\x01\x01\x92\x01\x04\b\x01\x10\x02R\x03val\"\xb8\x01\n" + + "\x19RequiredImplicitProto3Map\x12c\n" + + "\x03val\x18\x01 \x03(\v2B.buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntryB\r\xbaH\n" + + "\xc8\x01\x01\x9a\x01\x04\b\x01\x10\x02R\x03val\x1a6\n" + + "\bValEntry\x12\x10\n" + + "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\xa2\x02\n" + "\"com.buf.validate.conformance.casesB\x18RequiredFieldProto3ProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes = make([]protoimpl.MessageInfo, 21) +var file_buf_validate_conformance_cases_required_field_proto3_proto_msgTypes = make([]protoimpl.MessageInfo, 25) var file_buf_validate_conformance_cases_required_field_proto3_proto_goTypes = []any{ (*RequiredProto3Scalar)(nil), // 0: buf.validate.conformance.cases.RequiredProto3Scalar (*RequiredProto3ScalarIgnoreAlways)(nil), // 1: buf.validate.conformance.cases.RequiredProto3ScalarIgnoreAlways @@ -1358,25 +1540,30 @@ var file_buf_validate_conformance_cases_required_field_proto3_proto_goTypes = [] (*RequiredProto3MapKey)(nil), // 12: buf.validate.conformance.cases.RequiredProto3MapKey (*RequiredProto3MapValue)(nil), // 13: buf.validate.conformance.cases.RequiredProto3MapValue (*RequiredProto3RepeatedItem)(nil), // 14: buf.validate.conformance.cases.RequiredProto3RepeatedItem - (*RequiredProto3Message_Msg)(nil), // 15: buf.validate.conformance.cases.RequiredProto3Message.Msg - (*RequiredProto3MessageIgnoreAlways_Msg)(nil), // 16: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg - nil, // 17: buf.validate.conformance.cases.RequiredProto3Map.ValEntry - nil, // 18: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry - nil, // 19: buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry - nil, // 20: buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + (*RequiredImplicitProto3Scalar)(nil), // 15: buf.validate.conformance.cases.RequiredImplicitProto3Scalar + (*RequiredImplicitProto3Repeated)(nil), // 16: buf.validate.conformance.cases.RequiredImplicitProto3Repeated + (*RequiredImplicitProto3Map)(nil), // 17: buf.validate.conformance.cases.RequiredImplicitProto3Map + (*RequiredProto3Message_Msg)(nil), // 18: buf.validate.conformance.cases.RequiredProto3Message.Msg + (*RequiredProto3MessageIgnoreAlways_Msg)(nil), // 19: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg + nil, // 20: buf.validate.conformance.cases.RequiredProto3Map.ValEntry + nil, // 21: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry + nil, // 22: buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry + nil, // 23: buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + nil, // 24: buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntry } var file_buf_validate_conformance_cases_required_field_proto3_proto_depIdxs = []int32{ - 15, // 0: buf.validate.conformance.cases.RequiredProto3Message.val:type_name -> buf.validate.conformance.cases.RequiredProto3Message.Msg - 16, // 1: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg - 17, // 2: buf.validate.conformance.cases.RequiredProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredProto3Map.ValEntry - 18, // 3: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry - 19, // 4: buf.validate.conformance.cases.RequiredProto3MapKey.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry - 20, // 5: buf.validate.conformance.cases.RequiredProto3MapValue.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry - 6, // [6:6] is the sub-list for method output_type - 6, // [6:6] is the sub-list for method input_type - 6, // [6:6] is the sub-list for extension type_name - 6, // [6:6] is the sub-list for extension extendee - 0, // [0:6] is the sub-list for field type_name + 18, // 0: buf.validate.conformance.cases.RequiredProto3Message.val:type_name -> buf.validate.conformance.cases.RequiredProto3Message.Msg + 19, // 1: buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MessageIgnoreAlways.Msg + 20, // 2: buf.validate.conformance.cases.RequiredProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredProto3Map.ValEntry + 21, // 3: buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapIgnoreAlways.ValEntry + 22, // 4: buf.validate.conformance.cases.RequiredProto3MapKey.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapKey.ValEntry + 23, // 5: buf.validate.conformance.cases.RequiredProto3MapValue.val:type_name -> buf.validate.conformance.cases.RequiredProto3MapValue.ValEntry + 24, // 6: buf.validate.conformance.cases.RequiredImplicitProto3Map.val:type_name -> buf.validate.conformance.cases.RequiredImplicitProto3Map.ValEntry + 7, // [7:7] is the sub-list for method output_type + 7, // [7:7] is the sub-list for method input_type + 7, // [7:7] is the sub-list for extension type_name + 7, // [7:7] is the sub-list for extension extendee + 0, // [0:7] is the sub-list for field type_name } func init() { file_buf_validate_conformance_cases_required_field_proto3_proto_init() } @@ -1400,7 +1587,7 @@ func file_buf_validate_conformance_cases_required_field_proto3_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc), len(file_buf_validate_conformance_cases_required_field_proto3_proto_rawDesc)), NumEnums: 0, - NumMessages: 21, + NumMessages: 25, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/strings.pb.go b/internal/gen/buf/validate/conformance/cases/strings.pb.go index 7cd9e7d8..456f6608 100644 --- a/internal/gen/buf/validate/conformance/cases/strings.pb.go +++ b/internal/gen/buf/validate/conformance/cases/strings.pb.go @@ -3001,6 +3001,177 @@ func (b0 StringNotTUUID_builder) Build() *StringNotTUUID { return m0 } +type StringULID struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringULID) Reset() { + *x = StringULID{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringULID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringULID) ProtoMessage() {} + +func (x *StringULID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringULID) GetVal() string { + if x != nil { + return x.Val + } + return "" +} + +func (x *StringULID) SetVal(v string) { + x.Val = v +} + +type StringULID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringULID_builder) Build() *StringULID { + m0 := &StringULID{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type StringNotULID struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringNotULID) Reset() { + *x = StringNotULID{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringNotULID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringNotULID) ProtoMessage() {} + +func (x *StringNotULID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringNotULID) GetVal() string { + if x != nil { + return x.Val + } + return "" +} + +func (x *StringNotULID) SetVal(v string) { + x.Val = v +} + +type StringNotULID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringNotULID_builder) Build() *StringNotULID { + m0 := &StringNotULID{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type StringULIDIgnore struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringULIDIgnore) Reset() { + *x = StringULIDIgnore{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringULIDIgnore) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringULIDIgnore) ProtoMessage() {} + +func (x *StringULIDIgnore) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringULIDIgnore) GetVal() string { + if x != nil { + return x.Val + } + return "" +} + +func (x *StringULIDIgnore) SetVal(v string) { + x.Val = v +} + +type StringULIDIgnore_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringULIDIgnore_builder) Build() *StringULIDIgnore { + m0 := &StringULIDIgnore{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + type StringHttpHeaderName struct { state protoimpl.MessageState `protogen:"hybrid.v1"` Val string `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` @@ -3010,7 +3181,7 @@ type StringHttpHeaderName struct { func (x *StringHttpHeaderName) Reset() { *x = StringHttpHeaderName{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3022,7 +3193,7 @@ func (x *StringHttpHeaderName) String() string { func (*StringHttpHeaderName) ProtoMessage() {} func (x *StringHttpHeaderName) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3067,7 +3238,7 @@ type StringHttpHeaderValue struct { func (x *StringHttpHeaderValue) Reset() { *x = StringHttpHeaderValue{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3079,7 +3250,7 @@ func (x *StringHttpHeaderValue) String() string { func (*StringHttpHeaderValue) ProtoMessage() {} func (x *StringHttpHeaderValue) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3124,7 +3295,7 @@ type StringHttpHeaderNameLoose struct { func (x *StringHttpHeaderNameLoose) Reset() { *x = StringHttpHeaderNameLoose{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3136,7 +3307,7 @@ func (x *StringHttpHeaderNameLoose) String() string { func (*StringHttpHeaderNameLoose) ProtoMessage() {} func (x *StringHttpHeaderNameLoose) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3181,7 +3352,7 @@ type StringHttpHeaderValueLoose struct { func (x *StringHttpHeaderValueLoose) Reset() { *x = StringHttpHeaderValueLoose{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3193,7 +3364,7 @@ func (x *StringHttpHeaderValueLoose) String() string { func (*StringHttpHeaderValueLoose) ProtoMessage() {} func (x *StringHttpHeaderValueLoose) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3238,7 +3409,7 @@ type StringUUIDIgnore struct { func (x *StringUUIDIgnore) Reset() { *x = StringUUIDIgnore{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3250,7 +3421,7 @@ func (x *StringUUIDIgnore) String() string { func (*StringUUIDIgnore) ProtoMessage() {} func (x *StringUUIDIgnore) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3298,7 +3469,7 @@ type StringInOneof struct { func (x *StringInOneof) Reset() { *x = StringInOneof{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3310,7 +3481,7 @@ func (x *StringInOneof) String() string { func (*StringInOneof) ProtoMessage() {} func (x *StringInOneof) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3402,7 +3573,7 @@ func (b0 StringInOneof_builder) Build() *StringInOneof { type case_StringInOneof_Foo protoreflect.FieldNumber func (x case_StringInOneof_Foo) String() string { - md := file_buf_validate_conformance_cases_strings_proto_msgTypes[57].Descriptor() + md := file_buf_validate_conformance_cases_strings_proto_msgTypes[60].Descriptor() if x == 0 { return "not set" } @@ -3428,7 +3599,7 @@ type StringHostAndPort struct { func (x *StringHostAndPort) Reset() { *x = StringHostAndPort{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[61] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3440,7 +3611,7 @@ func (x *StringHostAndPort) String() string { func (*StringHostAndPort) ProtoMessage() {} func (x *StringHostAndPort) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[61] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3485,7 +3656,7 @@ type StringHostAndOptionalPort struct { func (x *StringHostAndOptionalPort) Reset() { *x = StringHostAndOptionalPort{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[62] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3497,7 +3668,7 @@ func (x *StringHostAndOptionalPort) String() string { func (*StringHostAndOptionalPort) ProtoMessage() {} func (x *StringHostAndOptionalPort) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[62] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3542,7 +3713,7 @@ type StringExample struct { func (x *StringExample) Reset() { *x = StringExample{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[63] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3554,7 +3725,7 @@ func (x *StringExample) String() string { func (*StringExample) ProtoMessage() {} func (x *StringExample) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[63] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3709,7 +3880,14 @@ const file_buf_validate_conformance_cases_strings_proto_rawDesc = "" + "\vStringTUUID\x12\x1a\n" + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x01R\x03val\",\n" + "\x0eStringNotTUUID\x12\x1a\n" + - "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x00R\x03val\"2\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x00R\x03val\"(\n" + + "\n" + + "StringULID\x12\x1a\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x98\x02\x01R\x03val\"+\n" + + "\rStringNotULID\x12\x1a\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x98\x02\x00R\x03val\"1\n" + + "\x10StringULIDIgnore\x12\x1d\n" + + "\x03val\x18\x01 \x01(\tB\v\xbaH\b\xd8\x01\x01r\x03\x98\x02\x01R\x03val\"2\n" + "\x14StringHttpHeaderName\x12\x1a\n" + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\xc0\x01\x01R\x03val\"3\n" + "\x15StringHttpHeaderValue\x12\x1a\n" + @@ -3732,7 +3910,7 @@ const file_buf_validate_conformance_cases_strings_proto_rawDesc = "" + "\x03val\x18\x01 \x01(\tB\v\xbaH\br\x06\x92\x02\x03fooR\x03valB\x96\x02\n" + "\"com.buf.validate.conformance.casesB\fStringsProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_strings_proto_msgTypes = make([]protoimpl.MessageInfo, 61) +var file_buf_validate_conformance_cases_strings_proto_msgTypes = make([]protoimpl.MessageInfo, 64) var file_buf_validate_conformance_cases_strings_proto_goTypes = []any{ (*StringNone)(nil), // 0: buf.validate.conformance.cases.StringNone (*StringConst)(nil), // 1: buf.validate.conformance.cases.StringConst @@ -3786,15 +3964,18 @@ var file_buf_validate_conformance_cases_strings_proto_goTypes = []any{ (*StringNotUUID)(nil), // 49: buf.validate.conformance.cases.StringNotUUID (*StringTUUID)(nil), // 50: buf.validate.conformance.cases.StringTUUID (*StringNotTUUID)(nil), // 51: buf.validate.conformance.cases.StringNotTUUID - (*StringHttpHeaderName)(nil), // 52: buf.validate.conformance.cases.StringHttpHeaderName - (*StringHttpHeaderValue)(nil), // 53: buf.validate.conformance.cases.StringHttpHeaderValue - (*StringHttpHeaderNameLoose)(nil), // 54: buf.validate.conformance.cases.StringHttpHeaderNameLoose - (*StringHttpHeaderValueLoose)(nil), // 55: buf.validate.conformance.cases.StringHttpHeaderValueLoose - (*StringUUIDIgnore)(nil), // 56: buf.validate.conformance.cases.StringUUIDIgnore - (*StringInOneof)(nil), // 57: buf.validate.conformance.cases.StringInOneof - (*StringHostAndPort)(nil), // 58: buf.validate.conformance.cases.StringHostAndPort - (*StringHostAndOptionalPort)(nil), // 59: buf.validate.conformance.cases.StringHostAndOptionalPort - (*StringExample)(nil), // 60: buf.validate.conformance.cases.StringExample + (*StringULID)(nil), // 52: buf.validate.conformance.cases.StringULID + (*StringNotULID)(nil), // 53: buf.validate.conformance.cases.StringNotULID + (*StringULIDIgnore)(nil), // 54: buf.validate.conformance.cases.StringULIDIgnore + (*StringHttpHeaderName)(nil), // 55: buf.validate.conformance.cases.StringHttpHeaderName + (*StringHttpHeaderValue)(nil), // 56: buf.validate.conformance.cases.StringHttpHeaderValue + (*StringHttpHeaderNameLoose)(nil), // 57: buf.validate.conformance.cases.StringHttpHeaderNameLoose + (*StringHttpHeaderValueLoose)(nil), // 58: buf.validate.conformance.cases.StringHttpHeaderValueLoose + (*StringUUIDIgnore)(nil), // 59: buf.validate.conformance.cases.StringUUIDIgnore + (*StringInOneof)(nil), // 60: buf.validate.conformance.cases.StringInOneof + (*StringHostAndPort)(nil), // 61: buf.validate.conformance.cases.StringHostAndPort + (*StringHostAndOptionalPort)(nil), // 62: buf.validate.conformance.cases.StringHostAndOptionalPort + (*StringExample)(nil), // 63: buf.validate.conformance.cases.StringExample } var file_buf_validate_conformance_cases_strings_proto_depIdxs = []int32{ 0, // [0:0] is the sub-list for method output_type @@ -3809,7 +3990,7 @@ func file_buf_validate_conformance_cases_strings_proto_init() { if File_buf_validate_conformance_cases_strings_proto != nil { return } - file_buf_validate_conformance_cases_strings_proto_msgTypes[57].OneofWrappers = []any{ + file_buf_validate_conformance_cases_strings_proto_msgTypes[60].OneofWrappers = []any{ (*StringInOneof_Bar)(nil), } type x struct{} @@ -3818,7 +3999,7 @@ func file_buf_validate_conformance_cases_strings_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_strings_proto_rawDesc), len(file_buf_validate_conformance_cases_strings_proto_rawDesc)), NumEnums: 0, - NumMessages: 61, + NumMessages: 64, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/strings_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/strings_protoopaque.pb.go index 5e712d53..328590af 100644 --- a/internal/gen/buf/validate/conformance/cases/strings_protoopaque.pb.go +++ b/internal/gen/buf/validate/conformance/cases/strings_protoopaque.pb.go @@ -3001,6 +3001,177 @@ func (b0 StringNotTUUID_builder) Build() *StringNotTUUID { return m0 } +type StringULID struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringULID) Reset() { + *x = StringULID{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringULID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringULID) ProtoMessage() {} + +func (x *StringULID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringULID) GetVal() string { + if x != nil { + return x.xxx_hidden_Val + } + return "" +} + +func (x *StringULID) SetVal(v string) { + x.xxx_hidden_Val = v +} + +type StringULID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringULID_builder) Build() *StringULID { + m0 := &StringULID{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type StringNotULID struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringNotULID) Reset() { + *x = StringNotULID{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringNotULID) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringNotULID) ProtoMessage() {} + +func (x *StringNotULID) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringNotULID) GetVal() string { + if x != nil { + return x.xxx_hidden_Val + } + return "" +} + +func (x *StringNotULID) SetVal(v string) { + x.xxx_hidden_Val = v +} + +type StringNotULID_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringNotULID_builder) Build() *StringNotULID { + m0 := &StringNotULID{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type StringULIDIgnore struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *StringULIDIgnore) Reset() { + *x = StringULIDIgnore{} + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *StringULIDIgnore) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*StringULIDIgnore) ProtoMessage() {} + +func (x *StringULIDIgnore) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *StringULIDIgnore) GetVal() string { + if x != nil { + return x.xxx_hidden_Val + } + return "" +} + +func (x *StringULIDIgnore) SetVal(v string) { + x.xxx_hidden_Val = v +} + +type StringULIDIgnore_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val string +} + +func (b0 StringULIDIgnore_builder) Build() *StringULIDIgnore { + m0 := &StringULIDIgnore{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + type StringHttpHeaderName struct { state protoimpl.MessageState `protogen:"opaque.v1"` xxx_hidden_Val string `protobuf:"bytes,1,opt,name=val,proto3"` @@ -3010,7 +3181,7 @@ type StringHttpHeaderName struct { func (x *StringHttpHeaderName) Reset() { *x = StringHttpHeaderName{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3022,7 +3193,7 @@ func (x *StringHttpHeaderName) String() string { func (*StringHttpHeaderName) ProtoMessage() {} func (x *StringHttpHeaderName) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[52] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3067,7 +3238,7 @@ type StringHttpHeaderValue struct { func (x *StringHttpHeaderValue) Reset() { *x = StringHttpHeaderValue{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3079,7 +3250,7 @@ func (x *StringHttpHeaderValue) String() string { func (*StringHttpHeaderValue) ProtoMessage() {} func (x *StringHttpHeaderValue) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[53] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3124,7 +3295,7 @@ type StringHttpHeaderNameLoose struct { func (x *StringHttpHeaderNameLoose) Reset() { *x = StringHttpHeaderNameLoose{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3136,7 +3307,7 @@ func (x *StringHttpHeaderNameLoose) String() string { func (*StringHttpHeaderNameLoose) ProtoMessage() {} func (x *StringHttpHeaderNameLoose) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[54] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3181,7 +3352,7 @@ type StringHttpHeaderValueLoose struct { func (x *StringHttpHeaderValueLoose) Reset() { *x = StringHttpHeaderValueLoose{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3193,7 +3364,7 @@ func (x *StringHttpHeaderValueLoose) String() string { func (*StringHttpHeaderValueLoose) ProtoMessage() {} func (x *StringHttpHeaderValueLoose) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[55] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3238,7 +3409,7 @@ type StringUUIDIgnore struct { func (x *StringUUIDIgnore) Reset() { *x = StringUUIDIgnore{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3250,7 +3421,7 @@ func (x *StringUUIDIgnore) String() string { func (*StringUUIDIgnore) ProtoMessage() {} func (x *StringUUIDIgnore) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[56] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3295,7 +3466,7 @@ type StringInOneof struct { func (x *StringInOneof) Reset() { *x = StringInOneof{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3307,7 +3478,7 @@ func (x *StringInOneof) String() string { func (*StringInOneof) ProtoMessage() {} func (x *StringInOneof) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[57] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3392,7 +3563,7 @@ func (b0 StringInOneof_builder) Build() *StringInOneof { type case_StringInOneof_Foo protoreflect.FieldNumber func (x case_StringInOneof_Foo) String() string { - md := file_buf_validate_conformance_cases_strings_proto_msgTypes[57].Descriptor() + md := file_buf_validate_conformance_cases_strings_proto_msgTypes[60].Descriptor() if x == 0 { return "not set" } @@ -3418,7 +3589,7 @@ type StringHostAndPort struct { func (x *StringHostAndPort) Reset() { *x = StringHostAndPort{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[61] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3430,7 +3601,7 @@ func (x *StringHostAndPort) String() string { func (*StringHostAndPort) ProtoMessage() {} func (x *StringHostAndPort) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[58] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[61] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3475,7 +3646,7 @@ type StringHostAndOptionalPort struct { func (x *StringHostAndOptionalPort) Reset() { *x = StringHostAndOptionalPort{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[62] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3487,7 +3658,7 @@ func (x *StringHostAndOptionalPort) String() string { func (*StringHostAndOptionalPort) ProtoMessage() {} func (x *StringHostAndOptionalPort) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[59] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[62] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3532,7 +3703,7 @@ type StringExample struct { func (x *StringExample) Reset() { *x = StringExample{} - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[63] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3544,7 +3715,7 @@ func (x *StringExample) String() string { func (*StringExample) ProtoMessage() {} func (x *StringExample) ProtoReflect() protoreflect.Message { - mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[60] + mi := &file_buf_validate_conformance_cases_strings_proto_msgTypes[63] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3699,7 +3870,14 @@ const file_buf_validate_conformance_cases_strings_proto_rawDesc = "" + "\vStringTUUID\x12\x1a\n" + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x01R\x03val\",\n" + "\x0eStringNotTUUID\x12\x1a\n" + - "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x00R\x03val\"2\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x88\x02\x00R\x03val\"(\n" + + "\n" + + "StringULID\x12\x1a\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x98\x02\x01R\x03val\"+\n" + + "\rStringNotULID\x12\x1a\n" + + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\x98\x02\x00R\x03val\"1\n" + + "\x10StringULIDIgnore\x12\x1d\n" + + "\x03val\x18\x01 \x01(\tB\v\xbaH\b\xd8\x01\x01r\x03\x98\x02\x01R\x03val\"2\n" + "\x14StringHttpHeaderName\x12\x1a\n" + "\x03val\x18\x01 \x01(\tB\b\xbaH\x05r\x03\xc0\x01\x01R\x03val\"3\n" + "\x15StringHttpHeaderValue\x12\x1a\n" + @@ -3722,7 +3900,7 @@ const file_buf_validate_conformance_cases_strings_proto_rawDesc = "" + "\x03val\x18\x01 \x01(\tB\v\xbaH\br\x06\x92\x02\x03fooR\x03valB\x96\x02\n" + "\"com.buf.validate.conformance.casesB\fStringsProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" -var file_buf_validate_conformance_cases_strings_proto_msgTypes = make([]protoimpl.MessageInfo, 61) +var file_buf_validate_conformance_cases_strings_proto_msgTypes = make([]protoimpl.MessageInfo, 64) var file_buf_validate_conformance_cases_strings_proto_goTypes = []any{ (*StringNone)(nil), // 0: buf.validate.conformance.cases.StringNone (*StringConst)(nil), // 1: buf.validate.conformance.cases.StringConst @@ -3776,15 +3954,18 @@ var file_buf_validate_conformance_cases_strings_proto_goTypes = []any{ (*StringNotUUID)(nil), // 49: buf.validate.conformance.cases.StringNotUUID (*StringTUUID)(nil), // 50: buf.validate.conformance.cases.StringTUUID (*StringNotTUUID)(nil), // 51: buf.validate.conformance.cases.StringNotTUUID - (*StringHttpHeaderName)(nil), // 52: buf.validate.conformance.cases.StringHttpHeaderName - (*StringHttpHeaderValue)(nil), // 53: buf.validate.conformance.cases.StringHttpHeaderValue - (*StringHttpHeaderNameLoose)(nil), // 54: buf.validate.conformance.cases.StringHttpHeaderNameLoose - (*StringHttpHeaderValueLoose)(nil), // 55: buf.validate.conformance.cases.StringHttpHeaderValueLoose - (*StringUUIDIgnore)(nil), // 56: buf.validate.conformance.cases.StringUUIDIgnore - (*StringInOneof)(nil), // 57: buf.validate.conformance.cases.StringInOneof - (*StringHostAndPort)(nil), // 58: buf.validate.conformance.cases.StringHostAndPort - (*StringHostAndOptionalPort)(nil), // 59: buf.validate.conformance.cases.StringHostAndOptionalPort - (*StringExample)(nil), // 60: buf.validate.conformance.cases.StringExample + (*StringULID)(nil), // 52: buf.validate.conformance.cases.StringULID + (*StringNotULID)(nil), // 53: buf.validate.conformance.cases.StringNotULID + (*StringULIDIgnore)(nil), // 54: buf.validate.conformance.cases.StringULIDIgnore + (*StringHttpHeaderName)(nil), // 55: buf.validate.conformance.cases.StringHttpHeaderName + (*StringHttpHeaderValue)(nil), // 56: buf.validate.conformance.cases.StringHttpHeaderValue + (*StringHttpHeaderNameLoose)(nil), // 57: buf.validate.conformance.cases.StringHttpHeaderNameLoose + (*StringHttpHeaderValueLoose)(nil), // 58: buf.validate.conformance.cases.StringHttpHeaderValueLoose + (*StringUUIDIgnore)(nil), // 59: buf.validate.conformance.cases.StringUUIDIgnore + (*StringInOneof)(nil), // 60: buf.validate.conformance.cases.StringInOneof + (*StringHostAndPort)(nil), // 61: buf.validate.conformance.cases.StringHostAndPort + (*StringHostAndOptionalPort)(nil), // 62: buf.validate.conformance.cases.StringHostAndOptionalPort + (*StringExample)(nil), // 63: buf.validate.conformance.cases.StringExample } var file_buf_validate_conformance_cases_strings_proto_depIdxs = []int32{ 0, // [0:0] is the sub-list for method output_type @@ -3799,7 +3980,7 @@ func file_buf_validate_conformance_cases_strings_proto_init() { if File_buf_validate_conformance_cases_strings_proto != nil { return } - file_buf_validate_conformance_cases_strings_proto_msgTypes[57].OneofWrappers = []any{ + file_buf_validate_conformance_cases_strings_proto_msgTypes[60].OneofWrappers = []any{ (*stringInOneof_Bar)(nil), } type x struct{} @@ -3808,7 +3989,7 @@ func file_buf_validate_conformance_cases_strings_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_strings_proto_rawDesc), len(file_buf_validate_conformance_cases_strings_proto_rawDesc)), NumEnums: 0, - NumMessages: 61, + NumMessages: 64, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/gen/buf/validate/conformance/cases/wkt_field_mask.pb.go b/internal/gen/buf/validate/conformance/cases/wkt_field_mask.pb.go new file mode 100644 index 00000000..41b848f8 --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/wkt_field_mask.pb.go @@ -0,0 +1,517 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/wkt_field_mask.proto + +//go:build !protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type FieldMaskNone struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskNone) Reset() { + *x = FieldMaskNone{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskNone) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskNone) ProtoMessage() {} + +func (x *FieldMaskNone) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskNone) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskNone) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskNone) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskNone) ClearVal() { + x.Val = nil +} + +type FieldMaskNone_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskNone_builder) Build() *FieldMaskNone { + m0 := &FieldMaskNone{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type FieldMaskRequired struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskRequired) Reset() { + *x = FieldMaskRequired{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskRequired) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskRequired) ProtoMessage() {} + +func (x *FieldMaskRequired) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskRequired) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskRequired) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskRequired) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskRequired) ClearVal() { + x.Val = nil +} + +type FieldMaskRequired_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskRequired_builder) Build() *FieldMaskRequired { + m0 := &FieldMaskRequired{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type FieldMaskConst struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskConst) Reset() { + *x = FieldMaskConst{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskConst) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskConst) ProtoMessage() {} + +func (x *FieldMaskConst) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskConst) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskConst) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskConst) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskConst) ClearVal() { + x.Val = nil +} + +type FieldMaskConst_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskConst_builder) Build() *FieldMaskConst { + m0 := &FieldMaskConst{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type FieldMaskIn struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskIn) Reset() { + *x = FieldMaskIn{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskIn) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskIn) ProtoMessage() {} + +func (x *FieldMaskIn) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[3] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskIn) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskIn) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskIn) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskIn) ClearVal() { + x.Val = nil +} + +type FieldMaskIn_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskIn_builder) Build() *FieldMaskIn { + m0 := &FieldMaskIn{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type FieldMaskNotIn struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskNotIn) Reset() { + *x = FieldMaskNotIn{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskNotIn) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskNotIn) ProtoMessage() {} + +func (x *FieldMaskNotIn) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[4] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskNotIn) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskNotIn) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskNotIn) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskNotIn) ClearVal() { + x.Val = nil +} + +type FieldMaskNotIn_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskNotIn_builder) Build() *FieldMaskNotIn { + m0 := &FieldMaskNotIn{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +type FieldMaskExample struct { + state protoimpl.MessageState `protogen:"hybrid.v1"` + Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3" json:"val,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskExample) Reset() { + *x = FieldMaskExample{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskExample) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskExample) ProtoMessage() {} + +func (x *FieldMaskExample) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[5] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskExample) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.Val + } + return nil +} + +func (x *FieldMaskExample) SetVal(v *fieldmaskpb.FieldMask) { + x.Val = v +} + +func (x *FieldMaskExample) HasVal() bool { + if x == nil { + return false + } + return x.Val != nil +} + +func (x *FieldMaskExample) ClearVal() { + x.Val = nil +} + +type FieldMaskExample_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskExample_builder) Build() *FieldMaskExample { + m0 := &FieldMaskExample{} + b, x := &b0, m0 + _, _ = b, x + x.Val = b.Val + return m0 +} + +var File_buf_validate_conformance_cases_wkt_field_mask_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc = "" + + "\n" + + "3buf/validate/conformance/cases/wkt_field_mask.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\x1a google/protobuf/field_mask.proto\"=\n" + + "\rFieldMaskNone\x12,\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskR\x03val\"I\n" + + "\x11FieldMaskRequired\x124\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\x06\xbaH\x03\xc8\x01\x01R\x03val\"K\n" + + "\x0eFieldMaskConst\x129\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\v\xbaH\b\xe2\x01\x05\n" + + "\x03\n" + + "\x01aR\x03val\"I\n" + + "\vFieldMaskIn\x12:\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\f\xbaH\t\xe2\x01\x06\x12\x01a\x12\x01bR\x03val\"L\n" + + "\x0eFieldMaskNotIn\x12:\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\f\xbaH\t\xe2\x01\x06\x1a\x01c\x1a\x01dR\x03val\"M\n" + + "\x10FieldMaskExample\x129\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\v\xbaH\b\xe2\x01\x05\"\x03\n" + + "\x01aR\x03valB\x9b\x02\n" + + "\"com.buf.validate.conformance.casesB\x11WktFieldMaskProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" + +var file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes = []any{ + (*FieldMaskNone)(nil), // 0: buf.validate.conformance.cases.FieldMaskNone + (*FieldMaskRequired)(nil), // 1: buf.validate.conformance.cases.FieldMaskRequired + (*FieldMaskConst)(nil), // 2: buf.validate.conformance.cases.FieldMaskConst + (*FieldMaskIn)(nil), // 3: buf.validate.conformance.cases.FieldMaskIn + (*FieldMaskNotIn)(nil), // 4: buf.validate.conformance.cases.FieldMaskNotIn + (*FieldMaskExample)(nil), // 5: buf.validate.conformance.cases.FieldMaskExample + (*fieldmaskpb.FieldMask)(nil), // 6: google.protobuf.FieldMask +} +var file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs = []int32{ + 6, // 0: buf.validate.conformance.cases.FieldMaskNone.val:type_name -> google.protobuf.FieldMask + 6, // 1: buf.validate.conformance.cases.FieldMaskRequired.val:type_name -> google.protobuf.FieldMask + 6, // 2: buf.validate.conformance.cases.FieldMaskConst.val:type_name -> google.protobuf.FieldMask + 6, // 3: buf.validate.conformance.cases.FieldMaskIn.val:type_name -> google.protobuf.FieldMask + 6, // 4: buf.validate.conformance.cases.FieldMaskNotIn.val:type_name -> google.protobuf.FieldMask + 6, // 5: buf.validate.conformance.cases.FieldMaskExample.val:type_name -> google.protobuf.FieldMask + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_wkt_field_mask_proto_init() } +func file_buf_validate_conformance_cases_wkt_field_mask_proto_init() { + if File_buf_validate_conformance_cases_wkt_field_mask_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc), len(file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc)), + NumEnums: 0, + NumMessages: 6, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_wkt_field_mask_proto = out.File + file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes = nil + file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs = nil +} diff --git a/internal/gen/buf/validate/conformance/cases/wkt_field_mask_protoopaque.pb.go b/internal/gen/buf/validate/conformance/cases/wkt_field_mask_protoopaque.pb.go new file mode 100644 index 00000000..15658326 --- /dev/null +++ b/internal/gen/buf/validate/conformance/cases/wkt_field_mask_protoopaque.pb.go @@ -0,0 +1,517 @@ +// Copyright 2023-2025 Buf Technologies, Inc. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// Code generated by protoc-gen-go. DO NOT EDIT. +// versions: +// protoc-gen-go v1.36.6 +// protoc (unknown) +// source: buf/validate/conformance/cases/wkt_field_mask.proto + +//go:build protoopaque + +package cases + +import ( + _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" + fieldmaskpb "google.golang.org/protobuf/types/known/fieldmaskpb" + reflect "reflect" + unsafe "unsafe" +) + +const ( + // Verify that this generated code is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) + // Verify that runtime/protoimpl is sufficiently up-to-date. + _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) +) + +type FieldMaskNone struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskNone) Reset() { + *x = FieldMaskNone{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskNone) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskNone) ProtoMessage() {} + +func (x *FieldMaskNone) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[0] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskNone) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskNone) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskNone) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskNone) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskNone_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskNone_builder) Build() *FieldMaskNone { + m0 := &FieldMaskNone{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type FieldMaskRequired struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskRequired) Reset() { + *x = FieldMaskRequired{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskRequired) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskRequired) ProtoMessage() {} + +func (x *FieldMaskRequired) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[1] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskRequired) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskRequired) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskRequired) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskRequired) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskRequired_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskRequired_builder) Build() *FieldMaskRequired { + m0 := &FieldMaskRequired{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type FieldMaskConst struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskConst) Reset() { + *x = FieldMaskConst{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskConst) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskConst) ProtoMessage() {} + +func (x *FieldMaskConst) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[2] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskConst) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskConst) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskConst) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskConst) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskConst_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskConst_builder) Build() *FieldMaskConst { + m0 := &FieldMaskConst{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type FieldMaskIn struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskIn) Reset() { + *x = FieldMaskIn{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskIn) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskIn) ProtoMessage() {} + +func (x *FieldMaskIn) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[3] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskIn) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskIn) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskIn) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskIn) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskIn_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskIn_builder) Build() *FieldMaskIn { + m0 := &FieldMaskIn{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type FieldMaskNotIn struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskNotIn) Reset() { + *x = FieldMaskNotIn{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskNotIn) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskNotIn) ProtoMessage() {} + +func (x *FieldMaskNotIn) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[4] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskNotIn) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskNotIn) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskNotIn) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskNotIn) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskNotIn_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskNotIn_builder) Build() *FieldMaskNotIn { + m0 := &FieldMaskNotIn{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +type FieldMaskExample struct { + state protoimpl.MessageState `protogen:"opaque.v1"` + xxx_hidden_Val *fieldmaskpb.FieldMask `protobuf:"bytes,1,opt,name=val,proto3"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *FieldMaskExample) Reset() { + *x = FieldMaskExample{} + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *FieldMaskExample) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*FieldMaskExample) ProtoMessage() {} + +func (x *FieldMaskExample) ProtoReflect() protoreflect.Message { + mi := &file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes[5] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +func (x *FieldMaskExample) GetVal() *fieldmaskpb.FieldMask { + if x != nil { + return x.xxx_hidden_Val + } + return nil +} + +func (x *FieldMaskExample) SetVal(v *fieldmaskpb.FieldMask) { + x.xxx_hidden_Val = v +} + +func (x *FieldMaskExample) HasVal() bool { + if x == nil { + return false + } + return x.xxx_hidden_Val != nil +} + +func (x *FieldMaskExample) ClearVal() { + x.xxx_hidden_Val = nil +} + +type FieldMaskExample_builder struct { + _ [0]func() // Prevents comparability and use of unkeyed literals for the builder. + + Val *fieldmaskpb.FieldMask +} + +func (b0 FieldMaskExample_builder) Build() *FieldMaskExample { + m0 := &FieldMaskExample{} + b, x := &b0, m0 + _, _ = b, x + x.xxx_hidden_Val = b.Val + return m0 +} + +var File_buf_validate_conformance_cases_wkt_field_mask_proto protoreflect.FileDescriptor + +const file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc = "" + + "\n" + + "3buf/validate/conformance/cases/wkt_field_mask.proto\x12\x1ebuf.validate.conformance.cases\x1a\x1bbuf/validate/validate.proto\x1a google/protobuf/field_mask.proto\"=\n" + + "\rFieldMaskNone\x12,\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskR\x03val\"I\n" + + "\x11FieldMaskRequired\x124\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\x06\xbaH\x03\xc8\x01\x01R\x03val\"K\n" + + "\x0eFieldMaskConst\x129\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\v\xbaH\b\xe2\x01\x05\n" + + "\x03\n" + + "\x01aR\x03val\"I\n" + + "\vFieldMaskIn\x12:\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\f\xbaH\t\xe2\x01\x06\x12\x01a\x12\x01bR\x03val\"L\n" + + "\x0eFieldMaskNotIn\x12:\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\f\xbaH\t\xe2\x01\x06\x1a\x01c\x1a\x01dR\x03val\"M\n" + + "\x10FieldMaskExample\x129\n" + + "\x03val\x18\x01 \x01(\v2\x1a.google.protobuf.FieldMaskB\v\xbaH\b\xe2\x01\x05\"\x03\n" + + "\x01aR\x03valB\x9b\x02\n" + + "\"com.buf.validate.conformance.casesB\x11WktFieldMaskProtoP\x01ZFbuf.build/go/protovalidate/internal/gen/buf/validate/conformance/cases\xa2\x02\x04BVCC\xaa\x02\x1eBuf.Validate.Conformance.Cases\xca\x02\x1eBuf\\Validate\\Conformance\\Cases\xe2\x02*Buf\\Validate\\Conformance\\Cases\\GPBMetadata\xea\x02!Buf::Validate::Conformance::Casesb\x06proto3" + +var file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes = make([]protoimpl.MessageInfo, 6) +var file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes = []any{ + (*FieldMaskNone)(nil), // 0: buf.validate.conformance.cases.FieldMaskNone + (*FieldMaskRequired)(nil), // 1: buf.validate.conformance.cases.FieldMaskRequired + (*FieldMaskConst)(nil), // 2: buf.validate.conformance.cases.FieldMaskConst + (*FieldMaskIn)(nil), // 3: buf.validate.conformance.cases.FieldMaskIn + (*FieldMaskNotIn)(nil), // 4: buf.validate.conformance.cases.FieldMaskNotIn + (*FieldMaskExample)(nil), // 5: buf.validate.conformance.cases.FieldMaskExample + (*fieldmaskpb.FieldMask)(nil), // 6: google.protobuf.FieldMask +} +var file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs = []int32{ + 6, // 0: buf.validate.conformance.cases.FieldMaskNone.val:type_name -> google.protobuf.FieldMask + 6, // 1: buf.validate.conformance.cases.FieldMaskRequired.val:type_name -> google.protobuf.FieldMask + 6, // 2: buf.validate.conformance.cases.FieldMaskConst.val:type_name -> google.protobuf.FieldMask + 6, // 3: buf.validate.conformance.cases.FieldMaskIn.val:type_name -> google.protobuf.FieldMask + 6, // 4: buf.validate.conformance.cases.FieldMaskNotIn.val:type_name -> google.protobuf.FieldMask + 6, // 5: buf.validate.conformance.cases.FieldMaskExample.val:type_name -> google.protobuf.FieldMask + 6, // [6:6] is the sub-list for method output_type + 6, // [6:6] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name +} + +func init() { file_buf_validate_conformance_cases_wkt_field_mask_proto_init() } +func file_buf_validate_conformance_cases_wkt_field_mask_proto_init() { + if File_buf_validate_conformance_cases_wkt_field_mask_proto != nil { + return + } + type x struct{} + out := protoimpl.TypeBuilder{ + File: protoimpl.DescBuilder{ + GoPackagePath: reflect.TypeOf(x{}).PkgPath(), + RawDescriptor: unsafe.Slice(unsafe.StringData(file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc), len(file_buf_validate_conformance_cases_wkt_field_mask_proto_rawDesc)), + NumEnums: 0, + NumMessages: 6, + NumExtensions: 0, + NumServices: 0, + }, + GoTypes: file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes, + DependencyIndexes: file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs, + MessageInfos: file_buf_validate_conformance_cases_wkt_field_mask_proto_msgTypes, + }.Build() + File_buf_validate_conformance_cases_wkt_field_mask_proto = out.File + file_buf_validate_conformance_cases_wkt_field_mask_proto_goTypes = nil + file_buf_validate_conformance_cases_wkt_field_mask_proto_depIdxs = nil +} diff --git a/lookups.go b/lookups.go index a86dd72f..f1140bac 100644 --- a/lookups.go +++ b/lookups.go @@ -60,6 +60,7 @@ var expectedStandardRules = map[protoreflect.Kind]protoreflect.FieldDescriptor{ var expectedWKTRules = map[protoreflect.FullName]protoreflect.FieldDescriptor{ "google.protobuf.Any": fieldRulesDesc.Fields().ByName("any"), "google.protobuf.Duration": fieldRulesDesc.Fields().ByName("duration"), + "google.protobuf.FieldMask": fieldRulesDesc.Fields().ByName("field_mask"), "google.protobuf.Timestamp": fieldRulesDesc.Fields().ByName("timestamp"), } diff --git a/program.go b/program.go index e7ff52a9..2fa4361e 100644 --- a/program.go +++ b/program.go @@ -100,6 +100,7 @@ func (s programSet) bindThis(val any) *variable { // source Expression. type compiledProgram struct { Program cel.Program + Rules protoreflect.Message Source *validate.Rule Path []*validate.FieldPathElement Value protoreflect.Value @@ -110,7 +111,11 @@ type compiledProgram struct { func (expr compiledProgram) eval(bindings *variable, cfg *validationConfig) (*Violation, error) { now := globalNowPool.Get(cfg.nowFn) defer globalNowPool.Put(now) - bindings.Next = now + bindings.Next = &variable{ + Next: now, + Name: "rules", + Val: expr.Rules, + } value, _, err := expr.Program.Eval(bindings) if err != nil {