4 #pragma GCC system_header
15 #define NS_PEER_BROWSE 3
17 #define NS_TCPIP_LOCAL 10
18 #define NS_TCPIP_HOSTS 11
35 #define SERVICE_REGISTER 1
36 #define SERVICE_DEREGISTER 2
37 #define SERVICE_FLUSH 3
38 #define SERVICE_FLAG_HARD 0x00000002
42 #if defined (_WINSOCK_H) || defined (_WINSOCK2_H) /* needed for LPSOCKADDR */
43 #ifndef __CSADDR_T_DEFINED /* also in winsock2.h, but not in winsock.h */
44 #define __CSADDR_T_DEFINED
45 typedef struct _SOCKET_ADDRESS
{
46 LPSOCKADDR lpSockaddr
;
48 } SOCKET_ADDRESS
,*PSOCKET_ADDRESS
,*LPSOCKET_ADDRESS
;
49 typedef struct _CSADDR_INFO
{
50 SOCKET_ADDRESS LocalAddr
;
51 SOCKET_ADDRESS RemoteAddr
;
54 } CSADDR_INFO
,*PCSADDR_INFO
,*LPCSADDR_INFO
;
58 #ifndef __BLOB_T_DEFINED /* also in wtypes.h and winsock2.h */
59 #define __BLOB_T_DEFINED
60 typedef struct _BLOB
{
63 } BLOB
,*PBLOB
,*LPBLOB
;
66 typedef struct _SERVICE_ADDRESS
{
69 DWORD dwAddressLength
;
70 DWORD dwPrincipalLength
;
74 typedef struct _SERVICE_ADDRESSES
{
76 SERVICE_ADDRESS Addresses
[1];
77 } SERVICE_ADDRESSES
, *PSERVICE_ADDRESSES
, *LPSERVICE_ADDRESSES
;
78 typedef struct _SERVICE_INFOA
{
87 LPSERVICE_ADDRESSES lpServiceAddress
;
88 BLOB ServiceSpecificInfo
;
89 } SERVICE_INFOA
, *LPSERVICE_INFOA
;
90 typedef struct _SERVICE_INFOW
{
99 LPSERVICE_ADDRESSES lpServiceAddress
;
100 BLOB ServiceSpecificInfo
;
101 } SERVICE_INFOW
, *LPSERVICE_INFOW
;
103 typedef void *LPSERVICE_ASYNC_INFO
;
104 INT WINAPI
SetServiceA(DWORD
,DWORD
,DWORD
,LPSERVICE_INFOA
,LPSERVICE_ASYNC_INFO
,LPDWORD
);
105 INT WINAPI
SetServiceW(DWORD
,DWORD
,DWORD
,LPSERVICE_INFOW
,LPSERVICE_ASYNC_INFO
,LPDWORD
);
106 INT WINAPI
GetAddressByNameA(DWORD
,LPGUID
,LPSTR
,LPINT
,DWORD
,LPSERVICE_ASYNC_INFO
,LPVOID
,LPDWORD
,LPSTR
,LPDWORD
);
107 INT WINAPI
GetAddressByNameW(DWORD
,LPGUID
,LPWSTR
,LPINT
,DWORD
,LPSERVICE_ASYNC_INFO
,LPVOID
,LPDWORD
,LPWSTR
,LPDWORD
);
110 typedef SERVICE_INFOW SERVICE_INFO
, *LPSERVICE_INFO
;
111 #define _SERVICE_INFO SERVICE_INFOW
112 #define SetService SetServiceW
113 #define GetAddressByName GetAddressByNameW
115 typedef SERVICE_INFOA SERVICE_INFO
, *LPSERVICE_INFO
;
116 #define _SERVICE_INFO SERVICE_INFOA
117 #define SetService SetServiceA
118 #define GetAddressByName GetAddressByNameA
121 #endif /* RC_INVOKED */
126 #endif /* _NSPAPI_H */