// ------------------------------------------------------------------------------ // <auto-generated> // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // </auto-generated> // ------------------------------------------------------------------------------ #pragma warning disable CS1591,CS1573,CS0465,CS0649,CS8019,CS1570,CS1584,CS1658,CS0436,CS8981,SYSLIB1092,CS3021,CS3019 using global::System; using global::System.Diagnostics; using global::System.Diagnostics.CodeAnalysis; using global::System.Runtime.CompilerServices; using global::System.Runtime.InteropServices; using global::System.Runtime.Versioning; using winmdroot = global::Windows.Win32; namespace Windows.Win32 { namespace System.WinRT { [Guid("AF86E2E0-B12D-4C6A-9C5A-D7AA65101E90")] [SupportedOSPlatform("windows8.0")] [global::System.CodeDom.Compiler.GeneratedCode("Microsoft.Windows.CsWin32", "0.3.287+85e3fa26dd.RR")] internal unsafe partial struct IInspectable :IComIID { /// <inheritdoc cref="QueryInterface(global::System.Guid*, void**)"/> [OverloadResolutionPriority(1)] internal unsafe winmdroot.Foundation.HRESULT QueryInterface(in global::System.Guid riid, out void* ppvObject) { fixed (void** ppvObjectLocal = &ppvObject) { fixed (global::System.Guid* riidLocal = &riid) { winmdroot.Foundation.HRESULT __result = this.QueryInterface(riidLocal, ppvObjectLocal); return __result; } } } public unsafe winmdroot.Foundation.HRESULT QueryInterface(global::System.Guid* riid, void** ppvObject) { return ((delegate *unmanaged [Stdcall]<IInspectable*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT>)lpVtbl[0])((IInspectable*)Unsafe.AsPointer(ref this), riid, ppvObject); } public uint AddRef() { return ((delegate *unmanaged [Stdcall]<IInspectable*,uint>)lpVtbl[1])((IInspectable*)Unsafe.AsPointer(ref this)); } public uint Release() { return ((delegate *unmanaged [Stdcall]<IInspectable*,uint>)lpVtbl[2])((IInspectable*)Unsafe.AsPointer(ref this)); } /// <inheritdoc cref="GetIids(uint*, global::System.Guid**)"/> [OverloadResolutionPriority(1)] internal unsafe winmdroot.Foundation.HRESULT GetIids(out uint iidCount, out global::System.Guid* iids) { fixed (global::System.Guid** iidsLocal = &iids) { fixed (uint* iidCountLocal = &iidCount) { winmdroot.Foundation.HRESULT __result = this.GetIids(iidCountLocal, iidsLocal); return __result; } } } /// <summary>Gets the interfaces that are implemented by the current Windows Runtime class.</summary> /// <param name="iidCount"> /// <para>Type: <b>ULONG*</b> The number of interfaces that are implemented by the current Windows Runtime object, excluding the <a href="https://docs.microsoft.com/windows/desktop/api/unknwn/nn-unknwn-iunknown">IUnknown</a> and <a href="https://docs.microsoft.com/windows/desktop/api/inspectable/nn-inspectable-iinspectable">IInspectable</a> implementations.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-getiids#parameters">Read more on learn.microsoft.com</see>.</para> /// </param> /// <param name="iids"> /// <para>Type: <b>IID**</b> A pointer to an array that contains an IID for each interface implemented by the current Windows Runtime object. The <a href="https://docs.microsoft.com/windows/desktop/api/unknwn/nn-unknwn-iunknown">IUnknown</a> and <a href="https://docs.microsoft.com/windows/desktop/api/inspectable/nn-inspectable-iinspectable">IInspectable</a> interfaces are excluded.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-getiids#parameters">Read more on learn.microsoft.com</see>.</para> /// </param> /// <returns> /// <para>Type: <b>HRESULT</b> This function can return the following values. </para> /// <para>This doc was truncated.</para> /// </returns> /// <remarks> /// <para>Use the <b>GetIids</b> method to discover the interfaces that are implemented by a Windows Runtime object. A <a href="https://docs.microsoft.com/windows/desktop/api/unknwn/nf-unknwn-iunknown-queryinterface(q)">QueryInterface</a> call on any IID in the <i>iids</i> array must succeed. The caller is responsible for freeing the IID array by using the <a href="https://docs.microsoft.com/windows/desktop/api/combaseapi/nf-combaseapi-cotaskmemfree">CoTaskMemFree</a> function.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-getiids#">Read more on learn.microsoft.com</see>.</para> /// </remarks> public unsafe winmdroot.Foundation.HRESULT GetIids(uint* iidCount, global::System.Guid** iids) { return ((delegate *unmanaged [Stdcall]<IInspectable*,uint* ,global::System.Guid** ,winmdroot.Foundation.HRESULT>)lpVtbl[3])((IInspectable*)Unsafe.AsPointer(ref this), iidCount, iids); } /// <inheritdoc cref="GetRuntimeClassName(winmdroot.System.WinRT.HSTRING*)"/> [OverloadResolutionPriority(1)] internal unsafe winmdroot.Foundation.HRESULT GetRuntimeClassName(out winmdroot.System.WinRT.HSTRING className) { fixed (winmdroot.System.WinRT.HSTRING* classNameLocal = &className) { winmdroot.Foundation.HRESULT __result = this.GetRuntimeClassName(classNameLocal); return __result; } } /// <summary>Gets the fully qualified name of the current Windows Runtime object.</summary> /// <param name="className"> /// <para>Type: <b><a href="https://docs.microsoft.com/windows/desktop/WinRT/hstring">HSTRING</a>*</b> The fully qualified name of the current Windows Runtime object.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-getruntimeclassname#parameters">Read more on learn.microsoft.com</see>.</para> /// </param> /// <returns> /// <para>Type: <b>HRESULT</b> This function can return the following values. </para> /// <para>This doc was truncated.</para> /// </returns> /// <remarks> /// <para>Use the <b>GetRuntimeClassName</b> method to retrieve the namespace-qualified name of a Windows Runtime object. The caller is responsible for freeing the <i>className</i> string by using the <a href="https://docs.microsoft.com/windows/desktop/api/winstring/nf-winstring-windowsdeletestring">WindowsDeleteString</a> function. The following table shows example class name strings that could be returned by the <b>GetRuntimeClassName</b> method.</para> /// <para></para> /// <para>This doc was truncated.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-getruntimeclassname#">Read more on learn.microsoft.com</see>.</para> /// </remarks> public unsafe winmdroot.Foundation.HRESULT GetRuntimeClassName(winmdroot.System.WinRT.HSTRING* className) { return ((delegate *unmanaged [Stdcall]<IInspectable*,winmdroot.System.WinRT.HSTRING* ,winmdroot.Foundation.HRESULT>)lpVtbl[4])((IInspectable*)Unsafe.AsPointer(ref this), className); } /// <inheritdoc cref="GetTrustLevel(winmdroot.System.WinRT.TrustLevel*)"/> [OverloadResolutionPriority(1)] internal unsafe winmdroot.Foundation.HRESULT GetTrustLevel(out winmdroot.System.WinRT.TrustLevel trustLevel) { fixed (winmdroot.System.WinRT.TrustLevel* trustLevelLocal = &trustLevel) { winmdroot.Foundation.HRESULT __result = this.GetTrustLevel(trustLevelLocal); return __result; } } /// <summary>Gets the trust level of the current Windows Runtime object.</summary> /// <param name="trustLevel"> /// <para>Type: <b><a href="https://docs.microsoft.com/windows/desktop/api/inspectable/ne-inspectable-trustlevel">TrustLevel</a>*</b> The trust level of the current Windows Runtime object. The default is <b>BaseLevel</b>.</para> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-gettrustlevel#parameters">Read more on learn.microsoft.com</see>.</para> /// </param> /// <returns> /// <para>Type: <b>HRESULT</b> This method always returns <b>S_OK</b>.</para> /// </returns> /// <remarks> /// <para><see href="https://learn.microsoft.com/windows/win32/api/inspectable/nf-inspectable-iinspectable-gettrustlevel">Learn more about this API from learn.microsoft.com</see>.</para> /// </remarks> public unsafe winmdroot.Foundation.HRESULT GetTrustLevel(winmdroot.System.WinRT.TrustLevel* trustLevel) { return ((delegate *unmanaged [Stdcall]<IInspectable*,winmdroot.System.WinRT.TrustLevel* ,winmdroot.Foundation.HRESULT>)lpVtbl[5])((IInspectable*)Unsafe.AsPointer(ref this), trustLevel); } internal unsafe global::Windows.Win32.Foundation.HRESULT QueryInterface<T>(out T* ppv) where T : unmanaged { Guid guid = typeof(T).GUID; void* pv; var hr = this.QueryInterface(&guid, &pv); if (hr.Succeeded) { ppv = (T*)pv; } else { ppv = null; } return hr; } internal struct Vtbl { internal delegate *unmanaged [Stdcall]<IInspectable*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT> QueryInterface_1; internal delegate *unmanaged [Stdcall]<IInspectable*,uint> AddRef_2; internal delegate *unmanaged [Stdcall]<IInspectable*,uint> Release_3; internal delegate *unmanaged [Stdcall]<IInspectable*,uint* ,global::System.Guid** ,winmdroot.Foundation.HRESULT> GetIids_4; internal delegate *unmanaged [Stdcall]<IInspectable*,winmdroot.System.WinRT.HSTRING* ,winmdroot.Foundation.HRESULT> GetRuntimeClassName_5; internal delegate *unmanaged [Stdcall]<IInspectable*,winmdroot.System.WinRT.TrustLevel* ,winmdroot.Foundation.HRESULT> GetTrustLevel_6; } private void** lpVtbl; /// <summary>The IID guid for this interface.</summary> /// <value>{af86e2e0-b12d-4c6a-9c5a-d7aa65101e90}</value> internal static readonly Guid IID_Guid = new Guid(0xAF86E2E0, 0xB12D, 0x4C6A, 0x9C, 0x5A, 0xD7, 0xAA, 0x65, 0x10, 0x1E, 0x90); readonly ref readonly Guid IComIID.Guid { [MethodImpl(MethodImplOptions.AggressiveInlining)] get => ref Unsafe.AsRef(in IID_Guid); } [Guid("AF86E2E0-B12D-4C6A-9C5A-D7AA65101E90"),InterfaceType(ComInterfaceType.InterfaceIsIUnknown),ComImport()] [SupportedOSPlatform("windows8.0")] internal interface Interface { [PreserveSig()] unsafe winmdroot.Foundation.HRESULT GetIids(uint* iidCount, global::System.Guid** iids); [PreserveSig()] unsafe winmdroot.Foundation.HRESULT GetRuntimeClassName(winmdroot.System.WinRT.HSTRING* className); [PreserveSig()] unsafe winmdroot.Foundation.HRESULT GetTrustLevel(winmdroot.System.WinRT.TrustLevel* trustLevel); } } } }