The PeerGraphCreate function creates a new peer graph. An application can specify information about a peer graph, and the type of security that a peer graph uses. A handle to a peer graph is returned, but a network connection is not established.
NOT_BUILD_WINDOWS_DEPRECATE HRESULT PeerGraphCreate( PPEER_GRAPH_PROPERTIES pGraphProperties, PCWSTR pwzDatabaseName, PPEER_SECURITY_INTERFACE pSecurityInterface, HGRAPH *phGraph );
All of the properties of a peer graph in the PEER_GRAPH_PROPERTIES structure.
The name of a record database to associate with a peer graph when it is created. The record database name must be a valid file name. Do not include a path with the file name. For a complete list of rules regarding file names, see the Naming a File item in the list of Graphing Reference_Links.
The information about a security provider for a peer graph in the PEER_SECURITY_INTERFACE structure.
Receives a handle to the peer graph that is created. When this handle is not required anymore, free it by calling PeerGraphClose.
Returns S_OK if the operation succeeds. Otherwise, the function returns one of the following values.
||One of the parameters is not valid.|
||There is not enough memory to perform a specified operation.|
||A database with a specified peer graph ID that already exists.|
||The peer graph must be initialized with a call to PeerGraphStartup before using this function.|
If you develop your own Security Service Provider (SSP), your application must not call the Peer Graphing API to access data in the peer graphing database, because that can cause a deadlock situation. Instead, the application must use a cached copy of the information. The cached copy is not created by the Peer Graphing API. The application must provide a mechanism for caching this data.
After PeerGraphCreate is called, the application can subscribe to events before it calls PeerGraphListen.
|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|