msxml3/tests: Add test saving XML with non-english characters.
[wine.git] / include / windows.foundation.collections.idl
blob876e15336a23414f0620072b94ca4ecacc739ee5
1 /*
2 * Copyright 2021 RĂ©mi Bernon for CodeWeavers
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.
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.
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
19 #ifdef __WIDL__
20 #pragma winrt ns_prefix
21 #endif
23 import "inspectable.idl";
24 import "asyncinfo.idl";
25 import "windowscontracts.idl";
26 /* import "eventtoken.idl"; */
28 namespace Windows {
29 namespace Foundation {
31 cpp_quote("#ifdef __cplusplus")
32 cpp_quote("} /* extern \"C\" */")
33 cpp_quote("namespace ABI { namespace Windows { namespace Foundation { namespace Internal {")
34 cpp_quote("template <class T> struct GetAbiType { typedef T type; };")
35 cpp_quote("template <class T> struct GetLogicalType { typedef T type; };")
36 cpp_quote("template <class L, class A> struct AggregateType {};")
37 cpp_quote("template <class L, class A> struct GetAbiType<AggregateType<L, A> > { typedef A type; };")
38 cpp_quote("template <class L, class A> struct GetLogicalType<AggregateType<L, A> > { typedef L type; };")
39 cpp_quote("}}}}")
40 cpp_quote("extern \"C\" {")
41 cpp_quote("#endif")
43 #ifdef __WIDL__
45 contract(Windows.Foundation.FoundationContract, 1.0),
46 uuid(9de1c535-6ae1-11e0-84e1-18a905bcc53f)
48 delegate HRESULT EventHandler<T>([in] IInspectable *sender, [in] T args);
50 interface IAsyncOperation<TResult>;
53 contract(Windows.Foundation.FoundationContract, 1.0),
54 uuid(fcdcf02c-e5d8-4478-915a-4d90b74b83a5)
56 delegate HRESULT AsyncOperationCompletedHandler<TResult>([in] IAsyncOperation<TResult> *info, [in] AsyncStatus status);
59 contract(Windows.Foundation.FoundationContract, 1.0),
60 uuid(9fc2b0bb-e446-44e2-aa61-9cab8f636af2)
62 interface IAsyncOperation<TResult> : IInspectable
64 [propput] HRESULT Completed([in] AsyncOperationCompletedHandler<TResult> *handler);
65 [propget] HRESULT Completed([out, retval] AsyncOperationCompletedHandler<TResult> **handler);
66 HRESULT GetResults([out, retval] TResult **results);
70 contract(Windows.Foundation.FoundationContract, 1.0),
71 uuid(9de1c534-6ae1-11e0-84e1-18a905bcc53f)
73 delegate HRESULT TypedEventHandler<TSender, TArgs>([in] TSender sender, [in] TArgs args);
75 namespace Collections
78 contract(Windows.Foundation.FoundationContract, 1.0),
79 uuid(e480ce40-a338-4ada-adcf-272272e48cb9)
81 interface IMapView<K, V> : IInspectable
83 HRESULT Lookup([in] K key, [out] V *value);
84 [propget] HRESULT Size([out] unsigned int *size);
85 HRESULT HasKey([in] K key, [out] boolean *found);
86 HRESULT Split([out] IMapView<K, V> **first, [out] IMapView<K, V> **second);
90 contract(Windows.Foundation.FoundationContract, 1.0),
91 uuid(6a79e863-4300-459a-9966-cbb660963ee1)
93 interface IIterator<T> : IInspectable
95 [propget] HRESULT Current([out, retval] T *value);
96 [propget] HRESULT HasCurrent([out, retval] BOOL *value);
97 HRESULT MoveNext([out, retval] BOOL *value);
98 HRESULT GetMany([in] UINT32 count, [in] UINT32 items_size, [out] T *items, [out, retval] UINT32 *value);
102 contract(Windows.Foundation.FoundationContract, 1.0),
103 uuid(faa585ea-6214-4217-afda-7f46de5869b3)
105 interface IIterable<T> : IInspectable
107 HRESULT First([out, retval] Windows.Foundation.Collections.IIterator<T> **value);
111 contract(Windows.Foundation.FoundationContract, 1.0),
112 uuid(bbe1fa4c-b0e3-4583-baef-1f1b2e483e56)
114 interface IVectorView<T> : IInspectable
116 HRESULT GetAt([in] UINT32 index, [out, retval] T *value);
117 [propget] HRESULT Size([out, retval] UINT32 *value);
118 HRESULT IndexOf([in, optional] T element, [out] UINT32 *index, [out, retval] BOOLEAN *value);
119 HRESULT GetMany([in] UINT32 start_index, [in] UINT32 items_size, [out] T *items, [out, retval] UINT32 *value);
122 #endif