File indexing completed on 2025-08-05 08:17:52
0001
0002
0003 #ifndef G4DETECTORS_PHG4TPCCYLINDERGEOMCONTAINER_H
0004 #define G4DETECTORS_PHG4TPCCYLINDERGEOMCONTAINER_H
0005
0006 #include <phool/PHObject.h>
0007
0008 #include <iostream> // for cout, ostream
0009 #include <map>
0010 #include <utility> // for make_pair, pair
0011
0012 class PHG4TpcCylinderGeom;
0013
0014 class PHG4TpcCylinderGeomContainer : public PHObject
0015 {
0016 public:
0017 typedef std::map<int, PHG4TpcCylinderGeom *> Map;
0018 typedef Map::iterator Iterator;
0019 typedef Map::const_iterator ConstIterator;
0020 typedef std::pair<Iterator, Iterator> Range;
0021 typedef std::pair<ConstIterator, ConstIterator> ConstRange;
0022
0023 PHG4TpcCylinderGeomContainer() {}
0024 ~PHG4TpcCylinderGeomContainer() override;
0025
0026
0027 void identify(std::ostream &os = std::cout) const override;
0028
0029 int AddLayerCellGeom(const int i, PHG4TpcCylinderGeom *mygeom);
0030 int AddLayerCellGeom(PHG4TpcCylinderGeom *mygeom);
0031 PHG4TpcCylinderGeom *GetLayerCellGeom(const int i);
0032 PHG4TpcCylinderGeom *GetFirstLayerCellGeom();
0033 int get_NLayers() const { return layergeoms.size(); }
0034 ConstRange get_begin_end() const { return {layergeoms.begin(), layergeoms.end()}; }
0035
0036 protected:
0037 Map layergeoms;
0038 ClassDefOverride(PHG4TpcCylinderGeomContainer, 1)
0039 };
0040
0041 #endif