public static void Encode(XdrDataOutputStream stream, TopologyResponseBody encodedTopologyResponseBody) { PeerStatList.Encode(stream, encodedTopologyResponseBody.InboundPeers); PeerStatList.Encode(stream, encodedTopologyResponseBody.OutboundPeers); Uint32.Encode(stream, encodedTopologyResponseBody.TotalInboundPeerCount); Uint32.Encode(stream, encodedTopologyResponseBody.TotalOutboundPeerCount); }
public static TopologyResponseBody Decode(XdrDataInputStream stream) { TopologyResponseBody decodedTopologyResponseBody = new TopologyResponseBody(); decodedTopologyResponseBody.InboundPeers = PeerStatList.Decode(stream); decodedTopologyResponseBody.OutboundPeers = PeerStatList.Decode(stream); decodedTopologyResponseBody.TotalInboundPeerCount = Uint32.Decode(stream); decodedTopologyResponseBody.TotalOutboundPeerCount = Uint32.Decode(stream); return(decodedTopologyResponseBody); }