/// The dimension of the packet portion (in bytes) that is delivered to the application.
/// </summary>
propertyintSnapshotLength
propertyintSnapshotLength
{
{
intget();
intget();
}
}
/// <summary>
/// True if the current file uses a different byte order than the current system.
/// </summary>
propertyboolIsFileSystemByteOrder
propertyboolIsFileSystemByteOrder
{
{
boolget();
boolget();
}
}
/// <summary>
/// The major version number of the pcap library used to write the file.
/// </summary>
propertyintFileMajorVersion
propertyintFileMajorVersion
{
{
intget();
intget();
}
}
/// <summary>
/// The minor version number of the pcap library used to write the file.
/// </summary>
propertyintFileMinorVersion
propertyintFileMinorVersion
{
{
intget();
intget();
}
}
/// <summary>
/// Return statistics on current capture.
/// The values represent packet statistics from the start of the run to the time of the call.
/// Supported only on live captures, not on offline. No statistics are stored in offline, so no statistics are available when reading from an offline device.
/// </summary>
/// <exception cref="System::InvalidOperationException">Thrown if there is an error or the underlying packet capture doesn't support packet statistics.</exception>
/// Puts a live communicator into "non-blocking" mode, or takes it out of "non-blocking" mode.
/// In "non-blocking" mode, an attempt to read from the communicator with ReceiveSomePackets will, if no packets are currently available to be read, return immediately rather than blocking waiting for packets to arrive.
/// ReceivePacket and ReceivePackets will not work in "non-blocking" mode.
/// <seealso cref="ReceiveSomePackets"/>
/// </summary>
/// <exception cref="System::InvalidOperationException">Thrown if there is an error.</exception>
propertyboolNonBlocking
propertyboolNonBlocking
{
{
boolget();
boolget();
voidset(boolvalue);
voidset(boolvalue);
}
}
/// <summary>
/// Set the size of the kernel buffer associated with an adapter.
/// If an old buffer was already created with a previous call to pcap_setbuff(), it is deleted and its content is discarded.
/// LivePacketDevice.Open() creates a 1 MByte buffer by default.
/// <!--seealso cref="LivePacketDevice::Open"/-->
/// </summary>
/// <param name="size">the size of the buffer in bytes</param>
/// <exception cref="System::InvalidOperationException">Thrown on failure.</exception>
voidSetKernelBufferSize(intsize);
voidSetKernelBufferSize(intsize);
/// <summary>
/// Set the minumum amount of data received by the kernel in a single call.
/// Changes the minimum amount of data in the kernel buffer that causes a read from the application to return (unless the timeout expires).
/// If the value of size is large, the kernel is forced to wait the arrival of several packets before copying the data to the user.
/// This guarantees a low number of system calls, i.e. low processor usage, and is a good setting for applications like packet-sniffers and protocol analyzers.
/// Vice versa, in presence of a small value for this variable, the kernel will copy the packets as soon as the application is ready to receive them.
/// This is useful for real time applications that need the best responsiveness from the kernel.
/// </summary>
/// <param name="size">minimum number of bytes to copy</param>
/// <exception cref="System::InvalidOperationException">Thrown on failure.</exception>
voidSetKernelMinimumBytesToCopy(intsize);
voidSetKernelMinimumBytesToCopy(intsize);
/// <summary>
/// Define a sampling method for packet capture.
/// This function allows applying a sampling method to the packet capture process.
/// The mtthod will be applied as soon as the capture starts.
/// </summary>
/// <remarks>
/// Warning: Sampling parameters cannot be changed when a capture is active. These parameters must be applied before starting the capture. If they are applied when the capture is in progress, the new settings are ignored.
/// Warning: Sampling works only when capturing data on Win32 or reading from a file. It has not been implemented on other platforms. Sampling works on remote machines provided that the probe (i.e. the capturing device) is a Win32 workstation.
/// </remarks>
/// <param name="method">The sampling method to be applied</param>
voidSetSamplingMethod(SamplingMethod^method);
voidSetSamplingMethod(SamplingMethod^method);
/// <summary>
/// Read a packet from an interface or from an offline capture.
/// This function is used to retrieve the next available packet, bypassing the callback method traditionally provided.
/// The method fills the packet parameter with the next captured packet.
/// <seealso cref="ReceiveSomePackets"/>
/// <seealso cref="ReceivePackets"/>
/// </summary>
/// <param name="packet">The received packet if it was read without problems. null otherwise.</param>
/// <returns>
/// <list type="table">
/// <listheader>
/// <term>Return value</term>
/// <description>description</description>
/// </listheader>
/// <item><term>Ok</term><description>The packet has been read without problems.</description></item>
/// <item><term>Timeout</term><description>The timeout set with LivePacketDevice.Open() has elapsed. In this case the packet out parameter will be null.</description></item>
/// <item><term>Eof</term><description>EOF was reached reading from an offline capture. In this case the packet out parameter will be null.</description></item>
/// </list>
/// </returns>
/// <exception cref="System::InvalidOperationException">Thrown if an error occurred.</exception>