// ------------------------------------------------------------------------------ // <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.Com { [Guid("3127CA40-446E-11CE-8135-00AA004BB851")] [CLSCompliant(false)] [global::System.CodeDom.Compiler.GeneratedCode("Microsoft.Windows.CsWin32", "0.3.287+85e3fa26dd.RR")] internal unsafe partial struct IErrorLog :winmdroot.IVTable<IErrorLog,IErrorLog.Vtbl>,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]<IErrorLog*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT>)lpVtbl[0])((IErrorLog*)Unsafe.AsPointer(ref this), riid, ppvObject); } public uint AddRef() { return ((delegate *unmanaged [Stdcall]<IErrorLog*,uint>)lpVtbl[1])((IErrorLog*)Unsafe.AsPointer(ref this)); } public uint Release() { return ((delegate *unmanaged [Stdcall]<IErrorLog*,uint>)lpVtbl[2])((IErrorLog*)Unsafe.AsPointer(ref this)); } /// <inheritdoc cref="AddError(winmdroot.Foundation.PCWSTR, winmdroot.System.Com.EXCEPINFO*)"/> [OverloadResolutionPriority(1)] internal unsafe void AddError(string pszPropName, in winmdroot.System.Com.EXCEPINFO pExcepInfo) { fixed (winmdroot.System.Com.EXCEPINFO* pExcepInfoLocal = &pExcepInfo) { fixed (char* pszPropNameLocal = pszPropName) { this.AddError(pszPropNameLocal, pExcepInfoLocal); } } } [UnmanagedCallersOnly(CallConvs = new []{ typeof(CallConvStdcall)} )] private static winmdroot.Foundation.HRESULT AddError(IErrorLog* pThis, winmdroot.Foundation.PCWSTR pszPropName, winmdroot.System.Com.EXCEPINFO* pExcepInfo) { try { winmdroot.Foundation.HRESULT __hr = winmdroot.ComHelpers.UnwrapCCW(pThis, out Interface __object); if (__hr.Failed) { return __hr; } return __object.AddError(pszPropName, pExcepInfo); } catch (Exception ex) { return (winmdroot.Foundation.HRESULT)ex.HResult; } } /// <summary>Adds an error for the specified property to the error log.</summary> /// <param name="pszPropName">The address of the name of the property to read. This cannot be NULL.</param> /// <param name="pExcepInfo">Pointer to an array of [EXCEPINFO](ns-oaidl-excepinfo.md) structures.</param> /// <returns></returns> /// <remarks></remarks> public unsafe void AddError(winmdroot.Foundation.PCWSTR pszPropName, winmdroot.System.Com.EXCEPINFO* pExcepInfo) { ((delegate *unmanaged [Stdcall]<IErrorLog*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.EXCEPINFO* ,winmdroot.Foundation.HRESULT>)lpVtbl[3])((IErrorLog*)Unsafe.AsPointer(ref this), pszPropName, pExcepInfo).ThrowOnFailure(); } 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]<IErrorLog*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT> QueryInterface_1; internal delegate *unmanaged [Stdcall]<IErrorLog*,uint> AddRef_2; internal delegate *unmanaged [Stdcall]<IErrorLog*,uint> Release_3; internal delegate *unmanaged [Stdcall]<IErrorLog*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.EXCEPINFO* ,winmdroot.Foundation.HRESULT> AddError_4; } public static void PopulateVTable(Vtbl* vtable) { vtable->AddError_4 = &AddError; } private void** lpVtbl; /// <summary>The IID guid for this interface.</summary> /// <value>{3127ca40-446e-11ce-8135-00aa004bb851}</value> internal static readonly Guid IID_Guid = new Guid(0x3127CA40, 0x446E, 0x11CE, 0x81, 0x35, 0x00, 0xAA, 0x00, 0x4B, 0xB8, 0x51); static ref readonly Guid IComIID.Guid { [MethodImpl(MethodImplOptions.AggressiveInlining)] get { ReadOnlySpan<byte> data = new byte[] { 0x40,0xCA,0x27,0x31,0x6E,0x44,0xCE,0x11,0x81,0x35,0x00,0xAA,0x00,0x4B,0xB8,0x51 }; return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data)); } } [Guid("3127CA40-446E-11CE-8135-00AA004BB851"),InterfaceType(ComInterfaceType.InterfaceIsIUnknown),ComImport()] internal interface Interface { [PreserveSig()] unsafe winmdroot.Foundation.HRESULT AddError(winmdroot.Foundation.PCWSTR pszPropName, winmdroot.System.Com.EXCEPINFO* pExcepInfo); } } } }