Aracılığıyla paylaş


IDevicePacketStream

Exchanges data with a connected DevicePacketStream on the desktop computer by reading and writing objects that implement IPacket.

IDevicePacketStream : public IUnknown

Methods

Method

Description

IDevicePacketStream::Read

Reads packets sent from the DevicePacketStream on the desktop computer.

IDevicePacketStream::Write

Writes a packet to the stream. The packet is read by the DevicePacketStream on the desktop computer.

IDevicePacketStream::IsConnected

Checks if stream is connected.

IDevicePacketStream::Disconnect

Disconnects the stream.

IDevicePacketStream::IsPacketAvailable

Checks if there is a packet ready to be read.

IDevicePacketStream::get_Buffering

Checks if Nagle's buffering algorithm is enabled on the stream.

IDevicePacketStream::put_Buffering

Enables or disables Nagle's buffering algorithm on the stream.

IDevicePacketStream::get_MaxPacketSize

Gets the maximum packet size limited by the underlying transport mechanism.

Remarks

To get an object that implements this interface, use IDeviceAgentTransport::AcceptConnectionEx.

Example

The following example is a device agent application that writes one packet to the desktop and reads one packet from the desktop.

Managed Equivalent

Microsoft.SmartDevice.DeviceAgentTransport..::.IDevicePacketStream

Requirements

DeviceAgentTransport.h

See Also

Other Resources

Unmanaged Device-Side Smart Device Connectivity API