#if !defined(_COML2API_H_)
#define _COML2API_H_
#ifdef _MSC_VER
#pragma once
#endif // _MSC_VER
#include <apiset.h>
#include <apisetcconv.h>
#include <combaseapi.h>
#include <objidl.h>
#include <propidlbase.h>
#pragma region Application Family
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)
#define CWCSTORAGENAME 32
#define STGM_DIRECT 0x00000000L
#define STGM_TRANSACTED 0x00010000L
#define STGM_SIMPLE 0x08000000L
#define STGM_READ 0x00000000L
#define STGM_WRITE 0x00000001L
#define STGM_READWRITE 0x00000002L
#define STGM_SHARE_DENY_NONE 0x00000040L
#define STGM_SHARE_DENY_READ 0x00000030L
#define STGM_SHARE_DENY_WRITE 0x00000020L
#define STGM_SHARE_EXCLUSIVE 0x00000010L
#define STGM_PRIORITY 0x00040000L
#define STGM_DELETEONRELEASE 0x04000000L
#if (WINVER >= 400)
#define STGM_NOSCRATCH 0x00100000L
#endif /* WINVER */
#define STGM_CREATE 0x00001000L
#define STGM_CONVERT 0x00020000L
#define STGM_FAILIFTHERE 0x00000000L
#define STGM_NOSNAPSHOT 0x00200000L
#if (_WIN32_WINNT >= 0x0500)
#define STGM_DIRECT_SWMR 0x00400000L
#endif
typedef
;
#define STGFMT_STORAGE 0
#define STGFMT_NATIVE 1
#define STGFMT_FILE 3
#define STGFMT_ANY 4
#define STGFMT_DOCFILE 5
#define STGFMT_DOCUMENT 0
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_opt_ _Null_terminated_ const WCHAR* pwcsName,
_Reserved_ DWORD reserved,
_Outptr_ IStorage** ppstgOpen
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
StgCreateDocfileOnILockBytes
(
_Outptr_ IStorage** ppstgOpen
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_opt_ _Null_terminated_ const WCHAR* pwcsName,
_In_opt_ IStorage* pstgPriority,
_In_opt_z_ SNB snbExclude,
_Outptr_ IStorage** ppstgOpen
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
StgOpenStorageOnILockBytes
(
_In_opt_ IStorage* pstgPriority,
_In_opt_z_ SNB snbExclude,
_Reserved_ DWORD reserved,
_Outptr_ IStorage** ppstgOpen
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ _Null_terminated_ const WCHAR* pwcsName
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ _Null_terminated_ const WCHAR* lpszName,
_In_opt_ const FILETIME* pctime,
_In_opt_ const FILETIME* patime,
_In_opt_ const FILETIME* pmtime
);
#if _WIN32_WINNT == 0x500
#define STGOPTIONS_VERSION 1
#elif _WIN32_WINNT > 0x500
#define STGOPTIONS_VERSION 2
#else
#define STGOPTIONS_VERSION 0
#endif
typedef
struct
{
;
;
;
#if STGOPTIONS_VERSION >= 2
const
*
;
#endif
}
;
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_opt_ _Null_terminated_ const WCHAR* pwcsName,
_Inout_opt_ STGOPTIONS* pStgOptions,
_In_opt_ PSECURITY_DESCRIPTOR pSecurityDescriptor,
_Outptr_ void** ppObjectOpen
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ _Null_terminated_ const WCHAR* pwcsName,
_Inout_opt_ STGOPTIONS* pStgOptions,
_In_opt_ PSECURITY_DESCRIPTOR pSecurityDescriptor,
_Outptr_ void** ppObjectOpen
);
#ifndef _STGCREATEPROPSTG_DEFINED_
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ const CLSID* pclsid,
_Reserved_ DWORD dwReserved,
_Outptr_ IPropertyStorage** ppPropStg
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_Reserved_ DWORD dwReserved,
_Outptr_ IPropertyStorage** ppPropStg
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_Reserved_ DWORD dwReserved,
_Outptr_ IPropertySetStorage** ppPropSetStg
);
#define CCH_MAX_PROPSTG_NAME 31
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ const FMTID* pfmtid,
_Out_writes_(CCH_MAX_PROPSTG_NAME + 1) LPOLESTR oszName
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_In_ const LPOLESTR oszName,
);
#endif // _STGCREATEPROPSTG_DEFINED_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
_Out_ HGLOBAL FAR * phglobal
);
_Check_return_
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
CreateILockBytesOnHGlobal
(
_In_opt_ HGLOBAL hGlobal,
_In_ BOOL fDeleteOnRelease,
_Outptr_ LPLOCKBYTES FAR * pplkbyt
);
WINOLEAPI
extern
"C"
__declspec
(dllimport)
__stdcall
(
);
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */
#pragma endregion
#endif // __COML2API_H__