1 | /**
|
---|
2 | * This file has no copyright assigned and is placed in the Public Domain.
|
---|
3 | * This file is part of the mingw-w64 runtime package.
|
---|
4 | * No warranty is given; refer to the file DISCLAIMER.PD within this package.
|
---|
5 | */
|
---|
6 | #ifndef __DTCHELP_H__
|
---|
7 | #define __DTCHELP_H__
|
---|
8 |
|
---|
9 | #include <_mingw_unicode.h>
|
---|
10 | #include <windows.h>
|
---|
11 |
|
---|
12 | #ifndef DEFINED_DTC_STATUS
|
---|
13 | #define DEFINED_DTC_STATUS
|
---|
14 |
|
---|
15 | typedef enum DTC_STATUS_ {
|
---|
16 | DTC_STATUS_UNKNOWN = 0,DTC_STATUS_STARTING = 1,DTC_STATUS_STARTED = 2,DTC_STATUS_PAUSING = 3,DTC_STATUS_PAUSED = 4,DTC_STATUS_CONTINUING = 5,
|
---|
17 | DTC_STATUS_STOPPING = 6,DTC_STATUS_STOPPED = 7,DTC_STATUS_E_CANTCONTROL = 8,DTC_STATUS_FAILED = 9
|
---|
18 | } DTC_STATUS;
|
---|
19 | #endif
|
---|
20 |
|
---|
21 | typedef HRESULT (__cdecl *DTC_GET_TRANSACTION_MANAGER)(char *pszHost,char *pszTmName,REFIID rid,DWORD dwReserved1,WORD wcbReserved2,void *pvReserved2,void **ppvObject);
|
---|
22 | typedef HRESULT (__cdecl *DTC_GET_TRANSACTION_MANAGER_EX_A)(char *i_pszHost,char *i_pszTmName,REFIID i_riid,DWORD i_grfOptions,void *i_pvConfigParams,void **o_ppvObject);
|
---|
23 | typedef HRESULT (__cdecl *DTC_GET_TRANSACTION_MANAGER_EX_W)(WCHAR *i_pwszHost,WCHAR *i_pwszTmName,REFIID i_riid,DWORD i_grfOptions,void *i_pvConfigParams,void **o_ppvObject);
|
---|
24 | typedef HRESULT (*DTC_INSTALL_CLIENT)(LPTSTR i_pszRemoteTmHostName,DWORD i_dwProtocol,DWORD i_dwOverwrite);
|
---|
25 |
|
---|
26 | #define DTC_GET_TRANSACTION_MANAGER_EX __MINGW_NAME_UAW(DTC_GET_TRANSACTION_MANAGER_EX)
|
---|
27 | #define LoadDtcHelperEx __MINGW_NAME_AW(LoadDtcHelperEx)
|
---|
28 | #define GetDTCStatus __MINGW_NAME_AW(GetDTCStatus)
|
---|
29 | #define StartDTC __MINGW_NAME_AW(StartDTC)
|
---|
30 | #define StopDTC __MINGW_NAME_AW(StopDTC)
|
---|
31 |
|
---|
32 | #define DTCINSTALL_E_CLIENT_ALREADY_INSTALLED __MSABI_LONG(0x0000180)
|
---|
33 | #define DTCINSTALL_E_SERVER_ALREADY_INSTALLED __MSABI_LONG(0x0000181)
|
---|
34 |
|
---|
35 | const DWORD DTC_INSTALL_OVERWRITE_CLIENT = 0x00000001;
|
---|
36 | const DWORD DTC_INSTALL_OVERWRITE_SERVER = 0x00000002;
|
---|
37 |
|
---|
38 | #ifdef __cplusplus
|
---|
39 | extern "C" {
|
---|
40 | #endif
|
---|
41 | DTC_GET_TRANSACTION_MANAGER __cdecl LoadDtcHelper(void);
|
---|
42 | DTC_GET_TRANSACTION_MANAGER_EX_A __cdecl LoadDtcHelperExA(void);
|
---|
43 | DTC_GET_TRANSACTION_MANAGER_EX_W __cdecl LoadDtcHelperExW(void);
|
---|
44 | void __cdecl FreeDtcHelper(void);
|
---|
45 | HMODULE __cdecl GetDtcLocaleResourceHandle(void);
|
---|
46 | HRESULT __cdecl Initialize(void);
|
---|
47 | HRESULT __cdecl Uninitialize(void);
|
---|
48 | DTC_STATUS __cdecl GetDTCStatusW(WCHAR *wszHostName);
|
---|
49 | DTC_STATUS __cdecl GetDTCStatusA(LPSTR szHostName);
|
---|
50 | HRESULT __cdecl StartDTCW(WCHAR *wszHostName);
|
---|
51 | HRESULT __cdecl StartDTCA(LPSTR szHostName);
|
---|
52 | HRESULT __cdecl StopDTCW(WCHAR *wszHostName);
|
---|
53 | HRESULT __cdecl StopDTCA(LPSTR szHostName);
|
---|
54 | HRESULT __cdecl DtcInstallClient(LPTSTR i_pszRemoteTmHostName,DWORD i_dwProtocol,DWORD i_dwOverwrite);
|
---|
55 | #ifdef __cplusplus
|
---|
56 | }
|
---|
57 | #endif
|
---|
58 |
|
---|
59 | #endif
|
---|