(data []byte)
| 332 | } |
| 333 | |
| 334 | func (m *NodePb) MarshalTo(data []byte) (int, error) { |
| 335 | var i int |
| 336 | _ = i |
| 337 | var l int |
| 338 | _ = l |
| 339 | if m.Bn != nil { |
| 340 | data[i] = 0xa |
| 341 | i++ |
| 342 | i = encodeVarintNode(data, i, uint64(m.Bn.Size())) |
| 343 | n1, err := m.Bn.MarshalTo(data[i:]) |
| 344 | if err != nil { |
| 345 | return 0, err |
| 346 | } |
| 347 | i += n1 |
| 348 | } |
| 349 | if m.Booln != nil { |
| 350 | data[i] = 0x12 |
| 351 | i++ |
| 352 | i = encodeVarintNode(data, i, uint64(m.Booln.Size())) |
| 353 | n2, err := m.Booln.MarshalTo(data[i:]) |
| 354 | if err != nil { |
| 355 | return 0, err |
| 356 | } |
| 357 | i += n2 |
| 358 | } |
| 359 | if m.Un != nil { |
| 360 | data[i] = 0x1a |
| 361 | i++ |
| 362 | i = encodeVarintNode(data, i, uint64(m.Un.Size())) |
| 363 | n3, err := m.Un.MarshalTo(data[i:]) |
| 364 | if err != nil { |
| 365 | return 0, err |
| 366 | } |
| 367 | i += n3 |
| 368 | } |
| 369 | if m.Fn != nil { |
| 370 | data[i] = 0x22 |
| 371 | i++ |
| 372 | i = encodeVarintNode(data, i, uint64(m.Fn.Size())) |
| 373 | n4, err := m.Fn.MarshalTo(data[i:]) |
| 374 | if err != nil { |
| 375 | return 0, err |
| 376 | } |
| 377 | i += n4 |
| 378 | } |
| 379 | if m.Tn != nil { |
| 380 | data[i] = 0x2a |
| 381 | i++ |
| 382 | i = encodeVarintNode(data, i, uint64(m.Tn.Size())) |
| 383 | n5, err := m.Tn.MarshalTo(data[i:]) |
| 384 | if err != nil { |
| 385 | return 0, err |
| 386 | } |
| 387 | i += n5 |
| 388 | } |
| 389 | if m.An != nil { |
| 390 | data[i] = 0x32 |
| 391 | i++ |
no test coverage detected