Belle II Software development
QuadTreeItem.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8#pragma once
9
10namespace Belle2 {
15 namespace TrackingUtilities {
16 class CDCWireHit;
17 class CDCSegment2D;
18 }
19 namespace TrackFindingCDC {
20
27 template<class AData>
29 public:
31 explicit QuadTreeItem(AData* data)
32 : m_data(data)
33 , m_usedFlag(false) {};
34
35 private:
37 QuadTreeItem(const QuadTreeItem& copy) = delete;
38
40 QuadTreeItem& operator=(QuadTreeItem const& copy) = delete;
41
42 public:
44 AData* getPointer() const
45 {
46 return m_data;
47 }
48
53 bool isUsed() const
54 {
55 return m_usedFlag;
56 }
57
59 void setUsedFlag(bool usedFlag = true)
60 {
61 m_usedFlag = usedFlag;
62 }
63
66 {
67 setUsedFlag(false);
68 }
69
70 private:
72 AData* m_data;
73
76 };
77
81 template<>
83
87 template<>
89
93 template<>
95
99 template<>
101 }
103}
bool m_usedFlag
This flag can be set to not use the item in the next quad tree search round.
QuadTreeItem(const QuadTreeItem &copy)=delete
Do not copy!
QuadTreeItem(AData *data)
Constructor.
bool isUsed() const
Flag is set if the item was used as a result of the quad tree search and should not be used in the ne...
AData * m_data
A pointer to the underlying item data.
QuadTreeItem & operator=(QuadTreeItem const &copy)=delete
Do not copy!
AData * getPointer() const
Returns the underlying data.
void unsetUsedFlag()
Unset the used flag again if you have noticed that a previous setting was wrong.
void setUsedFlag(bool usedFlag=true)
Set the used flag if you do not want that item to go into the next search round again.
A reconstructed sequence of two dimensional hits in one super layer.
Class representing a hit wire in the central drift chamber.
Definition CDCWireHit.h:58
Abstract base class for different kinds of events.