msvcrt: Fix _vswprintf* arguments.
[wine] / include / netcon.idl
1 /*
2  * Copyright 2009 Jacek Caban for CodeWeavers
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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17  */
18
19 #ifndef DO_NO_IMPORTS
20 import "oaidl.idl";
21 import "unknwn.idl";
22 import "wtypes.idl";
23 /* import "prsht.idl"; */
24 #endif
25
26 cpp_quote("DEFINE_GUID(CLSID_NetSharingManager,0x5c63c1ad,0x3956,0x4ff8,0x84,0x86,0x40,0x03,0x47,0x58,0x31,0x5b);")
27
28 [
29     object,
30     uuid(c08956a1-1cd3-11d1-b1c5-00805fc1270e),
31     pointer_default(unique)
32 ]
33 interface INetConnection : IUnknown
34 {
35     typedef enum tagNETCON_CHARACTERISTIC_FLAGS
36     {
37         NCCF_NONE               = 0x0000,
38         NCCF_ALL_USERS          = 0x0001,
39         NCCF_ALLOW_DUPLICATION  = 0x0002,
40         NCCF_ALLOW_REMOVAL      = 0x0004,
41         NCCF_ALLOW_RENAME       = 0x0008,
42         NCCF_INCOMING_ONLY      = 0x0020,
43         NCCF_OUTGOING_ONLY      = 0x0040,
44         NCCF_BRANDED            = 0x0080,
45         NCCF_SHARED             = 0x0100,
46         NCCF_BRIDGED            = 0x0200,
47         NCCF_FIREWALLED         = 0x0400,
48         NCCF_DEFAULT            = 0x0800,
49         NCCF_HOMENET_CAPABLE    = 0x1000,
50         NCCF_SHARED_PRIVATE     = 0x2000,
51         NCCF_QUARANTINED        = 0x4000,
52         NCCF_RESERVED           = 0x8000,
53         NCCF_BLUETOOTH_MASK  = 0x000F0000,
54         NCCF_LAN_MASK        = 0x00F00000
55     } NETCON_CHARACTERISTIC_FLAGS;
56
57     typedef enum tagNETCON_STATUS
58     {
59         NCS_DISCONNECTED,
60         NCS_CONNECTING,
61         NCS_CONNECTED,
62         NCS_DISCONNECTING,
63         NCS_HARDWARE_NOT_PRESENT,
64         NCS_HARDWARE_DISABLED,
65         NCS_HARDWARE_MALFUNCTION,
66         NCS_MEDIA_DISCONNECTED,
67         NCS_AUTHENTICATING,
68         NCS_AUTHENTICATION_SUCCEEDED,
69         NCS_AUTHENTICATION_FAILED,
70         NCS_INVALID_ADDRESS,
71         NCS_CREDENTIALS_REQUIRED
72     } NETCON_STATUS;
73
74     typedef enum tagNETCON_TYPE
75     {
76         NCT_DIRECT_CONNECT,
77         NCT_INBOUND,
78         NCT_INTERNET,
79         NCT_LAN,
80         NCT_PHONE,
81         NCT_TUNNEL,
82         NCT_BRIDGE
83     } NETCON_TYPE;
84
85     typedef enum tagNETCON_MEDIATYPE
86     {
87         NCM_NONE,
88         NCM_DIRECT,
89         NCM_ISDN,
90         NCM_LAN,
91         NCM_PHONE,
92         NCM_TUNNEL,
93         NCM_PPPOE,
94         NCM_BRIDGE,
95         NCM_SHAREDACCESSHOST_LAN,
96         NCM_SHAREDACCESSHOST_RAS
97     } NETCON_MEDIATYPE;
98
99     typedef struct tagNETCON_PROPERTIES
100     {
101         GUID              guidId;
102         [string] LPWSTR   pszwName;
103         [string] LPWSTR   pszwDeviceName;
104         NETCON_STATUS     Status;
105         NETCON_MEDIATYPE  MediaType;
106         DWORD             dwCharacter;
107         CLSID             clsidThisObject;
108         CLSID             clsidUiObject;
109     } NETCON_PROPERTIES;
110
111     HRESULT Connect();
112
113     HRESULT Disconnect();
114
115     HRESULT Delete();
116
117     HRESULT Duplicate(
118             [in, string] LPCWSTR pszwDuplicateName,
119             [out]        INetConnection **ppCon);
120
121     HRESULT GetProperties([out] NETCON_PROPERTIES **ppProps);
122
123     HRESULT GetUiObjectClassId([out, ref] CLSID *pclsid);
124
125     HRESULT Rename([in, string] LPCWSTR pszwNewName);
126 }
127
128 [
129     object,
130     uuid(24b7e9b5-e38f-4685-851b-00892cf5f940),
131     oleautomation,
132     dual,
133     pointer_default(unique)
134 ]
135 interface INetSharingPortMappingProps : IDispatch
136 {
137     [propget, id(1)]
138     HRESULT Name([out, retval] BSTR *pbstrName);
139
140     [propget, id(2)]
141     HRESULT IPProtocol([out, retval] UCHAR *pucIPProt);
142
143     [propget, id(3)]
144     HRESULT ExternalPort([out, retval] long *pusPort);
145
146     [propget, id(4)]
147     HRESULT InternalPort([out, retval] long *pusPort);
148
149     [propget, id(5)]
150     HRESULT Options([out, retval] long *pdwOptions);
151
152     [propget, id(6)]
153     HRESULT TargetName([out, retval] BSTR *pbstrTargetName);
154
155     [propget, id(7)]
156     HRESULT TargetIPAddress([out, retval] BSTR *pbstrTargetIPAddress);
157
158     [propget, id(8)]
159     HRESULT Enabled([out, retval] VARIANT_BOOL *pbool);
160 }
161
162 [
163     object,
164     uuid(c08956b1-1cd3-11d1-b1c5-00805fc1270e),
165     oleautomation,
166     dual,
167     pointer_default(unique)
168 ]
169 interface INetSharingPortMapping : IDispatch
170 {
171     [id(1)]
172     HRESULT Disable();
173
174     [id(2)]
175     HRESULT Enable();
176
177     [propget, id(3)]
178     HRESULT Properties([out, retval] INetSharingPortMappingProps **ppNSPMP);
179
180     [id(4)]
181     HRESULT Delete();
182 };
183 [
184     object,
185     uuid(02e4a2de-da20-4e34-89c8-ac22275a010b),
186     oleautomation,
187     dual,
188     pointer_default(unique)
189 ]
190 interface INetSharingPortMappingCollection : IDispatch
191 {
192     [propget, id(DISPID_NEWENUM), restricted]
193     HRESULT _NewEnum([out, retval] IUnknown **pVal);
194
195     [propget, id(1)]
196     HRESULT Count([out, retval] long *pVal);
197 }
198
199 [
200     object,
201     uuid(c08956b6-1cd3-11d1-b1c5-00805fc1270e),
202     oleautomation,
203     dual,
204     pointer_default(unique)
205 ]
206 interface INetSharingConfiguration : IDispatch
207 {
208     typedef enum tagSHARINGCONNECTIONTYPE {
209         ICSSHARINGTYPE_PUBLIC,
210         ICSSHARINGTYPE_PRIVATE
211     } SHARINGCONNECTIONTYPE, *LPSHARINGCONNECTIONTYPE;
212
213     typedef enum tagSHARINGCONNECTION_ENUM_FLAGS {
214             ICSSC_DEFAULT,
215             ICSSC_ENABLED
216     } SHARINGCONNECTION_ENUM_FLAGS;
217
218     typedef enum tagICS_TARGETTYPE {
219             ICSTT_NAME,
220             ICSTT_IPADDRESS
221     }ICS_TARGETTYPE;
222
223     [propget, id(1)]
224     HRESULT SharingEnabled([out, retval] VARIANT_BOOL *pbEnabled);
225
226     [propget, id(2)]
227     HRESULT SharingConnectionType([out, retval] SHARINGCONNECTIONTYPE *pType);
228
229     [id(3)]
230     HRESULT DisableSharing();
231
232     [id(4)]
233     HRESULT EnableSharing([in] SHARINGCONNECTIONTYPE Type);
234
235     [propget, id(5)]
236     HRESULT InternetFirewallEnabled([out, retval] VARIANT_BOOL *pbEnabled);
237
238     [id(6)]
239     HRESULT DisableInternetFirewall();
240
241     [id(7)]
242     HRESULT EnableInternetFirewall();
243
244     [propget, id(8)]
245     HRESULT EnumPortMappings(
246         [in] SHARINGCONNECTION_ENUM_FLAGS Flags,
247         [out, retval] INetSharingPortMappingCollection **ppColl);
248
249     [id(9)]
250     HRESULT AddPortMapping(
251             [in] BSTR bstrName,
252             [in] UCHAR ucIPProtocol,
253             [in] USHORT usExternalPort,
254             [in] USHORT usInternalPort,
255             [in] DWORD dwOptions,
256             [in] BSTR bstrTargetNameOrIPAddress,
257             [in] ICS_TARGETTYPE eTargetType,
258             [out, retval] INetSharingPortMapping **ppMapping );
259
260     [id(10)]
261     HRESULT RemovePortMapping([in] INetSharingPortMapping *pMapping);
262 }
263
264 [
265     object,
266     uuid(c08956b4-1cd3-11d1-b1c5-00805fc1270e),
267     pointer_default(unique)
268 ]
269 interface IEnumNetSharingPublicConnection : IUnknown
270 {
271     HRESULT Next(
272             [in] ULONG celt,
273             [out, size_is(celt), length_is(*pceltFetched)] VARIANT *rgVar,
274             [out] ULONG *pceltFetched);
275
276     HRESULT Skip([in] ULONG celt);
277
278     HRESULT Reset();
279
280     HRESULT Clone([out] IEnumNetSharingPublicConnection **ppenum);
281 }
282
283 [
284     object,
285     uuid(c08956b5-1cd3-11d1-b1c5-00805fc1270e),
286     pointer_default(unique)
287 ]
288 interface IEnumNetSharingPrivateConnection : IUnknown
289 {
290     HRESULT Next(
291             [in] ULONG celt,
292             [out, size_is(celt), length_is(*pCeltFetched)] VARIANT *rgVar,
293             [out] ULONG *pCeltFetched);
294
295     HRESULT Skip([in] ULONG celt);
296
297     HRESULT Reset();
298
299     HRESULT Clone([out] IEnumNetSharingPrivateConnection **ppenum);
300 }
301
302 [
303     object,
304     uuid(f4277c95-ce5b-463d-8167-5662d9bcaa72),
305     oleautomation,
306     dual,
307     pointer_default(unique)
308 ]
309 interface INetConnectionProps : IDispatch
310 {
311     [propget, id(1)]
312     HRESULT Guid([out, retval] BSTR *pbstrGuid);
313
314     [propget, id(2)]
315     HRESULT Name([out, retval] BSTR *pbstrName);
316
317     [propget, id(3)]
318     HRESULT DeviceName([out, retval] BSTR *pbstrDeviceName);
319
320     [propget, id(4)]
321     HRESULT Status([out, retval] NETCON_STATUS *pStatus);
322
323     [propget, id(5)]
324     HRESULT MediaType([out, retval] NETCON_MEDIATYPE *pMediaType);
325
326     [propget, id(6)]
327     HRESULT Characteristics([out, retval] DWORD *pdwFlags);
328 }
329
330 [
331     object,
332     uuid(7d7a6355-f372-4971-a149-bfc927be762a),
333     oleautomation,
334     dual,
335     pointer_default(unique)
336 ]
337 interface INetSharingPublicConnectionCollection : IDispatch
338 {
339     [propget, id(DISPID_NEWENUM), restricted]
340     HRESULT _NewEnum([out, retval] IUnknown **pVal);
341
342     [propget, id(1)]
343     HRESULT Count([out, retval] long *pVal);
344 }
345
346 [
347     object,
348     uuid(33c4643c-7811-46fa-a89a-768597bd7223),
349     oleautomation,
350     dual,
351     pointer_default(unique)
352  ]
353 interface INetSharingEveryConnectionCollection : IDispatch
354 {
355     [propget, id(DISPID_NEWENUM), restricted]
356     HRESULT _NewEnum([out, retval] IUnknown **pVal);
357
358     [propget, id(1)]
359     HRESULT Count([out, retval] long *pVal);
360 }
361
362 [
363     object,
364     uuid(38ae69e0-4409-402a-a2cb-e965c727f840),
365     oleautomation,
366     dual,
367     pointer_default(unique)
368  ]
369 interface INetSharingPrivateConnectionCollection : IDispatch
370 {
371     [propget, id(DISPID_NEWENUM), restricted]
372     HRESULT _NewEnum([out, retval] IUnknown **pVal);
373
374     [propget, id(1)]
375     HRESULT Count([out, retval] long *pVal);
376 }
377
378 [
379     object,
380     uuid(c08956b7-1cd3-11d1-b1c5-00805fc1270e),
381     oleautomation,
382     dual,
383     pointer_default(unique)
384 ]
385 interface INetSharingManager : IDispatch
386 {
387     [propget, id(1)]
388     HRESULT SharingInstalled([out, retval] VARIANT_BOOL *pbInstalled);
389
390     [propget, id(2)]
391     HRESULT EnumPublicConnections(
392             [in]  SHARINGCONNECTION_ENUM_FLAGS Flags,
393             [out, retval] INetSharingPublicConnectionCollection **ppColl);
394
395     [propget, id(3)]
396     HRESULT EnumPrivateConnections(
397             [in]  SHARINGCONNECTION_ENUM_FLAGS Flags,
398             [out, retval] INetSharingPrivateConnectionCollection **ppColl);
399
400     [propget, id(6)]
401     HRESULT INetSharingConfigurationForINetConnection(
402             [in] INetConnection *pNetConnection,
403             [out, retval] INetSharingConfiguration **ppNetSharingConfiguration);
404
405     [propget, id(7)]
406     HRESULT EnumEveryConnection([out, retval] INetSharingEveryConnectionCollection **ppColl);
407
408     [propget, id(8)]
409     HRESULT NetConnectionProps(
410             [in] INetConnection *pNetConnection,
411             [out, retval] INetConnectionProps **ppProps);
412 }