Packet Sniffer SDK VCL Edition

HNAdapter :: Properties :: ReceiveQueue

 Previous Next

Sets/Returns the handle of the HNQueue object.

Syntax:

property ReceiveQueue: Pointer;

Description:

Use this property to set the received packets queue.

If ReceiveQueue property was not set to NULL before the opening of the network adapter, then traffic processing will be executed by HNQueue component, otherwise a standard OnPacketReceive event handler will be called.

ReceiveQueue property can be changed only when HNAdapter component is closed (see IsOpened).

To set packets queue for the network adapter, please do the following:

...
HNQueue.MaxPacketSize := 1514;
HNQueue.ItemsCount := 50000;
HNQueue.AllocItems();
HNAdapter.ReceiveQueue := HNQueue.Handle;
...
HNAdapter.OpenAdapter();
...
HNAdapter.CloseAdapter();
...
HNQueue.FreeItems();
See also:HNAdapter, HNQueue, OnPacketReceive