ConstructInventoryPayload() public static method

public static ConstructInventoryPayload ( ImmutableArray invVectors ) : BitSharp.Network.InventoryPayload
invVectors ImmutableArray
return BitSharp.Network.InventoryPayload
コード例 #1
0
ファイル: RemoteSender.cs プロジェクト: yonglehou/BitSharp
        public async Task SendGetData(ImmutableArray <InventoryVector> invVectors)
        {
            await Task.Yield();

            var getDataPayload = Messaging.ConstructInventoryPayload(invVectors);
            var getDataMessage = Messaging.ConstructMessage("getdata", NetworkEncoder.EncodeInventoryPayload(getDataPayload));

            await SendMessageAsync(getDataMessage);
        }
コード例 #2
0
ファイル: RemoteSender.cs プロジェクト: yonglehou/BitSharp
        public async Task SendInventory(ImmutableArray <InventoryVector> invVectors)
        {
            await Task.Yield();

            var invPayload = Messaging.ConstructInventoryPayload(invVectors);
            var invMessage = Messaging.ConstructMessage("inv", NetworkEncoder.EncodeInventoryPayload(invPayload));

            await SendMessageAsync(invMessage);
        }