Share via


WDP_UNITDATA (Windows Embedded CE 6.0)

1/6/2010

This structure represents unit data and is used for transmitting data as unreliable datagrams. If a client is not listening on the incoming port or if the packet is too large, a WCMP message will be generated. For more information, see the "Remarks" section of this topic.

Syntax

typedef struct wdp_unitdata_tag{
  WAP_PRIMITIVE_ID wpiPrimitiveID;
  WAP_PRIMITIVE_TYPE wptPrimitiveType;
  DWORD dwValidFields;
  WAP_ADDRESS waSourceAddress;
  DWORD dwSourcePort;
  WAP_ADDRESS waDestinationAddress;
  DWORD dwDestinationPort;
  const BYTE* pbUserData;
  DWORD dwUserDataSize;
} WDP_UNITDATA;

Members

  • wpiPrimitiveID
    The primitive identifier. The only possible value is WAP_PRIMITIVE_ID_T_DUNITDATA, as defined by the WAP_PRIMITIVE_ID enumeration. Applications will cast the base structure according to this identifier. It is always present and valid.
  • wptPrimitiveType
    The primitive type. Possible values are any of the values defined for the WAP_PRIMITIVE_TYPE enumeration.
  • dwValidFields
    Bitmask that indicates the valid fields in the primitive, dependent on the value of wpiPrimitiveID. For possible values, see WAP_PRIMITIVE_BASE.
  • waSourceAddress
    A WAP_ADDRESS structure containing the sender's unique address. This member is optional and ignored on a WDP request over IP and Short Message Service (SMS) bearers. The appropriate source address will be filled in when the WDP indication is sent.
  • dwSourcePort
    The port used by the sender. For primitives of type WAP_PRIMITIVE_TYPE_REQUEST, this member is ignored. The source port is filled in with the value specified in the dwLocalPort parameter in WapOpen calls.
  • waDestinationAddress
    A WAP_ADDRESS structure containing the destination address of the user data that is being sent.
  • dwDestinationPort
    The destination port of the user data that is being sent.
  • pbUserData
    Pointer to the datagram that is being sent.
  • dwUserDataSize
    The number of bytes in the datagram indicated by pbUserData*.*

Remarks

Different bearers, such as IP and GSM Short Message Service (SMS), can have different behaviors when handling requests to send 0 bytes of user data. In particular, callers should not rely on being able to send 0-byte datagrams.

Requirements

Header wap.h
Windows Embedded CE Windows Embedded CE 6.0 and later

See Also

Reference

WapOpen
WAP_PRIMITIVE_ID
WAP_PRIMITIVE_TYPE
WAP_PRIMITIVE_BASE

Concepts

WAP Structures