BitSharp.Network.Messaging.ConstructInventoryPayload C# (CSharp) Method

ConstructInventoryPayload() public static method

public static ConstructInventoryPayload ( ImmutableArray invVectors ) : BitSharp.Network.InventoryPayload
invVectors ImmutableArray
return BitSharp.Network.InventoryPayload
        public static InventoryPayload ConstructInventoryPayload(ImmutableArray<InventoryVector> invVectors)
        {
            return new InventoryPayload
            (
                InventoryVectors: invVectors
            );
        }

Usage Example

示例#1
0
        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);
        }
All Usage Examples Of BitSharp.Network.Messaging::ConstructInventoryPayload