github.com/amazechain/amc@v0.1.3/api/protocol/msg_proto/msg.pb.go (about) 1 // Copyright 2022 The AmazeChain Authors 2 // This file is part of the AmazeChain library. 3 // 4 // The AmazeChain library is free software: you can redistribute it and/or modify 5 // it under the terms of the GNU Lesser General Public License as published by 6 // the Free Software Foundation, either version 3 of the License, or 7 // (at your option) any later version. 8 // 9 // The AmazeChain library is distributed in the hope that it will be useful, 10 // but WITHOUT ANY WARRANTY; without even the implied warranty of 11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 // GNU Lesser General Public License for more details. 13 // 14 // You should have received a copy of the GNU Lesser General Public License 15 // along with the AmazeChain library. If not, see <http://www.gnu.org/licenses/>. 16 17 // Code generated by protoc-gen-go. DO NOT EDIT. 18 // versions: 19 // protoc-gen-go v1.26.0 20 // protoc v3.20.0 21 // source: msg.proto 22 23 package msg_proto 24 25 import ( 26 types_pb "github.com/amazechain/amc/api/protocol/types_pb" 27 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 28 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 29 reflect "reflect" 30 sync "sync" 31 ) 32 33 const ( 34 // Verify that this generated code is sufficiently up-to-date. 35 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 36 // Verify that runtime/protoimpl is sufficiently up-to-date. 37 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 38 ) 39 40 type MessageData struct { 41 state protoimpl.MessageState 42 sizeCache protoimpl.SizeCache 43 unknownFields protoimpl.UnknownFields 44 45 ClientVersion string `protobuf:"bytes,2,opt,name=clientVersion,proto3" json:"clientVersion,omitempty"` //client version 46 Timestamp int64 `protobuf:"varint,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"` //unix time 47 Id string `protobuf:"bytes,4,opt,name=id,proto3" json:"id,omitempty"` // message id hash256(payload) 48 NodeID string `protobuf:"bytes,5,opt,name=nodeID,proto3" json:"nodeID,omitempty"` //id of peer that created the message, not the peer that may have send it. 49 NodePubKey []byte `protobuf:"bytes,6,opt,name=nodePubKey,proto3" json:"nodePubKey,omitempty"` // peer public key 50 Sign []byte `protobuf:"bytes,7,opt,name=sign,proto3" json:"sign,omitempty"` // signature of message data 51 Payload []byte `protobuf:"bytes,8,opt,name=payload,proto3" json:"payload,omitempty"` // payload 52 Gossip bool `protobuf:"varint,9,opt,name=gossip,proto3" json:"gossip,omitempty"` 53 } 54 55 func (x *MessageData) Reset() { 56 *x = MessageData{} 57 if protoimpl.UnsafeEnabled { 58 mi := &file_msg_proto_msgTypes[0] 59 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 60 ms.StoreMessageInfo(mi) 61 } 62 } 63 64 func (x *MessageData) String() string { 65 return protoimpl.X.MessageStringOf(x) 66 } 67 68 func (*MessageData) ProtoMessage() {} 69 70 func (x *MessageData) ProtoReflect() protoreflect.Message { 71 mi := &file_msg_proto_msgTypes[0] 72 if protoimpl.UnsafeEnabled && x != nil { 73 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 74 if ms.LoadMessageInfo() == nil { 75 ms.StoreMessageInfo(mi) 76 } 77 return ms 78 } 79 return mi.MessageOf(x) 80 } 81 82 // Deprecated: Use MessageData.ProtoReflect.Descriptor instead. 83 func (*MessageData) Descriptor() ([]byte, []int) { 84 return file_msg_proto_rawDescGZIP(), []int{0} 85 } 86 87 func (x *MessageData) GetClientVersion() string { 88 if x != nil { 89 return x.ClientVersion 90 } 91 return "" 92 } 93 94 func (x *MessageData) GetTimestamp() int64 { 95 if x != nil { 96 return x.Timestamp 97 } 98 return 0 99 } 100 101 func (x *MessageData) GetId() string { 102 if x != nil { 103 return x.Id 104 } 105 return "" 106 } 107 108 func (x *MessageData) GetNodeID() string { 109 if x != nil { 110 return x.NodeID 111 } 112 return "" 113 } 114 115 func (x *MessageData) GetNodePubKey() []byte { 116 if x != nil { 117 return x.NodePubKey 118 } 119 return nil 120 } 121 122 func (x *MessageData) GetSign() []byte { 123 if x != nil { 124 return x.Sign 125 } 126 return nil 127 } 128 129 func (x *MessageData) GetPayload() []byte { 130 if x != nil { 131 return x.Payload 132 } 133 return nil 134 } 135 136 func (x *MessageData) GetGossip() bool { 137 if x != nil { 138 return x.Gossip 139 } 140 return false 141 } 142 143 type NewBlockMessageData struct { 144 state protoimpl.MessageState 145 sizeCache protoimpl.SizeCache 146 unknownFields protoimpl.UnknownFields 147 148 Hash *types_pb.H256 `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` 149 Number *types_pb.H256 `protobuf:"bytes,2,opt,name=Number,proto3" json:"Number,omitempty"` 150 Block *types_pb.Block `protobuf:"bytes,3,opt,name=block,proto3" json:"block,omitempty"` 151 } 152 153 func (x *NewBlockMessageData) Reset() { 154 *x = NewBlockMessageData{} 155 if protoimpl.UnsafeEnabled { 156 mi := &file_msg_proto_msgTypes[1] 157 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 158 ms.StoreMessageInfo(mi) 159 } 160 } 161 162 func (x *NewBlockMessageData) String() string { 163 return protoimpl.X.MessageStringOf(x) 164 } 165 166 func (*NewBlockMessageData) ProtoMessage() {} 167 168 func (x *NewBlockMessageData) ProtoReflect() protoreflect.Message { 169 mi := &file_msg_proto_msgTypes[1] 170 if protoimpl.UnsafeEnabled && x != nil { 171 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 172 if ms.LoadMessageInfo() == nil { 173 ms.StoreMessageInfo(mi) 174 } 175 return ms 176 } 177 return mi.MessageOf(x) 178 } 179 180 // Deprecated: Use NewBlockMessageData.ProtoReflect.Descriptor instead. 181 func (*NewBlockMessageData) Descriptor() ([]byte, []int) { 182 return file_msg_proto_rawDescGZIP(), []int{1} 183 } 184 185 func (x *NewBlockMessageData) GetHash() *types_pb.H256 { 186 if x != nil { 187 return x.Hash 188 } 189 return nil 190 } 191 192 func (x *NewBlockMessageData) GetNumber() *types_pb.H256 { 193 if x != nil { 194 return x.Number 195 } 196 return nil 197 } 198 199 func (x *NewBlockMessageData) GetBlock() *types_pb.Block { 200 if x != nil { 201 return x.Block 202 } 203 return nil 204 } 205 206 type ProtocolHandshakeMessage struct { 207 state protoimpl.MessageState 208 sizeCache protoimpl.SizeCache 209 unknownFields protoimpl.UnknownFields 210 211 Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` 212 GenesisHash *types_pb.H256 `protobuf:"bytes,2,opt,name=genesisHash,proto3" json:"genesisHash,omitempty"` 213 CurrentHeight *types_pb.H256 `protobuf:"bytes,3,opt,name=currentHeight,proto3" json:"currentHeight,omitempty"` 214 } 215 216 func (x *ProtocolHandshakeMessage) Reset() { 217 *x = ProtocolHandshakeMessage{} 218 if protoimpl.UnsafeEnabled { 219 mi := &file_msg_proto_msgTypes[2] 220 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 221 ms.StoreMessageInfo(mi) 222 } 223 } 224 225 func (x *ProtocolHandshakeMessage) String() string { 226 return protoimpl.X.MessageStringOf(x) 227 } 228 229 func (*ProtocolHandshakeMessage) ProtoMessage() {} 230 231 func (x *ProtocolHandshakeMessage) ProtoReflect() protoreflect.Message { 232 mi := &file_msg_proto_msgTypes[2] 233 if protoimpl.UnsafeEnabled && x != nil { 234 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 235 if ms.LoadMessageInfo() == nil { 236 ms.StoreMessageInfo(mi) 237 } 238 return ms 239 } 240 return mi.MessageOf(x) 241 } 242 243 // Deprecated: Use ProtocolHandshakeMessage.ProtoReflect.Descriptor instead. 244 func (*ProtocolHandshakeMessage) Descriptor() ([]byte, []int) { 245 return file_msg_proto_rawDescGZIP(), []int{2} 246 } 247 248 func (x *ProtocolHandshakeMessage) GetVersion() string { 249 if x != nil { 250 return x.Version 251 } 252 return "" 253 } 254 255 func (x *ProtocolHandshakeMessage) GetGenesisHash() *types_pb.H256 { 256 if x != nil { 257 return x.GenesisHash 258 } 259 return nil 260 } 261 262 func (x *ProtocolHandshakeMessage) GetCurrentHeight() *types_pb.H256 { 263 if x != nil { 264 return x.CurrentHeight 265 } 266 return nil 267 } 268 269 type TopicScoreSnapshot struct { 270 state protoimpl.MessageState 271 sizeCache protoimpl.SizeCache 272 unknownFields protoimpl.UnknownFields 273 274 // Time a peer has spent in the gossip mesh. 275 TimeInMesh uint64 `protobuf:"varint,1,opt,name=time_in_mesh,json=timeInMesh,proto3" json:"time_in_mesh,omitempty"` 276 // This is the number of first message deliveries in the topic. 277 FirstMessageDeliveries float32 `protobuf:"fixed32,2,opt,name=first_message_deliveries,json=firstMessageDeliveries,proto3" json:"first_message_deliveries,omitempty"` 278 // This is the number of message deliveries in the mesh, within the MeshMessageDeliveriesWindow of 279 // message validation.It effectively tracks first and near-first 280 // deliveries, ie a message seen from a mesh peer before we have forwarded it to them. 281 MeshMessageDeliveries float32 `protobuf:"fixed32,3,opt,name=mesh_message_deliveries,json=meshMessageDeliveries,proto3" json:"mesh_message_deliveries,omitempty"` 282 // This is the number of invalid messages in the topic from the peer. 283 InvalidMessageDeliveries float32 `protobuf:"fixed32,4,opt,name=invalid_message_deliveries,json=invalidMessageDeliveries,proto3" json:"invalid_message_deliveries,omitempty"` 284 } 285 286 func (x *TopicScoreSnapshot) Reset() { 287 *x = TopicScoreSnapshot{} 288 if protoimpl.UnsafeEnabled { 289 mi := &file_msg_proto_msgTypes[3] 290 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 291 ms.StoreMessageInfo(mi) 292 } 293 } 294 295 func (x *TopicScoreSnapshot) String() string { 296 return protoimpl.X.MessageStringOf(x) 297 } 298 299 func (*TopicScoreSnapshot) ProtoMessage() {} 300 301 func (x *TopicScoreSnapshot) ProtoReflect() protoreflect.Message { 302 mi := &file_msg_proto_msgTypes[3] 303 if protoimpl.UnsafeEnabled && x != nil { 304 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 305 if ms.LoadMessageInfo() == nil { 306 ms.StoreMessageInfo(mi) 307 } 308 return ms 309 } 310 return mi.MessageOf(x) 311 } 312 313 // Deprecated: Use TopicScoreSnapshot.ProtoReflect.Descriptor instead. 314 func (*TopicScoreSnapshot) Descriptor() ([]byte, []int) { 315 return file_msg_proto_rawDescGZIP(), []int{3} 316 } 317 318 func (x *TopicScoreSnapshot) GetTimeInMesh() uint64 { 319 if x != nil { 320 return x.TimeInMesh 321 } 322 return 0 323 } 324 325 func (x *TopicScoreSnapshot) GetFirstMessageDeliveries() float32 { 326 if x != nil { 327 return x.FirstMessageDeliveries 328 } 329 return 0 330 } 331 332 func (x *TopicScoreSnapshot) GetMeshMessageDeliveries() float32 { 333 if x != nil { 334 return x.MeshMessageDeliveries 335 } 336 return 0 337 } 338 339 func (x *TopicScoreSnapshot) GetInvalidMessageDeliveries() float32 { 340 if x != nil { 341 return x.InvalidMessageDeliveries 342 } 343 return 0 344 } 345 346 var File_msg_proto protoreflect.FileDescriptor 347 348 var file_msg_proto_rawDesc = []byte{ 349 0x0a, 0x09, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x09, 0x6d, 0x73, 0x67, 350 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x74, 0x79, 0x70, 0x65, 0x73, 0x5f, 0x70, 0x62, 351 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xdf, 0x01, 0x0a, 352 0x0b, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x44, 0x61, 0x74, 0x61, 0x12, 0x24, 0x0a, 0x0d, 353 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 354 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x56, 0x65, 0x72, 0x73, 0x69, 355 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 356 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 357 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 358 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x44, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 359 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x44, 0x12, 0x1e, 0x0a, 0x0a, 0x6e, 0x6f, 0x64, 0x65, 360 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x6e, 0x6f, 361 0x64, 0x65, 0x50, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x67, 0x6e, 362 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x73, 0x69, 0x67, 0x6e, 0x12, 0x18, 0x0a, 0x07, 363 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x70, 364 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x67, 0x6f, 0x73, 0x73, 0x69, 0x70, 365 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x67, 0x6f, 0x73, 0x73, 0x69, 0x70, 0x22, 0x88, 366 0x01, 0x0a, 0x13, 0x4e, 0x65, 0x77, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4d, 0x65, 0x73, 0x73, 0x61, 367 0x67, 0x65, 0x44, 0x61, 0x74, 0x61, 0x12, 0x22, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 368 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x5f, 0x70, 0x62, 0x2e, 369 0x48, 0x32, 0x35, 0x36, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x26, 0x0a, 0x06, 0x4e, 0x75, 370 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x74, 0x79, 0x70, 371 0x65, 0x73, 0x5f, 0x70, 0x62, 0x2e, 0x48, 0x32, 0x35, 0x36, 0x52, 0x06, 0x4e, 0x75, 0x6d, 0x62, 372 0x65, 0x72, 0x12, 0x25, 0x0a, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x03, 0x20, 0x01, 0x28, 373 0x0b, 0x32, 0x0f, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x5f, 0x70, 0x62, 0x2e, 0x42, 0x6c, 0x6f, 374 0x63, 0x6b, 0x52, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x22, 0x9c, 0x01, 0x0a, 0x18, 0x50, 0x72, 375 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x48, 0x61, 0x6e, 0x64, 0x73, 0x68, 0x61, 0x6b, 0x65, 0x4d, 376 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 377 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 378 0x12, 0x30, 0x0a, 0x0b, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x48, 0x61, 0x73, 0x68, 0x18, 379 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x5f, 0x70, 0x62, 380 0x2e, 0x48, 0x32, 0x35, 0x36, 0x52, 0x0b, 0x67, 0x65, 0x6e, 0x65, 0x73, 0x69, 0x73, 0x48, 0x61, 381 0x73, 0x68, 0x12, 0x34, 0x0a, 0x0d, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x48, 0x65, 0x69, 382 0x67, 0x68, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x74, 0x79, 0x70, 0x65, 383 0x73, 0x5f, 0x70, 0x62, 0x2e, 0x48, 0x32, 0x35, 0x36, 0x52, 0x0d, 0x63, 0x75, 0x72, 0x72, 0x65, 384 0x6e, 0x74, 0x48, 0x65, 0x69, 0x67, 0x68, 0x74, 0x22, 0xe6, 0x01, 0x0a, 0x12, 0x54, 0x6f, 0x70, 385 0x69, 0x63, 0x53, 0x63, 0x6f, 0x72, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 386 0x20, 0x0a, 0x0c, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x69, 0x6e, 0x5f, 0x6d, 0x65, 0x73, 0x68, 0x18, 387 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x49, 0x6e, 0x4d, 0x65, 0x73, 388 0x68, 0x12, 0x38, 0x0a, 0x18, 0x66, 0x69, 0x72, 0x73, 0x74, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 389 0x67, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x69, 0x65, 0x73, 0x18, 0x02, 0x20, 390 0x01, 0x28, 0x02, 0x52, 0x16, 0x66, 0x69, 0x72, 0x73, 0x74, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 391 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x69, 0x65, 0x73, 0x12, 0x36, 0x0a, 0x17, 0x6d, 392 0x65, 0x73, 0x68, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x69, 393 0x76, 0x65, 0x72, 0x69, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x15, 0x6d, 0x65, 394 0x73, 0x68, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 395 0x69, 0x65, 0x73, 0x12, 0x3c, 0x0a, 0x1a, 0x69, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x5f, 0x6d, 396 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x69, 0x65, 397 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x02, 0x52, 0x18, 0x69, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 398 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x69, 0x65, 399 0x73, 0x42, 0x32, 0x5a, 0x30, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 400 0x61, 0x6d, 0x61, 0x7a, 0x65, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2f, 0x61, 0x6d, 0x63, 0x2f, 0x61, 401 0x70, 0x69, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x63, 0x6f, 0x6c, 0x2f, 0x6d, 0x73, 0x67, 0x5f, 402 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 403 } 404 405 var ( 406 file_msg_proto_rawDescOnce sync.Once 407 file_msg_proto_rawDescData = file_msg_proto_rawDesc 408 ) 409 410 func file_msg_proto_rawDescGZIP() []byte { 411 file_msg_proto_rawDescOnce.Do(func() { 412 file_msg_proto_rawDescData = protoimpl.X.CompressGZIP(file_msg_proto_rawDescData) 413 }) 414 return file_msg_proto_rawDescData 415 } 416 417 var file_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 4) 418 var file_msg_proto_goTypes = []interface{}{ 419 (*MessageData)(nil), // 0: msg_proto.MessageData 420 (*NewBlockMessageData)(nil), // 1: msg_proto.NewBlockMessageData 421 (*ProtocolHandshakeMessage)(nil), // 2: msg_proto.ProtocolHandshakeMessage 422 (*TopicScoreSnapshot)(nil), // 3: msg_proto.TopicScoreSnapshot 423 (*types_pb.H256)(nil), // 4: types_pb.H256 424 (*types_pb.Block)(nil), // 5: types_pb.Block 425 } 426 var file_msg_proto_depIdxs = []int32{ 427 4, // 0: msg_proto.NewBlockMessageData.hash:type_name -> types_pb.H256 428 4, // 1: msg_proto.NewBlockMessageData.Number:type_name -> types_pb.H256 429 5, // 2: msg_proto.NewBlockMessageData.block:type_name -> types_pb.Block 430 4, // 3: msg_proto.ProtocolHandshakeMessage.genesisHash:type_name -> types_pb.H256 431 4, // 4: msg_proto.ProtocolHandshakeMessage.currentHeight:type_name -> types_pb.H256 432 5, // [5:5] is the sub-list for method output_type 433 5, // [5:5] is the sub-list for method input_type 434 5, // [5:5] is the sub-list for extension type_name 435 5, // [5:5] is the sub-list for extension extendee 436 0, // [0:5] is the sub-list for field type_name 437 } 438 439 func init() { file_msg_proto_init() } 440 func file_msg_proto_init() { 441 if File_msg_proto != nil { 442 return 443 } 444 if !protoimpl.UnsafeEnabled { 445 file_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 446 switch v := v.(*MessageData); i { 447 case 0: 448 return &v.state 449 case 1: 450 return &v.sizeCache 451 case 2: 452 return &v.unknownFields 453 default: 454 return nil 455 } 456 } 457 file_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 458 switch v := v.(*NewBlockMessageData); i { 459 case 0: 460 return &v.state 461 case 1: 462 return &v.sizeCache 463 case 2: 464 return &v.unknownFields 465 default: 466 return nil 467 } 468 } 469 file_msg_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { 470 switch v := v.(*ProtocolHandshakeMessage); i { 471 case 0: 472 return &v.state 473 case 1: 474 return &v.sizeCache 475 case 2: 476 return &v.unknownFields 477 default: 478 return nil 479 } 480 } 481 file_msg_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { 482 switch v := v.(*TopicScoreSnapshot); i { 483 case 0: 484 return &v.state 485 case 1: 486 return &v.sizeCache 487 case 2: 488 return &v.unknownFields 489 default: 490 return nil 491 } 492 } 493 } 494 type x struct{} 495 out := protoimpl.TypeBuilder{ 496 File: protoimpl.DescBuilder{ 497 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 498 RawDescriptor: file_msg_proto_rawDesc, 499 NumEnums: 0, 500 NumMessages: 4, 501 NumExtensions: 0, 502 NumServices: 0, 503 }, 504 GoTypes: file_msg_proto_goTypes, 505 DependencyIndexes: file_msg_proto_depIdxs, 506 MessageInfos: file_msg_proto_msgTypes, 507 }.Build() 508 File_msg_proto = out.File 509 file_msg_proto_rawDesc = nil 510 file_msg_proto_goTypes = nil 511 file_msg_proto_depIdxs = nil 512 }