CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_8_patch3/src/Fireworks/Core/interface/FWParameterSetterBase.h

Go to the documentation of this file.
00001 #ifndef Fireworks_Core_FWParameterSetterBase_h
00002 #define Fireworks_Core_FWParameterSetterBase_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     Core
00006 // Class  :     FWParameterSetterBase
00007 //
00016 //
00017 // Original Author:  Chris Jones
00018 //         Created:  Fri Mar  7 14:16:14 EST 2008
00019 // $Id: FWParameterSetterBase.h,v 1.8 2012/02/22 03:45:57 amraktad Exp $
00020 //
00021 
00022 // system include files
00023 #include <boost/shared_ptr.hpp>
00024 
00025 // user include files
00026 
00027 // forward declarations
00028 class FWParameterBase;
00029 class FWParameterSetterEditorBase;
00030 class TGFrame;
00031 
00032 class FWParameterSetterBase
00033 {
00034 public:
00035    FWParameterSetterBase();
00036    virtual ~FWParameterSetterBase();
00037 
00038    // ---------- const member functions ---------------------
00039 
00040    // ---------- static member functions --------------------
00041 
00042    static boost::shared_ptr<FWParameterSetterBase> makeSetterFor(FWParameterBase*);
00043 
00044    // ---------- member functions ---------------------------
00045 
00046    void             attach(FWParameterBase*, FWParameterSetterEditorBase*);
00047    virtual TGFrame* build(TGFrame* iParent, bool labelBack = true) = 0;
00048 
00049    virtual void     setEnabled(bool);
00050 
00051 protected:
00052    void update() const;
00053    FWParameterSetterEditorBase* frame() const { return m_frame; }
00054 
00055 private:
00056    virtual void attach(FWParameterBase*) = 0;
00057 
00058    FWParameterSetterBase(const FWParameterSetterBase&);                  // stop default
00059    const FWParameterSetterBase& operator=(const FWParameterSetterBase&); // stop default
00060 
00061    // ---------- member data --------------------------------
00062 
00063    FWParameterSetterEditorBase* m_frame;
00064 };
00065 
00066 #endif