2 * Copyright 1997 Marcus Meissner
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 #ifndef __WINE_OLE_IFS_H
20 #define __WINE_OLE_IFS_H
28 typedef CHAR OLECHAR16;
29 typedef LPSTR LPOLESTR16;
30 typedef LPCSTR LPCOLESTR16;
32 /***********************************************************************
36 typedef struct IMalloc16 IMalloc16, *LPMALLOC16;
38 #define INTERFACE IMalloc16
39 DECLARE_INTERFACE_(IMalloc16,IUnknown)
41 /*** IUnknown methods ***/
42 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
43 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
44 STDMETHOD_(ULONG,Release)(THIS) PURE;
45 /*** IMalloc16 methods ***/
46 STDMETHOD_(LPVOID,Alloc)(THIS_ DWORD cb) PURE;
47 STDMETHOD_(LPVOID,Realloc)(THIS_ LPVOID pv, DWORD cb) PURE;
48 STDMETHOD_(void,Free)(THIS_ LPVOID pv) PURE;
49 STDMETHOD_(DWORD,GetSize)(THIS_ LPVOID pv) PURE;
50 STDMETHOD_(INT16,DidAlloc)(THIS_ LPVOID pv) PURE;
51 STDMETHOD_(LPVOID,HeapMinimize)(THIS) PURE;
55 /**********************************************************************/
57 extern LPMALLOC16 IMalloc16_Constructor(void);
59 /**********************************************************************/
61 typedef struct ILockBytes16 *LPLOCKBYTES16, ILockBytes16;
63 #define INTERFACE ILockBytes16
64 DECLARE_INTERFACE_(ILockBytes16,IUnknown)
66 /*** IUnknown methods ***/
67 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
68 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
69 STDMETHOD_(ULONG,Release)(THIS) PURE;
70 /*** ILockBytes16 methods ***/
71 STDMETHOD(ReadAt)(THIS_ ULARGE_INTEGER ulOffset, void *pv, ULONG cb, ULONG *pcbRead) PURE;
72 STDMETHOD(WriteAt)(THIS_ ULARGE_INTEGER ulOffset, const void *pv, ULONG cb, ULONG *pcbWritten) PURE;
73 STDMETHOD(Flush)(THIS) PURE;
74 STDMETHOD(SetSize)(THIS_ ULARGE_INTEGER cb) PURE;
75 STDMETHOD(LockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) PURE;
76 STDMETHOD(UnlockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) PURE;
77 STDMETHOD(Stat)(THIS_ STATSTG *pstatstg, DWORD grfStatFlag) PURE;
81 /**********************************************************************/
83 typedef struct tagSTATSTG16
87 ULARGE_INTEGER cbSize;
92 DWORD grfLocksSupported;
98 typedef struct IStream16 IStream16, *LPSTREAM16;
100 #define INTERFACE IStream16
101 DECLARE_INTERFACE_(IStream16,ISequentialStream)
103 /*** IUnknown methods ***/
104 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
105 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
106 STDMETHOD_(ULONG,Release)(THIS) PURE;
107 /*** ISequentialStream methods ***/
108 STDMETHOD_(HRESULT,Read)(THIS_ void* pv, ULONG cb, ULONG* pcbRead) PURE;
109 STDMETHOD_(HRESULT,Write)(THIS_ const void* pv, ULONG cb, ULONG* pcbWritten) PURE;
110 /*** IStream16 methods ***/
111 STDMETHOD(Seek)(THIS_ LARGE_INTEGER dlibMove, DWORD dwOrigin, ULARGE_INTEGER* plibNewPosition) PURE;
112 STDMETHOD(SetSize)(THIS_ ULARGE_INTEGER libNewSize) PURE;
113 STDMETHOD(CopyTo)(THIS_ IStream16* pstm, ULARGE_INTEGER cb, ULARGE_INTEGER* pcbRead, ULARGE_INTEGER* pcbWritten) PURE;
114 STDMETHOD(Commit)(THIS_ DWORD grfCommitFlags) PURE;
115 STDMETHOD(Revert)(THIS) PURE;
116 STDMETHOD(LockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) PURE;
117 STDMETHOD(UnlockRegion)(THIS_ ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType) PURE;
118 STDMETHOD(Stat)(THIS_ STATSTG* pstatstg, DWORD grfStatFlag) PURE;
119 STDMETHOD(Clone)(THIS_ IStream16** ppstm) PURE;
123 /**********************************************************************/
125 typedef OLECHAR16 **SNB16;
127 typedef struct IStorage16 IStorage16, *LPSTORAGE16;
129 #define INTERFACE IStorage16
130 DECLARE_INTERFACE_(IStorage16,IUnknown)
132 /*** IUnknown methods ***/
133 STDMETHOD_(HRESULT,QueryInterface)(THIS_ REFIID riid, void** ppvObject) PURE;
134 STDMETHOD_(ULONG,AddRef)(THIS) PURE;
135 STDMETHOD_(ULONG,Release)(THIS) PURE;
136 /*** IStorage16 methods ***/
137 STDMETHOD_(HRESULT,CreateStream)(THIS_ LPCOLESTR16 pwcsName, DWORD grfMode, DWORD reserved1, DWORD reserved2, IStream16** ppstm) PURE;
138 STDMETHOD_(HRESULT,OpenStream)(THIS_ LPCOLESTR16 pwcsName, void* reserved1, DWORD grfMode, DWORD reserved2, IStream16** ppstm) PURE;
139 STDMETHOD_(HRESULT,CreateStorage)(THIS_ LPCOLESTR16 pwcsName, DWORD grfMode, DWORD dwStgFmt, DWORD reserved2, IStorage16** ppstg) PURE;
140 STDMETHOD_(HRESULT,OpenStorage)(THIS_ LPCOLESTR16 pwcsName, IStorage16* pstgPriority, DWORD grfMode, SNB16 snbExclude, DWORD reserved, IStorage16** ppstg) PURE;
141 STDMETHOD_(HRESULT,CopyTo)(THIS_ DWORD ciidExclude, const IID* rgiidExclude, SNB16 snbExclude, IStorage16* pstgDest) PURE;
142 STDMETHOD_(HRESULT,MoveElementTo)(THIS_ LPCOLESTR16 pwcsName, IStorage16* pstgDest, LPCOLESTR16 pwcsNewName, DWORD grfFlags) PURE;
143 STDMETHOD_(HRESULT,Commit)(THIS_ DWORD grfCommitFlags) PURE;
144 STDMETHOD_(HRESULT,Revert)(THIS) PURE;
145 STDMETHOD_(HRESULT,EnumElements)(THIS_ DWORD reserved1, void* reserved2, DWORD reserved3, IEnumSTATSTG** ppenum) PURE;
146 STDMETHOD_(HRESULT,DestroyElement)(THIS_ LPCOLESTR16 pwcsName) PURE;
147 STDMETHOD_(HRESULT,RenameElement)(THIS_ LPCOLESTR16 pwcsOldName, LPCOLESTR16 pwcsNewName) PURE;
148 STDMETHOD_(HRESULT,SetElementTimes)(THIS_ LPCOLESTR16 pwcsName, const FILETIME* pctime, const FILETIME* patime, const FILETIME* pmtime) PURE;
149 STDMETHOD_(HRESULT,SetClass)(THIS_ REFCLSID clsid) PURE;
150 STDMETHOD_(HRESULT,SetStateBits)(THIS_ DWORD grfStateBits, DWORD grfMask) PURE;
151 STDMETHOD_(HRESULT,Stat)(THIS_ STATSTG* pstatstg, DWORD grfStatFlag) PURE;
155 #endif /* __WINE_OLE_IFS_H */