| 1 |
/* |
| 2 |
* Copyright 2022 Zhiyi Zhang 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 |
#ifdef __WIDL__ |
| 20 |
#pragma winrt ns_prefix |
| 21 |
#endif |
| 22 |
|
| 23 |
import "inspectable.idl"; |
| 24 |
import "asyncinfo.idl"; |
| 25 |
import "eventtoken.idl"; |
| 26 |
import "windowscontracts.idl"; |
| 27 |
import "windows.foundation.idl"; |
| 28 |
|
| 29 |
namespace Windows.Foundation.Metadata |
| 30 |
{ |
| 31 |
typedef enum GCPressureAmount GCPressureAmount; |
| 32 |
|
| 33 |
interface IApiInformationStatics; |
| 34 |
|
| 35 |
runtimeclass ApiInformation; |
| 36 |
|
| 37 |
[ |
| 38 |
contract(Windows.Foundation.FoundationContract, 1.0) |
| 39 |
] |
| 40 |
enum GCPressureAmount |
| 41 |
{ |
| 42 |
Low = 0, |
| 43 |
Medium = 1, |
| 44 |
High = 2 |
| 45 |
}; |
| 46 |
|
| 47 |
[ |
| 48 |
contract(Windows.Foundation.FoundationContract, 1.0), |
| 49 |
exclusiveto(Windows.Foundation.Metadata.ApiInformation), |
| 50 |
uuid(997439fe-f681-4a11-b416-c13a47e8ba36) |
| 51 |
] |
| 52 |
interface IApiInformationStatics : IInspectable |
| 53 |
{ |
| 54 |
HRESULT IsTypePresent([in] HSTRING type_name, [out, retval] boolean *value); |
| 55 |
[overload("IsMethodPresent")] HRESULT IsMethodPresent([in] HSTRING type_name, [in] HSTRING method_name, [out, retval] boolean *value); |
| 56 |
[overload("IsMethodPresent")] HRESULT IsMethodPresentWithArity([in] HSTRING type_name, [in] HSTRING method_name, [in] UINT32 parameter_count, [out, retval] boolean *value); |
| 57 |
HRESULT IsEventPresent([in] HSTRING type_name, [in] HSTRING event_name, [out, retval] boolean *value); |
| 58 |
HRESULT IsPropertyPresent([in] HSTRING type_name, [in] HSTRING property_name, [out, retval] boolean *value); |
| 59 |
HRESULT IsReadOnlyPropertyPresent([in] HSTRING type_name, [in] HSTRING property_name, [out, retval] boolean *value); |
| 60 |
HRESULT IsWriteablePropertyPresent([in] HSTRING type_name, [in] HSTRING property_name, [out, retval] boolean *value); |
| 61 |
HRESULT IsEnumNamedValuePresent([in] HSTRING enum_type_name, [in] HSTRING value_name, [out, retval] boolean *value); |
| 62 |
[overload("IsApiContractPresent")] HRESULT IsApiContractPresentByMajor([in] HSTRING contract_name, [in] UINT16 major_version, [out, retval] boolean *value); |
| 63 |
[overload("IsApiContractPresent")] HRESULT IsApiContractPresentByMajorAndMinor([in] HSTRING contract_name, [in] UINT16 major_version, [in] UINT16 minor_version, [out, retval] boolean *value); |
| 64 |
} |
| 65 |
|
| 66 |
[ |
| 67 |
contract(Windows.Foundation.FoundationContract, 1.0), |
| 68 |
marshaling_behavior(agile), |
| 69 |
static(Windows.Foundation.Metadata.IApiInformationStatics, Windows.Foundation.FoundationContract, 1.0), |
| 70 |
threading(both) |
| 71 |
] |
| 72 |
runtimeclass ApiInformation |
| 73 |
{ |
| 74 |
} |
| 75 |
} |