00001 /***************************************************************************** 00002 * Copyright (C) 2011 by Benjamin Hadorn (b_hadorn@bluewin.ch) 00003 ***************************************************************************** 00004 * Project : Zeus Base Library 00005 * Module : IZUnknown 00006 * Package : Zeus.ZeusBase.System.Interfaces 00007 * Author : Benjamin Hadorn 00008 * Date : 27.12.2011 00009 * System : Zeus-Framework 00010 ***************************************************************************** 00011 * Licence: * 00012 * This library is free software; you can redistribute it and/or modify * 00013 * it under the terms of the GNU Lesser General Public License as * 00014 * published by the Free Software Foundation; either version * 00015 * 2.1 of the License, or (at your option) any later version. * 00016 * * 00017 * This library is distributed in the hope that it will be useful, * 00018 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00019 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * 00020 * GNU Lesser General Public License for more details. * 00021 * * 00022 * You should have received a copy of the GNU Lesser General Public * 00023 * License along with this library; if not, write to the Free Software * 00024 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA * 00025 *****************************************************************************/ 00026 00027 /***************************************************************************** 00028 * Changes: 00029 * 27.12.2011 bha: created zeus 2.0 00030 *****************************************************************************/ 00031 00032 #ifndef IZUnknownHPP 00033 #define IZUnknownHPP 00034 00035 #ifdef _MSC_VER 00036 #pragma warning(push, 1) 00037 #endif 00038 00039 #include <stddef.h> 00040 00041 #ifdef _MSC_VER 00042 #pragma warning(pop) 00043 #endif 00044 00045 #include <zeusbase/Config/PlatformDefines.hpp> 00046 #include <zeusbase/Config/RetvalDefines.hpp> 00047 #include <zeusbase/System/Interfaces/IZUnknownImplHelper.hpp> 00048 00049 // {0000000-0000-0000-C000-000000000046} Do not modify! Must be equal to IUnknown from COM. 00050 #define INTERFACE_IZUnknown TIID(0x00000000, 0x0000, 0x0000, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46) 00051 00052 00053 BEGIN_NAMESPACE_Zeus 00054 00055 /***************************************************************************/ 00064 /***************************************************************************/ 00065 class IZUnknown 00066 { 00067 HIDE_ASSIGNMENT_OPERATOR(IZUnknown) 00068 HIDE_DESTRUCTOR(IZUnknown) 00069 00070 public: 00071 00072 /***********************************************************************/ 00083 /***********************************************************************/ 00084 virtual Retval MQUALIFIER askForInterface(const InterfaceID& rInterfaceID, IZUnknown*& rpIface)=0; 00085 00086 /***********************************************************************/ 00092 /***********************************************************************/ 00093 virtual void MQUALIFIER addRef() const=0; 00094 00095 /***********************************************************************/ 00100 /***********************************************************************/ 00101 virtual void MQUALIFIER release() const=0; 00102 00103 }; 00104 00105 END_NAMESPACE_Zeus 00106 00107 #endif