// Code generated by protoc-gen-go. // source: encode.proto // DO NOT EDIT! package nmsg_base import proto "github.com/golang/protobuf/proto" import fmt "fmt" import math "math" // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf type EncodeType int32 const ( EncodeType_TEXT EncodeType = 0 EncodeType_JSON EncodeType = 1 EncodeType_YAML EncodeType = 2 EncodeType_MSGPACK EncodeType = 3 EncodeType_XML EncodeType = 4 ) var EncodeType_name = map[int32]string{ 0: "TEXT", 1: "JSON", 2: "YAML", 3: "MSGPACK", 4: "XML", } var EncodeType_value = map[string]int32{ "TEXT": 0, "JSON": 1, "YAML": 2, "MSGPACK": 3, "XML": 4, } func (x EncodeType) Enum() *EncodeType { p := new(EncodeType) *p = x return p } func (x EncodeType) String() string { return proto.EnumName(EncodeType_name, int32(x)) } func (x *EncodeType) UnmarshalJSON(data []byte) error { value, err := proto.UnmarshalJSONEnum(EncodeType_value, data, "EncodeType") if err != nil { return err } *x = EncodeType(value) return nil } func (EncodeType) EnumDescriptor() ([]byte, []int) { return fileDescriptor3, []int{0} } type Encode struct { Type *EncodeType `protobuf:"varint,1,req,name=type,enum=nmsg.base.EncodeType" json:"type,omitempty"` Payload []byte `protobuf:"bytes,2,req,name=payload" json:"payload,omitempty"` XXX_unrecognized []byte `json:"-"` } func (m *Encode) Reset() { *m = Encode{} } func (m *Encode) String() string { return proto.CompactTextString(m) } func (*Encode) ProtoMessage() {} func (*Encode) Descriptor() ([]byte, []int) { return fileDescriptor3, []int{0} } func (m *Encode) GetType() EncodeType { if m != nil && m.Type != nil { return *m.Type } return EncodeType_TEXT } func (m *Encode) GetPayload() []byte { if m != nil { return m.Payload } return nil } func init() { proto.RegisterType((*Encode)(nil), "nmsg.base.Encode") proto.RegisterEnum("nmsg.base.EncodeType", EncodeType_name, EncodeType_value) } func init() { proto.RegisterFile("encode.proto", fileDescriptor3) } var fileDescriptor3 = []byte{ // 148 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe2, 0xe2, 0x49, 0xcd, 0x4b, 0xce, 0x4f, 0x49, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xcc, 0xcb, 0x2d, 0x4e, 0xd7, 0x4b, 0x4a, 0x2c, 0x4e, 0x55, 0xb2, 0xe3, 0x62, 0x73, 0x05, 0x4b, 0x09, 0x29, 0x73, 0xb1, 0x94, 0x54, 0x16, 0xa4, 0x4a, 0x30, 0x2a, 0x30, 0x69, 0xf0, 0x19, 0x89, 0xea, 0xc1, 0xd5, 0xe8, 0x41, 0x14, 0x84, 0x00, 0x25, 0x85, 0xf8, 0xb9, 0xd8, 0x0b, 0x12, 0x2b, 0x73, 0xf2, 0x13, 0x53, 0x24, 0x98, 0x80, 0xea, 0x78, 0xb4, 0x1c, 0xb8, 0xb8, 0x90, 0xa4, 0x39, 0xb8, 0x58, 0x42, 0x5c, 0x23, 0x42, 0x04, 0x18, 0x40, 0x2c, 0xaf, 0x60, 0x7f, 0x3f, 0x01, 0x46, 0x10, 0x2b, 0xd2, 0xd1, 0xd7, 0x47, 0x80, 0x49, 0x88, 0x9b, 0x8b, 0xdd, 0x37, 0xd8, 0x3d, 0xc0, 0xd1, 0xd9, 0x5b, 0x80, 0x59, 0x88, 0x9d, 0x8b, 0x39, 0x02, 0x28, 0xca, 0x02, 0x08, 0x00, 0x00, 0xff, 0xff, 0xb9, 0x9e, 0xfe, 0xff, 0x9b, 0x00, 0x00, 0x00, }