mirror of
https://github.com/chai2010/advanced-go-programming-book.git
synced 2025-05-24 20:52:22 +00:00
89 lines
3.4 KiB
Go
89 lines
3.4 KiB
Go
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// source: helloworld.proto
|
|
|
|
package main
|
|
|
|
import proto "github.com/golang/protobuf/proto"
|
|
import fmt "fmt"
|
|
import math "math"
|
|
import _ "github.com/mwitkow/go-proto-validators"
|
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
var _ = proto.Marshal
|
|
var _ = fmt.Errorf
|
|
var _ = math.Inf
|
|
|
|
// This is a compile-time assertion to ensure that this generated file
|
|
// is compatible with the proto package it is being compiled against.
|
|
// A compilation error at this line likely means your copy of the
|
|
// proto package needs to be updated.
|
|
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
|
|
|
|
type Message struct {
|
|
ImportantString string `protobuf:"bytes,1,opt,name=important_string,json=importantString,proto3" json:"important_string,omitempty"`
|
|
Age int32 `protobuf:"varint,2,opt,name=age,proto3" json:"age,omitempty"`
|
|
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
XXX_unrecognized []byte `json:"-"`
|
|
XXX_sizecache int32 `json:"-"`
|
|
}
|
|
|
|
func (m *Message) Reset() { *m = Message{} }
|
|
func (m *Message) String() string { return proto.CompactTextString(m) }
|
|
func (*Message) ProtoMessage() {}
|
|
func (*Message) Descriptor() ([]byte, []int) {
|
|
return fileDescriptor_helloworld_6a5a39a6dbe7620e, []int{0}
|
|
}
|
|
func (m *Message) XXX_Unmarshal(b []byte) error {
|
|
return xxx_messageInfo_Message.Unmarshal(m, b)
|
|
}
|
|
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
return xxx_messageInfo_Message.Marshal(b, m, deterministic)
|
|
}
|
|
func (dst *Message) XXX_Merge(src proto.Message) {
|
|
xxx_messageInfo_Message.Merge(dst, src)
|
|
}
|
|
func (m *Message) XXX_Size() int {
|
|
return xxx_messageInfo_Message.Size(m)
|
|
}
|
|
func (m *Message) XXX_DiscardUnknown() {
|
|
xxx_messageInfo_Message.DiscardUnknown(m)
|
|
}
|
|
|
|
var xxx_messageInfo_Message proto.InternalMessageInfo
|
|
|
|
func (m *Message) GetImportantString() string {
|
|
if m != nil {
|
|
return m.ImportantString
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (m *Message) GetAge() int32 {
|
|
if m != nil {
|
|
return m.Age
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func init() {
|
|
proto.RegisterType((*Message)(nil), "main.Message")
|
|
}
|
|
|
|
func init() { proto.RegisterFile("helloworld.proto", fileDescriptor_helloworld_6a5a39a6dbe7620e) }
|
|
|
|
var fileDescriptor_helloworld_6a5a39a6dbe7620e = []byte{
|
|
// 185 bytes of a gzipped FileDescriptorProto
|
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0xc8, 0x48, 0xcd, 0xc9,
|
|
0xc9, 0x2f, 0xcf, 0x2f, 0xca, 0x49, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0xc9, 0x4d,
|
|
0xcc, 0xcc, 0x93, 0x32, 0x4b, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0xcf,
|
|
0x2d, 0xcf, 0x2c, 0xc9, 0xce, 0x2f, 0xd7, 0x4f, 0xcf, 0xd7, 0x05, 0x2b, 0xd1, 0x2d, 0x4b, 0xcc,
|
|
0xc9, 0x4c, 0x49, 0x2c, 0xc9, 0x2f, 0x2a, 0xd6, 0x87, 0x33, 0x21, 0xba, 0x95, 0x52, 0xb8, 0xd8,
|
|
0x7d, 0x53, 0x8b, 0x8b, 0x13, 0xd3, 0x53, 0x85, 0x6c, 0xb9, 0x04, 0x32, 0x73, 0x0b, 0xf2, 0x8b,
|
|
0x4a, 0x12, 0xf3, 0x4a, 0xe2, 0x8b, 0x4b, 0x8a, 0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