ClassImp(AliMpSegFactory)
/// \endcond
+Int_t AliMpSegFactory::fgNumberOfInstances(0);
+
//______________________________________________________________________________
AliMpSegFactory::AliMpSegFactory()
: TObject(),
/// Standard constructor
AliDebug(1,"");
fMpMap->SetOwner(true);
+ ++fgNumberOfInstances;
}
//______________________________________________________________________________
// The segmentations is supposed to be deleted in the client code
AliDebug(1,"");
+ --fgNumberOfInstances;
}
//
/// Fill the map of electronic cards IDs to segmentations for
/// given detElemId
- AliDebug(1,Form("detElemId=%d",detElemId));
+ AliDebugStream(2) << "detElemId=" << detElemId << endl;;
AliMpExMap* mde = new AliMpExMap(true);
mde->SetOwner(kFALSE);
TObject* object = fMpSegmentations.Get(deName);
if ( object ) return (AliMpVSegmentation*)object;
- AliDebug(1,Form("Creating segmentation for detElemId=%d cath=%d",
- detElemId,cath));
+ AliDebugStream(3)
+ << "Creating segmentation for detElemId=" << detElemId
+ << " cath=" << cath << endl;
// Read mapping data and create segmentation
//
void DeleteSegmentations();
+ static Int_t NumberOfInstances() { return fgNumberOfInstances; }
+
private:
AliMpSegFactory(const AliMpSegFactory& rhs);
AliMpSegFactory& operator=(const AliMpSegFactory& rhs);
AliMpStringObjMap fMpSegmentations;///< Map of mapping segmentations to DE names
AliMpExMap* fMpMap; ///< Map of el. cards IDs to segmentations
+ static Int_t fgNumberOfInstances; ///< number of AliMpSegFactory objects...
+
ClassDef(AliMpSegFactory,0) // The factory for building mapping segmentations
};