Porting fixes.
[wine.git] / include / objidl.idl
blob502214839c5b16b2ddf4ce296dbc6eb3a509b9c9
1 /*
2 * Copyright 2002 Ove Kaaven
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 import "unknwn.idl";
21 interface IStream;
22 interface IEnumString;
23 interface IRunningObjectTable;
24 interface IMoniker;
25 interface IAdviseSink;
26 interface IAsyncManager;
28 /* FIXME: COSERVERINFO should be moved here from wtypes.idl */
30 /******************** Fundamentals ********************/
33 local,
34 object,
35 uuid(00000003-0000-0000-C000-000000000046)
37 interface IMarshal : IUnknown
39 typedef [unique] IMarshal *LPMARSHAL;
41 HRESULT GetUnmarshalClass(
42 [in] REFIID riid,
43 [in, unique] void *pv,
44 [in] DWORD dwDestContext,
45 [in, unique] void *pvDestContext,
46 [in] DWORD mshlflags,
47 [out] CLSID *pCid);
49 HRESULT GetMarshalSizeMax(
50 [in] REFIID riid,
51 [in, unique] void *pv,
52 [in] DWORD dwDestContext,
53 [in, unique] void *pvDestContext,
54 [in] DWORD mshlflags,
55 [out] DWORD *pSize);
57 HRESULT MarshalInterface(
58 [in, unique] IStream *pStm,
59 [in] REFIID riid,
60 [in, unique] void *pv,
61 [in] DWORD dwDestContext,
62 [in, unique] void *pvDestContext,
63 [in] DWORD mshlflags);
65 HRESULT UnmarshalInterface(
66 [in, unique] IStream *pStm,
67 [in] REFIID riid,
68 [out] void **ppv);
70 HRESULT ReleaseMarshalData(
71 [in, unique] IStream *pStm);
73 HRESULT DisconnectObject(
74 [in] DWORD dwReserved);
78 local,
79 object,
80 uuid(00000018-0000-0000-C000-000000000046)
82 interface IStdMarshalInfo : IUnknown
84 typedef [unique] IStdMarshalInfo *LPSTDMARSHALINFO;
86 HRESULT GetClassForHandler(
87 [in] DWORD dwDestContext,
88 [in, unique] void *pvDestContext,
89 [out] CLSID *pClsid);
93 local,
94 object,
95 uuid(00000019-0000-0000-C000-000000000046)
97 interface IExternalConnection : IUnknown
99 typedef [unique] IExternalConnection *LPEXTERNALCONNECTION;
101 typedef enum tagEXTCONN {
102 EXTCONN_STRONG = 0x0001,
103 EXTCONN_WEAK = 0x0002,
104 EXTCONN_CALLABLE = 0x0004
105 } EXTCONN;
107 DWORD AddConnection(
108 [in] DWORD extconn,
109 [in] DWORD reserved);
111 DWORD ReleaseConnection(
112 [in] DWORD extconn,
113 [in] DWORD reserved,
114 [in] BOOL fLastReleaseCloses);
118 local,
119 object,
120 uuid(00000020-0000-0000-C000-000000000046)
122 interface IMultiQI : IUnknown
124 typedef [unique] IMultiQI *LPMULTIQI;
126 typedef struct tagMULTI_QI {
127 const IID *pIID;
128 IUnknown *pItf;
129 HRESULT hr;
130 } MULTI_QI;
132 HRESULT QueryMultipleInterfaces(
133 [in] ULONG cMQIs,
134 [in, out] MULTI_QI *pMQIs);
138 local,
139 object,
140 uuid(00000002-0000-0000-C000-000000000046)
142 interface IMalloc : IUnknown
144 typedef [unique] IMalloc *LPMALLOC;
146 LPVOID Alloc(
147 [in] ULONG cb);
149 LPVOID Realloc(
150 [in] LPVOID pv,
151 [in] ULONG cb);
153 void Free(
154 [in] LPVOID pv);
156 ULONG GetSize(
157 [in] LPVOID pv);
159 int DidAlloc(LPVOID pv);
161 void HeapMinimize();
165 local,
166 object,
167 uuid(0000001d-0000-0000-C000-000000000046)
169 interface IMallocSpy : IUnknown
171 typedef [unique] IMallocSpy *LPMALLOCSPY;
173 ULONG PreAlloc(
174 [in] ULONG cbRequest);
176 LPVOID PostAlloc(
177 [in] LPVOID pActual);
179 LPVOID PreFree(
180 [in] LPVOID pRequest,
181 [in] BOOL fSpyed);
183 void PostFree(
184 [in] BOOL fSpyed);
186 ULONG PreRealloc(
187 [in] LPVOID pRequest,
188 [in] ULONG cbRequest,
189 [out] LPVOID *ppNewRequest,
190 [in] BOOL fSpyed);
192 LPVOID PostRealloc(
193 [in] LPVOID pActual,
194 [in] BOOL fSpyed);
196 LPVOID PreGetSize(
197 [in] LPVOID pRequest,
198 [in] BOOL fSpyed);
200 ULONG PostGetSize(
201 [in] ULONG cbActual,
202 [in] BOOL fSpyed);
204 LPVOID PreDidAlloc(
205 [in] LPVOID pRequest,
206 [in] BOOL fSpyed);
208 int PostDidAlloc(
209 [in] LPVOID pRequest,
210 [in] BOOL fSpyed,
211 [in] int fActual);
213 void PreHeapMinimize();
215 void PostHeapMinimize();
219 object,
220 uuid(00000100-0000-0000-C000-000000000046),
221 pointer_default(unique)
223 interface IEnumUnknown : IUnknown
225 typedef [unique] IEnumUnknown *LPENUMUNKNOWN;
227 [local]
228 HRESULT Next(
229 [in] ULONG celt,
230 [out] IUnknown **rgelt,
231 [out] ULONG *pceltFetched);
233 [call_as(Next)]
234 HRESULT RemoteNext(
235 [in] ULONG celt,
236 [out, size_is(celt), length_is(*pceltFetched)]
237 IUnknown **rgelt,
238 [out] ULONG *pceltFetched);
240 HRESULT Skip(
241 [in] ULONG celt);
243 HRESULT Reset();
245 HRESULT Clone(
246 [out] IEnumUnknown **ppenum);
250 object,
251 uuid(00000022-0000-0000-C000-000000000046),
252 version(1.0),
253 pointer_default(unique)
255 interface ISurrogate : IUnknown
257 typedef [unique] ISurrogate *LPSURROGATE;
259 HRESULT LoadDllServer(
260 [in] REFCLSID Clsid);
261 HRESULT FreeSurrogate();
265 local,
266 object,
267 uuid(00000146-0000-0000-C000-000000000046)
269 interface IGlobalInterfaceTable : IUnknown
271 typedef [unique] IGlobalInterfaceTable *LPGLOBALINTERFACETABLE;
273 HRESULT RegisterInterfaceInGlobal(
274 [in] IUnknown *pUnk,
275 [in] REFIID riid,
276 [out] DWORD *pdwCookie);
278 HRESULT RevokeInterfaceFromGlobal(
279 [in] DWORD dwCookie);
281 HRESULT GetInterfaceFromGlobal(
282 [in] DWORD dwCookie,
283 [in] REFIID riid,
284 [out, iid_is(riid)] void **ppv);
287 /******************** Monikers ********************/
290 object,
291 uuid(0000000e-0000-0000-C000-000000000046),
292 pointer_default(unique)
294 interface IBindCtx : IUnknown
296 typedef [unique] IBindCtx *LPBINDCTX;
297 typedef [unique] IBindCtx *LPBC;
299 typedef struct tagBIND_OPTS {
300 DWORD cbStruct;
301 DWORD grfFlags;
302 DWORD grfMode;
303 DWORD dwTickCountDeadline;
304 } BIND_OPTS, *LPBIND_OPTS;
306 /* FIXME: C++ crap */
307 typedef struct tagBIND_OPTS2 {
308 DWORD cbStruct;
309 DWORD grfFlags;
310 DWORD grfMode;
311 DWORD dwTickCountDeadline;
312 DWORD dwTrackFlags;
313 DWORD dwClassContext;
314 LCID locale;
315 COSERVERINFO *pServerInfo;
316 } BIND_OPTS2, *LPBIND_OPTS2;
318 typedef enum tagBIND_FLAGS {
319 BIND_MAYBOTHERUSER = 1,
320 BIND_JUSTTESTEXISTENCE = 2
321 } BIND_FLAGS;
323 HRESULT RegisterObjectBound(
324 [in, unique] IUnknown *punk);
326 HRESULT RevokeObjectBound(
327 [in, unique] IUnknown *punk);
329 HRESULT ReleaseBoundObjects();
331 [local]
332 HRESULT SetBindOptions(
333 [in] BIND_OPTS *pbindopts);
335 [call_as(SetBindOptions)]
336 HRESULT RemoteSetBindOptions(
337 [in] BIND_OPTS2 *pbindopts);
339 [local]
340 HRESULT GetBindOptions(
341 [in, out] BIND_OPTS *pbindopts);
343 [call_as(GetBindOptions)]
344 HRESULT RemoteGetBindOptions(
345 [in, out] BIND_OPTS2 *pbindopts);
347 HRESULT GetRunningObjectTable(
348 [out] IRunningObjectTable **pprot);
350 HRESULT RegisterObjectParam(
351 [in] LPOLESTR pszKey,
352 [in, unique] IUnknown *punk);
354 HRESULT GetObjectParam(
355 [in] LPOLESTR pszKey,
356 [out] IUnknown **ppunk);
358 HRESULT EnumObjectParam(
359 [out] IEnumString **ppenum);
361 HRESULT RevokeObjectParam(
362 [in] LPOLESTR pszKey);
366 object,
367 uuid(00000102-0000-0000-C000-000000000046),
368 pointer_default(unique)
370 interface IEnumMoniker : IUnknown
372 typedef [unique] IEnumMoniker *LPENUMMONIKER;
374 [local]
375 HRESULT Next(
376 [in] ULONG celt,
377 [out, size_is(celt), length_is(*pceltFetched)]
378 IMoniker **rgelt,
379 [out] ULONG *pceltFetched);
381 [call_as(Next)]
382 HRESULT RemoteNext(
383 [in] ULONG celt,
384 [out, size_is(celt), length_is(*pceltFetched)]
385 IMoniker **rgelt,
386 [out] ULONG *pceltFetched);
388 HRESULT Skip(
389 [in] ULONG celt);
391 HRESULT Reset();
393 HRESULT Clone(
394 [out] IEnumMoniker **ppenum);
398 object,
399 uuid(00000126-0000-0000-C000-000000000046)
401 interface IRunnableObject : IUnknown
403 typedef [unique] IRunnableObject *LPRUNNABLEOBJECT;
405 HRESULT GetRunningClass(
406 [out] LPCLSID lpClsid);
408 HRESULT Run(
409 [in] LPBINDCTX pbc);
411 [local]
412 BOOL IsRunning();
414 [call_as(IsRunning)]
415 HRESULT RemoteIsRunning();
417 HRESULT LockRunning(
418 [in] BOOL fLock,
419 [in] BOOL fLastUnlockCloses);
421 HRESULT SetContainedObject(
422 [in] BOOL fContained);
425 /* GetObject is defined in wingdi.h as WINELIB_NAME_AW(GetObject),
426 * which resolves to a compilation failure if __WINESRC__ is defined,
427 * but GetObject is used as a valid method name below, so we have
428 * to undefine it if __WINESRC__ is defined */
429 cpp_quote("#ifdef __WINESRC__")
430 cpp_quote("#undef GetObject")
431 cpp_quote("#endif")
434 object,
435 uuid(00000010-0000-0000-C000-000000000046)
437 interface IRunningObjectTable : IUnknown
439 typedef [unique] IRunningObjectTable *LPRUNNINGOBJECTTABLE;
441 HRESULT Register(
442 [in] DWORD grfFlags,
443 [in, unique] IUnknown *punkObject,
444 [in, unique] IMoniker *pmkObjectName,
445 [out] DWORD *pdwRegister);
447 HRESULT Revoke(
448 [in] DWORD dwRegister);
450 HRESULT IsRunning(
451 [in, unique] IMoniker *pmkObjectName);
453 HRESULT GetObject(
454 [in, unique] IMoniker *pmkObjectName,
455 [out] IUnknown **ppunkObject);
457 HRESULT NoteChangeTime(
458 [in] DWORD dwRegister,
459 [in] FILETIME *pfiletime);
461 HRESULT GetTimeOfLastChange(
462 [in, unique] IMoniker *pmkObjectName,
463 [out] FILETIME *pfiletime);
465 HRESULT EnumRunning(
466 [out] IEnumMoniker **ppenumMoniker);
470 object,
471 uuid(0000010c-0000-0000-C000-000000000046)
473 interface IPersist : IUnknown
475 typedef [unique] IPersist *LPPERSIST;
477 HRESULT GetClassID(
478 [out] CLSID *pClassID);
482 object,
483 uuid(00000109-0000-0000-C000-000000000046),
484 pointer_default(unique)
486 interface IPersistStream : IPersist
488 typedef [unique] IPersistStream *LPPERSISTSTREAM;
490 HRESULT IsDirty();
492 HRESULT Load(
493 [in, unique] IStream *pStm);
495 HRESULT Save(
496 [in, unique] IStream *pStm,
497 [in] BOOL fClearDirty);
499 HRESULT GetSizeMax(
500 [out] ULARGE_INTEGER *pcbSize);
504 object,
505 uuid(0000000f-0000-0000-C000-000000000046),
506 pointer_default(unique)
508 interface IMoniker : IPersistStream
510 typedef [unique] IMoniker *LPMONIKER;
512 typedef enum tagMKSYS {
513 MKSYS_NONE = 0,
514 MKSYS_GENERICCOMPOSITE = 1,
515 MKSYS_FILEMONIKER = 2,
516 MKSYS_ANTIMONIKER = 3,
517 MKSYS_ITEMMONIKER = 4,
518 MKSYS_POINTERMONIKER = 5,
519 /* MKSYS_URLMONIKER = 6, */ /* defined in urlmon.idl */
520 MKSYS_CLASSMONIKER = 7
521 } MKSYS;
523 typedef [v1_enum] enum tagMKREDUCE {
524 MKRREDUCE_ONE = 3 << 16,
525 MKRREDUCE_TOUSER = 2 << 16,
526 MKRREDUCE_THROUGHUSER = 1 << 16,
527 MKRREDUCE_ALL = 0
528 } MKRREDUCE;
530 [local]
531 HRESULT BindToObject(
532 [in, unique] IBindCtx *pbc,
533 [in, unique] IMoniker *pmkToLeft,
534 [in] REFIID riidResult,
535 [out, iid_is(riidResult)] void **ppvResult);
537 [call_as(BindToObject)]
538 HRESULT RemoteBindToObject(
539 [in, unique] IBindCtx *pbc,
540 [in, unique] IMoniker *pmkToLeft,
541 [in] REFIID riidResult,
542 [out, iid_is(riidResult)] IUnknown **ppvResult);
544 [local]
545 HRESULT BindToStorage(
546 [in, unique] IBindCtx *pbc,
547 [in, unique] IMoniker *pmkToLeft,
548 [in] REFIID riid,
549 [out, iid_is(riid)] void **ppvObj);
551 [call_as(BindToStorage)]
552 HRESULT RemoteBindToStorage(
553 [in, unique] IBindCtx *pbc,
554 [in, unique] IMoniker *pmkToLeft,
555 [in] REFIID riid,
556 [out, iid_is(riid)] IUnknown **ppvObj);
558 HRESULT Reduce(
559 [in, unique] IBindCtx *pbc,
560 [in] DWORD dwReduceHowFar,
561 [in, out, unique] IMoniker **ppmkToLeft,
562 [out] IMoniker **ppmkReduced);
564 HRESULT ComposeWith(
565 [in, unique] IMoniker *pmkRight,
566 [in] BOOL fOnlyIfNotGeneric,
567 [out] IMoniker **ppmkComposite);
569 HRESULT Enum(
570 [in] BOOL fForward,
571 [out] IEnumMoniker **ppenumMoniker);
573 HRESULT IsEqual(
574 [in, unique] IMoniker *pmkOtherMoniker);
576 HRESULT Hash(
577 [out] DWORD *pdwHash);
579 HRESULT IsRunning(
580 [in, unique] IBindCtx *pbc,
581 [in, unique] IMoniker *pmkToLeft,
582 [in, unique] IMoniker *pmkNewlyRunning);
584 HRESULT GetTimeOfLastChange(
585 [in, unique] IBindCtx *pbc,
586 [in, unique] IMoniker *pmkToLeft,
587 [out] FILETIME *pFileTime);
589 HRESULT Inverse(
590 [out] IMoniker **ppmk);
592 HRESULT CommonPrefixWith(
593 [in, unique] IMoniker *pmkOther,
594 [out] IMoniker **ppmkPrefix);
596 HRESULT RelativePathTo(
597 [in, unique] IMoniker *pmkOther,
598 [out] IMoniker **ppmkRelPath);
600 HRESULT GetDisplayName(
601 [in, unique] IBindCtx *pbc,
602 [in, unique] IMoniker *pmkToLeft,
603 [out] LPOLESTR *ppszDisplayName);
605 HRESULT ParseDisplayName(
606 [in, unique] IBindCtx *pbc,
607 [in, unique] IMoniker *pmkToLeft,
608 [in] LPOLESTR pszDisplayName,
609 [out] ULONG *pchEaten,
610 [out] IMoniker **ppmkOut);
612 HRESULT IsSystemMoniker(
613 [out] DWORD *pdwMksys);
617 object,
618 uuid(f29f6bc0-5021-11ce-aa15-00006901293f),
619 pointer_default(unique)
621 interface IROTData : IUnknown
623 HRESULT GetComparisonData(
624 [out, size_is(cbMax)] byte *pbData,
625 [in] ULONG cbMax,
626 [out] ULONG *pcbData);
630 object,
631 uuid(00000101-0000-0000-C000-000000000046),
632 pointer_default(unique)
634 interface IEnumString : IUnknown
636 typedef [unique] IEnumString *LPENUMSTRING;
638 [local]
639 HRESULT Next(
640 [in] ULONG celt,
641 [out, size_is(celt), length_is(*pceltFetched)]
642 LPOLESTR *rgelt,
643 [out] ULONG *pceltFetched);
645 [call_as(Next)]
646 HRESULT RemoteNext(
647 [in] ULONG celt,
648 [out, size_is(celt), length_is(*pceltFetched)]
649 LPOLESTR *rgelt,
650 [out] ULONG *pceltFetched);
652 HRESULT Skip(
653 [in] ULONG celt);
655 HRESULT Reset();
657 HRESULT Clone(
658 [out] IEnumString **ppenum);
662 object,
663 uuid(00000140-0000-0000-C000-000000000046)
665 interface IClassActivator : IUnknown
667 HRESULT GetClassObject(
668 [in] REFCLSID rclsid,
669 [in] DWORD dwClassContext,
670 [in] LCID locale,
671 [in] REFIID riid,
672 [out, iid_is(riid)] void **ppv);
675 /******************** Storage ********************/
678 object,
679 uuid(0c733a30-2a1c-11ce-ade5-00aa0044773d),
680 pointer_default(unique)
682 interface ISequentialStream : IUnknown
684 [local]
685 HRESULT Read(
686 [out, size_is(cb), length_is(*pcbRead)]
687 void *pv,
688 [in] ULONG cb,
689 [out] ULONG *pcbRead);
691 [call_as(Read)]
692 HRESULT RemoteRead(
693 [out, size_is(cb), length_is(*pcbRead)]
694 byte *pv,
695 [in] ULONG cb,
696 [out] ULONG *pcbRead);
698 [local]
699 HRESULT Write(
700 [in, size_is(cb)] const void *pv,
701 [in] ULONG cb,
702 [out] ULONG *pcbWritten);
704 [call_as(Write)]
705 HRESULT RemoteWrite(
706 [in, size_is(cb)] const byte *pv,
707 [in] ULONG cb,
708 [out] ULONG *pcbWritten);
712 object,
713 uuid(0000000c-0000-0000-C000-000000000046),
714 pointer_default(unique)
716 interface IStream : ISequentialStream
718 typedef [unique] IStream *LPSTREAM;
720 typedef struct tagSTATSTG {
721 LPOLESTR pwcsName;
722 DWORD type;
723 ULARGE_INTEGER cbSize;
724 FILETIME mtime;
725 FILETIME ctime;
726 FILETIME atime;
727 DWORD grfMode;
728 DWORD grfLocksSupported;
729 CLSID clsid;
730 DWORD grfStateBits;
731 DWORD reserved;
732 } STATSTG;
734 typedef enum tagSTGTY {
735 STGTY_STORAGE = 1,
736 STGTY_STREAM = 2,
737 STGTY_LOCKBYTES = 3,
738 STGTY_PROPERTY = 4
739 } STGTY;
741 typedef enum tagSTREAM_SEEK {
742 STREAM_SEEK_SET = 0,
743 STREAM_SEEK_CUR = 1,
744 STREAM_SEEK_END = 2
745 } STREAM_SEEK;
747 /* these are defined in Linux's fcntl.h,
748 * undefine them to avoid conflicts */
749 cpp_quote("#undef LOCK_MAND")
750 cpp_quote("#undef LOCK_READ")
751 cpp_quote("#undef LOCK_WRITE")
752 cpp_quote("#undef LOCK_RW")
754 typedef enum tagLOCKTYPE {
755 LOCK_WRITE = 1,
756 LOCK_EXCLUSIVE = 2,
757 LOCK_ONLYONCE = 4
758 } LOCKTYPE;
760 [local]
761 HRESULT Seek(
762 [in] LARGE_INTEGER dlibMove,
763 [in] DWORD dwOrigin,
764 [out] ULARGE_INTEGER *plibNewPosition);
766 [call_as(Seek)]
767 HRESULT RemoteSeek(
768 [in] LARGE_INTEGER dlibMove,
769 [in] DWORD dwOrigin,
770 [out] ULARGE_INTEGER *plibNewPosition);
772 HRESULT SetSize(
773 [in] ULARGE_INTEGER libNewSize);
775 [local]
776 HRESULT CopyTo(
777 [in, unique] IStream *pstm,
778 [in] ULARGE_INTEGER cb,
779 [out] ULARGE_INTEGER *pcbRead,
780 [out] ULARGE_INTEGER *pcbWritten);
782 [call_as(CopyTo)]
783 HRESULT RemoteCopyTo(
784 [in, unique] IStream *pstm,
785 [in] ULARGE_INTEGER cb,
786 [out] ULARGE_INTEGER *pcbRead,
787 [out] ULARGE_INTEGER *pcbWritten);
789 HRESULT Commit(
790 [in] DWORD grfCommitFlags);
792 HRESULT Revert();
794 HRESULT LockRegion(
795 [in] ULARGE_INTEGER libOffset,
796 [in] ULARGE_INTEGER cb,
797 [in] DWORD dwLockType);
799 HRESULT UnlockRegion(
800 [in] ULARGE_INTEGER libOffset,
801 [in] ULARGE_INTEGER cb,
802 [in] DWORD dwLockType);
804 HRESULT Stat(
805 [out] STATSTG *pstatstg,
806 [in] DWORD grfStatFlag);
808 HRESULT Clone(
809 [out] IStream **ppstm);
813 object,
814 uuid(0000000d-0000-0000-C000-000000000046),
815 pointer_default(unique)
817 interface IEnumSTATSTG : IUnknown
819 typedef [unique] IEnumSTATSTG *LPENUMSTATSTG;
821 [local]
822 HRESULT Next(
823 [in] ULONG celt,
824 [out, size_is(celt), length_is(*pceltFetched)]
825 STATSTG *rgelt,
826 [out] ULONG *pceltFetched);
828 [call_as(Next)]
829 HRESULT RemoteNext(
830 [in] ULONG celt,
831 [out, size_is(celt), length_is(*pceltFetched)]
832 STATSTG *rgelt,
833 [out] ULONG *pceltFetched);
835 HRESULT Skip(
836 [in] ULONG celt);
838 HRESULT Reset();
840 HRESULT Clone(
841 [out] IEnumSTATSTG **ppenum);
845 object,
846 uuid(0000000b-0000-0000-C000-000000000046),
847 pointer_default(unique)
849 interface IStorage : IUnknown
851 typedef [unique] IStorage *LPSTORAGE;
853 typedef struct tagRemSNB {
854 unsigned long ulCntStr;
855 unsigned long ulCntChar;
856 [size_is(ulCntChar)] OLECHAR rgString[];
857 } RemSNB;
859 typedef [unique] RemSNB *wireSNB;
860 typedef [wire_marshal(wireSNB)] OLECHAR **SNB;
862 HRESULT CreateStream(
863 [in] LPCOLESTR pwcsName,
864 [in] DWORD grfMode,
865 [in] DWORD reserved1,
866 [in] DWORD reserved2,
867 [out] IStream **ppstm);
869 [local]
870 HRESULT OpenStream(
871 [in] LPCOLESTR pwcsName,
872 [in, unique] void *reserved1,
873 [in] DWORD grfMode,
874 [in] DWORD reserved2,
875 [out] IStream **ppstm);
877 [call_as(OpenStream)]
878 HRESULT RemoteOpenStream(
879 [in] LPCOLESTR pwcsName,
880 [in] unsigned long cbReserved1,
881 [in, unique, size_is(cbReserved1)] byte *reserved1,
882 [in] DWORD grfMode,
883 [in] DWORD reserved2,
884 [out] IStream **ppstm);
886 HRESULT CreateStorage(
887 [in] LPCOLESTR pwcsName,
888 [in] DWORD grfMode,
889 [in] DWORD dwStgFmt,
890 [in] DWORD reserved2,
891 [out] IStorage **ppstg);
893 HRESULT OpenStorage(
894 [in, unique] LPCOLESTR pwcsName,
895 [in, unique] IStorage *pstgPriority,
896 [in] DWORD grfMode,
897 [in, unique] SNB snbExclude,
898 [in] DWORD reserved,
899 [out] IStorage **ppstg);
901 HRESULT CopyTo(
902 [in] DWORD ciidExclude,
903 [in, unique, size_is(ciidExclude)] const IID *rgiidExclude,
904 [in, unique] SNB snbExclude,
905 [in, unique] IStorage *pstgDest);
907 HRESULT MoveElementTo(
908 [in] LPCOLESTR pwcsName,
909 [in, unique] IStorage *pstgDest,
910 [in] LPCOLESTR pwcsNewName,
911 [in] DWORD grfFlags);
913 HRESULT Commit(
914 [in] DWORD grfCommitFlags);
916 HRESULT Revert();
918 [local]
919 HRESULT EnumElements(
920 [in] DWORD reserved1,
921 [in, unique, size_is(1)] void *reserved2,
922 [in] DWORD reserved3,
923 [out] IEnumSTATSTG **ppenum);
925 [call_as(EnumElements)]
926 HRESULT RemoteEnumElements(
927 [in] DWORD reserved1,
928 [in] unsigned long cbReserved2,
929 [in, unique, size_is(cbReserved2)] byte *reserved2,
930 [in] DWORD reserved3,
931 [out] IEnumSTATSTG **ppenum);
933 HRESULT DestroyElement(
934 [in] LPCOLESTR pwcsName);
936 HRESULT RenameElement(
937 [in] LPCOLESTR pwcsOldName,
938 [in] LPCOLESTR pwcsNewName);
940 HRESULT SetElementTimes(
941 [in, unique] LPCOLESTR pwcsName,
942 [in, unique] const FILETIME *pctime,
943 [in, unique] const FILETIME *patime,
944 [in, unique] const FILETIME *pmtime);
946 HRESULT SetClass(
947 [in] REFCLSID clsid);
949 HRESULT SetStateBits(
950 [in] DWORD grfStateBits,
951 [in] DWORD grfMask);
953 HRESULT Stat(
954 [out] STATSTG *pstatstg,
955 [in] DWORD grfStatFlag);
959 object,
960 uuid(0000010b-0000-0000-C000-000000000046),
961 pointer_default(unique)
963 interface IPersistFile : IPersist
965 typedef [unique] IPersistFile *LPPERSISTFILE;
967 HRESULT IsDirty();
969 HRESULT Load(
970 [in] LPCOLESTR pszFileName,
971 [in] DWORD dwMode);
973 HRESULT Save(
974 [in, unique] LPCOLESTR pszFileName,
975 [in] BOOL fRemember);
977 HRESULT SaveCompleted(
978 [in, unique] LPCOLESTR pszFileName);
980 HRESULT GetCurFile(
981 [out] LPOLESTR *ppszFileName);
985 object,
986 uuid(0000010a-0000-0000-C000-000000000046),
987 pointer_default(unique)
989 interface IPersistStorage : IPersist
991 typedef [unique] IPersistStorage *LPPERSISTSTORAGE;
993 HRESULT IsDirty();
995 HRESULT InitNew(
996 [in, unique] IStorage *pStg);
998 HRESULT Load(
999 [in, unique] IStorage *pStg);
1001 HRESULT Save(
1002 [in, unique] IStorage *pStgSave,
1003 [in] BOOL fSameAsLoad);
1005 HRESULT SaveCompleted(
1006 [in, unique] IStorage *pStgNew);
1008 HRESULT HandsOffStorage();
1012 object,
1013 uuid(00000012-0000-0000-C000-000000000046),
1014 pointer_default(unique)
1016 interface IRootStorage : IUnknown
1018 typedef [unique] IRootStorage *LPROOTSTORAGE;
1020 HRESULT SwitchToFile(
1021 [in] LPOLESTR pszFile);
1025 object,
1026 uuid(0000000a-0000-0000-C000-000000000046),
1027 pointer_default(unique)
1029 interface ILockBytes : IUnknown
1031 typedef [unique] ILockBytes *LPLOCKBYTES;
1033 [local]
1034 HRESULT ReadAt(
1035 [in] ULARGE_INTEGER ulOffset,
1036 [out, size_is(cb), length_is(*pcbRead)]
1037 void *pv,
1038 [in] ULONG cb,
1039 [out] ULONG *pcbRead);
1041 [call_as(ReadAt)]
1042 HRESULT RemoteReadAt(
1043 [in] ULARGE_INTEGER ulOffset,
1044 [out, size_is(cb), length_is(*pcbRead)]
1045 byte *pv,
1046 [in] ULONG cb,
1047 [out] ULONG *pcbRead);
1049 [local]
1050 HRESULT WriteAt(
1051 [in] ULARGE_INTEGER ulOffset,
1052 [in, size_is(cb)] const void *pv,
1053 [in] ULONG cb,
1054 [out] ULONG *pcbWritten);
1056 [call_as(WriteAt)]
1057 HRESULT RemoteWriteAt(
1058 [in] ULARGE_INTEGER ulOffset,
1059 [in, size_is(cb)] const byte *pv,
1060 [in] ULONG cb,
1061 [out] ULONG *pcbWritten);
1063 HRESULT Flush();
1065 HRESULT SetSize(
1066 [in] ULARGE_INTEGER cb);
1068 HRESULT LockRegion(
1069 [in] ULARGE_INTEGER libOffset,
1070 [in] ULARGE_INTEGER cb,
1071 [in] DWORD dwLockType);
1073 HRESULT UnlockRegion(
1074 [in] ULARGE_INTEGER libOffset,
1075 [in] ULARGE_INTEGER cb,
1076 [in] DWORD dwLockType);
1078 HRESULT Stat(
1079 [out] STATSTG *pstatstg,
1080 [in] DWORD grfStatFlag);
1084 object,
1085 uuid(99caf010-415e-11cf-8814-00aa00b569f5),
1086 pointer_default(unique)
1088 interface IFillLockBytes : IUnknown
1090 [local]
1091 HRESULT FillAppend(
1092 [in, size_is(cb)] const void *pv,
1093 [in] ULONG cb,
1094 [out] ULONG *pcbWritten);
1096 [call_as(FillAppend)]
1097 HRESULT RemoteFillAppend(
1098 [in, size_is(cb)] const byte *pv,
1099 [in] ULONG cb,
1100 [out] ULONG *pcbWritten);
1102 [local]
1103 HRESULT FillAt(
1104 [in] ULARGE_INTEGER ulOffset,
1105 [in, size_is(cb)] const void *pv,
1106 [in] ULONG cb,
1107 [out] ULONG *pcbWritten);
1109 [call_as(FillAt)]
1110 HRESULT RemoteFillAt(
1111 [in] ULARGE_INTEGER ulOffset,
1112 [in, size_is(cb)] const byte *pv,
1113 [in] ULONG cb,
1114 [out] ULONG *pcbWritten);
1116 HRESULT SetFillSize(
1117 [in] ULARGE_INTEGER ulSize);
1119 HRESULT Terminate(
1120 [in] BOOL bCanceled);
1124 object,
1125 uuid(a9d758a0-4617-11cf-95fc-00aa00680db4),
1126 pointer_default(unique)
1128 interface IProgressNotify : IUnknown
1130 HRESULT OnProgress(
1131 [in] DWORD dwProgressCurrent,
1132 [in] DWORD dwProgressMaximum,
1133 [in] BOOL fAccurate,
1134 [in] BOOL fOwner);
1138 local,
1139 object,
1140 uuid(0e6d4d90-6738-11cf-9608-00aa00680db4),
1141 pointer_default(unique)
1143 interface ILayoutStorage : IUnknown
1145 typedef struct tagStorageLayout {
1146 DWORD LayoutType;
1147 OLECHAR *pwcsElementName;
1148 LARGE_INTEGER cOffset;
1149 LARGE_INTEGER cBytes;
1150 } StorageLayout;
1152 HRESULT LayoutScript(
1153 [in] StorageLayout *pStorageLayout,
1154 [in] DWORD nEntries,
1155 [in] DWORD glfInterleavedFlag);
1157 HRESULT BeginMonitor();
1159 HRESULT EndMonitor();
1161 HRESULT ReLayoutDocfile(
1162 [in] OLECHAR *pwcsNewDfName);
1164 HRESULT ReLayoutDocfileOnILockBytes(
1165 [in] ILockBytes *pILockBytes);
1168 /******************** Data Object ********************/
1171 object,
1172 uuid(00000103-0000-0000-C000-000000000046),
1173 pointer_default(unique)
1175 interface IEnumFORMATETC : IUnknown
1177 typedef [unique] IEnumFORMATETC *LPENUMFORMATETC;
1179 typedef struct tagDVTARGETDEVICE {
1180 DWORD tdSize;
1181 WORD tdDriverNameOffset;
1182 WORD tdDeviceNameOffset;
1183 WORD tdPortNameOffset;
1184 WORD tdExtDevmodeOffset;
1185 [size_is(tdSize - sizeof(DWORD) - 4*sizeof(WORD))]
1186 BYTE tdData[];
1187 } DVTARGETDEVICE;
1189 typedef CLIPFORMAT *LPCLIPFORMAT;
1191 typedef struct tagFORMATETC {
1192 CLIPFORMAT cfFormat;
1193 [unique] DVTARGETDEVICE *ptd;
1194 DWORD dwAspect;
1195 LONG lindex;
1196 DWORD tymed;
1197 } FORMATETC, *LPFORMATETC;
1199 [local]
1200 HRESULT Next(
1201 [in] ULONG celt,
1202 [out, size_is(celt), length_is(*pceltFetched)]
1203 FORMATETC *rgelt,
1204 [out] ULONG *pceltFetched);
1206 [call_as(Next)]
1207 HRESULT RemoteNext(
1208 [in] ULONG celt,
1209 [out, size_is(celt), length_is(*pceltFetched)]
1210 FORMATETC *rgelt,
1211 [out] ULONG *pceltFetched);
1213 HRESULT Skip(
1214 [in] ULONG celt);
1216 HRESULT Reset();
1218 HRESULT Clone(
1219 [out] IEnumFORMATETC **ppenum);
1223 object,
1224 uuid(00000105-0000-0000-C000-000000000046),
1225 pointer_default(unique)
1227 interface IEnumSTATDATA : IUnknown
1229 typedef [unique] IEnumSTATDATA *LPENUMSTATDATA;
1231 typedef enum tagADVF {
1232 ADVF_NODATA = 1,
1233 ADVF_PRIMEFIRST = 2,
1234 ADVF_ONLYONCE = 4,
1235 ADVF_DATAONSTOP = 64,
1236 ADVFCACHE_NOHANDLER = 8,
1237 ADVFCACHE_FORCEBUILTIN = 16,
1238 ADVFCACHE_ONSAVE = 32
1239 } ADVF;
1241 typedef struct tagSTATDATA
1243 FORMATETC formatetc;
1244 DWORD advf;
1245 [unique] IAdviseSink *pAdvSink;
1246 DWORD dwConnection;
1247 } STATDATA, *LPSTATDATA;
1249 [local]
1250 HRESULT Next(
1251 [in] ULONG celt,
1252 [out, size_is(celt), length_is(*pceltFetched)]
1253 STATDATA *rgelt,
1254 [out] ULONG *pceltFetched);
1256 [call_as(Next)]
1257 HRESULT RemoteNext(
1258 [in] ULONG celt,
1259 [out, size_is(celt), length_is(*pceltFetched)]
1260 STATDATA *rgelt,
1261 [out] ULONG *pceltFetched);
1263 HRESULT Skip(
1264 [in] ULONG celt);
1266 HRESULT Reset();
1268 HRESULT Clone(
1269 [out] IEnumSTATDATA **ppenum);
1273 object,
1274 uuid(0000010f-0000-0000-C000-000000000046),
1275 pointer_default(unique)
1277 interface IAdviseSink : IUnknown
1279 typedef IAdviseSink *LPADVISESINK;
1281 typedef [v1_enum] enum tagTYMED {
1282 TYMED_HGLOBAL = 1,
1283 TYMED_FILE = 2,
1284 TYMED_ISTREAM = 4,
1285 TYMED_ISTORAGE = 8,
1286 TYMED_GDI = 16,
1287 TYMED_MFPICT = 32,
1288 TYMED_ENHMF = 64,
1289 TYMED_NULL = 0
1290 } TYMED;
1292 typedef struct tagRemSTGMEDIUM {
1293 DWORD tymed;
1294 DWORD dwHandleType;
1295 unsigned long pData;
1296 unsigned long pUnkForRelease;
1297 unsigned long cbData;
1298 [size_is(cbData)] byte data[];
1299 } RemSTGMEDIUM;
1301 /* FIXME: C/C++ nameless union version */
1302 typedef struct tagSTGMEDIUM {
1303 DWORD tymed;
1304 [switch_is(tymed)] union {
1305 [case(TYMED_GDI)] HBITMAP hBitmap;
1306 [case(TYMED_MFPICT)] HMETAFILEPICT hMetaFilePict;
1307 [case(TYMED_ENHMF)] HENHMETAFILE hEnhMetaFile;
1308 [case(TYMED_HGLOBAL)] HGLOBAL hGlobal;
1309 [case(TYMED_FILE)] LPOLESTR lpszFileName;
1310 [case(TYMED_ISTREAM)] IStream *pstm;
1311 [case(TYMED_ISTORAGE)] IStorage *pstg;
1312 [default] ;
1314 [unique] IUnknown *pUnkForRelease;
1315 } uSTGMEDIUM;
1317 /* copied from wingdi.h */
1318 #define OBJ_PEN 1
1319 #define OBJ_BRUSH 2
1320 #define OBJ_DC 3
1321 #define OBJ_METADC 4
1322 #define OBJ_PAL 5
1323 #define OBJ_FONT 6
1324 #define OBJ_BITMAP 7
1325 #define OBJ_REGION 8
1326 #define OBJ_METAFILE 9
1327 #define OBJ_MEMDC 10
1328 #define OBJ_EXTPEN 11
1329 #define OBJ_ENHMETADC 12
1330 #define OBJ_ENHMETAFILE 13
1332 typedef union _GDI_OBJECT switch(DWORD ObjectType) u {
1333 case OBJ_BITMAP: wireHBITMAP hBitmap;
1334 case OBJ_PAL: wireHPALETTE hPalette;
1335 default: wireHGLOBAL hGeneric;
1336 } GDI_OBJECT;
1338 typedef struct _userSTGMEDIUM {
1339 union switch(DWORD tymed) u {
1340 case TYMED_NULL: ;
1341 case TYMED_MFPICT: wireHMETAFILEPICT hMetaFilePict;
1342 case TYMED_ENHMF: wireHENHMETAFILE hHEnhMetaFile;
1343 case TYMED_GDI: GDI_OBJECT *hGdiHandle;
1344 case TYMED_HGLOBAL: wireHGLOBAL hGlobal;
1345 case TYMED_FILE: LPOLESTR lpszFileName;
1346 case TYMED_ISTREAM: BYTE_BLOB *pstm;
1347 case TYMED_ISTORAGE: BYTE_BLOB *pstg;
1349 IUnknown *pUnkForRelease;
1350 } userSTGMEDIUM;
1352 typedef [unique] userSTGMEDIUM *wireSTGMEDIUM;
1353 typedef [wire_marshal(wireSTGMEDIUM)] uSTGMEDIUM STGMEDIUM;
1355 typedef [unique] userSTGMEDIUM *wireASYNC_STGMEDIUM;
1356 typedef [wire_marshal(wireASYNC_STGMEDIUM)] STGMEDIUM ASYNC_STGMEDIUM;
1358 typedef STGMEDIUM *LPSTGMEDIUM;
1360 typedef struct _userFLAG_STGMEDIUM {
1361 long ContextFlags;
1362 long fPassOwnership;
1363 userSTGMEDIUM Stgmed;
1364 } userFLAG_STGMEDIUM;
1366 typedef [unique] userFLAG_STGMEDIUM *wireFLAG_STGMEDIUM;
1368 typedef [wire_marshal(wireFLAG_STGMEDIUM)] struct _FLAG_STGMEDIUM {
1369 long ContextFlags;
1370 long fPassOwnership;
1371 STGMEDIUM Stgmed;
1372 } FLAG_STGMEDIUM;
1374 [local]
1375 void OnDataChange(
1376 [in, unique] FORMATETC *pFormatetc,
1377 [in, unique] STGMEDIUM *pStgmed);
1379 [call_as(OnDataChange), async]
1380 HRESULT RemoteOnDataChange(
1381 [in] IAsyncManager **ppIAM,
1382 [in, unique] FORMATETC *pFormatetc,
1383 [in, unique] ASYNC_STGMEDIUM *pStgmed);
1385 [local]
1386 void OnViewChange(
1387 [in] DWORD dwAspect,
1388 [in] LONG lindex);
1390 [call_as(OnViewChange), async]
1391 HRESULT RemoteOnViewChange(
1392 [in] IAsyncManager **ppIAM,
1393 [in] DWORD dwAspect,
1394 [in] LONG lindex);
1396 [local]
1397 void OnRename(
1398 [in] IMoniker *pmk);
1400 [call_as(OnRename), async]
1401 HRESULT RemoteOnRename(
1402 [in] IAsyncManager **ppIAM,
1403 [in] IMoniker *pmk);
1405 [local]
1406 void OnSave();
1408 [call_as(OnSave), async]
1409 HRESULT RemoteOnSave(
1410 [in] IAsyncManager **ppIAM);
1412 [local]
1413 void OnClose();
1415 [call_as(OnClose)]
1416 HRESULT RemoteOnClose();
1420 object,
1421 uuid(00000125-0000-0000-C000-000000000046),
1422 pointer_default(unique)
1424 interface IAdviseSink2 : IAdviseSink
1426 typedef [unique] IAdviseSink2 *LPADVISESINK2;
1428 [local]
1429 void OnLinkSrcChange(
1430 [in, unique] IMoniker *pmk);
1432 [call_as(OnLinkSrcChange), async]
1433 HRESULT RemoteOnLinkSrcChange(
1434 [in] IAsyncManager **ppIAM,
1435 [in, unique] IMoniker *pmk);
1439 object,
1440 uuid(0000010e-0000-0000-C000-000000000046),
1441 pointer_default(unique)
1443 interface IDataObject : IUnknown
1445 typedef [unique] IDataObject *LPDATAOBJECT;
1447 typedef enum tagDATADIR {
1448 DATADIR_GET = 1,
1449 DATADIR_SET = 2
1450 } DATADIR;
1452 [local]
1453 HRESULT GetData(
1454 [in, unique] FORMATETC *pformatetcIn,
1455 [out] STGMEDIUM *pmedium);
1457 [call_as(GetData)]
1458 HRESULT RemoteGetData(
1459 [in, unique] FORMATETC *pformatetcIn,
1460 [out] STGMEDIUM *pRemoteMedium);
1462 [local]
1463 HRESULT GetDataHere(
1464 [in, unique] FORMATETC *pformatetc,
1465 [in, out] STGMEDIUM *pmedium);
1467 [call_as(GetDataHere)]
1468 HRESULT RemoteGetDataHere(
1469 [in, unique] FORMATETC *pformatetc,
1470 [in, out] STGMEDIUM *pRemoteMedium);
1472 HRESULT QueryGetData(
1473 [in, unique] FORMATETC *pformatetc);
1475 HRESULT GetCanonicalFormatEtc(
1476 [in, unique] FORMATETC *pformatectIn,
1477 [out] FORMATETC *pformatetcOut);
1479 [local]
1480 HRESULT SetData(
1481 [in, unique] FORMATETC *pformatetc,
1482 [in, unique] STGMEDIUM *pmedium,
1483 [in] BOOL fRelease);
1485 [call_as(SetData)]
1486 HRESULT RemoteSetData(
1487 [in, unique] FORMATETC *pformatetc,
1488 [in, unique] FLAG_STGMEDIUM *pmedium,
1489 [in] BOOL fRelease);
1491 HRESULT EnumFormatEtc(
1492 [in] DWORD dwDirection,
1493 [out] IEnumFORMATETC **ppenumFormatEtc);
1495 HRESULT DAdvise(
1496 [in] FORMATETC *pformatetc,
1497 [in] DWORD advf,
1498 [in, unique] IAdviseSink *pAdvSink,
1499 [out] DWORD *pdwConnection);
1501 HRESULT DUnadvise(
1502 [in] DWORD dwConnection);
1504 HRESULT EnumDAdvise(
1505 [out] IEnumSTATDATA **ppenumAdvise);
1509 local,
1510 object,
1511 uuid(00000110-0000-0000-C000-000000000046)
1513 interface IDataAdviseHolder : IUnknown
1515 typedef [unique] IDataAdviseHolder *LPDATAADVISEHOLDER;
1517 HRESULT Advise(
1518 [in, unique] IDataObject *pDataObject,
1519 [in, unique] FORMATETC *pFetc,
1520 [in] DWORD advf,
1521 [in, unique] IAdviseSink *pAdvise,
1522 [out] DWORD *pdwConnection);
1524 HRESULT Unadvise(
1525 [in] DWORD dwConnection);
1527 HRESULT EnumAdvise(
1528 [out] IEnumSTATDATA **ppenumAdvise);
1530 HRESULT SendOnDataChange(
1531 [in, unique] IDataObject *pDataObject,
1532 [in] DWORD dwReserved,
1533 [in] DWORD advf);
1536 /******************** Remoting ********************/
1539 local,
1540 object,
1541 uuid(00000016-0000-0000-C000-000000000046)
1543 interface IMessageFilter : IUnknown
1545 typedef [unique] IMessageFilter *LPMESSAGEFILTER;
1547 typedef enum tagCALLTYPE {
1548 CALLTYPE_TOPLEVEL = 1,
1549 CALLTYPE_NESTED = 2,
1550 CALLTYPE_ASYNC = 3,
1551 CALLTYPE_TOPLEVEL_CALLPENDING = 4,
1552 CALLTYPE_ASYNC_CALLPENDING = 5
1553 } CALLTYPE;
1555 typedef enum tagSERVERCALL {
1556 SERVERCALL_ISHANDLED = 0,
1557 SERVERCALL_REJECTED = 1,
1558 SERVERCALL_RETRYLATER = 2
1559 } SERVERCALL;
1561 typedef enum tagPENDINGTYPE {
1562 PENDINGTYPE_TOPLEVEL = 1,
1563 PENDINGTYPE_NESTED = 2
1564 } PENDINGTYPE;
1566 typedef enum tagPENDINGMSG {
1567 PENDINGMSG_CANCELCALL = 0,
1568 PENDINGMSG_WAITNOPROCESS = 1,
1569 PENDINGMSG_WAITDEFPROCESS = 2
1570 } PENDINGMSG;
1572 typedef struct tagINTERFACEINFO {
1573 IUnknown *pUnk;
1574 IID iid;
1575 WORD wMethod;
1576 } INTERFACEINFO, *LPINTERFACEINFO;
1578 DWORD HandleInComingCall(
1579 [in] DWORD dwCallType,
1580 [in] HTASK htaskCaller,
1581 [in] DWORD dwTickCount,
1582 [in] LPINTERFACEINFO lpInterfaceInfo);
1584 DWORD RetryRejectedCall(
1585 [in] HTASK htaskCallee,
1586 [in] DWORD dwTickCount,
1587 [in] DWORD dwRejectType);
1589 DWORD MessagePending(
1590 [in] HTASK htaskCallee,
1591 [in] DWORD dwTickCount,
1592 [in] DWORD dwPendingType);
1596 local,
1597 object,
1598 uuid(D5F56B60-593B-101A-B569-08002B2DBF7A)
1600 interface IRpcChannelBuffer : IUnknown
1602 typedef [unique] IRpcChannelBuffer *LPRPCCHANNELBUFFER;
1604 typedef unsigned long RPCOLEDATAREP;
1606 typedef struct tagRPCOLEMESSAGE {
1607 void *reserved1;
1608 RPCOLEDATAREP dataRepresentation;
1609 void *Buffer;
1610 ULONG cbBuffer;
1611 ULONG iMethod;
1612 void *reserved2[5];
1613 ULONG rpcFlags;
1614 } RPCOLEMESSAGE;
1616 typedef RPCOLEMESSAGE *PRPCOLEMESSAGE;
1618 HRESULT GetBuffer(
1619 [in] RPCOLEMESSAGE *pMessage,
1620 [in] REFIID riid);
1622 HRESULT SendReceive(
1623 [in,out] RPCOLEMESSAGE *pMessage,
1624 [out] ULONG *pStatus);
1626 HRESULT FreeBuffer(
1627 [in] RPCOLEMESSAGE *pMessage);
1629 HRESULT GetDestCtx(
1630 [out] DWORD *pdwDestContext,
1631 [out] void **ppvDestContext);
1633 HRESULT IsConnected();
1637 local,
1638 object,
1639 uuid(594f31d0-7f19-11d0-b194-00a0c90dc8bf)
1641 interface IRpcChannelBuffer2 : IRpcChannelBuffer
1643 typedef [unique] IRpcChannelBuffer2 *LPRPCCHANNELBUFFER2;
1645 HRESULT GetProtocolVersion(
1646 [in,out] DWORD *pdwVersion);
1650 local,
1651 object,
1652 uuid(25B15600-0115-11d0-BF0D-00AA00B8DFD2)
1654 interface IRpcChannelBuffer3 : IRpcChannelBuffer2
1656 typedef [unique] IRpcChannelBuffer3 *LPRPCCHANNELBUFFER3;
1658 HRESULT Send(
1659 [in,out] RPCOLEMESSAGE *pMsg,
1660 [out] ULONG *pulStatus);
1662 HRESULT Receive(
1663 [in,out] RPCOLEMESSAGE *pMsg,
1664 [in] ULONG ulSize,
1665 [out] ULONG *pulStatus);
1667 HRESULT Cancel(
1668 [in] RPCOLEMESSAGE *pMsg);
1670 HRESULT GetCallContext(
1671 [in] RPCOLEMESSAGE *pMsg,
1672 [in] REFIID riid,
1673 [out] void **pInterface);
1675 HRESULT GetDestCtxEx(
1676 [in] RPCOLEMESSAGE *pMsg,
1677 [out] DWORD *pdwDestContext,
1678 [out] void **ppvDestContext);
1680 HRESULT GetState(
1681 [in] RPCOLEMESSAGE *pMsg,
1682 [out] DWORD *pState);
1684 HRESULT RegisterAsync(
1685 [in] RPCOLEMESSAGE *pMsg,
1686 [in] IAsyncManager *pAsyncMgr);
1690 local,
1691 object,
1692 uuid(D5F56A34-593B-101A-B569-08002B2DBF7A)
1694 interface IRpcProxyBuffer : IUnknown
1696 typedef [unique] IRpcProxyBuffer *LPRPCPROXYBUFFER;
1698 HRESULT Connect(
1699 [in, unique] IRpcChannelBuffer *pRpcChannelBuffer);
1701 void Disconnect();
1705 local,
1706 object,
1707 uuid(D5F56AFC-593B-101A-B569-08002B2DBF7A)
1709 interface IRpcStubBuffer : IUnknown
1711 typedef [unique] IRpcStubBuffer *LPRPCSTUBBUFFER;
1713 HRESULT Connect(
1714 [in] IUnknown *pUnkServer);
1716 void Disconnect();
1718 HRESULT Invoke(
1719 [in] RPCOLEMESSAGE *_prpcmsg,
1720 [in] IRpcChannelBuffer *_pRpcChannelBuffer);
1722 IRpcStubBuffer *IsIIDSupported(
1723 [in] REFIID riid);
1725 ULONG CountRefs();
1727 HRESULT DebugServerQueryInterface(
1728 void **ppv);
1730 void DebugServerRelease(
1731 void *pv);
1735 local,
1736 object,
1737 uuid(D5F569D0-593B-101A-B569-08002B2DBF7A)
1739 interface IPSFactoryBuffer : IUnknown
1741 typedef [unique] IPSFactoryBuffer *LPPSFACTORYBUFFER;
1743 HRESULT CreateProxy(
1744 [in] IUnknown *pUnkOuter,
1745 [in] REFIID riid,
1746 [out] IRpcProxyBuffer **ppProxy,
1747 [out] void **ppv);
1749 HRESULT CreateStub(
1750 [in] REFIID riid,
1751 [in, unique] IUnknown *pUnkServer,
1752 [out] IRpcStubBuffer **ppStub);
1756 local,
1757 object,
1758 uuid(1008c4a0-7613-11cf-9af1-0020af6e72f4)
1760 interface IChannelHook : IUnknown
1762 typedef [unique] IChannelHook *LPCHANNELHOOK;
1764 typedef struct SChannelHookCallInfo {
1765 IID iid;
1766 DWORD cbSize;
1767 GUID uCausality;
1768 DWORD dwServerPid;
1769 DWORD iMethod;
1770 void *pObject;
1771 } SChannelHookCallInfo;
1773 void ClientGetSize(
1774 [in] REFGUID uExtent,
1775 [in] REFIID riid,
1776 [out] ULONG *pDataSize);
1778 void ClientFillBuffer(
1779 [in] REFGUID uExtent,
1780 [in] REFIID riid,
1781 [in, out] ULONG *pDataSize,
1782 [in] void *pDataBuffer);
1784 void ClientNotify(
1785 [in] REFGUID uExtent,
1786 [in] REFIID riid,
1787 [in] ULONG cbDataSize,
1788 [in] void *pDataBuffer,
1789 [in] DWORD lDataRep,
1790 [in] HRESULT hrFault);
1792 void ServerNotify(
1793 [in] REFGUID uExtent,
1794 [in] REFIID riid,
1795 [in] ULONG cbDataSize,
1796 [in] void *pDataBuffer,
1797 [in] DWORD lDataRep);
1799 void ServerGetSize(
1800 [in] REFGUID uExtent,
1801 [in] REFIID riid,
1802 [in] HRESULT hrFault,
1803 [out] ULONG *pDataSize);
1805 void ServerFillBuffer(
1806 [in] REFGUID uExtent,
1807 [in] REFIID riid,
1808 [in, out] ULONG *pDataSize,
1809 [in] void *pDataBuffer,
1810 [in] HRESULT hrFault );
1813 /******************** Property Storage ********************/
1815 interface IEnumSTATPROPSTG;
1816 interface IEnumSTATPROPSETSTG;
1819 object,
1820 uuid(00000138-0000-0000-C000-000000000046),
1821 pointer_default(unique)
1823 interface IPropertyStorage : IUnknown
1825 typedef [unique] IPropertyStorage *LPPROPERTYSTORAGE;
1827 extern const FMTID FMTID_SummaryInformation;
1828 extern const FMTID FMTID_DocSummaryInformation;
1829 extern const FMTID FMTID_UserDefinedProperties;
1831 const DWORD PROPSETFLAG_DEFAULT = 0;
1832 const DWORD PROPSETFLAG_NONSIMPLE = 1;
1833 const DWORD PROPSETFLAG_ANSI = 2;
1834 const DWORD PROPSETFLAG_UNBUFFERED = 4;
1836 typedef struct tagPROPVARIANT PROPVARIANT;
1838 #define TYPEDEF_CA(type, name) \
1839 typedef struct tag##name { \
1840 ULONG cElems; \
1841 [size_is(cElems)] \
1842 type *pElems; \
1843 } name
1845 TYPEDEF_CA(unsigned char, CAUB);
1846 TYPEDEF_CA(short, CAI);
1847 TYPEDEF_CA(USHORT, CAUI);
1848 TYPEDEF_CA(long, CAL);
1849 TYPEDEF_CA(ULONG, CAUL);
1850 TYPEDEF_CA(float, CAFLT);
1851 TYPEDEF_CA(double, CADBL);
1852 TYPEDEF_CA(CY, CACY);
1853 TYPEDEF_CA(DATE, CADATE);
1854 TYPEDEF_CA(BSTR, CABSTR);
1855 TYPEDEF_CA(BSTRBLOB, CABSTRBLOB);
1856 TYPEDEF_CA(VARIANT_BOOL, CABOOL);
1857 TYPEDEF_CA(SCODE, CASCODE);
1858 TYPEDEF_CA(PROPVARIANT, CAPROPVARIANT);
1859 TYPEDEF_CA(LARGE_INTEGER, CAH);
1860 TYPEDEF_CA(ULARGE_INTEGER, CAUH);
1861 TYPEDEF_CA(LPSTR, CALPSTR);
1862 TYPEDEF_CA(LPWSTR, CALPWSTR);
1863 TYPEDEF_CA(FILETIME, CAFILETIME);
1864 TYPEDEF_CA(CLIPDATA, CACLIPDATA);
1865 TYPEDEF_CA(CLSID, CACLSID);
1867 struct tagPROPVARIANT {
1868 VARTYPE vt;
1869 WORD wReserved1;
1870 WORD wReserved2;
1871 WORD wReserved3;
1872 [switch_is(vt & 0x1fff)] union {
1873 [case(VT_EMPTY, VT_NULL)] ;
1874 [case(VT_I1)] char cVal;
1875 [case(VT_UI1)] UCHAR bVal;
1876 [case(VT_I2)] short iVal;
1877 [case(VT_UI2)] USHORT uiVal;
1878 [case(VT_BOOL)] VARIANT_BOOL boolVal;
1879 #if 0 /* illegal in C++ */
1880 [case(VT_ILLEGAL)] _VARIANT_BOOL bool;
1881 #endif
1882 [case(VT_I4)] long lVal;
1883 [case(VT_UI4)] ULONG ulVal;
1884 [case(VT_R4)] float fltVal;
1885 [case(VT_ERROR)] SCODE scode;
1886 [case(VT_I8)] LARGE_INTEGER hVal;
1887 [case(VT_UI8)] ULARGE_INTEGER uhVal;
1888 [case(VT_R8)] double dblVal;
1889 [case(VT_CY)] CY cyVal;
1890 [case(VT_DATE)] DATE date;
1891 [case(VT_FILETIME)] FILETIME filetime;
1892 [case(VT_CLSID)] CLSID *puuid;
1893 [case(VT_BLOB, VT_BLOB_OBJECT)] BLOB blob;
1894 [case(VT_CF)] CLIPDATA *pclipdata;
1895 [case(VT_STREAM, VT_STREAMED_OBJECT)] IStream *pStream;
1896 [case(VT_STORAGE, VT_STORED_OBJECT)] IStorage *pStorage;
1897 [case(VT_BSTR)] BSTR bstrVal;
1898 [case(VT_BSTR_BLOB)] BSTRBLOB bstrblobVal;
1899 [case(VT_LPSTR)] LPSTR pszVal;
1900 [case(VT_LPWSTR)] LPWSTR pwszVal;
1901 [case(VT_UI1|VT_VECTOR)] CAUB caub;
1902 [case(VT_I2|VT_VECTOR)] CAI cai;
1903 [case(VT_UI2|VT_VECTOR)] CAUI caui;
1904 [case(VT_BOOL|VT_VECTOR)] CABOOL cabool;
1905 [case(VT_I4|VT_VECTOR)] CAL cal;
1906 [case(VT_UI4|VT_VECTOR)] CAUL caul;
1907 [case(VT_R4|VT_VECTOR)] CAFLT caflt;
1908 [case(VT_ERROR|VT_VECTOR)] CASCODE cascode;
1909 [case(VT_I8|VT_VECTOR)] CAH cah;
1910 [case(VT_UI8|VT_VECTOR)] CAUH cauh;
1911 [case(VT_R8|VT_VECTOR)] CADBL cadbl;
1912 [case(VT_CY|VT_VECTOR)] CACY cacy;
1913 [case(VT_DATE|VT_VECTOR)] CADATE cadate;
1914 [case(VT_FILETIME|VT_VECTOR)] CAFILETIME cafiletime;
1915 [case(VT_CLSID|VT_VECTOR)] CACLSID cauuid;
1916 [case(VT_CF|VT_VECTOR)] CACLIPDATA caclipdata;
1917 [case(VT_BSTR|VT_VECTOR)] CABSTR cabstr;
1918 [case(VT_BSTR_BLOB|VT_VECTOR)] CABSTRBLOB cabstrblob;
1919 [case(VT_LPSTR|VT_VECTOR)] CALPSTR calpstr;
1920 [case(VT_LPWSTR|VT_VECTOR)] CALPWSTR calpwstr;
1921 [case(VT_VARIANT|VT_VECTOR)] CAPROPVARIANT capropvar;
1925 typedef struct tagPROPVARIANT *LPPROPVARIANT;
1927 /* FIXME: bunches of property IDs */
1929 const ULONG PRSPEC_INVALID = 0xffffffff;
1930 const ULONG PRSPEC_LPWSTR = 0;
1931 const ULONG PRSPEC_PROPID = 1;
1933 typedef struct tagPROPSPEC {
1934 ULONG ulKind;
1935 [switch_is(ulKind)] union {
1936 [case(PRSPEC_PROPID)] PROPID propid;
1937 [case(PRSPEC_LPWSTR)] LPOLESTR lpwstr;
1938 [default] ;
1940 } PROPSPEC;
1942 typedef struct tagSTATPROPSTG {
1943 LPOLESTR lpwstrName;
1944 PROPID propid;
1945 VARTYPE vt;
1946 } STATPROPSTG;
1948 /* FIXME: macros */
1950 typedef struct tagSTATPROPSETSTG {
1951 FMTID fmtid;
1952 CLSID clsid;
1953 DWORD grfFlags;
1954 FILETIME mtime;
1955 FILETIME ctime;
1956 FILETIME atime;
1957 DWORD dwOSVersion;
1958 } STATPROPSETSTG;
1960 HRESULT ReadMultiple(
1961 [in] ULONG cpspec,
1962 [in, size_is(cpspec)] const PROPSPEC rgpspec[],
1963 [out, size_is(cpspec)] PROPVARIANT rgpropvar[]);
1965 HRESULT WriteMultiple(
1966 [in] ULONG cpspec,
1967 [in, size_is(cpspec)] const PROPSPEC rgpspec[],
1968 [in, size_is(cpspec)] const PROPVARIANT rgpropvar[],
1969 [in] PROPID propidNameFirst);
1971 HRESULT DeleteMultiple(
1972 [in] ULONG cpspec,
1973 [in, size_is(cpspec)] const PROPSPEC rgpspec[]);
1975 HRESULT ReadPropertyNames(
1976 [in] ULONG cpropid,
1977 [in, size_is(cpropid)] const PROPID rgpropid[],
1978 [out, size_is(cpropid)] LPOLESTR rglpwstrName[]);
1980 HRESULT WritePropertyNames(
1981 [in] ULONG cpropid,
1982 [in, size_is(cpropid)] const PROPID rgpropid[],
1983 [in, size_is(cpropid)] const LPOLESTR rglpwstrName[]);
1985 HRESULT DeletePropertyNames(
1986 [in] ULONG cpropid,
1987 [in, size_is(cpropid)] const PROPID rgpropid[]);
1989 HRESULT Commit(
1990 [in] DWORD grfCommitFlags);
1992 HRESULT Revert();
1994 HRESULT Enum(
1995 [out] IEnumSTATPROPSTG **ppenum);
1997 HRESULT SetTimes(
1998 [in] const FILETIME *pctime,
1999 [in] const FILETIME *patime,
2000 [in] const FILETIME *pmtime);
2002 HRESULT SetClass(
2003 [in] REFCLSID clsid);
2005 HRESULT Stat(
2006 [out] STATPROPSETSTG *statpsstg);
2010 object,
2011 uuid(0000013A-0000-0000-C000-000000000046),
2012 pointer_default(unique)
2014 interface IPropertySetStorage : IUnknown
2016 typedef [unique] IPropertySetStorage *LPPROPERTYSETSTORAGE;
2018 HRESULT Create(
2019 [in] REFFMTID rfmtid,
2020 [in, unique] const CLSID *pclsid,
2021 [in] DWORD grfFlags,
2022 [in] DWORD grfMode,
2023 [out] IPropertyStorage **ppprstg);
2025 HRESULT Open(
2026 [in] REFFMTID rfmtid,
2027 [in] DWORD grfMode,
2028 [out] IPropertyStorage **ppprstg);
2030 HRESULT Delete(
2031 [in] REFFMTID rfmtid);
2033 HRESULT Enum(
2034 [out] IEnumSTATPROPSETSTG **ppenum);
2038 object,
2039 uuid(00000139-0000-0000-C000-000000000046),
2040 pointer_default(unique)
2042 interface IEnumSTATPROPSTG : IUnknown
2044 typedef [unique] IEnumSTATPROPSTG *LPENUMSTATPROPSTG;
2046 [local]
2047 HRESULT Next(
2048 [in] ULONG celt,
2049 [out, size_is(celt), length_is(*pceltFetched)]
2050 STATPROPSTG *rgelt,
2051 [out] ULONG *pceltFetched);
2053 [call_as(Next)]
2054 HRESULT RemoteNext(
2055 [in] ULONG celt,
2056 [out, size_is(celt), length_is(*pceltFetched)]
2057 STATPROPSTG *rgelt,
2058 [out] ULONG *pceltFetched);
2060 HRESULT Skip(
2061 [in] ULONG celt);
2063 HRESULT Reset();
2065 HRESULT Clone(
2066 [out] IEnumSTATPROPSTG **ppenum);
2070 object,
2071 uuid(0000013B-0000-0000-C000-000000000046),
2072 pointer_default(unique)
2074 interface IEnumSTATPROPSETSTG : IUnknown
2076 typedef [unique] IEnumSTATPROPSETSTG *LPENUMSTATPROPSETSTG;
2078 [local]
2079 HRESULT Next(
2080 [in] ULONG celt,
2081 [out, size_is(celt), length_is(*pceltFetched)]
2082 STATPROPSETSTG *rgelt,
2083 [out] ULONG *pceltFetched);
2085 [call_as(Next)]
2086 HRESULT RemoteNext(
2087 [in] ULONG celt,
2088 [out, size_is(celt), length_is(*pceltFetched)]
2089 STATPROPSETSTG *rgelt,
2090 [out] ULONG *pceltFetched);
2092 HRESULT Skip(
2093 [in] ULONG celt);
2095 HRESULT Reset();
2097 HRESULT Clone(
2098 [out] IEnumSTATPROPSETSTG **ppenum);
2101 /******************** Connection Points ********************/
2102 /* FIXME */
2104 /******************** DCOM ********************/
2107 local,
2108 object,
2109 uuid(0000013D-0000-0000-C000-000000000046)
2111 interface IClientSecurity : IUnknown
2113 typedef struct tagSOLE_AUTHENTICATION_SERVICE {
2114 DWORD dwAuthnSvc;
2115 DWORD dwAuthzSvc;
2116 OLECHAR *pPrincipalName;
2117 HRESULT hr;
2118 } SOLE_AUTHENTICATION_SERVICE;
2120 typedef SOLE_AUTHENTICATION_SERVICE *PSOLE_AUTHENTICATION_SERVICE;
2122 typedef enum tagEOLE_AUTHENTICATION_CAPABILITIES {
2123 EOAC_NONE = 0x0,
2124 EOAC_MUTUAL_AUTH = 0x1,
2125 EOAC_CLOAKING = 0x10,
2126 EOAC_SECURE_REFS = 0x2,
2127 EOAC_ACCESS_CONTROL = 0x4,
2128 EOAC_APPID = 0x8
2129 } EOLE_AUTHENTICATION_CAPABILITIES;
2131 HRESULT QueryBlanket(
2132 [in] IUnknown *pProxy,
2133 [out] DWORD *pAuthnSvc,
2134 [out] DWORD *pAuthzSvc,
2135 [out] OLECHAR **pServerPrincName,
2136 [out] DWORD *pAuthnLevel,
2137 [out] DWORD *pImpLevel,
2138 [out] void **pAuthInfo,
2139 [out] DWORD *pCapabilites);
2141 HRESULT SetBlanket(
2142 [in] IUnknown *pProxy,
2143 [in] DWORD AuthnSvc,
2144 [in] DWORD AuthzSvc,
2145 [in] OLECHAR *pServerPrincName,
2146 [in] DWORD AuthnLevel,
2147 [in] DWORD ImpLevel,
2148 [in] void *pAuthInfo,
2149 [in] DWORD Capabilities);
2151 HRESULT CopyProxy(
2152 [in] IUnknown *pProxy,
2153 [out] IUnknown **ppCopy);
2157 local,
2158 object,
2159 uuid(0000013E-0000-0000-C000-000000000046)
2161 interface IServerSecurity : IUnknown
2163 HRESULT QueryBlanket(
2164 [out] DWORD *pAuthnSvc,
2165 [out] DWORD *pAuthzSvc,
2166 [out] OLECHAR **pServerPrincName,
2167 [out] DWORD *pAuthnLevel,
2168 [out] DWORD *pImpLevel,
2169 [out] void **pPrivs,
2170 [out] DWORD *pCapabilities);
2172 HRESULT ImpersonateClient();
2174 HRESULT RevertToSelf();
2176 BOOL IsImpersonating();
2180 local,
2181 object,
2182 uuid(00000024-0000-0000-C000-000000000046)
2184 interface IAsyncSetup : IUnknown
2186 HRESULT GetAsyncManager(
2187 [in] REFIID riid,
2188 [in] IUnknown *pOuter,
2189 [in] DWORD dwFlags,
2190 [out] IUnknown **ppInner,
2191 [out] IAsyncManager **ppAsyncMgr);
2195 local,
2196 object,
2197 uuid(0000002A-0000-0000-C000-000000000046)
2199 interface IAsyncManager : IUnknown
2201 typedef enum tagDCOM_CALL_STATE {
2202 DCOM_NONE = 0,
2203 DCOM_CALL_COMPLETE = 1,
2204 DCOM_CALL_CANCELED = 2
2205 } DCOM_CALL_STATE;
2207 HRESULT CompleteCall(
2208 [in] HRESULT Result);
2209 HRESULT GetCallContext(
2210 [in] REFIID riid,
2211 [out] void **pInterface);
2212 HRESULT GetState(
2213 [out] ULONG *pulStateFlags);