File: Windows.Win32.IStorage.g.cs
Project: src\src\System.Private.Windows.Core\src\System.Private.Windows.Core.csproj (System.Private.Windows.Core)
// ------------------------------------------------------------------------------
// <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
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.StructuredStorage
	{
		[Guid("0000000B-0000-0000-C000-000000000046")]
		[SupportedOSPlatform("windows5.0")]
		[global::System.CodeDom.Compiler.GeneratedCode("Microsoft.Windows.CsWin32", "0.3.151+58e949951d.RR")]
		internal unsafe partial struct IStorage
			:IVTable<IStorage,IStorage.Vtbl>,IComIID		{
			/// <inheritdoc cref="QueryInterface(global::System.Guid*, void**)"/>
			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]<IStorage*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT>)lpVtbl[0])((IStorage*)Unsafe.AsPointer(ref this), riid, ppvObject);
			}

			public uint AddRef()
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint>)lpVtbl[1])((IStorage*)Unsafe.AsPointer(ref this));
			}

			public uint Release()
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint>)lpVtbl[2])((IStorage*)Unsafe.AsPointer(ref this));
			}

			/// <inheritdoc cref="CreateStream(winmdroot.Foundation.PCWSTR, winmdroot.System.Com.STGM, uint, uint, winmdroot.System.Com.IStream**)"/>
			internal unsafe winmdroot.Foundation.HRESULT CreateStream(string pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				fixed (char* pwcsNameLocal = pwcsName)
				{
					winmdroot.Foundation.HRESULT __result = this.CreateStream(pwcsNameLocal, grfMode, reserved1, reserved2, ppstm);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT CreateStream(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.CreateStream(pwcsName, grfMode, reserved1, reserved2, ppstm);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Creates and opens a stream object with the specified name contained in this storage object.</summary>
			/// <param name="pwcsName">A pointer to a wide character null-terminated Unicode string that contains the name of the newly created stream. The name can be used later to open or reopen the stream. The name must not exceed 31 characters in length, not including the string terminator. The 000 through 01f characters, serving as the first character of the stream/storage name, are reserved for use by OLE. This is a compound file restriction, not a structured storage restriction.</param>
			/// <param name="grfMode">Specifies the access mode to use when opening the newly created stream. For more information and descriptions of the possible values, see <a href="https://docs.microsoft.com/windows/desktop/Stg/stgm-constants">STGM Constants</a>.</param>
			/// <param name="reserved1">Reserved for future use; must be zero.</param>
			/// <param name="reserved2">Reserved for future use; must be zero.</param>
			/// <param name="ppstm">
			/// <para>On return, pointer to the location of the new <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istream">IStream</a> interface pointer. This is only valid if the operation is successful. When an error occurs, this parameter is set to <b>NULL</b>.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-createstream#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The new stream was successfully created.| |E_PENDING | Asynchronous Storage only: Part or all of the necessary data is currently unavailable. | |STG_E_ACCESSDENIED | Not enough permissions to create stream.| |STG_E_FILEALREADYEXISTS | The name specified for the stream already exists in the storage object and the *grfMode* parameter includes the value STGM_FAILIFTHERE.| |STG_E_INSUFFICIENTMEMORY | The stream was not created due to a lack of memory.| |STG_E_INVALIDFLAG | The value specified for the *grfMode* parameter is not a valid **STGM** constants value.| |STG_E_INVALIDFUNCTION | The specified combination of flags in the *grfMode* parameter is not supported; for example, when this method is called without the STGM_SHARE_EXCLUSIVE flag.| |STG_E_INVALIDNAME | Invalid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the stream object was invalid.| |STG_E_INVALIDPARAMETER | One of the parameters was invalid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The stream was not created because there are too many open files.|</para>
			/// </returns>
			/// <remarks>
			/// <para>If a stream with the name specified in the <i>pwcsName</i> parameter already exists and the <i>grfMode</i> parameter includes the STGM_CREATE flag, the existing stream is replaced by a newly created one. Both the destruction of the old stream and the creation of the new stream object are subject to the transaction mode on the parent storage object. The COM-provided compound file implementation of the <b>IStorage::CreateStream</b> method does not support the following behaviors: </para>
			/// <para>This doc was truncated.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-createstream#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT CreateStream(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.STGM ,uint ,uint ,winmdroot.System.Com.IStream** ,winmdroot.Foundation.HRESULT>)lpVtbl[3])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, grfMode, reserved1, reserved2, ppstm);
			}

			/// <inheritdoc cref="OpenStream(winmdroot.Foundation.PCWSTR, void*, winmdroot.System.Com.STGM, uint, winmdroot.System.Com.IStream**)"/>
			internal unsafe winmdroot.Foundation.HRESULT OpenStream(string pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				fixed (char* pwcsNameLocal = pwcsName)
				{
					winmdroot.Foundation.HRESULT __result = this.OpenStream(pwcsNameLocal, default, grfMode, reserved2, ppstm);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT OpenStream(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, [Optional] void* reserved1, winmdroot.System.Com.STGM grfMode, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.OpenStream(pwcsName, reserved1, grfMode, reserved2, ppstm);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Opens an existing stream object within this storage object in the specified access mode.</summary>
			/// <param name="pwcsName">A pointer to a wide character null-terminated Unicode string that contains the name of the stream to open. The 000 through 01f characters, serving as the first character of the stream/storage name, are reserved for use by OLE. This is a compound file restriction, not a structured storage restriction.</param>
			/// <param name="reserved1">Reserved for future use; must be <b>NULL</b>.</param>
			/// <param name="grfMode">Specifies the access mode to be assigned to the open stream. For more information and descriptions of possible values, see <a href="https://docs.microsoft.com/windows/desktop/Stg/stgm-constants">STGM Constants</a>.  Other modes you choose must at least specify STGM_SHARE_EXCLUSIVE when calling this method in the compound file implementation.</param>
			/// <param name="reserved2">Reserved for future use; must be zero.</param>
			/// <param name="ppstm">
			/// <para>A pointer to <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istream">IStream</a> pointer variable that receives the interface pointer to the newly opened stream object. If an error occurs, *<i>ppstm</i> must be set to <b>NULL</b>.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-openstream#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The stream was successfully opened.| |E_PENDING | Asynchronous Storage only: Part or all of the stream data is currently unavailable. | |STG_E_ACCESSDENIED | Not enough permissions to open stream.| |STG_E_FILENOTFOUND | The stream with specified name does not exist.| |STG_E_INSUFFICIENTMEMORY | The stream was not opened due to a lack of memory.| |STG_E_INVALIDFLAG | The value specified for the *grfMode* parameter is not a valid **STGM** constants value.| |STG_E_INVALIDFUNCTION | The specified combination of flags in the *grfMode* parameter is not supported; for example, when this method is called without the STGM_SHARE_EXCLUSIVE flag.| |STG_E_INVALIDNAME | Invalid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the stream object was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The stream was not opened because there are too many open files.|</para>
			/// </returns>
			/// <remarks><b>IStorage::OpenStream</b> opens an existing stream object within this storage object in the access mode specified in <i>grfMode</i>. There are restrictions on the permissions that can be given in <i>grfMode</i>. For example, the permissions on this storage object restrict the permissions on its streams. In general, access restrictions on streams need to be stricter than those on their parent storages. Compound-file streams must be opened with STGM_SHARE_EXCLUSIVE.</remarks>
			public unsafe winmdroot.Foundation.HRESULT OpenStream(winmdroot.Foundation.PCWSTR pwcsName, [Optional] void* reserved1, winmdroot.System.Com.STGM grfMode, uint reserved2, winmdroot.System.Com.IStream** ppstm)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,void* ,winmdroot.System.Com.STGM ,uint ,winmdroot.System.Com.IStream** ,winmdroot.Foundation.HRESULT>)lpVtbl[4])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, reserved1, grfMode, reserved2, ppstm);
			}

			/// <inheritdoc cref="CreateStorage(winmdroot.Foundation.PCWSTR, winmdroot.System.Com.STGM, uint, uint, winmdroot.System.Com.StructuredStorage.IStorage**)"/>
			internal unsafe winmdroot.Foundation.HRESULT CreateStorage(string pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				fixed (char* pwcsNameLocal = pwcsName)
				{
					winmdroot.Foundation.HRESULT __result = this.CreateStorage(pwcsNameLocal, grfMode, reserved1, reserved2, ppstg);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT CreateStorage(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.CreateStorage(pwcsName, grfMode, reserved1, reserved2, ppstg);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Creates and opens a new storage object nested within this storage object with the specified name in the specified access mode.</summary>
			/// <param name="pwcsName">A pointer to a wide character null-terminated Unicode string that contains the name of the newly created storage object. The name can be used later to reopen the storage object. The name must not exceed 31 characters in length, not including the string terminator. The 000 through 01f characters, serving as the first character of the stream/storage name, are reserved for use by OLE. This is a compound file restriction, not a structured storage restriction.</param>
			/// <param name="grfMode">A value that specifies the access mode to use when opening the newly created storage object. For more information and a description of possible values, see <a href="https://docs.microsoft.com/windows/desktop/Stg/stgm-constants">STGM Constants</a>.</param>
			/// <param name="reserved1">Reserved for future use; must be zero.</param>
			/// <param name="reserved2">Reserved for future use; must be zero.</param>
			/// <param name="ppstg">
			/// <para>A pointer, when successful, to the location of the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> pointer to the newly created storage object. This parameter is set to <b>NULL</b> if an error occurs.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-createstorage#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The storage object was created successfully.| |E_PENDING | Asynchronous Storage only: Part or all of the necessary data is currently unavailable. | |STG_E_ACCESSDENIED | Not enough permissions to create storage object.| |STG_E_FILEALREADYEXISTS | The name specified for the storage object already exists in the storage object and the *grfMode* parameter includes the flag STGM_FAILIFTHERE.| |STG_E_INSUFFICIENTMEMORY | The storage object was not created due to a lack of memory.| |STG_E_INVALIDFLAG | The value specified for the *grfMode<* parameter is not a valid *STGM* constant value.|he value specified for the grfMode parameter is not a valid |STG_E_INVALIDFUNCTION | The specified combination of flags in the *grfMode* parameter is not supported.| |STG_E_INVALIDNAME | Not a valid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the storage object was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The storage object was not created because there are too many open files.| |STG_S_CONVERTED | The existing stream with the specified name was replaced with a new storage object containing a single stream called CONTENTS. The new storage object will be added.|</para>
			/// </returns>
			/// <remarks>
			/// <para>If a storage with the name specified in the <i>pwcsName</i> parameter already exists within the parent storage object, and the <i>grfMode</i> parameter includes the STGM_CREATE flag, the existing storage is replaced by the new one. If the <i>grfMode</i> parameter includes the STGM_CONVERT flag, the existing element is converted to a stream object named CONTENTS and the new storage object is created containing the CONTENTS stream object. The destruction of the old element and the creation of the new storage object are both subject to the transaction mode on the parent storage object. Be aware that you cannot use STGM_CONVERT if you are also using STGM_CREATE. The COM-provided compound file implementation of the <b>IStorage::CreateStorage</b> method does not support the following behavior: </para>
			/// <para>This doc was truncated.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-createstorage#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT CreateStorage(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.STGM ,uint ,uint ,winmdroot.System.Com.StructuredStorage.IStorage** ,winmdroot.Foundation.HRESULT>)lpVtbl[5])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, grfMode, reserved1, reserved2, ppstg);
			}

			/// <inheritdoc cref="OpenStorage(winmdroot.Foundation.PCWSTR, winmdroot.System.Com.StructuredStorage.IStorage*, winmdroot.System.Com.STGM, ushort**, uint, winmdroot.System.Com.StructuredStorage.IStorage**)"/>
			internal unsafe winmdroot.Foundation.HRESULT OpenStorage(string pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgPriority, winmdroot.System.Com.STGM grfMode, in ushort* snbExclude, uint reserved, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				fixed (ushort** snbExcludeLocal = &snbExclude)
				{
					fixed (char* pwcsNameLocal = pwcsName)
					{
						winmdroot.Foundation.HRESULT __result = this.OpenStorage(pwcsNameLocal, pstgPriority, grfMode, snbExcludeLocal, reserved, ppstg);
						return __result;
					}
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT OpenStorage(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgPriority, winmdroot.System.Com.STGM grfMode, ushort** snbExclude, uint reserved, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.OpenStorage(pwcsName, pstgPriority, grfMode, snbExclude, reserved, ppstg);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Opens an existing storage object with the specified name in the specified access mode.</summary>
			/// <param name="pwcsName">A pointer to a wide character null-terminated Unicode string that contains the name of the storage object to open. The 000 through 01f characters, serving as the first character of the stream/storage name, are reserved for use by OLE. This is a compound file restriction, not a structured storage restriction. It is ignored if <i>pstgPriority</i> is non-<b>NULL</b>.</param>
			/// <param name="pstgPriority">Must be <b>NULL</b>. A non-<b>NULL</b> value will return STG_E_INVALIDPARAMETER.</param>
			/// <param name="grfMode">Specifies the access mode to use when opening the storage object. For descriptions of the possible values, see <a href="https://docs.microsoft.com/windows/desktop/Stg/stgm-constants">STGM Constants</a>. Other modes you choose must at least specify STGM_SHARE_EXCLUSIVE when calling this method.</param>
			/// <param name="snbExclude">Must be <b>NULL</b>. A non-<b>NULL</b> value will return STG_E_INVALIDPARAMETER.</param>
			/// <param name="reserved">Reserved for future use; must be zero.</param>
			/// <param name="ppstg">
			/// <para>When successful, pointer to the location of an <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> pointer to the opened storage object. This parameter is set to <b>NULL</b> if an error occurs.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-openstorage#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The storage object was opened successfully.| |E_PENDING | Asynchronous Storage only: Part or all of the storage's data is currently unavailable. | |STG_E_ACCESSDENIED | Not enough permissions to open storage object.| |STG_E_FILENOTFOUND | The storage object with the specified name does not exist.| |STG_E_INSUFFICIENTMEMORY | The storage object was not opened due to a lack of memory.| |STG_E_INVALIDFLAG | The value specified for the *grfMode* parameter is not a valid **STGM** constants value.| |STG_E_INVALIDFUNCTION | The specified combination of flags in the *grfMode* parameter is not supported.| |STG_E_INVALIDNAME | Not a valid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the storage object was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The storage object was not created because there are too many open files.| |STG_S_CONVERTED | The existing stream with the specified name was replaced with a new storage object containing a single stream called CONTENTS. In direct mode, the new storage is immediately written to disk. In transacted mode, the new storage is written to a temporary storage in memory and later written to disk when it is committed.|</para>
			/// </returns>
			/// <remarks>
			/// <para>If the <i>pstgPriority</i> parameter is <b>NULL</b>, it is ignored. If the <i>pstgPriority</i> parameter is not <b>NULL</b>, it is an <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> pointer to a previous opening of an element of the storage object, usually one that was opened in priority mode. The storage object should be closed and reopened according to <i>grfMode</i>. When the <b>IStorage::OpenStorage</b> method returns, <i>pstgPriority</i> is no longer valid. Use the value supplied in the <i>ppstg</i> parameter. Storage objects can be opened with STGM_DELETEONRELEASE, in which case the object is destroyed when it receives its final release. This is useful for creating temporary storage objects.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-openstorage#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT OpenStorage(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgPriority, winmdroot.System.Com.STGM grfMode, ushort** snbExclude, uint reserved, winmdroot.System.Com.StructuredStorage.IStorage** ppstg)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.System.Com.STGM ,ushort** ,uint ,winmdroot.System.Com.StructuredStorage.IStorage** ,winmdroot.Foundation.HRESULT>)lpVtbl[6])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, pstgPriority, grfMode, snbExclude, reserved, ppstg);
			}

			/// <inheritdoc cref="CopyTo(uint, global::System.Guid*, ushort**, winmdroot.System.Com.StructuredStorage.IStorage*)"/>
			internal unsafe winmdroot.Foundation.HRESULT CopyTo(ReadOnlySpan<global::System.Guid> rgiidExclude, ushort** snbExclude, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest)
			{
				fixed (global::System.Guid* rgiidExcludeLocal = rgiidExclude)
				{
					winmdroot.Foundation.HRESULT __result = this.CopyTo((uint )rgiidExclude.Length, rgiidExcludeLocal, snbExclude, pstgDest);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT CopyTo(IStorage* pThis, uint ciidExclude, [Optional] global::System.Guid* rgiidExclude, [Optional] ushort** snbExclude, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.CopyTo(ciidExclude, rgiidExclude, snbExclude, pstgDest);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Copies the entire contents of an open storage object to another storage object.</summary>
			/// <param name="ciidExclude">The number of elements in the array pointed to by <i>rgiidExclude</i>. If <i>rgiidExclude</i> is <b>NULL</b>, then <i>ciidExclude</i> is ignored.</param>
			/// <param name="rgiidExclude">
			/// <para>An array of interface identifiers (IIDs) that either the caller knows about and does not want copied or that the storage object does not support, but whose state the caller will later explicitly copy. The array can include <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a>, indicating that only stream objects are to be copied, and <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istream">IStream</a>, indicating that only storage objects are to be copied. An array length of zero indicates that only the state exposed by the <b>IStorage</b> object is to be copied; all other interfaces on the object are to be ignored. Passing <b>NULL</b> indicates that all interfaces on the object are to be copied.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-copyto#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <param name="snbExclude">
			/// <para>A string name block (refer to <a href="https://docs.microsoft.com/windows/desktop/Stg/snb">SNB</a>) that specifies a block of storage or stream objects that are not to be copied to the destination. These elements are not created at the destination. If <b>IID_IStorage</b> is in the <i>rgiidExclude</i> array, this parameter is ignored. This parameter may be <b>NULL</b>.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-copyto#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <param name="pstgDest">
			/// <para>A pointer to the open storage object into which this storage object is to be copied. The destination storage object can be a different implementation of the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> interface from the source storage object. Thus, <b>IStorage::CopyTo</b> can use only publicly available methods of the destination storage object. If <i>pstgDest</i> is open in transacted mode, it can be reverted by calling its <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-revert">IStorage::Revert</a> method.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-copyto#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The storage object was successfully copied.| |E_PENDING | Asynchronous Storage only: Part or all of the data to be copied is currently unavailable. | |STG_E_ACCESSDENIED | The destination storage object is a child of the source storage object.| |STG_E_INSUFFICIENTMEMORY | The copy was not completed due to a lack of memory.| |STG_E_INVALIDPOINTER | The pointer specified for the storage object was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_TOOMANYOPENFILES | The copy was not completed because there are too many open files.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_MEDIUMFULL | The copy was not completed because the storage medium is full.|</para>
			/// </returns>
			/// <remarks>
			/// <para>This method merges elements contained in the source storage object with those already present in the destination. The layout of the destination storage object may differ from the source storage object. The copy process is recursive, invoking <b>IStorage::CopyTo</b> and <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istream-copyto">IStream::CopyTo</a> on the elements nested inside the source. When copying a stream on top of an existing stream with the same name, the existing stream is first removed and then replaced with the source stream. When copying a storage on top of an existing storage with the same name, the existing storage is not removed. As a result, after the copy operation, the destination <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> contains older elements, unless they were replaced by newer ones with the same names. A storage object may expose interfaces other than <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a>, including <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-irootstorage">IRootStorage</a>, <a href="https://docs.microsoft.com/windows/desktop/api/propidl/nn-propidl-ipropertystorage">IPropertyStorage</a>, or <a href="https://docs.microsoft.com/windows/desktop/api/propidl/nn-propidl-ipropertysetstorage">IPropertySetStorage</a>. The <i>rgiidExclude</i> parameter permits the exclusion of any or all of these additional interfaces from the copy operation. A caller with a newer or more efficient copy of an existing substorage or stream object may want to exclude the current versions of these objects from the copy operation. The <i>snbExclude</i> and <i>rgiidExclude</i> parameters provide two ways of excluding a storage objects existing storages or streams. <h3><a id="Note_to_Callers"></a><a id="note_to_callers"></a><a id="NOTE_TO_CALLERS"></a>Note to Callers</h3> The most common way to use the <b>IStorage::CopyTo</b> method is to copy everything from the source to the destination, as in most full-save and save-as operations. The following  example code shows how to copy everything  from the source storage object to the destination storage object.</para>
			/// <para></para>
			/// <para>This doc was truncated.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-copyto#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT CopyTo(uint ciidExclude, [Optional] global::System.Guid* rgiidExclude, [Optional] ushort** snbExclude, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint ,global::System.Guid* ,ushort** ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.Foundation.HRESULT>)lpVtbl[7])((IStorage*)Unsafe.AsPointer(ref this), ciidExclude, rgiidExclude, snbExclude, pstgDest);
			}

			/// <inheritdoc cref="MoveElementTo(winmdroot.Foundation.PCWSTR, winmdroot.System.Com.StructuredStorage.IStorage*, winmdroot.Foundation.PCWSTR, uint)"/>
			internal unsafe winmdroot.Foundation.HRESULT MoveElementTo(string pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest, string pwcsNewName, uint grfFlags)
			{
				fixed (char* pwcsNewNameLocal = pwcsNewName)
				{
					fixed (char* pwcsNameLocal = pwcsName)
					{
						winmdroot.Foundation.HRESULT __result = this.MoveElementTo(pwcsNameLocal, pstgDest, pwcsNewNameLocal, grfFlags);
						return __result;
					}
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT MoveElementTo(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest, winmdroot.Foundation.PCWSTR pwcsNewName, uint grfFlags)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.MoveElementTo(pwcsName, pstgDest, pwcsNewName, grfFlags);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The MoveElementTo method copies or moves a substorage or stream from this storage object to another storage object.</summary>
			/// <param name="pwcsName">Pointer to a wide character null-terminated Unicode string that contains the name of the element in this storage object to be moved or copied.</param>
			/// <param name="pstgDest"><a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-istorage">IStorage</a> pointer to the destination storage object.</param>
			/// <param name="pwcsNewName">Pointer to a wide character null-terminated unicode string that contains the new name for the element in its new storage object.</param>
			/// <param name="grfFlags">
			/// <para>Specifies whether the operation should be a move (STGMOVE_MOVE) or a copy (STGMOVE_COPY). See the <a href="https://docs.microsoft.com/windows/desktop/api/wtypes/ne-wtypes-stgmove">STGMOVE</a> enumeration.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-moveelementto#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The storage object was successfully copied or moved.| |E_PENDING | Asynchronous Storage only: Part or all of the element's data is currently unavailable. | |STG_E_ACCESSDENIED | The destination storage object is a child of the source storage object. Or, the destination object and element name are the same as the source object and element name. In other words, you cannot move an element to itself.| |STG_E_FILENOTFOUND | The element with the specified name does not exist.| |STG_E_FILEALREADYEXISTS | The specified file already exists.| |STG_E_INSUFFICIENTMEMORY | The copy or move was not completed due to a lack of memory.| |STG_E_INVALIDFLAG | The value for the *grfFlags* parameter is not valid.| |STG_E_INVALIDNAME | Not a valid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the storage object was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The copy or move was not completed because there are too many open files.|</para>
			/// </returns>
			/// <remarks>
			/// <para>The <b>IStorage::MoveElementTo</b> method is typically the same as invoking the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-copyto">IStorage::CopyTo</a> method on the indicated element and then removing the source element. In this case, the <b>MoveElementTo</b> method uses only the publicly available functions of the destination storage object to carry out the move. If the source and destination storage objects have special knowledge about each other's implementation (they could, for example, be different instances of the same implementation), this method can be implemented more efficiently. Before calling this method, the element to be moved must be closed, and the destination storage must be open. Also, the destination object and element cannot be the same storage object/element name as the source of the move. That is, you cannot move an element to itself.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-moveelementto#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT MoveElementTo(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest, winmdroot.Foundation.PCWSTR pwcsNewName, uint grfFlags)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.Foundation.PCWSTR ,uint ,winmdroot.Foundation.HRESULT>)lpVtbl[8])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, pstgDest, pwcsNewName, grfFlags);
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT Commit(IStorage* pThis, uint grfCommitFlags)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.Commit(grfCommitFlags);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The Commit method ensures that any changes made to a storage object open in transacted mode are reflected in the parent storage.</summary>
			/// <param name="grfCommitFlags">
			/// <para>Controls how the changes are committed to the storage object. See the <a href="https://docs.microsoft.com/windows/desktop/api/wtypes/ne-wtypes-stgc">STGC</a> enumeration for a definition of these values.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-commit#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | Changes to the storage object were successfully committed to the parent level. If STGC_CONSOLIDATE was specified, the storage was successfully consolidated, or the storage was already too compact to consolidate further.| |STG_S_MULTIPLEOPENS | The commit operation succeeded, but the storage could not be consolidated because it had been opened multiple times using the STGM_NOSNAPSHOT flag.| |STG_S_CANNOTCONSOLIDATE | The commit operation succeeded, but the storage could not be consolidated due to an incorrect storage mode. For compound files, the storage may have been opened using the STGM_NOSCRATCH flag, or the storage may not be the outermost transacted level.| |STG_S_CONSOLIDATIONFAILED | The commit operation succeeded, but the storage could not be consolidated due to an internal error (for example, a memory allocation failure).| |E_PENDING | Asynchronous storage only: Part or all of the data to be committed is currently unavailable.| |STG_E_INVALIDFLAG | The value for the *grfCommitFlags* parameter is not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_NOTCURRENT | Another open instance of the storage object has committed changes. As a result, the current commit operation may overwrite previous changes.| |STG_E_MEDIUMFULL | No space left on device to commit.| |STG_E_TOOMANYOPENFILES | The commit operation could not be completed because there are too many open files.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.|</para>
			/// </returns>
			/// <remarks>
			/// <para><b>IStorage::Commit</b> makes permanent changes to a storage object that is in transacted mode, in which changes are accumulated in a buffer, and not reflected in the storage object until there is a call to this method. The alternative is to open an object in direct mode, in which changes are immediately reflected in the storage object. An object opened in the direct mode does not require calling <b>IStorage::Commit</b> to make permanent changes in the storage object. Calling the <b>IStorage::Commit</b> method on a nonroot storage opened in direct mode has no effect. Opening a root storage object in direct mode ensures that changes in memory buffers are written to the underlying storage device. The commit operation publishes the current changes in this storage object and its children to the next level up in the storage hierarchy. To undo current changes before committing them, call <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-revert">IStorage::Revert</a> to roll back to the last-committed version. Calling <b>IStorage::Commit</b> has no effect on currently opened nested elements of this storage object. They remain valid and can be used. However, the <b>IStorage::Commit</b> method does not automatically commit changes to these nested elements. The commit operation publishes only known changes to the next higher level in the storage hierarchy. Thus, transactions to nested levels must be committed to this storage object before they can be committed to higher levels. In commit operations, you need to take steps to ensure that data is protected during the commit process: </para>
			/// <para>This doc was truncated.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-commit#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public winmdroot.Foundation.HRESULT Commit(uint grfCommitFlags)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint ,winmdroot.Foundation.HRESULT>)lpVtbl[9])((IStorage*)Unsafe.AsPointer(ref this), grfCommitFlags);
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT Revert(IStorage* pThis)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.Revert();
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The Revert method discards all changes that have been made to the storage object since the last commit operation.</summary>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The revert operation was successful.| |E_PENDING | Asynchronous Storage only: Part or all of the storage's data is currently unavailable. | |STG_E_INSUFFICIENTMEMORY | The revert operation could not be completed due to a lack of memory.| |STG_E_TOOMANYOPENFILES | The revert operation could not be completed because there are too many open files.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.|</para>
			/// </returns>
			/// <remarks>
			/// <para>For storage objects opened in transacted mode, the <b>IStorage::Revert</b> method discards any uncommitted changes to this storage object or changes that have been committed to this storage object from nested elements. After this method returns, any existing elements (substorages or streams) that were opened from the reverted storage object are invalid and can no longer be used. Specifying these reverted elements in any call except <a href="https://docs.microsoft.com/windows/desktop/api/unknwn/nf-unknwn-iunknown-release">IUnknown::Release</a> returns the error STG_E_REVERTED This method has no effect on storage objects opened in direct mode.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-revert#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public winmdroot.Foundation.HRESULT Revert()
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.HRESULT>)lpVtbl[10])((IStorage*)Unsafe.AsPointer(ref this));
			}

			/// <inheritdoc cref="EnumElements(uint, void*, uint, winmdroot.System.Com.StructuredStorage.IEnumSTATSTG**)"/>
			internal unsafe winmdroot.Foundation.HRESULT EnumElements(winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ppenum)
			{
				winmdroot.Foundation.HRESULT __result = this.EnumElements(default, default, default, ppenum);
				return __result;
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT EnumElements(IStorage* pThis, uint reserved1, [Optional] void* reserved2, uint reserved3, winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ppenum)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.EnumElements(reserved1, reserved2, reserved3, ppenum);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The EnumElements method retrieves a pointer to an enumerator object that can be used to enumerate the storage and stream objects contained within this storage object.</summary>
			/// <param name="reserved1">Reserved for future use; must be zero.</param>
			/// <param name="reserved2">Reserved for future use; must be <b>NULL</b>.</param>
			/// <param name="reserved3">Reserved for future use; must be zero.</param>
			/// <param name="ppenum">
			/// <para>Pointer to <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-ienumstatstg">IEnumSTATSTG</a>* pointer variable that receives the interface pointer to the new enumerator object.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-enumelements#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The enumerator object was successfully returned.| |E_PENDING | Asynchronous Storage only: Part or all of the element's data is currently unavailable.| |STG_E_INSUFFICIENTMEMORY | The enumerator object could not be created due to lack of memory.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.|</para>
			/// </returns>
			/// <remarks>
			/// <para>The enumerator object returned by this method implements the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-ienumstatstg">IEnumSTATSTG</a> interface, one of the standard enumerator interfaces that contain the <b>Next</b>, <b>Reset</b>, <b>Clone</b>, and <b>Skip</b> methods. <b>IEnumSTATSTG</b> enumerates the data stored in an array of <a href="https://docs.microsoft.com/windows/desktop/api/objidl/ns-objidl-statstg">STATSTG</a> structures. The storage object must be open in read mode to allow the enumeration of its elements. The enumerator object is permitted to enumerate the elements in any order. The enumerator object is also permitted to treat the enumeration as a snapshot or to have the enumeration reflect the current state of the storage object.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-enumelements#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT EnumElements(uint reserved1, [Optional] void* reserved2, uint reserved3, winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ppenum)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint ,void* ,uint ,winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ,winmdroot.Foundation.HRESULT>)lpVtbl[11])((IStorage*)Unsafe.AsPointer(ref this), reserved1, reserved2, reserved3, ppenum);
			}

			/// <inheritdoc cref="DestroyElement(winmdroot.Foundation.PCWSTR)"/>
			internal unsafe winmdroot.Foundation.HRESULT DestroyElement(string pwcsName)
			{
				fixed (char* pwcsNameLocal = pwcsName)
				{
					winmdroot.Foundation.HRESULT __result = this.DestroyElement(pwcsNameLocal);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT DestroyElement(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.DestroyElement(pwcsName);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>Removes the specified storage or stream from this storage object.</summary>
			/// <param name="pwcsName">A pointer to a wide character null-terminated Unicode string that contains the name of the storage or stream to be removed.</param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The element was successfully removed.| |E_PENDING | Asynchronous Storage only: Part or all of the element data is currently unavailable. | |STG_E_ACCESSDENIED | The caller does not have permissions to remove the element.| |STG_E_FILENOTFOUND | The element with the specified name does not exist.| |STG_E_INSUFFICIENTMEMORY | The element was not removed due to a lack of memory.| |STG_E_INVALIDNAME | Invalid value for *pwcsName*.| |STG_E_INVALIDPOINTER | The pointer specified for the element was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The element was not removed because there are too many open files.|</para>
			/// </returns>
			/// <remarks>
			/// <para>The <b>DestroyElement</b> method deletes a substorage or stream from the current storage object. After a successful call to <b>DestroyElement</b>, any open instance of the destroyed element from the parent storage becomes invalid. If a storage object is opened in the transacted mode, destruction of an element requires that the call to <b>DestroyElement</b> be followed by a call to <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-commit">IStorage::Commit</a>. <div class="alert"><b>Note</b>  The <b>DestroyElement</b> method does not shrink the directory stream.  It only marks the deleted directory entry as invalid.  Invalid entries are reused when creating a new storage or stream.  <p class="note">For content streams, the deleted stream sectors are marked as free. If the free sectors are at the end of the file, the document file should shrink.  To compact a document file, call <b>IStorage::CopyTo</b> on the root storage object and copy to a new storage object. </div> <div> </div></para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-destroyelement#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public winmdroot.Foundation.HRESULT DestroyElement(winmdroot.Foundation.PCWSTR pwcsName)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.HRESULT>)lpVtbl[12])((IStorage*)Unsafe.AsPointer(ref this), pwcsName);
			}

			/// <inheritdoc cref="RenameElement(winmdroot.Foundation.PCWSTR, winmdroot.Foundation.PCWSTR)"/>
			internal unsafe winmdroot.Foundation.HRESULT RenameElement(string pwcsOldName, string pwcsNewName)
			{
				fixed (char* pwcsNewNameLocal = pwcsNewName)
				{
					fixed (char* pwcsOldNameLocal = pwcsOldName)
					{
						winmdroot.Foundation.HRESULT __result = this.RenameElement(pwcsOldNameLocal, pwcsNewNameLocal);
						return __result;
					}
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT RenameElement(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsOldName, winmdroot.Foundation.PCWSTR pwcsNewName)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.RenameElement(pwcsOldName, pwcsNewName);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The RenameElement method renames the specified substorage or stream in this storage object.</summary>
			/// <param name="pwcsOldName">
			/// <para>Pointer to a wide character null-terminated Unicode string that contains the name of the substorage or stream to be changed. <div class="alert"><b>Note</b>  The <i>pwcsName</i>, created in <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-createstorage">CreateStorage</a> or <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-createstream">CreateStream</a> must not exceed 31 characters in length, not including the string terminator.</div> <div> </div></para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-renameelement#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <param name="pwcsNewName">
			/// <para>Pointer to a wide character null-terminated unicode string that contains the new name for the specified substorage or stream. <div class="alert"><b>Note</b>  The <i>pwcsName</i>, created in <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-createstorage">CreateStorage</a> or <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-createstream">CreateStream</a> must not exceed 31 characters in length, not including the string terminator.</div> <div> </div></para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-renameelement#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The element was successfully renamed.| |E_PENDING | Asynchronous Storage only: Part or all of the element's data is currently unavailable.| |STG_E_ACCESSDENIED | The caller does not have enough permissions for renaming the element.| |STG_E_FILENOTFOUND | The element with the specified old name does not exist.| |STG_E_FILEALREADYEXISTS | The element specified by the new name already exists.| |STG_E_INSUFFICIENTMEMORY | The element was not renamed due to a lack of memory.| |STG_E_INVALIDNAME | Invalid value for one of the names.| |STG_E_INVALIDPOINTER | The pointer specified for the element was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.| |STG_E_TOOMANYOPENFILES | The element was not renamed because there are too many open files.|</para>
			/// </returns>
			/// <remarks>
			/// <para><b>IStorage::RenameElement</b> renames the specified substorage or stream in this storage object. An element in a storage object cannot be renamed while it is open. The rename operation is subject to committing the changes if the storage is open in transacted mode. The <b>IStorage::RenameElement</b> method is not guaranteed to work in low memory with storage objects open in transacted mode. It may work in direct mode.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-renameelement#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public winmdroot.Foundation.HRESULT RenameElement(winmdroot.Foundation.PCWSTR pwcsOldName, winmdroot.Foundation.PCWSTR pwcsNewName)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.HRESULT>)lpVtbl[13])((IStorage*)Unsafe.AsPointer(ref this), pwcsOldName, pwcsNewName);
			}

			/// <inheritdoc cref="SetElementTimes(winmdroot.Foundation.PCWSTR, global::System.Runtime.InteropServices.ComTypes.FILETIME*, global::System.Runtime.InteropServices.ComTypes.FILETIME*, global::System.Runtime.InteropServices.ComTypes.FILETIME*)"/>
			internal unsafe winmdroot.Foundation.HRESULT SetElementTimes(string pwcsName, in global::System.Runtime.InteropServices.ComTypes.FILETIME pctime, in global::System.Runtime.InteropServices.ComTypes.FILETIME patime, in global::System.Runtime.InteropServices.ComTypes.FILETIME pmtime)
			{
				fixed (global::System.Runtime.InteropServices.ComTypes.FILETIME* pmtimeLocal = &pmtime)
				{
					fixed (global::System.Runtime.InteropServices.ComTypes.FILETIME* patimeLocal = &patime)
					{
						fixed (global::System.Runtime.InteropServices.ComTypes.FILETIME* pctimeLocal = &pctime)
						{
							fixed (char* pwcsNameLocal = pwcsName)
							{
								winmdroot.Foundation.HRESULT __result = this.SetElementTimes(pwcsNameLocal, pctimeLocal, patimeLocal, pmtimeLocal);
								return __result;
							}
						}
					}
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT SetElementTimes(IStorage* pThis, winmdroot.Foundation.PCWSTR pwcsName, global::System.Runtime.InteropServices.ComTypes.FILETIME* pctime, global::System.Runtime.InteropServices.ComTypes.FILETIME* patime, global::System.Runtime.InteropServices.ComTypes.FILETIME* pmtime)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.SetElementTimes(pwcsName, pctime, patime, pmtime);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The SetElementTimes method sets the modification, access, and creation times of the specified storage element, if the underlying file system supports this method.</summary>
			/// <param name="pwcsName">The name of the storage object element whose times are to be modified. If <b>NULL</b>, the time is set on the root storage rather than one of its elements.</param>
			/// <param name="pctime">Either the new creation time for the element or <b>NULL</b> if the creation time is not to be modified.</param>
			/// <param name="patime">Either the new access time for the element or <b>NULL</b> if the access time is not to be modified.</param>
			/// <param name="pmtime">Either the new modification time for the element or <b>NULL</b> if the modification time is not to be modified.</param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The time values were successfully set.| |E_PENDING | Asynchronous Storage only: Part or all of the element's data is currently unavailable.| |STG_E_ACCESSDENIED | The caller does not have enough permissions for changing the element.| |STG_E_FILENOTFOUND | The element with the specified name does not exist.| |STG_E_INSUFFICIENTMEMORY | The element was not changed due to a lack of memory.| |STG_E_INVALIDNAME | Not a valid value for the element name.| |STG_E_INVALIDPOINTER | The pointer specified for the element was not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.| |STG_E_TOOMANYOPENFILES | The element was not changed because there are too many open files.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.|</para>
			/// </returns>
			/// <remarks>
			/// <para><b>SetElementTimes</b>  sets time statistics for the specified storage element within this storage object. Not all file systems support all the time values. This method sets those times that are supported and ignores the rest. Each time-value parameter can be <b>NULL</b>; indicating that no modification should occur. Call the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-stat">IStorage::Stat</a> method to retrieve these time values.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-setelementtimes#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT SetElementTimes(winmdroot.Foundation.PCWSTR pwcsName, global::System.Runtime.InteropServices.ComTypes.FILETIME* pctime, global::System.Runtime.InteropServices.ComTypes.FILETIME* patime, global::System.Runtime.InteropServices.ComTypes.FILETIME* pmtime)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,winmdroot.Foundation.HRESULT>)lpVtbl[14])((IStorage*)Unsafe.AsPointer(ref this), pwcsName, pctime, patime, pmtime);
			}

			/// <inheritdoc cref="SetClass(global::System.Guid*)"/>
			internal unsafe winmdroot.Foundation.HRESULT SetClass(in global::System.Guid clsid)
			{
				fixed (global::System.Guid* clsidLocal = &clsid)
				{
					winmdroot.Foundation.HRESULT __result = this.SetClass(clsidLocal);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT SetClass(IStorage* pThis, global::System.Guid* clsid)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.SetClass(clsid);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The SetClass method assigns the specified class identifier (CLSID) to this storage object.</summary>
			/// <param name="clsid">The CLSID that is to be associated with the storage object.</param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The CLSID was successfully assigned.| |E_PENDING | Asynchronous Storage only: Part or all of the storage's data is currently unavailable.| |STG_E_ACCESSDENIED | The caller does not have enough permissions for assigning a CLSID to the storage object.| |STG_E_MEDIUMFULL | Not enough space was left on device to complete the operation.| |STG_E_REVERTED | The storage object has been invalidated by a revert operation above it in the transaction tree.|</para>
			/// </returns>
			/// <remarks>
			/// <para>When first created, a storage object has an associated CLSID of CLSID_NULL. Call <b>SetClass</b> to assign a CLSID to the storage object. Call the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-stat">IStorage::Stat</a> method to retrieve the current CLSID of a storage object.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-setclass#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT SetClass(global::System.Guid* clsid)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,global::System.Guid* ,winmdroot.Foundation.HRESULT>)lpVtbl[15])((IStorage*)Unsafe.AsPointer(ref this), clsid);
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT SetStateBits(IStorage* pThis, uint grfStateBits, uint grfMask)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.SetStateBits(grfStateBits, grfMask);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The SetStateBits method stores up to 32 bits of state information in this storage object.</summary>
			/// <param name="grfStateBits">Specifies the new values of the bits to set. No legal values are defined for these bits; they are all reserved for future use and must not be used by applications.</param>
			/// <param name="grfMask">A binary mask indicating which bits in <i>grfStateBits</i> are significant in this call.</param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The state information was successfully set.| |E_PENDING | Asynchronous Storage only: Part or all of the storage's data is currently unavailable. | |STG_E_ACCESSDENIED | The caller does not have enough permissions for changing this storage object.| |STG_E_INVALIDFLAG | The value for the grfStateBits or *grfMask* parameter is not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.|</para>
			/// </returns>
			/// <remarks>The values for the state bits are not currently defined.</remarks>
			public winmdroot.Foundation.HRESULT SetStateBits(uint grfStateBits, uint grfMask)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,uint ,uint ,winmdroot.Foundation.HRESULT>)lpVtbl[16])((IStorage*)Unsafe.AsPointer(ref this), grfStateBits, grfMask);
			}

			/// <inheritdoc cref="Stat(winmdroot.System.Com.STATSTG*, uint)"/>
			internal unsafe winmdroot.Foundation.HRESULT Stat(out winmdroot.System.Com.STATSTG pstatstg, uint grfStatFlag)
			{
				fixed (winmdroot.System.Com.STATSTG* pstatstgLocal = &pstatstg)
				{
					winmdroot.Foundation.HRESULT __result = this.Stat(pstatstgLocal, grfStatFlag);
					return __result;
				}
			}

			[UnmanagedCallersOnly(CallConvs = new []{
typeof(CallConvStdcall)}
)]
			private static winmdroot.Foundation.HRESULT Stat(IStorage* pThis, winmdroot.System.Com.STATSTG* pstatstg, uint grfStatFlag)
			{
				try
				{
					winmdroot.Foundation.HRESULT __hr = ComHelpers.UnwrapCCW(pThis, out Interface __object);
					if (__hr.Failed)
					{
						return __hr;
					}
					return __object.Stat(pstatstg, grfStatFlag);
				}
				catch (Exception ex)
				{
					return (winmdroot.Foundation.HRESULT)ex.HResult;
				}
			}

			/// <summary>The Stat method retrieves the STATSTG structure for this open storage object.</summary>
			/// <param name="pstatstg">
			/// <para>On return, pointer to a <a href="https://docs.microsoft.com/windows/desktop/api/objidl/ns-objidl-statstg">STATSTG</a> structure where this method places information about the open storage object. This parameter is <b>NULL</b> if an error occurs.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-stat#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <param name="grfStatFlag">
			/// <para>Specifies that some of the members in the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/ns-objidl-statstg">STATSTG</a> structure are not returned, thus saving a memory allocation operation. Values are taken from the <a href="https://docs.microsoft.com/windows/desktop/api/wtypes/ne-wtypes-statflag">STATFLAG</a> enumeration.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-stat#parameters">Read more on docs.microsoft.com</see>.</para>
			/// </param>
			/// <returns>
			/// <para>This method can return one of these values. | Return code | Description | |----------------|---------------| |S_OK | The STATSTG structure was successfully returned at the specified location.| |E_PENDING | Asynchronous Storage only: Part or all of the storage's data is currently unavailable.| |STG_E_ACCESSDENIED | The caller does not have enough permissions for accessing statistics for this storage object.| |STG_E_INSUFFICIENTMEMORY | The STATSTG structure was not returned due to a lack of memory.| |STG_E_INVALIDFLAG | The value for the *grfStateFlag* parameter is not valid.| |STG_E_INVALIDPARAMETER | One of the parameters was not valid.|</para>
			/// </returns>
			/// <remarks>
			/// <para><b>IStorage::Stat</b> retrieves the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/ns-objidl-statstg">STATSTG</a> structure for the current storage object. The <b>STATSTG</b> structure contains statistical information about the storage object. <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nf-objidl-istorage-enumelements">IStorage::EnumElements</a> returns a pointer to an enumerator object. The enumerator object returned by this method implements the <a href="https://docs.microsoft.com/windows/desktop/api/objidl/nn-objidl-ienumstatstg">IEnumSTATSTG</a> interface, through which the data stored in the array of the <b>STATSTG</b> structures is enumerated.</para>
			/// <para><see href="https://learn.microsoft.com/windows/win32/api/objidl/nf-objidl-istorage-stat#">Read more on docs.microsoft.com</see>.</para>
			/// </remarks>
			public unsafe winmdroot.Foundation.HRESULT Stat(winmdroot.System.Com.STATSTG* pstatstg, uint grfStatFlag)
			{
				return ((delegate *unmanaged [Stdcall]<IStorage*,winmdroot.System.Com.STATSTG* ,uint ,winmdroot.Foundation.HRESULT>)lpVtbl[17])((IStorage*)Unsafe.AsPointer(ref this), pstatstg, grfStatFlag);
			}

			internal unsafe global::Windows.Win32.Foundation.HRESULT QueryInterface<T>(out T* ppv)
where T : unmanaged

			{
				var hr = this.QueryInterface(typeof(T).GUID, out void* pv);
				if (hr.Succeeded)

				{
					ppv = (T*)pv;
				}
				else

				{
					ppv = null;
				}

				return hr;
			}

			internal struct Vtbl
			{
				internal delegate *unmanaged [Stdcall]<IStorage*,global::System.Guid* ,void** ,winmdroot.Foundation.HRESULT> QueryInterface_1;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint> AddRef_2;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint> Release_3;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.STGM ,uint ,uint ,winmdroot.System.Com.IStream** ,winmdroot.Foundation.HRESULT> CreateStream_4;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,void* ,winmdroot.System.Com.STGM ,uint ,winmdroot.System.Com.IStream** ,winmdroot.Foundation.HRESULT> OpenStream_5;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.STGM ,uint ,uint ,winmdroot.System.Com.StructuredStorage.IStorage** ,winmdroot.Foundation.HRESULT> CreateStorage_6;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.System.Com.STGM ,ushort** ,uint ,winmdroot.System.Com.StructuredStorage.IStorage** ,winmdroot.Foundation.HRESULT> OpenStorage_7;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint ,global::System.Guid* ,ushort** ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.Foundation.HRESULT> CopyTo_8;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.System.Com.StructuredStorage.IStorage* ,winmdroot.Foundation.PCWSTR ,uint ,winmdroot.Foundation.HRESULT> MoveElementTo_9;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint ,winmdroot.Foundation.HRESULT> Commit_10;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.HRESULT> Revert_11;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint ,void* ,uint ,winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ,winmdroot.Foundation.HRESULT> EnumElements_12;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.HRESULT> DestroyElement_13;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.PCWSTR ,winmdroot.Foundation.HRESULT> RenameElement_14;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.Foundation.PCWSTR ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,global::System.Runtime.InteropServices.ComTypes.FILETIME* ,winmdroot.Foundation.HRESULT> SetElementTimes_15;

				internal delegate *unmanaged [Stdcall]<IStorage*,global::System.Guid* ,winmdroot.Foundation.HRESULT> SetClass_16;

				internal delegate *unmanaged [Stdcall]<IStorage*,uint ,uint ,winmdroot.Foundation.HRESULT> SetStateBits_17;

				internal delegate *unmanaged [Stdcall]<IStorage*,winmdroot.System.Com.STATSTG* ,uint ,winmdroot.Foundation.HRESULT> Stat_18;
			} 
			public static void PopulateVTable(Vtbl* vtable)
			{
				vtable->CreateStream_4 = &CreateStream;
				vtable->OpenStream_5 = &OpenStream;
				vtable->CreateStorage_6 = &CreateStorage;
				vtable->OpenStorage_7 = &OpenStorage;
				vtable->CopyTo_8 = &CopyTo;
				vtable->MoveElementTo_9 = &MoveElementTo;
				vtable->Commit_10 = &Commit;
				vtable->Revert_11 = &Revert;
				vtable->EnumElements_12 = &EnumElements;
				vtable->DestroyElement_13 = &DestroyElement;
				vtable->RenameElement_14 = &RenameElement;
				vtable->SetElementTimes_15 = &SetElementTimes;
				vtable->SetClass_16 = &SetClass;
				vtable->SetStateBits_17 = &SetStateBits;
				vtable->Stat_18 = &Stat;
			}

			private void** lpVtbl;

			/// <summary>The IID guid for this interface.</summary>
			/// <value>{0000000b-0000-0000-c000-000000000046}</value>
			internal static readonly Guid IID_Guid = new Guid(0x0000000B, 0x0000, 0x0000, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46);

			static ref readonly Guid IComIID.Guid			{
								[MethodImpl(MethodImplOptions.AggressiveInlining)]
get
				{
					ReadOnlySpan<byte> data = new byte[]					{
0x0B,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x46					};
					return ref Unsafe.As<byte,Guid>(ref MemoryMarshal.GetReference(data));
				}
			}
			[Guid("0000000B-0000-0000-C000-000000000046"),InterfaceType(ComInterfaceType.InterfaceIsIUnknown),ComImport()]
			[SupportedOSPlatform("windows5.0")]
			internal interface Interface
			{
				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT CreateStream(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.IStream** ppstm);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT OpenStream(winmdroot.Foundation.PCWSTR pwcsName, [Optional] void* reserved1, winmdroot.System.Com.STGM grfMode, uint reserved2, winmdroot.System.Com.IStream** ppstm);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT CreateStorage(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.STGM grfMode, uint reserved1, uint reserved2, winmdroot.System.Com.StructuredStorage.IStorage** ppstg);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT OpenStorage(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgPriority, winmdroot.System.Com.STGM grfMode, ushort** snbExclude, uint reserved, winmdroot.System.Com.StructuredStorage.IStorage** ppstg);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT CopyTo(uint ciidExclude, [Optional] global::System.Guid* rgiidExclude, [Optional] ushort** snbExclude, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT MoveElementTo(winmdroot.Foundation.PCWSTR pwcsName, winmdroot.System.Com.StructuredStorage.IStorage* pstgDest, winmdroot.Foundation.PCWSTR pwcsNewName, uint grfFlags);

								[PreserveSig()]
winmdroot.Foundation.HRESULT Commit(uint grfCommitFlags);

								[PreserveSig()]
winmdroot.Foundation.HRESULT Revert();

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT EnumElements(uint reserved1, [Optional] void* reserved2, uint reserved3, winmdroot.System.Com.StructuredStorage.IEnumSTATSTG** ppenum);

								[PreserveSig()]
winmdroot.Foundation.HRESULT DestroyElement(winmdroot.Foundation.PCWSTR pwcsName);

								[PreserveSig()]
winmdroot.Foundation.HRESULT RenameElement(winmdroot.Foundation.PCWSTR pwcsOldName, winmdroot.Foundation.PCWSTR pwcsNewName);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT SetElementTimes(winmdroot.Foundation.PCWSTR pwcsName, global::System.Runtime.InteropServices.ComTypes.FILETIME* pctime, global::System.Runtime.InteropServices.ComTypes.FILETIME* patime, global::System.Runtime.InteropServices.ComTypes.FILETIME* pmtime);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT SetClass(global::System.Guid* clsid);

								[PreserveSig()]
winmdroot.Foundation.HRESULT SetStateBits(uint grfStateBits, uint grfMask);

				[PreserveSig()]
				unsafe winmdroot.Foundation.HRESULT Stat(winmdroot.System.Com.STATSTG* pstatstg, uint grfStatFlag);
			}
		}
	}
}