github.com/myafeier/fabric@v1.0.1-0.20170722181825-3a4b1f2bce86/common/tools/protolator/testprotos/sample.pb.go (about) 1 // Code generated by protoc-gen-go. DO NOT EDIT. 2 // source: sample.proto 3 4 /* 5 Package testprotos is a generated protocol buffer package. 6 7 It is generated from these files: 8 sample.proto 9 10 It has these top-level messages: 11 SimpleMsg 12 NestedMsg 13 StaticallyOpaqueMsg 14 VariablyOpaqueMsg 15 DynamicMsg 16 ContextlessMsg 17 */ 18 package testprotos 19 20 import proto "github.com/golang/protobuf/proto" 21 import fmt "fmt" 22 import math "math" 23 24 // Reference imports to suppress errors if they are not otherwise used. 25 var _ = proto.Marshal 26 var _ = fmt.Errorf 27 var _ = math.Inf 28 29 // This is a compile-time assertion to ensure that this generated file 30 // is compatible with the proto package it is being compiled against. 31 // A compilation error at this line likely means your copy of the 32 // proto package needs to be updated. 33 const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package 34 35 // SimpleMsg is designed to test that all three types of message fields, plain, map, 36 // and slice are handled by the protolator tool 37 type SimpleMsg struct { 38 PlainField string `protobuf:"bytes,1,opt,name=plain_field,json=plainField" json:"plain_field,omitempty"` 39 MapField map[string]string `protobuf:"bytes,2,rep,name=map_field,json=mapField" json:"map_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` 40 SliceField []string `protobuf:"bytes,3,rep,name=slice_field,json=sliceField" json:"slice_field,omitempty"` 41 } 42 43 func (m *SimpleMsg) Reset() { *m = SimpleMsg{} } 44 func (m *SimpleMsg) String() string { return proto.CompactTextString(m) } 45 func (*SimpleMsg) ProtoMessage() {} 46 func (*SimpleMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } 47 48 func (m *SimpleMsg) GetPlainField() string { 49 if m != nil { 50 return m.PlainField 51 } 52 return "" 53 } 54 55 func (m *SimpleMsg) GetMapField() map[string]string { 56 if m != nil { 57 return m.MapField 58 } 59 return nil 60 } 61 62 func (m *SimpleMsg) GetSliceField() []string { 63 if m != nil { 64 return m.SliceField 65 } 66 return nil 67 } 68 69 // NestedMsg is designed to test the nested message component 70 type NestedMsg struct { 71 PlainNestedField *SimpleMsg `protobuf:"bytes,1,opt,name=plain_nested_field,json=plainNestedField" json:"plain_nested_field,omitempty"` 72 MapNestedField map[string]*SimpleMsg `protobuf:"bytes,2,rep,name=map_nested_field,json=mapNestedField" json:"map_nested_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` 73 SliceNestedField []*SimpleMsg `protobuf:"bytes,3,rep,name=slice_nested_field,json=sliceNestedField" json:"slice_nested_field,omitempty"` 74 } 75 76 func (m *NestedMsg) Reset() { *m = NestedMsg{} } 77 func (m *NestedMsg) String() string { return proto.CompactTextString(m) } 78 func (*NestedMsg) ProtoMessage() {} 79 func (*NestedMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } 80 81 func (m *NestedMsg) GetPlainNestedField() *SimpleMsg { 82 if m != nil { 83 return m.PlainNestedField 84 } 85 return nil 86 } 87 88 func (m *NestedMsg) GetMapNestedField() map[string]*SimpleMsg { 89 if m != nil { 90 return m.MapNestedField 91 } 92 return nil 93 } 94 95 func (m *NestedMsg) GetSliceNestedField() []*SimpleMsg { 96 if m != nil { 97 return m.SliceNestedField 98 } 99 return nil 100 } 101 102 // StaticallyOpaqueMsg is designed to test the statically opaque message component 103 // All fields are statically marshaled to the NestedMsg type 104 type StaticallyOpaqueMsg struct { 105 PlainOpaqueField []byte `protobuf:"bytes,1,opt,name=plain_opaque_field,json=plainOpaqueField,proto3" json:"plain_opaque_field,omitempty"` 106 MapOpaqueField map[string][]byte `protobuf:"bytes,2,rep,name=map_opaque_field,json=mapOpaqueField" json:"map_opaque_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value,proto3"` 107 SliceOpaqueField [][]byte `protobuf:"bytes,3,rep,name=slice_opaque_field,json=sliceOpaqueField,proto3" json:"slice_opaque_field,omitempty"` 108 } 109 110 func (m *StaticallyOpaqueMsg) Reset() { *m = StaticallyOpaqueMsg{} } 111 func (m *StaticallyOpaqueMsg) String() string { return proto.CompactTextString(m) } 112 func (*StaticallyOpaqueMsg) ProtoMessage() {} 113 func (*StaticallyOpaqueMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} } 114 115 func (m *StaticallyOpaqueMsg) GetPlainOpaqueField() []byte { 116 if m != nil { 117 return m.PlainOpaqueField 118 } 119 return nil 120 } 121 122 func (m *StaticallyOpaqueMsg) GetMapOpaqueField() map[string][]byte { 123 if m != nil { 124 return m.MapOpaqueField 125 } 126 return nil 127 } 128 129 func (m *StaticallyOpaqueMsg) GetSliceOpaqueField() [][]byte { 130 if m != nil { 131 return m.SliceOpaqueField 132 } 133 return nil 134 } 135 136 // VariablyOpaqueMsg is designed to test the staticaly opaque message component 137 // The opaque type is determined by opaque_type 138 type VariablyOpaqueMsg struct { 139 OpaqueType string `protobuf:"bytes,1,opt,name=opaque_type,json=opaqueType" json:"opaque_type,omitempty"` 140 PlainOpaqueField []byte `protobuf:"bytes,2,opt,name=plain_opaque_field,json=plainOpaqueField,proto3" json:"plain_opaque_field,omitempty"` 141 MapOpaqueField map[string][]byte `protobuf:"bytes,3,rep,name=map_opaque_field,json=mapOpaqueField" json:"map_opaque_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value,proto3"` 142 SliceOpaqueField [][]byte `protobuf:"bytes,4,rep,name=slice_opaque_field,json=sliceOpaqueField,proto3" json:"slice_opaque_field,omitempty"` 143 } 144 145 func (m *VariablyOpaqueMsg) Reset() { *m = VariablyOpaqueMsg{} } 146 func (m *VariablyOpaqueMsg) String() string { return proto.CompactTextString(m) } 147 func (*VariablyOpaqueMsg) ProtoMessage() {} 148 func (*VariablyOpaqueMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} } 149 150 func (m *VariablyOpaqueMsg) GetOpaqueType() string { 151 if m != nil { 152 return m.OpaqueType 153 } 154 return "" 155 } 156 157 func (m *VariablyOpaqueMsg) GetPlainOpaqueField() []byte { 158 if m != nil { 159 return m.PlainOpaqueField 160 } 161 return nil 162 } 163 164 func (m *VariablyOpaqueMsg) GetMapOpaqueField() map[string][]byte { 165 if m != nil { 166 return m.MapOpaqueField 167 } 168 return nil 169 } 170 171 func (m *VariablyOpaqueMsg) GetSliceOpaqueField() [][]byte { 172 if m != nil { 173 return m.SliceOpaqueField 174 } 175 return nil 176 } 177 178 // DynamicMsg is designed to test the dynamic message component 179 // The dynamic wrapper applied to ContextlessMsg is determined by 180 // dynamic_type 181 type DynamicMsg struct { 182 DynamicType string `protobuf:"bytes,1,opt,name=dynamic_type,json=dynamicType" json:"dynamic_type,omitempty"` 183 PlainDynamicField *ContextlessMsg `protobuf:"bytes,2,opt,name=plain_dynamic_field,json=plainDynamicField" json:"plain_dynamic_field,omitempty"` 184 MapDynamicField map[string]*ContextlessMsg `protobuf:"bytes,3,rep,name=map_dynamic_field,json=mapDynamicField" json:"map_dynamic_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` 185 SliceDynamicField []*ContextlessMsg `protobuf:"bytes,4,rep,name=slice_dynamic_field,json=sliceDynamicField" json:"slice_dynamic_field,omitempty"` 186 } 187 188 func (m *DynamicMsg) Reset() { *m = DynamicMsg{} } 189 func (m *DynamicMsg) String() string { return proto.CompactTextString(m) } 190 func (*DynamicMsg) ProtoMessage() {} 191 func (*DynamicMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} } 192 193 func (m *DynamicMsg) GetDynamicType() string { 194 if m != nil { 195 return m.DynamicType 196 } 197 return "" 198 } 199 200 func (m *DynamicMsg) GetPlainDynamicField() *ContextlessMsg { 201 if m != nil { 202 return m.PlainDynamicField 203 } 204 return nil 205 } 206 207 func (m *DynamicMsg) GetMapDynamicField() map[string]*ContextlessMsg { 208 if m != nil { 209 return m.MapDynamicField 210 } 211 return nil 212 } 213 214 func (m *DynamicMsg) GetSliceDynamicField() []*ContextlessMsg { 215 if m != nil { 216 return m.SliceDynamicField 217 } 218 return nil 219 } 220 221 // ContextlessMsg is designed to carry a message of completely arbitrary type 222 // Because there is no context for the type embedded in the message, the opaque 223 // type must be dynamically added at runtime 224 type ContextlessMsg struct { 225 OpaqueField []byte `protobuf:"bytes,1,opt,name=opaque_field,json=opaqueField,proto3" json:"opaque_field,omitempty"` 226 } 227 228 func (m *ContextlessMsg) Reset() { *m = ContextlessMsg{} } 229 func (m *ContextlessMsg) String() string { return proto.CompactTextString(m) } 230 func (*ContextlessMsg) ProtoMessage() {} 231 func (*ContextlessMsg) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} } 232 233 func (m *ContextlessMsg) GetOpaqueField() []byte { 234 if m != nil { 235 return m.OpaqueField 236 } 237 return nil 238 } 239 240 func init() { 241 proto.RegisterType((*SimpleMsg)(nil), "testprotos.SimpleMsg") 242 proto.RegisterType((*NestedMsg)(nil), "testprotos.NestedMsg") 243 proto.RegisterType((*StaticallyOpaqueMsg)(nil), "testprotos.StaticallyOpaqueMsg") 244 proto.RegisterType((*VariablyOpaqueMsg)(nil), "testprotos.VariablyOpaqueMsg") 245 proto.RegisterType((*DynamicMsg)(nil), "testprotos.DynamicMsg") 246 proto.RegisterType((*ContextlessMsg)(nil), "testprotos.ContextlessMsg") 247 } 248 249 func init() { proto.RegisterFile("sample.proto", fileDescriptor0) } 250 251 var fileDescriptor0 = []byte{ 252 // 577 bytes of a gzipped FileDescriptorProto 253 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x93, 0x41, 0x6f, 0xd3, 0x30, 254 0x14, 0xc7, 0xd5, 0x64, 0x20, 0xfa, 0x12, 0x46, 0x9b, 0x0e, 0x69, 0xca, 0x65, 0x65, 0x5c, 0x86, 255 0x36, 0x25, 0xd0, 0x5e, 0x10, 0x5c, 0xc6, 0x06, 0x1c, 0x90, 0x06, 0x52, 0x8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0xc6, 0x54, 0xde, 0xe8, 0x66, 0x6b, 0xec, 0x49, 0x0f, 0x1b, 0x94, 0x84, 0x0a, 0x3c, 0x85, 0x9e, 268 0x1c, 0xd9, 0x92, 0x50, 0x93, 0xdf, 0x31, 0x25, 0xce, 0x5d, 0xe5, 0xe4, 0x46, 0xbf, 0x9a, 0x7f, 269 0x33, 0xb3, 0x8a, 0x32, 0x99, 0xa2, 0x60, 0xc9, 0xba, 0x28, 0xbb, 0x2e, 0x19, 0x36, 0x18, 0x22, 270 0xe1, 0x1b, 0x18, 0xb4, 0x78, 0xb5, 0xf0, 0xda, 0x37, 0x79, 0xad, 0x35, 0x30, 0x30, 0x7e, 0x77, 271 0x60, 0x30, 0x15, 0x44, 0xa4, 0x09, 0x61, 0xac, 0x7e, 0x51, 0x90, 0xcf, 0x4b, 0xbc, 0x1f, 0x07, 272 0x2b, 0xa0, 0x1c, 0x4b, 0x06, 0x50, 0x5f, 0x93, 0x53, 0x67, 0xd5, 0x90, 0xef, 0x15, 0x39, 0xeb, 273 0xac, 0x22, 0x37, 0xb6, 0x12, 0x5c, 0x34, 0x92, 0x0c, 0x0d, 0xa5, 0x86, 0xa1, 0x29, 0x7f, 0xb0, 274 0x62, 0x68, 0x19, 0x48, 0x86, 0xbe, 0x86, 0x65, 0x9c, 0x0e, 0x1f, 0x21, 0xac, 0x3f, 0x45, 0xff, 275 0x76, 0xb9, 0x7c, 0x93, 0xca, 0x0f, 0x07, 0xfa, 0xaf, 0x48, 0x99, 0x92, 0x99, 0xc9, 0x64, 0x07, 276 0x3c, 0x1d, 0x40, 0xd4, 0x05, 0x5d, 0xbd, 0x19, 0x55, 0x7a, 0x59, 0x17, 0x74, 0x0d, 0x34, 0x67, 277 0x0d, 0xb4, 0x77, 0x2d, 0xd0, 0xd4, 0xbd, 0xb8, 0x67, 0x42, 0xbb, 0x90, 0xe3, 0x1f, 0x90, 0x6d, 278 0xfc, 0x3f, 0x64, 0xdf, 0x5c, 0x80, 0xc7, 0x75, 0x4e, 0xb2, 0x34, 0x91, 0xac, 0x6e, 0x81, 0x3f, 279 0x57, 0x2b, 0x13, 0x96, 0xa7, 0x6b, 0x48, 0xeb, 0x19, 0x0c, 0x14, 0xad, 0xd5, 0xc1, 0x06, 0x97, 280 0x37, 0x0a, 0x4d, 0x04, 0xc7, 0x3c, 0x17, 0xf4, 0xab, 0x60, 0xb4, 0xaa, 0xe4, 0xf5, 0xed, 0x63, 281 0x9b, 0x36, 0x53, 0xe3, 0xbe, 0x86, 0xbe, 0x64, 0x69, 0x2b, 0x29, 0x98, 0xfb, 0xa6, 0x52, 0x93, 282 0x50, 0x52, 0x34, 0x25, 0x14, 0xc6, 0x1b, 0x99, 0x5d, 0x95, 0x21, 0x15, 0x47, 0x5b, 0x7a, 0x03, 283 0xa5, 0x2f, 0x0d, 0x89, 0x6d, 0xa6, 0x56, 0xf8, 0x01, 0xb6, 0xda, 0x4c, 0x5b, 0x30, 0xdf, 0xb5, 284 0x9f, 0xf1, 0x65, 0x3e, 0xc6, 0x27, 0x18, 0xc3, 0xa6, 0xbd, 0x29, 0xbf, 0x42, 0xcb, 0xfb, 0xd5, 285 0xb7, 0x18, 0x13, 0x1c, 0x1d, 0xbd, 0x3d, 0x5c, 0xa4, 0xe2, 0x6c, 0x39, 0x8b, 0x12, 0x9e, 0xc5, 286 0x67, 0x75, 0x41, 0x4b, 0x46, 0xe7, 0x0b, 0x5a, 0xc6, 0xa7, 0x64, 0x56, 0xa6, 0x49, 0x9c, 0xf0, 287 0x2c, 0xe3, 0x79, 0x2c, 0x38, 0x67, 0x55, 0x8c, 0x19, 0x18, 0x11, 0xbc, 0x8c, 0x9b, 0x48, 0xb3, 288 0xab, 0xf8, 0x3b, 0xfe, 0x1d, 0x00, 0x00, 0xff, 0xff, 0xb4, 0x56, 0x77, 0x65, 0x7d, 0x06, 0x00, 289 0x00, 290 }