CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_6_1_2_SLHC2_patch1/src/Fireworks/Core/interface/FWSimpleProxyBuilder.h

Go to the documentation of this file.
00001 #ifndef Fireworks_Core_FWSimpleProxyBuilder_h
00002 #define Fireworks_Core_FWSimpleProxyBuilder_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     Core
00006 // Class  :     FWSimpleProxyBuilder
00007 //
00016 //
00017 // Original Author:  Chris Jones, AljaMrak-Tadel
00018 //         Created:  Tue March 28  2 09:46:36 EST 2010
00019 // $Id: FWSimpleProxyBuilder.h,v 1.10 2010/10/22 14:34:45 amraktad Exp $
00020 //
00021 
00022 // system include files
00023 #include <typeinfo>
00024 
00025 // user include files
00026 #include "Fireworks/Core/interface/FWProxyBuilderBase.h"
00027 #include "Fireworks/Core/interface/FWSimpleProxyHelper.h"
00028 
00029 // forward declarations
00030 
00031 class FWSimpleProxyBuilder : public FWProxyBuilderBase {
00032 
00033 public:
00034    FWSimpleProxyBuilder(const std::type_info& iType);
00035    virtual ~FWSimpleProxyBuilder();
00036 
00037    // ---------- const member functions ---------------------
00038 
00039    // ---------- static member functions --------------------
00041    static std::string typeOfBuilder();
00042 
00043    // ---------- member functions ---------------------------
00044 
00045 protected:
00046    virtual void build(const FWEventItem* iItem, TEveElementList* product, const FWViewContext*);
00047    virtual void buildViewType(const FWEventItem* iItem, TEveElementList* product, FWViewType::EType viewType, const FWViewContext*);
00048 
00049  
00050    virtual void clean();
00051    FWSimpleProxyHelper m_helper;
00052 private:
00053    FWSimpleProxyBuilder(const FWSimpleProxyBuilder&); // stop default
00054 
00055    const FWSimpleProxyBuilder& operator=(const FWSimpleProxyBuilder&); // stop default
00056 
00057    virtual void itemChangedImp(const FWEventItem*);
00058    
00059    virtual bool visibilityModelChanges(const FWModelId&, TEveElement*, FWViewType::EType, const FWViewContext*);
00060 
00061    //called once for each item in collection, the void* points to the
00062    // object properly offset in memory
00063    virtual void build(const void*, unsigned int iIndex, TEveElement& iItemHolder, const FWViewContext*) = 0;
00064    virtual void buildViewType(const void*, unsigned int iIndex, TEveElement& iItemHolder, FWViewType::EType, const FWViewContext*) = 0;
00065 
00066    // ---------- member data --------------------------------
00067 };
00068 
00069 
00070 #endif