Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygenpunknown.h
Go to the documentation of this file.
00001 /* 00002 ReactOS Kernel-Mode COM 00003 by Andrew Greenwood 00004 00005 This file is in the public domain. 00006 */ 00007 00008 #ifndef _UNKNOWN_H_ 00009 #define _UNKNOWN_H_ 00010 00011 #ifdef __cplusplus 00012 extern "C" { 00013 #include <wdm.h> 00014 } 00015 #else 00016 #include <wdm.h> 00017 #endif 00018 00019 #include <windef.h> 00020 #define COM_NO_WINDOWS_H 00021 #include <basetyps.h> 00022 00023 #ifdef PUT_GUIDS_HERE 00024 #include <initguid.h> 00025 #endif 00026 00027 /* =============================================================== 00028 IUnknown 00029 */ 00030 00031 #ifndef __IUnknown_INTERFACE_DEFINED__ 00032 #define __IUnknown_INTERFACE_DEFINED__ 00033 00034 DEFINE_GUID(IID_IUnknown, 00035 0x00000000, 0x0000, 0x0000, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x46); 00036 00037 #undef INTERFACE 00038 #define INTERFACE IUnknown 00039 00040 DECLARE_INTERFACE(IUnknown) { 00041 STDMETHOD_(NTSTATUS, QueryInterface)( THIS_ 00042 IN REFIID, 00043 OUT PVOID*) PURE; 00044 00045 STDMETHOD_(ULONG, AddRef)( THIS ) PURE; 00046 00047 STDMETHOD_(ULONG, Release)( THIS ) PURE; 00048 }; 00049 00050 #endif /* __IUnknown_INTERFACE_DEFINED__ */ 00051 00052 #undef INTERFACE 00053 00054 typedef IUnknown *PUNKNOWN; 00055 00056 /* =============================================================== 00057 IUnknown definition 00058 Boilerplate code macro for use in subclassed interfaces 00059 */ 00060 00061 #define DEFINE_ABSTRACT_UNKNOWN() \ 00062 STDMETHOD_(NTSTATUS, QueryInterface)( THIS_ \ 00063 REFIID InterfaceId, \ 00064 PVOID* Interface) PURE; \ 00065 \ 00066 STDMETHOD_(ULONG, AddRef)(THIS) PURE; \ 00067 \ 00068 STDMETHOD_(ULONG, Release)(THIS) PURE; 00069 00070 /* =============================================================== 00071 Constructor callback definition 00072 */ 00073 00074 typedef HRESULT 00075 (NTAPI *PFNCREATEINSTANCE)( 00076 OUT PUNKNOWN* Unknown, 00077 IN REFCLSID ClassId, 00078 IN PUNKNOWN OuterUnknown, 00079 IN POOL_TYPE PoolType); 00080 00081 #endif /* _UNKNOWN_H_ */ Generated on Sun May 27 2012 04:30:15 for ReactOS by
1.7.6.1
|