Print

Print


Commit in slicPandora/src on MAIN
SimCalorimeterHitProcessor.cpp+81.15 -> 1.16
if CalorimeterHit type collection already exists then don't have Pandora create it

slicPandora/src
SimCalorimeterHitProcessor.cpp 1.15 -> 1.16
diff -u -r1.15 -r1.16
--- SimCalorimeterHitProcessor.cpp	8 Jun 2010 23:12:22 -0000	1.15
+++ SimCalorimeterHitProcessor.cpp	10 Jun 2010 19:11:19 -0000	1.16
@@ -57,6 +57,14 @@
          iter != calTypes.end();
          iter++)
     {
+        // If a collection with name of CalorimeterType already exists,
+        // then assume conversion to CalorimeterHit took place externally and skip it.
+        const std::vector<std::string>* collNames = event->getCollectionNames();
+        if (find(collNames->begin(), collNames->end(), std::string(*iter)) != collNames->end())
+        {
+            continue;
+        }
+
         PandoraApi::GeometryParameters::SubDetectorParameters* subdet = geom->getSubDetectorFromType((*iter));
         std::string subdetName = (*iter);
         const DetectorGeometry::ExtraSubDetectorParameters& xsubdet = subdetExtras->find(subdetName)->second;
CVSspam 0.2.8