github.com/gogo/protobuf@v1.3.2/protoc-gen-gogo/testdata/proto3/proto3.pb.go (about)

     1  // Code generated by protoc-gen-gogo. DO NOT EDIT.
     2  // source: proto3/proto3.proto
     3  
     4  package proto3
     5  
     6  import (
     7  	fmt "fmt"
     8  	proto "github.com/gogo/protobuf/proto"
     9  	math "math"
    10  )
    11  
    12  // Reference imports to suppress errors if they are not otherwise used.
    13  var _ = proto.Marshal
    14  var _ = fmt.Errorf
    15  var _ = math.Inf
    16  
    17  // This is a compile-time assertion to ensure that this generated file
    18  // is compatible with the proto package it is being compiled against.
    19  // A compilation error at this line likely means your copy of the
    20  // proto package needs to be updated.
    21  const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
    22  
    23  type Request_Flavour int32
    24  
    25  const (
    26  	Request_SWEET         Request_Flavour = 0
    27  	Request_SOUR          Request_Flavour = 1
    28  	Request_UMAMI         Request_Flavour = 2
    29  	Request_GOPHERLICIOUS Request_Flavour = 3
    30  )
    31  
    32  var Request_Flavour_name = map[int32]string{
    33  	0: "SWEET",
    34  	1: "SOUR",
    35  	2: "UMAMI",
    36  	3: "GOPHERLICIOUS",
    37  }
    38  
    39  var Request_Flavour_value = map[string]int32{
    40  	"SWEET":         0,
    41  	"SOUR":          1,
    42  	"UMAMI":         2,
    43  	"GOPHERLICIOUS": 3,
    44  }
    45  
    46  func (x Request_Flavour) String() string {
    47  	return proto.EnumName(Request_Flavour_name, int32(x))
    48  }
    49  
    50  func (Request_Flavour) EnumDescriptor() ([]byte, []int) {
    51  	return fileDescriptor_ab04eb4084a521db, []int{0, 0}
    52  }
    53  
    54  type Request struct {
    55  	Name                 string          `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
    56  	Key                  []int64         `protobuf:"varint,2,rep,packed,name=key,proto3" json:"key,omitempty"`
    57  	Taste                Request_Flavour `protobuf:"varint,3,opt,name=taste,proto3,enum=proto3.Request_Flavour" json:"taste,omitempty"`
    58  	Book                 *Book           `protobuf:"bytes,4,opt,name=book,proto3" json:"book,omitempty"`
    59  	Unpacked             []int64         `protobuf:"varint,5,rep,name=unpacked,proto3" json:"unpacked,omitempty"`
    60  	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
    61  	XXX_unrecognized     []byte          `json:"-"`
    62  	XXX_sizecache        int32           `json:"-"`
    63  }
    64  
    65  func (m *Request) Reset()         { *m = Request{} }
    66  func (m *Request) String() string { return proto.CompactTextString(m) }
    67  func (*Request) ProtoMessage()    {}
    68  func (*Request) Descriptor() ([]byte, []int) {
    69  	return fileDescriptor_ab04eb4084a521db, []int{0}
    70  }
    71  func (m *Request) XXX_Unmarshal(b []byte) error {
    72  	return xxx_messageInfo_Request.Unmarshal(m, b)
    73  }
    74  func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
    75  	return xxx_messageInfo_Request.Marshal(b, m, deterministic)
    76  }
    77  func (m *Request) XXX_Merge(src proto.Message) {
    78  	xxx_messageInfo_Request.Merge(m, src)
    79  }
    80  func (m *Request) XXX_Size() int {
    81  	return xxx_messageInfo_Request.Size(m)
    82  }
    83  func (m *Request) XXX_DiscardUnknown() {
    84  	xxx_messageInfo_Request.DiscardUnknown(m)
    85  }
    86  
    87  var xxx_messageInfo_Request proto.InternalMessageInfo
    88  
    89  func (m *Request) GetName() string {
    90  	if m != nil {
    91  		return m.Name
    92  	}
    93  	return ""
    94  }
    95  
    96  func (m *Request) GetKey() []int64 {
    97  	if m != nil {
    98  		return m.Key
    99  	}
   100  	return nil
   101  }
   102  
   103  func (m *Request) GetTaste() Request_Flavour {
   104  	if m != nil {
   105  		return m.Taste
   106  	}
   107  	return Request_SWEET
   108  }
   109  
   110  func (m *Request) GetBook() *Book {
   111  	if m != nil {
   112  		return m.Book
   113  	}
   114  	return nil
   115  }
   116  
   117  func (m *Request) GetUnpacked() []int64 {
   118  	if m != nil {
   119  		return m.Unpacked
   120  	}
   121  	return nil
   122  }
   123  
   124  type Book struct {
   125  	Title                string   `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"`
   126  	RawData              []byte   `protobuf:"bytes,2,opt,name=raw_data,json=rawData,proto3" json:"raw_data,omitempty"`
   127  	XXX_NoUnkeyedLiteral struct{} `json:"-"`
   128  	XXX_unrecognized     []byte   `json:"-"`
   129  	XXX_sizecache        int32    `json:"-"`
   130  }
   131  
   132  func (m *Book) Reset()         { *m = Book{} }
   133  func (m *Book) String() string { return proto.CompactTextString(m) }
   134  func (*Book) ProtoMessage()    {}
   135  func (*Book) Descriptor() ([]byte, []int) {
   136  	return fileDescriptor_ab04eb4084a521db, []int{1}
   137  }
   138  func (m *Book) XXX_Unmarshal(b []byte) error {
   139  	return xxx_messageInfo_Book.Unmarshal(m, b)
   140  }
   141  func (m *Book) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
   142  	return xxx_messageInfo_Book.Marshal(b, m, deterministic)
   143  }
   144  func (m *Book) XXX_Merge(src proto.Message) {
   145  	xxx_messageInfo_Book.Merge(m, src)
   146  }
   147  func (m *Book) XXX_Size() int {
   148  	return xxx_messageInfo_Book.Size(m)
   149  }
   150  func (m *Book) XXX_DiscardUnknown() {
   151  	xxx_messageInfo_Book.DiscardUnknown(m)
   152  }
   153  
   154  var xxx_messageInfo_Book proto.InternalMessageInfo
   155  
   156  func (m *Book) GetTitle() string {
   157  	if m != nil {
   158  		return m.Title
   159  	}
   160  	return ""
   161  }
   162  
   163  func (m *Book) GetRawData() []byte {
   164  	if m != nil {
   165  		return m.RawData
   166  	}
   167  	return nil
   168  }
   169  
   170  func init() {
   171  	proto.RegisterEnum("proto3.Request_Flavour", Request_Flavour_name, Request_Flavour_value)
   172  	proto.RegisterType((*Request)(nil), "proto3.Request")
   173  	proto.RegisterType((*Book)(nil), "proto3.Book")
   174  }
   175  
   176  func init() { proto.RegisterFile("proto3/proto3.proto", fileDescriptor_ab04eb4084a521db) }
   177  
   178  var fileDescriptor_ab04eb4084a521db = []byte{
   179  	// 303 bytes of a gzipped FileDescriptorProto
   180  	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x3c, 0x90, 0x4d, 0x4f, 0xf2, 0x40,
   181  	0x14, 0x85, 0x99, 0x7e, 0xbc, 0xc0, 0x7d, 0xd1, 0x8c, 0x57, 0x13, 0xc7, 0x8d, 0x99, 0xb0, 0xea,
   182  	0x86, 0x92, 0xe0, 0x42, 0x63, 0xdc, 0x88, 0xa2, 0x92, 0x48, 0x30, 0x83, 0xc4, 0xc4, 0x8d, 0x99,
   183  	0xc2, 0x58, 0x49, 0x81, 0xc1, 0x76, 0x2a, 0xf1, 0xcf, 0xfa, 0x5b, 0x4c, 0x3b, 0xc5, 0xd5, 0x3d,
   184  	0xf7, 0x23, 0xcf, 0xc9, 0x3d, 0x70, 0xb8, 0x49, 0xb5, 0xd1, 0x67, 0x5d, 0x5b, 0xc2, 0xb2, 0xe0,
   185  	0x3f, 0xdb, 0xb5, 0x7f, 0x08, 0xd4, 0x85, 0xfa, 0xcc, 0x55, 0x66, 0x10, 0xc1, 0x5b, 0xcb, 0x95,
   186  	0x62, 0x84, 0x93, 0xa0, 0x29, 0x4a, 0x8d, 0x14, 0xdc, 0x44, 0x7d, 0x33, 0x87, 0xbb, 0x81, 0x2b,
   187  	0x0a, 0x89, 0x1d, 0xf0, 0x8d, 0xcc, 0x8c, 0x62, 0x2e, 0x27, 0xc1, 0x7e, 0xef, 0x38, 0xac, 0xb8,
   188  	0x15, 0x25, 0xbc, 0x5b, 0xca, 0x2f, 0x9d, 0xa7, 0xc2, 0x5e, 0x21, 0x07, 0x2f, 0xd2, 0x3a, 0x61,
   189  	0x1e, 0x27, 0xc1, 0xff, 0x5e, 0x6b, 0x77, 0xdd, 0xd7, 0x3a, 0x11, 0xe5, 0x06, 0x4f, 0xa1, 0x91,
   190  	0xaf, 0x37, 0x72, 0x96, 0xa8, 0x39, 0xf3, 0x0b, 0x9f, 0xbe, 0x43, 0x6b, 0xe2, 0x6f, 0xd6, 0xbe,
   191  	0x82, 0x7a, 0xc5, 0xc4, 0x26, 0xf8, 0x93, 0x97, 0xc1, 0xe0, 0x99, 0xd6, 0xb0, 0x01, 0xde, 0x64,
   192  	0x3c, 0x15, 0x94, 0x14, 0xc3, 0xe9, 0xe8, 0x7a, 0x34, 0xa4, 0x0e, 0x1e, 0xc0, 0xde, 0xfd, 0xf8,
   193  	0xe9, 0x61, 0x20, 0x1e, 0x87, 0x37, 0xc3, 0xf1, 0x74, 0x42, 0xdd, 0xf6, 0x39, 0x78, 0x85, 0x17,
   194  	0x1e, 0x81, 0x6f, 0x16, 0x66, 0xb9, 0xfb, 0xce, 0x36, 0x78, 0x02, 0x8d, 0x54, 0x6e, 0xdf, 0xe6,
   195  	0xd2, 0x48, 0xe6, 0x70, 0x12, 0xb4, 0x44, 0x3d, 0x95, 0xdb, 0x5b, 0x69, 0x64, 0xff, 0xf2, 0xf5,
   196  	0x22, 0x5e, 0x98, 0x8f, 0x3c, 0x0a, 0x67, 0x7a, 0xd5, 0x8d, 0x75, 0xac, 0x6d, 0x82, 0x51, 0xfe,
   197  	0x6e, 0xc5, 0xac, 0x13, 0xab, 0x75, 0xa7, 0x5c, 0x18, 0x95, 0x99, 0x82, 0x51, 0x65, 0x1c, 0x55,
   198  	0xe9, 0xfe, 0x06, 0x00, 0x00, 0xff, 0xff, 0xf6, 0xe1, 0xfa, 0x46, 0x7b, 0x01, 0x00, 0x00,
   199  }