test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
FWOverlapTableManager.h
Go to the documentation of this file.
1 #ifndef Fireworks_Core_FWOverlapTableManager_h
2 #define Fireworks_Core_FWOverlapTableManager_h
3 // -*- C++ -*-
4 //
5 // Package: Core
6 // Class : FWOverlapTableManager
7 //
16 //
17 // Original Author:
18 // Created: Wed Jan 4 20:34:38 CET 2012
19 //
20 
22 #include "TGeoMatrix.h"
23 #include "TGeoNode.h"
24 #include "TGeoOverlap.h"
25 #include <map>
26 
27 
28 class FWOverlapTableView;
29 class TGeoOverlap;
30 class TGeoIterator;
31 
32 
34 {
35 public:
37  {
38  kVisMarker = BIT(5),
39  kOverlap = BIT(6),
40  kOverlapChild = BIT(7)
41  };
42 
43  class QuadId : public TNamed
44  {
45  public:
46  QuadId():m_ovl(0), m_parentIdx(-1){}
47  QuadId(TGeoOverlap* ovl, int idx){ m_ovl = ovl; m_parentIdx = idx; }
48 
49  virtual ~QuadId(){}
50  virtual const char* GetName() const { return m_ovl->GetTitle(); }
51  virtual const char* GetTitle() const { return m_ovl->GetTitle(); }
52 
53  TGeoOverlap* m_ovl;
55  std::vector<int> m_nodes;
56  };
57 
59  virtual ~FWOverlapTableManager();
60 
61  virtual void recalculateVisibility();
62  virtual void recalculateVisibilityNodeRec(int);
63  void importOverlaps(std::string path, double precision);
64  virtual int numberOfColumns() const {return 6;}
65 
66  virtual std::vector<std::string> getTitles() const;
67 
68  FWTableCellRendererBase* cellRenderer(int iSortedRowNumber, int iCol) const;
69 
70  void getOverlapTitles(int,TString&) const;
71  void printOverlaps(int) const;
72 
73  void setDaughtersSelfVisibility(int i, bool v);
74 protected:
75  virtual bool nodeIsParent(const NodeInfo&) const;
76  // virtual const char* cellName(const NodeInfo& data) const;
77 
78 private:
79  FWOverlapTableManager(const FWOverlapTableManager&); // stop default
80  const FWOverlapTableManager& operator=(const FWOverlapTableManager&); // stop default
81 
82  void addOverlapEntry(TGeoOverlap*, int, int , TGeoHMatrix*);
84 
85  std::multimap<int, int> m_mapNodeOverlaps;
86 };
87 
88 
89 #endif
int i
Definition: DBlmapReader.cc:9
std::multimap< int, int > m_mapNodeOverlaps
const FWOverlapTableManager & operator=(const FWOverlapTableManager &)
void addOverlapEntry(TGeoOverlap *, int, int, TGeoHMatrix *)
virtual void recalculateVisibilityNodeRec(int)
void getOverlapTitles(int, TString &) const
virtual std::vector< std::string > getTitles() const
returns the title names for each column
FWTableCellRendererBase * cellRenderer(int iSortedRowNumber, int iCol) const
FWOverlapTableManager(FWOverlapTableView *)
virtual void recalculateVisibility()
void setDaughtersSelfVisibility(int i, bool v)
virtual int numberOfColumns() const
Number of columns in the table.
QuadId(TGeoOverlap *ovl, int idx)
virtual const char * GetName() const
virtual const char * GetTitle() const
virtual bool nodeIsParent(const NodeInfo &) const
void importOverlaps(std::string path, double precision)
FWOverlapTableView * m_browser