WSAGetServiceClassInfo
The Windows
Sockets WSAGetServiceClassInfo function retrieves all of the class
information (schema) pertaining to a specified service class from a specified
name space provider.
INT WSAGetServiceClassInfo(
LPGUID lpProviderId, |
|
LPGUID lpServiceClassId, |
|
LPDWORD lpdwBufSize, |
|
LPWSASERVICECLASSINFO lpServiceClassInfo |
|
); |
|
Parameters
lpProviderId
[in] Pointer
to a GUID which identifies a specific name space provider
lpServiceClassId
[in] Pointer
to a GUID identifying the service class in question
lpdwBufferLength
[in/out] On
input, the number of bytes contained in the buffer pointed to by lpServiceClassInfos.
On output, if the function fails and the error is WSAEFAULT, then it contains
the minimum number of bytes to pass for the lpServiceClassInfo to
retrieve the record.
lpServiceClasslnfo
[out] Returns
service class information from the indicated name space provider for the
specified service class.
Remarks
The service
class information retrieved from a particular name space provider may not
necessarily be the complete set of class information that was supplied when the
service class was installed. Individual name space providers are only required
to retain service class information that is applicable to the name spaces that
they support. See section Service Class Data Structures
Return Values
The return
value is zero if the operation was successful. Otherwise, the value
SOCKET_ERROR is returned, and a specific error number may be retrieved by
calling WSAGetLastError.
Error Codes
WSAEFAULT |
The buffer
referenced by lpServiceClassInfo is too small. Pass in a larger
buffer. |
WSA_INVALID_PARAMETER |
the
specified service class ID or name space provider ID is invalid. |
WSANOTINITIALIZED |
The Windows
Sockets 2 DLL has not been initialized. The application must first call WSAStartup
before calling any Windows Sockets functions. |