Callback.h

Go to the documentation of this file.
00001 // @(#)root/reflex:$Id: Callback.h 29288 2009-07-01 13:03:35Z axel $
00002 // Author: Stefan Roiser 2004
00003 
00004 // Copyright CERN, CH-1211 Geneva 23, 2004-2006, All rights reserved.
00005 //
00006 // Permission to use, copy, modify, and distribute this software for any
00007 // purpose is hereby granted without fee, provided that this copyright and
00008 // permissions notice appear in all copies and derivatives.
00009 //
00010 // This software is provided "as is" without express or implied warranty.
00011 
00012 #ifndef Reflex_Callback
00013 #define Reflex_Callback
00014 
00015 // Include files
00016 #include "Reflex/Kernel.h"
00017 
00018 
00019 namespace Reflex {
00020 // forward declarations
00021 class Type;
00022 class Member;
00023 
00024 /**
00025  * @class Callback Callback.h Reflex/Callback.h
00026  * @author Pere Mato
00027  * @date 12/11/2004
00028  * @ingroup Ref
00029  */
00030 class RFLX_API ICallback {
00031 public:
00032    /** constructor */
00033    ICallback() {}
00034 
00035    /** destructor */
00036    virtual ~ICallback() {}
00037 
00038    /**
00039     * operator call (virtual)
00040     */
00041    virtual void operator ()(const Type&) = 0;
00042    virtual void operator ()(const Member&) = 0;
00043 
00044 };    // class ICallback
00045 
00046 
00047 RFLX_API void InstallClassCallback(ICallback* cb);
00048 RFLX_API void UninstallClassCallback(ICallback* cb);
00049 RFLX_API void FireClassCallback(const Type&);
00050 RFLX_API void FireFunctionCallback(const Member&);
00051 
00052 } // namespace Reflex
00053 
00054 #endif // Reflex_Callback

Generated on Tue Jul 5 14:25:50 2011 for ROOT_528-00b_version by  doxygen 1.5.1