Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The PeerGraphSendData function sends data to a neighbor node or a directly connected node.
Syntax
NOT_BUILD_WINDOWS_DEPRECATE HRESULT PeerGraphSendData(
[in] HGRAPH hGraph,
[in] ULONGLONG ullConnectionId,
[in] const GUID *pType,
[in] ULONG cbData,
[in] PVOID pvData
);
Parameters
[in] hGraph
Handle to the peer graph.
[in] ullConnectionId
Specifies the unique ID of the connection to send data on.
[in] pType
Specifies an application-defined data type to send. This parameter cannot be NULL.
[in] cbData
Specifies the number of bytes pointed to by pvData.
[in] pvData
Pointer to the data to send.
Return value
Returns S_OK if the operation succeeds; otherwise, the function returns one of the following values:
Return code | Description |
---|---|
|
One of the parameters is not valid. |
|
No connection with the given ID exists. |
|
The handle to the peer graph is invalid. |
|
The graph must be initialized with a call to PeerGraphStartup before using this function. |
Remarks
The PeerGraphSendData function returns as soon as data has been sent to the network layer; the peer graphing layer does not wait for an acknowledgment from the other side of the connection.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP with SP2 [desktop apps only],Windows XP with SP1 with the Advanced Networking Pack forWindows XP |
Minimum supported server | None supported |
Target Platform | Windows |
Header | p2p.h |
Library | P2PGraph.lib |
DLL | P2PGraph.dll |