56 std::vector<QwDetectorInfo*>::push_back(&detector);
57 std::sort(begin(),end(),
compare());
62 std::vector<QwDetectorInfo*>::push_back(detector);
63 std::sort(begin(),end(),
compare());
68 QwGeometry::const_iterator i;
69 for (i = detectors.begin(); i != detectors.end(); i++)
70 std::vector<QwDetectorInfo*>::push_back(*i);
71 std::sort(begin(),end(),
compare());
75 void push_back(std::vector<QwDetectorInfo>& detectors) {
76 std::vector<QwDetectorInfo>::iterator i;
77 for (i = detectors.begin(); i != detectors.end(); i++)
78 std::vector<QwDetectorInfo*>::push_back(&(*i));
79 std::sort(begin(),end(),
compare());
85 for (const_iterator i = begin(); i != end(); i++)
86 if ((*i)->GetDetectorName() ==
name)
94 for (const_iterator i = begin(); i != end(); i++)
95 if ((*i)->GetRegion() == r)
103 for (const_iterator i = begin(); i != end(); i++)
104 if ((*i)->GetPackage() == p)
112 for (const_iterator i = begin(); i != end(); i++)
113 if ((*i)->GetDirection() == d)
121 for (const_iterator i = begin(); i != end(); i++)
122 if ((*i)->GetType() == t)
130 for (const_iterator i = begin(); i != end(); i++)
134 && (*i)->GetType() == d->
GetType())
152 for (QwGeometry::const_iterator i = begin(); i != end(); i++) {
169 for (QwGeometry::const_iterator i = detectors.begin(); i != detectors.end(); i++) {
171 stream << *(*i) << std::endl;
173 stream <<
"(null)" << std::endl;
const QwGeometry in(const EQwDetectorPackage &p) const
Get detectors in given package.
Functor for sorting QwDetectorInfo pointers.
#define QwOut
Predefined log drain for explicit output.
void push_back(QwDetectorInfo &detector)
Add single detector object.
QwGeometry(const QwGeometry &that)
Copy constructor.
std::ostream & operator<<(std::ostream &out, const QwColor &color)
Output stream operator which uses the enum-to-escape-code mapping.
const QwGeometry in(const EQwRegionID &r) const
Get detectors in given region.
EQwDetectorPackage GetPackage() const
void push_back(const QwGeometry &detectors)
Add another geometry.
EQwRegionID GetRegion() const
EQwDirectionID GetDirection() const
const QwGeometry as(const QwDetectorInfo *d) const
Get detectors like specified detector (same region, same package, same type)
const QwGeometry name(const std::string &name)
Get detectors by name.
friend std::ostream & operator<<(std::ostream &stream, const QwGeometry &detectors)
void push_back(QwDetectorInfo *detector)
Add single detector pointer.
bool operator()(const QwDetectorInfo *lhs, const QwDetectorInfo *rhs)
EQwDetectorType GetType() const
static std::ostream & endl(std::ostream &)
End of the line.
Collection of QwDetectorInfo pointers that specifies an experimental geometry.
const QwGeometry of(const EQwDetectorType &t) const
Get detectors of given type.
virtual ~QwGeometry()
Virtual destructor.
QwGeometry & operator=(const QwGeometry &that)
Assignment operator.
QwGeometry()
Default constructor.
void push_back(std::vector< QwDetectorInfo > &detectors)
Add vector of detectors.
const QwGeometry in(const EQwDirectionID &d) const
Get detectors in given direction.