dpaddr.h 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338
  1. /*
  2. * Copyright (C) 2003 Raphael Junqueira
  3. *
  4. * This library is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU Lesser General Public
  6. * License as published by the Free Software Foundation; either
  7. * version 2.1 of the License, or (at your option) any later version.
  8. *
  9. * This library is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  12. * Lesser General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU Lesser General Public
  15. * License along with this library; if not, write to the Free Software
  16. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  17. */
  18. #ifndef __WINE_DPLAY8_DPADDR_H
  19. #define __WINE_DPLAY8_DPADDR_H
  20. #include <ole2.h>
  21. #include <dplay8.h>
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif /* defined(__cplusplus) */
  25. typedef struct sockaddr SOCKADDR;
  26. /*****************************************************************************
  27. * DirectPlay8Addr defines
  28. */
  29. #define DPNA_DATATYPE_STRING 0x00000001
  30. #define DPNA_DATATYPE_DWORD 0x00000002
  31. #define DPNA_DATATYPE_GUID 0x00000003
  32. #define DPNA_DATATYPE_BINARY 0x00000004
  33. #define DPNA_DATATYPE_STRING_ANSI 0x00000005
  34. #define DPNA_DPNSVR_PORT 6073
  35. #define DPNA_INDEX_INVALID 0xFFFFFFFF
  36. #define DPNA_SEPARATOR_KEYVALUE L'='
  37. #define DPNA_SEPARATOR_KEYVALUE_A '='
  38. #define DPNA_SEPARATOR_USERDATA L'#'
  39. #define DPNA_SEPARATOR_USERDATA_A '#'
  40. #define DPNA_SEPARATOR_COMPONENT L';'
  41. #define DPNA_SEPARATOR_COMPONENT_A ';'
  42. #define DPNA_ESCAPECHAR L'%'
  43. #define DPNA_ESCAPECHAR_A '%'
  44. #define DPNA_HEADER_A "x-directplay:/"
  45. #define DPNA_KEY_APPLICATION_INSTANCE_A "applicationinstance"
  46. #define DPNA_KEY_BAUD_A "baud"
  47. #define DPNA_KEY_DEVICE_A "device"
  48. #define DPNA_KEY_FLOWCONTROL_A "flowcontrol"
  49. #define DPNA_KEY_HOSTNAME_A "hostname"
  50. #define DPNA_KEY_PARITY_A "parity"
  51. #define DPNA_KEY_PHONENUMBER_A "phonenumber"
  52. #define DPNA_KEY_PORT_A "port"
  53. #define DPNA_KEY_PROGRAM_A "program"
  54. #define DPNA_KEY_PROVIDER_A "provider"
  55. #define DPNA_KEY_STOPBITS_A "stopbits"
  56. #define DPNA_STOP_BITS_ONE_A "1"
  57. #define DPNA_STOP_BITS_ONE_FIVE_A "1.5"
  58. #define DPNA_STOP_BITS_TWO_A "2"
  59. #define DPNA_PARITY_NONE_A "NONE"
  60. #define DPNA_PARITY_EVEN_A "EVEN"
  61. #define DPNA_PARITY_ODD_A "ODD"
  62. #define DPNA_PARITY_MARK_A "MARK"
  63. #define DPNA_PARITY_SPACE_A "SPACE"
  64. #define DPNA_FLOW_CONTROL_NONE_A "NONE"
  65. #define DPNA_FLOW_CONTROL_XONXOFF_A "XONXOFF"
  66. #define DPNA_FLOW_CONTROL_RTS_A "RTS"
  67. #define DPNA_FLOW_CONTROL_DTR_A "DTR"
  68. #define DPNA_FLOW_CONTROL_RTSDTR_A "RTSDTR"
  69. #define DPNA_VALUE_TCPIPPROVIDER_A "IP"
  70. #define DPNA_VALUE_IPXPROVIDER_A "IPX"
  71. #define DPNA_VALUE_MODEMPROVIDER_A "MODEM"
  72. #define DPNA_VALUE_SERIALPROVIDER_A "SERIAL"
  73. /* And now the same thing but as Unicode strings */
  74. #if defined(__GNUC__)
  75. # define DPNA_HEADER (const WCHAR []){ 'x','-','d','i','r','e','c','t','p','l','a','y',':','/',0 }
  76. # define DPNA_KEY_APPLICATION_INSTANCE (const WCHAR []){ 'a','p','p','l','i','c','a','t','i','o','n','i','n','s','t','a','n','c','e',0 }
  77. # define DPNA_KEY_BAUD (const WCHAR []){ 'b','a','u','d',0 }
  78. # define DPNA_KEY_DEVICE (const WCHAR []){ 'd','e','v','i','c','e',0 }
  79. # define DPNA_KEY_FLOWCONTROL (const WCHAR []){ 'f','l','o','w','c','o','n','t','r','o','l',0 }
  80. # define DPNA_KEY_HOSTNAME (const WCHAR []){ 'h','o','s','t','n','a','m','e',0 }
  81. # define DPNA_KEY_PARITY (const WCHAR []){ 'p','a','r','i','t','y',0 }
  82. # define DPNA_KEY_PHONENUMBER (const WCHAR []){ 'p','h','o','n','e','n','u','m','b','e','r',0 }
  83. # define DPNA_KEY_PORT (const WCHAR []){ 'p','o','r','t',0 }
  84. # define DPNA_KEY_PROGRAM (const WCHAR []){ 'p','r','o','g','r','a','m',0 }
  85. # define DPNA_KEY_PROVIDER (const WCHAR []){ 'p','r','o','v','i','d','e','r',0 }
  86. # define DPNA_KEY_STOPBITS (const WCHAR []){ 's','t','o','p','b','i','t','s',0 }
  87. # define DPNA_STOP_BITS_ONE (const WCHAR []){ '1',0 }
  88. # define DPNA_STOP_BITS_ONE_FIVE (const WCHAR []){ '1','.','5',0 }
  89. # define DPNA_STOP_BITS_TWO (const WCHAR []){ '2',0 }
  90. # define DPNA_PARITY_NONE (const WCHAR []){ 'N','O','N','E',0 }
  91. # define DPNA_PARITY_EVEN (const WCHAR []){ 'E','V','E','N',0 }
  92. # define DPNA_PARITY_ODD (const WCHAR []){ 'O','D','D',0 }
  93. # define DPNA_PARITY_MARK (const WCHAR []){ 'M','A','R','K',0 }
  94. # define DPNA_PARITY_SPACE (const WCHAR []){ 'S','P','A','C','E',0 }
  95. # define DPNA_FLOW_CONTROL_NONE (const WCHAR []){ 'N','O','N','E',0 }
  96. # define DPNA_FLOW_CONTROL_XONXOFF (const WCHAR []){ 'X','O','N','X','O','F','F',0 }
  97. # define DPNA_FLOW_CONTROL_RTS (const WCHAR []){ 'R','T','S',0 }
  98. # define DPNA_FLOW_CONTROL_DTR (const WCHAR []){ 'D','T','R',0 }
  99. # define DPNA_FLOW_CONTROL_RTSDTR (const WCHAR []){ 'R','T','S','D','T','R',0 }
  100. # define DPNA_VALUE_TCPIPPROVIDER (const WCHAR []){ 'I','P',0 }
  101. # define DPNA_VALUE_IPXPROVIDER (const WCHAR []){ 'I','P','X',0 }
  102. # define DPNA_VALUE_MODEMPROVIDER (const WCHAR []){ 'M','O','D','E','M',0 }
  103. # define DPNA_VALUE_SERIALPROVIDER (const WCHAR []){ 'S','E','R','I','A','L',0 }
  104. #elif defined(_MSC_VER)
  105. # define DPNA_HEADER L"x-directplay:/"
  106. # define DPNA_KEY_APPLICATION_INSTANCE L"applicationinstance"
  107. # define DPNA_KEY_BAUD L"baud"
  108. # define DPNA_KEY_DEVICE L"device"
  109. # define DPNA_KEY_FLOWCONTROL L"flowcontrol"
  110. # define DPNA_KEY_HOSTNAME L"hostname"
  111. # define DPNA_KEY_PARITY L"parity"
  112. # define DPNA_KEY_PHONENUMBER L"phonenumber"
  113. # define DPNA_KEY_PORT L"port"
  114. # define DPNA_KEY_PROGRAM L"program"
  115. # define DPNA_KEY_PROVIDER L"provider"
  116. # define DPNA_KEY_STOPBITS L"stopbits"
  117. # define DPNA_STOP_BITS_ONE L"1"
  118. # define DPNA_STOP_BITS_ONE_FIVE L"1.5"
  119. # define DPNA_STOP_BITS_TWO L"2"
  120. # define DPNA_PARITY_NONE L"NONE"
  121. # define DPNA_PARITY_EVEN L"EVEN"
  122. # define DPNA_PARITY_ODD L"ODD"
  123. # define DPNA_PARITY_MARK L"MARK"
  124. # define DPNA_PARITY_SPACE L"SPACE"
  125. # define DPNA_FLOW_CONTROL_NONE L"NONE"
  126. # define DPNA_FLOW_CONTROL_XONXOFF L"XONXOFF"
  127. # define DPNA_FLOW_CONTROL_RTS L"RTS"
  128. # define DPNA_FLOW_CONTROL_DTR L"DTR"
  129. # define DPNA_FLOW_CONTROL_RTSDTR L"RTSDTR"
  130. # define DPNA_VALUE_TCPIPPROVIDER L"IP"
  131. # define DPNA_VALUE_IPXPROVIDER L"IPX"
  132. # define DPNA_VALUE_MODEMPROVIDER L"MODEM"
  133. # define DPNA_VALUE_SERIALPROVIDER L"SERIAL"
  134. #else
  135. static const WCHAR DPNA_HEADER[] = { 'x','-','d','i','r','e','c','t','p','l','a','y',':','/',0 };
  136. static const WCHAR DPNA_KEY_APPLICATION_INSTANCE[] = { 'a','p','p','l','i','c','a','t','i','o','n','i','n','s','t','a','n','c','e',0 };
  137. static const WCHAR DPNA_KEY_BAUD[] = { 'b','a','u','d',0 };
  138. static const WCHAR DPNA_KEY_DEVICE[] = { 'd','e','v','i','c','e',0 };
  139. static const WCHAR DPNA_KEY_FLOWCONTROL[] = { 'f','l','o','w','c','o','n','t','r','o','l',0 };
  140. static const WCHAR DPNA_KEY_HOSTNAME[] = { 'h','o','s','t','n','a','m','e',0 };
  141. static const WCHAR DPNA_KEY_PARITY[] = { 'p','a','r','i','t','y',0 };
  142. static const WCHAR DPNA_KEY_PHONENUMBER[] = { 'p','h','o','n','e','n','u','m','b','e','r',0 };
  143. static const WCHAR DPNA_KEY_PORT[] = { 'p','o','r','t',0 };
  144. static const WCHAR DPNA_KEY_PROGRAM[] = { 'p','r','o','g','r','a','m',0 };
  145. static const WCHAR DPNA_KEY_PROVIDER[] = { 'p','r','o','v','i','d','e','r',0 };
  146. static const WCHAR DPNA_KEY_STOPBITS[] = { 's','t','o','p','b','i','t','s',0 };
  147. static const WCHAR DPNA_STOP_BITS_ONE[] = { '1',0 };
  148. static const WCHAR DPNA_STOP_BITS_ONE_FIVE[] = { '1','.','5',0 };
  149. static const WCHAR DPNA_STOP_BITS_TWO[] = { '2',0 };
  150. static const WCHAR DPNA_PARITY_NONE[] = { 'N','O','N','E',0 };
  151. static const WCHAR DPNA_PARITY_EVEN[] = { 'E','V','E','N',0 };
  152. static const WCHAR DPNA_PARITY_ODD[] = { 'O','D','D',0 };
  153. static const WCHAR DPNA_PARITY_MARK[] = { 'M','A','R','K',0 };
  154. static const WCHAR DPNA_PARITY_SPACE[] = { 'S','P','A','C','E',0 };
  155. static const WCHAR DPNA_FLOW_CONTROL_NONE[] = { 'N','O','N','E',0 };
  156. static const WCHAR DPNA_FLOW_CONTROL_XONXOFF[] = { 'X','O','N','X','O','F','F',0 };
  157. static const WCHAR DPNA_FLOW_CONTROL_RTS[] = { 'R','T','S',0 };
  158. static const WCHAR DPNA_FLOW_CONTROL_DTR[] = { 'D','T','R',0 };
  159. static const WCHAR DPNA_FLOW_CONTROL_RTSDTR[] = { 'R','T','S','D','T','R',0 };
  160. static const WCHAR DPNA_VALUE_TCPIPPROVIDER[] = { 'I','P',0 };
  161. static const WCHAR DPNA_VALUE_IPXPROVIDER[] = { 'I','P','X',0 };
  162. static const WCHAR DPNA_VALUE_MODEMPROVIDER[] = { 'M','O','D','E','M',0 };
  163. static const WCHAR DPNA_VALUE_SERIALPROVIDER[] = { 'S','E','R','I','A','L',0 };
  164. #endif
  165. #define DPNA_BAUD_RATE_9600 9600
  166. #define DPNA_BAUD_RATE_14400 14400
  167. #define DPNA_BAUD_RATE_19200 19200
  168. #define DPNA_BAUD_RATE_38400 38400
  169. #define DPNA_BAUD_RATE_56000 56000
  170. #define DPNA_BAUD_RATE_57600 57600
  171. #define DPNA_BAUD_RATE_115200 115200
  172. /*****************************************************************************
  173. * Predeclare the interfaces
  174. */
  175. DEFINE_GUID(CLSID_DirectPlay8Address, 0x934a9523, 0xa3ca, 0x4bc5, 0xad, 0xa0, 0xd6, 0xd9, 0x5d, 0x97, 0x94, 0x21);
  176. DEFINE_GUID(IID_IDirectPlay8Address, 0x83783300, 0x4063, 0x4c8a, 0x9d, 0xb3, 0x82, 0x83, 0xa, 0x7f, 0xeb, 0x31);
  177. typedef struct IDirectPlay8Address IDirectPlay8Address, *PDIRECTPLAY8ADDRESS, *LPDIRECTPLAY8ADDRESS;
  178. DEFINE_GUID(IID_IDirectPlay8AddressIP, 0xe5a0e990, 0x2bad, 0x430b, 0x87, 0xda, 0xa1, 0x42, 0xcf, 0x75, 0xde, 0x58);
  179. typedef struct IDirectPlay8AddressIP IDirectPlay8AddressIP, *PDIRECTPLAY8ADDRESSIP, *LPDIRECTPLAY8ADDRESSIP;
  180. /*****************************************************************************
  181. * IDirectPlay8Address interface
  182. */
  183. #define INTERFACE IDirectPlay8Address
  184. DECLARE_INTERFACE_(IDirectPlay8Address,IUnknown)
  185. {
  186. /*** IUnknown methods ***/
  187. STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
  188. STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  189. STDMETHOD_(ULONG,Release)(THIS) PURE;
  190. /*** IDirectPlay8Address methods ***/
  191. STDMETHOD(BuildFromURLW)(THIS_ WCHAR* pwszSourceURL) PURE;
  192. STDMETHOD(BuildFromURLA)(THIS_ CHAR* pszSourceURL) PURE;
  193. STDMETHOD(Duplicate)(THIS_ PDIRECTPLAY8ADDRESS* ppdpaNewAddress) PURE;
  194. STDMETHOD(SetEqual)(THIS_ PDIRECTPLAY8ADDRESS pdpaAddress) PURE;
  195. STDMETHOD(IsEqual)(THIS_ PDIRECTPLAY8ADDRESS pdpaAddress) PURE;
  196. STDMETHOD(Clear)(THIS) PURE;
  197. STDMETHOD(GetURLW)(THIS_ WCHAR* pwszURL, PDWORD pdwNumChars) PURE;
  198. STDMETHOD(GetURLA)(THIS_ CHAR* pszURL, PDWORD pdwNumChars) PURE;
  199. STDMETHOD(GetSP)(THIS_ GUID* pguidSP) PURE;
  200. STDMETHOD(GetUserData)(THIS_ LPVOID pvUserData, PDWORD pdwBufferSize) PURE;
  201. STDMETHOD(SetSP)(THIS_ CONST GUID* CONST pguidSP) PURE;
  202. STDMETHOD(SetUserData)(THIS_ CONST void* CONST pvUserData, CONST DWORD dwDataSize) PURE;
  203. STDMETHOD(GetNumComponents)(THIS_ PDWORD pdwNumComponents) PURE;
  204. STDMETHOD(GetComponentByName)(THIS_ CONST WCHAR* CONST pwszName, LPVOID pvBuffer, PDWORD pdwBufferSize, PDWORD pdwDataType) PURE;
  205. STDMETHOD(GetComponentByIndex)(THIS_ CONST DWORD dwComponentID, WCHAR* pwszName, PDWORD pdwNameLen, void* pvBuffer, PDWORD pdwBufferSize, PDWORD pdwDataType) PURE;
  206. STDMETHOD(AddComponent)(THIS_ CONST WCHAR* CONST pwszName, CONST void* CONST lpvData, CONST DWORD dwDataSize, CONST DWORD dwDataType) PURE;
  207. STDMETHOD(GetDevice)(THIS_ GUID* pDevGuid) PURE;
  208. STDMETHOD(SetDevice)(THIS_ CONST GUID* CONST devGuid) PURE;
  209. STDMETHOD(BuildFromDirectPlay4Address)(THIS_ LPVOID pvAddress, DWORD dwDataSize) PURE;
  210. };
  211. #undef INTERFACE
  212. #if !defined(__cplusplus) || defined(CINTERFACE)
  213. /*** IUnknown methods ***/
  214. #define IDirectPlay8Address_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(p,a,b)
  215. #define IDirectPlay8Address_AddRef(p) (p)->lpVtbl->AddRef(p)
  216. #define IDirectPlay8Address_Release(p) (p)->lpVtbl->Release(p)
  217. /*** IDirectPlay8Address methods ***/
  218. #define IDirectPlay8Address_BuildFromURLW(p,a) (p)->lpVtbl->BuildFromURLW(p,a)
  219. #define IDirectPlay8Address_BuildFromURLA(p,a) (p)->lpVtbl->BuildFromURLA(p,a)
  220. #define IDirectPlay8Address_Duplicate(p,a) (p)->lpVtbl->Duplicate(p,a)
  221. #define IDirectPlay8Address_SetEqual(p,a) (p)->lpVtbl->SetEqual(p,a)
  222. #define IDirectPlay8Address_IsEqual(p,a) (p)->lpVtbl->IsEqual(p,a)
  223. #define IDirectPlay8Address_Clear(p) (p)->lpVtbl->Clear(p)
  224. #define IDirectPlay8Address_GetURLW(p,a,b) (p)->lpVtbl->GetURLW(p,a,b)
  225. #define IDirectPlay8Address_GetURLA(p,a,b) (p)->lpVtbl->GetURLA(p,a,b)
  226. #define IDirectPlay8Address_GetSP(p,a) (p)->lpVtbl->GetSP(p,a)
  227. #define IDirectPlay8Address_GetUserData(p,a,b) (p)->lpVtbl->GetUserData(p,a,b)
  228. #define IDirectPlay8Address_SetSP(p,a) (p)->lpVtbl->SetSP(p,a)
  229. #define IDirectPlay8Address_SetUserData(p,a,b) (p)->lpVtbl->SetUserData(p,a,b)
  230. #define IDirectPlay8Address_GetNumComponents(p,a) (p)->lpVtbl->GetNumComponents(p,a)
  231. #define IDirectPlay8Address_GetComponentByName(p,a,b,c,d) (p)->lpVtbl->GetComponentByName(p,a,b,c,d)
  232. #define IDirectPlay8Address_GetComponentByIndex(p,a,b,c,d,e,f) (p)->lpVtbl->GetComponentByIndex(p,a,b,c,d,e,f)
  233. #define IDirectPlay8Address_AddComponent(p,a,b,c,d) (p)->lpVtbl->AddComponent(p,a,b,c,d)
  234. #define IDirectPlay8Address_SetDevice(p,a) (p)->lpVtbl->SetDevice(p,a)
  235. #define IDirectPlay8Address_GetDevice(p,a) (p)->lpVtbl->GetDevice(p,a)
  236. #define IDirectPlay8Address_BuildFromDirectPlay4Address(p,a,b) (p)->lpVtbl->BuildFromDirectPlay4Address(p,a,b)
  237. #else
  238. /*** IUnknown methods ***/
  239. #define IDirectPlay8Address_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  240. #define IDirectPlay8Address_AddRef(p) (p)->AddRef()
  241. #define IDirectPlay8Address_Release(p) (p)->Release()
  242. /*** IDirectPlay8Address methods ***/
  243. #define IDirectPlay8Address_BuildFromURLW(p,a) (p)->BuildFromURLW(a)
  244. #define IDirectPlay8Address_BuildFromURLA(p,a) (p)->BuildFromURLA(a)
  245. #define IDirectPlay8Address_Duplicate(p,a) (p)->Duplicate(a)
  246. #define IDirectPlay8Address_SetEqual(p,a) (p)->SetEqual(a)
  247. #define IDirectPlay8Address_IsEqual(p,a) (p)->IsEqual(a)
  248. #define IDirectPlay8Address_Clear(p) (p)->Clear()
  249. #define IDirectPlay8Address_GetURLW(p,a,b) (p)->GetURLW(a,b)
  250. #define IDirectPlay8Address_GetURLA(p,a,b) (p)->GetURLA(a,b)
  251. #define IDirectPlay8Address_GetSP(p,a) (p)->GetSP(a)
  252. #define IDirectPlay8Address_GetUserData(p,a,b) (p)->GetUserData(a,b)
  253. #define IDirectPlay8Address_SetSP(p,a) (p)->SetSP(a)
  254. #define IDirectPlay8Address_SetUserData(p,a,b) (p)->SetUserData(a,b)
  255. #define IDirectPlay8Address_GetNumComponents(p,a) (p)->GetNumComponents(a)
  256. #define IDirectPlay8Address_GetComponentByName(p,a,b,c,d) (p)->GetComponentByName(a,b,c,d)
  257. #define IDirectPlay8Address_GetComponentByIndex(p,a,b,c,d,e,f) (p)->GetComponentByIndex(a,b,c,d,e,f)
  258. #define IDirectPlay8Address_AddComponent(p,a,b,c,d) (p)->AddComponent(a,b,c,d)
  259. #define IDirectPlay8Address_SetDevice(p,a) (p)->SetDevice(a)
  260. #define IDirectPlay8Address_GetDevice(p,a) (p)->GetDevice(a)
  261. #define IDirectPlay8Address_BuildFromDirectPlay4Address(p,a,b) (p)->BuildFromDirectPlay4Address(a,b)
  262. #endif
  263. /*****************************************************************************
  264. * IDirectPlay8AddressIP interface
  265. */
  266. #define INTERFACE IDirectPlay8AddressIP
  267. DECLARE_INTERFACE_(IDirectPlay8AddressIP,IUnknown)
  268. {
  269. /*** IUnknown methods ***/
  270. STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
  271. STDMETHOD_(ULONG,AddRef)(THIS) PURE;
  272. STDMETHOD_(ULONG,Release)(THIS) PURE;
  273. /*** IDirectPlay8AddressIP methods ***/
  274. STDMETHOD(BuildFromSockAddr)(THIS_ CONST SOCKADDR* CONST pSockAddr) PURE;
  275. STDMETHOD(BuildAddress)(THIS_ CONST WCHAR* CONST wszAddress, CONST USHORT usPort) PURE;
  276. STDMETHOD(BuildLocalAddress)(THIS_ CONST GUID* CONST pguidAdapter, CONST USHORT usPort) PURE;
  277. STDMETHOD(GetSockAddress)(THIS_ SOCKADDR* pSockAddr, PDWORD) PURE;
  278. STDMETHOD(GetLocalAddress)(THIS_ GUID* pguidAdapter, USHORT* pusPort) PURE;
  279. STDMETHOD(GetAddress)(THIS_ WCHAR* wszAddress, PDWORD pdwAddressLength, USHORT* psPort) PURE;
  280. };
  281. #undef INTERFACE
  282. #if !defined(__cplusplus) || defined(CINTERFACE)
  283. /*** IUnknown methods ***/
  284. #define IDirectPlay8AddressIP_QueryInterface(p,a,b) (p)->lpVtbl->QueryInterface(a,b)
  285. #define IDirectPlay8AddressIP_AddRef(p) (p)->lpVtbl->AddRef()
  286. #define IDirectPlay8AddressIP_Release(p) (p)->lpVtbl->Release()
  287. /*** IDirectPlay8AddressIP methods ***/
  288. #define IDirectPlay8AddressIP_BuildFromSockAddr(p,a) (p)->lpVtbl->BuildFromSockAddr(a)
  289. #define IDirectPlay8AddressIP_BuildAddress(p,a,b) (p)->lpVtbl->BuildAddress(a,b)
  290. #define IDirectPlay8AddressIP_BuildLocalAddress(p,a,b) (p)->lpVtbl->BuildLocalAddress(a,b)
  291. #define IDirectPlay8AddressIP_GetSockAddress(p,a,b) (p)->lpVtbl->GetSockAddress(a,b)
  292. #define IDirectPlay8AddressIP_GetLocalAddress(p,a,b) (p)->lpVtbl->GetLocalAddress(a,b)
  293. #define IDirectPlay8AddressIP_GetAddress(p,a,b,c) (p)->lpVtbl->GetAddress(a,b,c)
  294. #else
  295. /*** IUnknown methods ***/
  296. #define IDirectPlay8AddressIP_QueryInterface(p,a,b) (p)->QueryInterface(a,b)
  297. #define IDirectPlay8AddressIP_AddRef(p) (p)->AddRef()
  298. #define IDirectPlay8AddressIP_Release(p) (p)->Release()
  299. /*** IDirectPlay8AddressIP methods ***/
  300. #define IDirectPlay8AddressIP_BuildFromSockAddr(p,a) (p)->BuildFromSockAddr(a)
  301. #define IDirectPlay8AddressIP_BuildAddress(p,a,b) (p)->BuildAddress(a,b)
  302. #define IDirectPlay8AddressIP_BuildLocalAddress(p,a,b) (p)->BuildLocalAddress(a,b)
  303. #define IDirectPlay8AddressIP_GetSockAddress(p,a,b) (p)->GetSockAddress(a,b)
  304. #define IDirectPlay8AddressIP_GetLocalAddress(p,a,b) (p)->GetLocalAddress(a,b)
  305. #define IDirectPlay8AddressIP_GetAddress(p,a,b,c) (p)->GetAddress(a,b,c)
  306. #endif
  307. #ifdef __cplusplus
  308. }
  309. #endif
  310. #endif