xref: /aosp_15_r20/external/golang-protobuf/cmd/protoc-gen-go/testdata/proto3/enum.pb.go (revision 1c12ee1efe575feb122dbf939ff15148a3b3e8f2)
1*1c12ee1eSDan Willemsen// Copyright 2018 The Go Authors. All rights reserved.
2*1c12ee1eSDan Willemsen// Use of this source code is governed by a BSD-style
3*1c12ee1eSDan Willemsen// license that can be found in the LICENSE file.
4*1c12ee1eSDan Willemsen
5*1c12ee1eSDan Willemsen// Code generated by protoc-gen-go. DO NOT EDIT.
6*1c12ee1eSDan Willemsen// source: cmd/protoc-gen-go/testdata/proto3/enum.proto
7*1c12ee1eSDan Willemsen
8*1c12ee1eSDan Willemsenpackage proto3
9*1c12ee1eSDan Willemsen
10*1c12ee1eSDan Willemsenimport (
11*1c12ee1eSDan Willemsen	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
12*1c12ee1eSDan Willemsen	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
13*1c12ee1eSDan Willemsen	reflect "reflect"
14*1c12ee1eSDan Willemsen	sync "sync"
15*1c12ee1eSDan Willemsen)
16*1c12ee1eSDan Willemsen
17*1c12ee1eSDan Willemsentype Enum int32
18*1c12ee1eSDan Willemsen
19*1c12ee1eSDan Willemsenconst (
20*1c12ee1eSDan Willemsen	Enum_ZERO Enum = 0
21*1c12ee1eSDan Willemsen	Enum_ONE  Enum = 1
22*1c12ee1eSDan Willemsen	Enum_TWO  Enum = 2
23*1c12ee1eSDan Willemsen)
24*1c12ee1eSDan Willemsen
25*1c12ee1eSDan Willemsen// Enum value maps for Enum.
26*1c12ee1eSDan Willemsenvar (
27*1c12ee1eSDan Willemsen	Enum_name = map[int32]string{
28*1c12ee1eSDan Willemsen		0: "ZERO",
29*1c12ee1eSDan Willemsen		1: "ONE",
30*1c12ee1eSDan Willemsen		2: "TWO",
31*1c12ee1eSDan Willemsen	}
32*1c12ee1eSDan Willemsen	Enum_value = map[string]int32{
33*1c12ee1eSDan Willemsen		"ZERO": 0,
34*1c12ee1eSDan Willemsen		"ONE":  1,
35*1c12ee1eSDan Willemsen		"TWO":  2,
36*1c12ee1eSDan Willemsen	}
37*1c12ee1eSDan Willemsen)
38*1c12ee1eSDan Willemsen
39*1c12ee1eSDan Willemsenfunc (x Enum) Enum() *Enum {
40*1c12ee1eSDan Willemsen	p := new(Enum)
41*1c12ee1eSDan Willemsen	*p = x
42*1c12ee1eSDan Willemsen	return p
43*1c12ee1eSDan Willemsen}
44*1c12ee1eSDan Willemsen
45*1c12ee1eSDan Willemsenfunc (x Enum) String() string {
46*1c12ee1eSDan Willemsen	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
47*1c12ee1eSDan Willemsen}
48*1c12ee1eSDan Willemsen
49*1c12ee1eSDan Willemsenfunc (Enum) Descriptor() protoreflect.EnumDescriptor {
50*1c12ee1eSDan Willemsen	return file_cmd_protoc_gen_go_testdata_proto3_enum_proto_enumTypes[0].Descriptor()
51*1c12ee1eSDan Willemsen}
52*1c12ee1eSDan Willemsen
53*1c12ee1eSDan Willemsenfunc (Enum) Type() protoreflect.EnumType {
54*1c12ee1eSDan Willemsen	return &file_cmd_protoc_gen_go_testdata_proto3_enum_proto_enumTypes[0]
55*1c12ee1eSDan Willemsen}
56*1c12ee1eSDan Willemsen
57*1c12ee1eSDan Willemsenfunc (x Enum) Number() protoreflect.EnumNumber {
58*1c12ee1eSDan Willemsen	return protoreflect.EnumNumber(x)
59*1c12ee1eSDan Willemsen}
60*1c12ee1eSDan Willemsen
61*1c12ee1eSDan Willemsen// Deprecated: Use Enum.Descriptor instead.
62*1c12ee1eSDan Willemsenfunc (Enum) EnumDescriptor() ([]byte, []int) {
63*1c12ee1eSDan Willemsen	return file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescGZIP(), []int{0}
64*1c12ee1eSDan Willemsen}
65*1c12ee1eSDan Willemsen
66*1c12ee1eSDan Willemsenvar File_cmd_protoc_gen_go_testdata_proto3_enum_proto protoreflect.FileDescriptor
67*1c12ee1eSDan Willemsen
68*1c12ee1eSDan Willemsenvar file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDesc = []byte{
69*1c12ee1eSDan Willemsen	0x0a, 0x2c, 0x63, 0x6d, 0x64, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x2d, 0x67, 0x65, 0x6e,
70*1c12ee1eSDan Willemsen	0x2d, 0x67, 0x6f, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f,
71*1c12ee1eSDan Willemsen	0x74, 0x6f, 0x33, 0x2f, 0x65, 0x6e, 0x75, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x15,
72*1c12ee1eSDan Willemsen	0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x2e, 0x70,
73*1c12ee1eSDan Willemsen	0x72, 0x6f, 0x74, 0x6f, 0x33, 0x2a, 0x22, 0x0a, 0x04, 0x45, 0x6e, 0x75, 0x6d, 0x12, 0x08, 0x0a,
74*1c12ee1eSDan Willemsen	0x04, 0x5a, 0x45, 0x52, 0x4f, 0x10, 0x00, 0x12, 0x07, 0x0a, 0x03, 0x4f, 0x4e, 0x45, 0x10, 0x01,
75*1c12ee1eSDan Willemsen	0x12, 0x07, 0x0a, 0x03, 0x54, 0x57, 0x4f, 0x10, 0x02, 0x42, 0x3e, 0x5a, 0x3c, 0x67, 0x6f, 0x6f,
76*1c12ee1eSDan Willemsen	0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x70,
77*1c12ee1eSDan Willemsen	0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x63, 0x6d, 0x64, 0x2f, 0x70, 0x72, 0x6f, 0x74,
78*1c12ee1eSDan Willemsen	0x6f, 0x63, 0x2d, 0x67, 0x65, 0x6e, 0x2d, 0x67, 0x6f, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61,
79*1c12ee1eSDan Willemsen	0x74, 0x61, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f,
80*1c12ee1eSDan Willemsen	0x33,
81*1c12ee1eSDan Willemsen}
82*1c12ee1eSDan Willemsen
83*1c12ee1eSDan Willemsenvar (
84*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescOnce sync.Once
85*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescData = file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDesc
86*1c12ee1eSDan Willemsen)
87*1c12ee1eSDan Willemsen
88*1c12ee1eSDan Willemsenfunc file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescGZIP() []byte {
89*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescOnce.Do(func() {
90*1c12ee1eSDan Willemsen		file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescData = protoimpl.X.CompressGZIP(file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescData)
91*1c12ee1eSDan Willemsen	})
92*1c12ee1eSDan Willemsen	return file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDescData
93*1c12ee1eSDan Willemsen}
94*1c12ee1eSDan Willemsen
95*1c12ee1eSDan Willemsenvar file_cmd_protoc_gen_go_testdata_proto3_enum_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
96*1c12ee1eSDan Willemsenvar file_cmd_protoc_gen_go_testdata_proto3_enum_proto_goTypes = []interface{}{
97*1c12ee1eSDan Willemsen	(Enum)(0), // 0: goproto.protoc.proto3.Enum
98*1c12ee1eSDan Willemsen}
99*1c12ee1eSDan Willemsenvar file_cmd_protoc_gen_go_testdata_proto3_enum_proto_depIdxs = []int32{
100*1c12ee1eSDan Willemsen	0, // [0:0] is the sub-list for method output_type
101*1c12ee1eSDan Willemsen	0, // [0:0] is the sub-list for method input_type
102*1c12ee1eSDan Willemsen	0, // [0:0] is the sub-list for extension type_name
103*1c12ee1eSDan Willemsen	0, // [0:0] is the sub-list for extension extendee
104*1c12ee1eSDan Willemsen	0, // [0:0] is the sub-list for field type_name
105*1c12ee1eSDan Willemsen}
106*1c12ee1eSDan Willemsen
107*1c12ee1eSDan Willemsenfunc init() { file_cmd_protoc_gen_go_testdata_proto3_enum_proto_init() }
108*1c12ee1eSDan Willemsenfunc file_cmd_protoc_gen_go_testdata_proto3_enum_proto_init() {
109*1c12ee1eSDan Willemsen	if File_cmd_protoc_gen_go_testdata_proto3_enum_proto != nil {
110*1c12ee1eSDan Willemsen		return
111*1c12ee1eSDan Willemsen	}
112*1c12ee1eSDan Willemsen	type x struct{}
113*1c12ee1eSDan Willemsen	out := protoimpl.TypeBuilder{
114*1c12ee1eSDan Willemsen		File: protoimpl.DescBuilder{
115*1c12ee1eSDan Willemsen			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
116*1c12ee1eSDan Willemsen			RawDescriptor: file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDesc,
117*1c12ee1eSDan Willemsen			NumEnums:      1,
118*1c12ee1eSDan Willemsen			NumMessages:   0,
119*1c12ee1eSDan Willemsen			NumExtensions: 0,
120*1c12ee1eSDan Willemsen			NumServices:   0,
121*1c12ee1eSDan Willemsen		},
122*1c12ee1eSDan Willemsen		GoTypes:           file_cmd_protoc_gen_go_testdata_proto3_enum_proto_goTypes,
123*1c12ee1eSDan Willemsen		DependencyIndexes: file_cmd_protoc_gen_go_testdata_proto3_enum_proto_depIdxs,
124*1c12ee1eSDan Willemsen		EnumInfos:         file_cmd_protoc_gen_go_testdata_proto3_enum_proto_enumTypes,
125*1c12ee1eSDan Willemsen	}.Build()
126*1c12ee1eSDan Willemsen	File_cmd_protoc_gen_go_testdata_proto3_enum_proto = out.File
127*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_rawDesc = nil
128*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_goTypes = nil
129*1c12ee1eSDan Willemsen	file_cmd_protoc_gen_go_testdata_proto3_enum_proto_depIdxs = nil
130*1c12ee1eSDan Willemsen}
131