Compartilhar via


NSPGetServiceClassInfo (Compact 2013)

3/26/2014

This function retrieves all the pertinent class information (schema) pertaining to the name-space provider. It retrieves any name space-specific information that is common to all instances of the service, including connection information for SAP, or port information for SAP or TCP.

Syntax

int NSPGetServiceClassInfo(
  LPGUID lpProviderId,
  LPDWORD lpdwBufSize,
  LPWSASERVICECLASSINFOW lpServiceClassInfo 
);

Parameters

  • lpProviderId
    [in] Pointer to the GUID of the specific name space provider from which the service class schema is to be retrieved.
  • lpdwBufSize
    [in] Number of bytes contained in the buffer pointed to by lpServiceClassInfo on input. Alternately, if the function fails and the error is WSAEFAULT, lpdwBufSize contains the minimum number of bytes to pass for the lpServiceClassInfo to retrieve the record on output.
  • lpServiceClassInfo
    [in] Returns service class to name space-specific mapping information. The lpServiceClassId parameter must be filled in to indicate which WSASERVICECLASSINFOW record should be returned.

Return Value

If no error occurs, NSPGetServiceClass returns NO_ERROR (zero). Otherwise, the function returns SOCKET_ERROR (-1) and it must set the appropriate error code using the SetLastError function.

Note

The default Name Service Provider (for DNS/WINS) in Windows Embedded Compact does not support this function and will always return SOCKET_ERROR and set the error code to WSAEOPNOTSUPP.

Remarks

The W2_32.dll uses this function to retrieve the name space specific information passed into the NSPLookupServiceBegin and NSPSetService.

Requirements

Header

ws2spi.h

Library

Ws2.lib

See Also

Reference

Winsock SPI Functions
NSPLookupServiceBegin
NSPSetService