CMS 3D CMS Logo

Public Types | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes

edm::eventsetup::DataProxyProvider Class Reference

#include <DataProxyProvider.h>

Inheritance diagram for edm::eventsetup::DataProxyProvider:
CondDBESSource edm::ESProxyFactoryProducer FWLiteESSource PoolDBESSource edm::ESProducer AnalyticalPropagatorESProducer BeamHaloPropagatorESProducer BeamSpotFakeConditions BtagPerformanceESProducer CaloGeometryBuilder CaloGeometryDBEP< T, U > CaloGeometryEP< T > CaloMiscalibTools CaloMiscalibToolsMC CaloTopologyBuilder CaloTowerConstituentsMapBuilder CaloTowerHardcodeGeometryEP CaloTPGTranscoderULUTs CastorDbProducer CastorHardcodeCalibrations CastorHardcodeGeometryEP CastorTextCalibrations Chi2MeasurementEstimatorESProducer CkfDebugTrajectoryBuilderESProducer CkfTrajectoryBuilderESProducer CloseComponentsMergerESProducer< N > ClusterShapeHitFilterESProducer ClusterShapeTrajectoryFilterESProducer CompositeTrajectoryFilterESProducer CosmicParametersDefinerForTPESProducer CSCBadChambersConditions CSCBadStripsConditions CSCBadWiresConditions CSCChamberIndexValues CSCChamberMapValues CSCChamberTimeCorrectionsValues CSCChipSpeedCorrectionDBConditions CSCCrateMapValues CSCCrosstalkConditions CSCCrosstalkDBConditions CSCDBL1TPParametersConditions CSCDDUMapValues CSCFakeCrosstalkConditions CSCFakeDBCrosstalk CSCFakeDBCrosstalkPopCon CSCFakeDBGains CSCFakeDBGainsPopCon CSCFakeDBNoiseMatrix CSCFakeDBPedestals CSCFakeGainsConditions CSCFakeNoiseMatrixConditions CSCFakePedestalsConditions CSCGainsConditions CSCGainsDBConditions CSCGeometryESModule CSCL1TPParametersConditions CSCNoiseMatrixConditions CSCNoiseMatrixDBConditions CSCPedestalsDBConditions CSCTFConfigProducer DetIdAssociatorESProducer DetLayerGeometryESProducer DistanceBetweenComponentsESProducer< N > DTConfigDBProducer DTConfigTrivialProducer DTFakeT0ESProducer DTFakeTTrigESProducer DTFakeVDriftESProducer DTGeometryESModule DTTrackFinderConfig EcalElectronicsMappingBuilder EcalGlobalShowerContainmentCorrectionsVsEtaESProducer EcalLaserCorrectionService EcalRegionCablingESProducer EcalSeverityLevelESProducer EcalShowerContainmentCorrectionsESProducer EcalTBGeometryBuilder EcalTBHodoscopeGeometryEP EcalTrigPrimESProducer EcalTrigTowerConstituentsMapBuilder EcalTrivialConditionRetriever EcalUnpackerWorkerESProducer edm::ESProducerLooper ElectronLikelihoodESSource ESTrivialConditionRetriever ESUnpackerWorkerESProducer FakeAlignmentProducer FakeAlignmentSource FakeCaloAlignmentEP FastPixelCPEESProducer FastStripCPEESProducer FWRecoGeometryESProducer GeantPropagatorESProducer GlobalDetLayerGeometryESProducer GlobalTrackingGeometryESProducer GroupedCkfTrajectoryBuilderESProducer GsfMaterialEffectsESProducer GsfTrajectoryFitterESProducer GsfTrajectorySmootherESProducer HcalAlignmentEP HcalDbProducer HcalDDDGeometryEP HcalHardcodeCalibrations HcalHardcodeGeometryEP HcalOmdsCalibrations HcalRecAlgoESProducer HcalTextCalibrations HcalTopologyIdealEP HcalTPGCoderULUT HepPDTESSource HiTrivialConditionRetriever JetCorrectionService< Corrector > JetCorrectionServiceChain JetTagComputerESProducer< ConcreteJetTagComputer > KFFittingSmootherESProducer KFSwitching1DUpdatorESProducer KFTrajectoryFitterESProducer KFTrajectorySmootherESProducer KFUpdatorESProducer L1CaloGeometryProd L1CaloInputScalesProducer L1ConfigOnlineProdBase< TRcd, TData > L1ConfigOnlineProdBase< L1CaloEcalScaleRcd, L1CaloEcalScale > L1ConfigOnlineProdBase< L1CaloHcalScaleRcd, L1CaloHcalScale > L1ConfigOnlineProdBase< L1EmEtScaleRcd, L1CaloEtScale > L1ConfigOnlineProdBase< L1GctChannelMaskRcd, L1GctChannelMask > L1ConfigOnlineProdBase< L1GctJetFinderParamsRcd, L1GctJetFinderParams > L1ConfigOnlineProdBase< L1GtParametersRcd, L1GtParameters > L1ConfigOnlineProdBase< L1GtPrescaleFactorsAlgoTrigRcd, L1GtPrescaleFactors > L1ConfigOnlineProdBase< L1GtPrescaleFactorsTechTrigRcd, L1GtPrescaleFactors > L1ConfigOnlineProdBase< L1GtPsbSetupRcd, L1GtPsbSetup > L1ConfigOnlineProdBase< L1GtTriggerMaskAlgoTrigRcd, L1GtTriggerMask > L1ConfigOnlineProdBase< L1GtTriggerMaskTechTrigRcd, L1GtTriggerMask > L1ConfigOnlineProdBase< L1GtTriggerMaskVetoTechTrigRcd, L1GtTriggerMask > L1ConfigOnlineProdBase< L1GtTriggerMenuRcd, L1GtTriggerMenu > L1ConfigOnlineProdBase< L1HfRingEtScaleRcd, L1CaloEtScale > L1ConfigOnlineProdBase< L1HtMissScaleRcd, L1CaloEtScale > L1ConfigOnlineProdBase< L1JetEtScaleRcd, L1CaloEtScale > L1ConfigOnlineProdBase< L1MuCSCPtLutRcd, L1MuCSCPtLut > L1ConfigOnlineProdBase< L1MuCSCTFAlignmentRcd, L1MuCSCTFAlignment > L1ConfigOnlineProdBase< L1MuCSCTFConfigurationRcd, L1MuCSCTFConfiguration > L1ConfigOnlineProdBase< L1MuDTEtaPatternLutRcd, L1MuDTEtaPatternLut > L1ConfigOnlineProdBase< L1MuDTExtLutRcd, L1MuDTExtLut > L1ConfigOnlineProdBase< L1MuDTPhiLutRcd, L1MuDTPhiLut > L1ConfigOnlineProdBase< L1MuDTPtaLutRcd, L1MuDTPtaLut > L1ConfigOnlineProdBase< L1MuDTQualPatternLutRcd, L1MuDTQualPatternLut > L1ConfigOnlineProdBase< L1MuDTTFMasksRcd, L1MuDTTFMasks > L1ConfigOnlineProdBase< L1MuDTTFParametersRcd, L1MuDTTFParameters > L1ConfigOnlineProdBase< L1MuGMTChannelMaskRcd, L1MuGMTChannelMask > L1ConfigOnlineProdBase< L1MuGMTParametersRcd, L1MuGMTParameters > L1ConfigOnlineProdBase< L1MuTriggerPtScaleRcd, L1MuTriggerPtScale > L1ConfigOnlineProdBase< L1MuTriggerScalesRcd, L1MuTriggerScales > L1ConfigOnlineProdBase< L1RCTChannelMaskRcd, L1RCTChannelMask > L1ConfigOnlineProdBase< L1RCTParametersRcd, L1RCTParameters > L1ConfigOnlineProdBase< L1RPCBxOrConfigRcd, L1RPCBxOrConfig > L1ConfigOnlineProdBase< L1RPCConeDefinitionRcd, L1RPCConeDefinition > L1ConfigOnlineProdBase< L1RPCConfigRcd, L1RPCConfig > L1ConfigOnlineProdBase< L1RPCHsbConfigRcd, L1RPCHsbConfig > L1CSCTriggerPrimitivesConfigProducer L1GctConfigProducers L1GtBoardMapsTrivialProducer L1GtParametersTrivialProducer L1GtPrescaleFactorsAlgoTrigTrivialProducer L1GtPrescaleFactorsTechTrigTrivialProducer L1GtPsbSetupTrivialProducer L1GtStableParametersTrivialProducer L1GtTriggerMaskAlgoTrigTrivialProducer L1GtTriggerMaskTechTrigTrivialProducer L1GtTriggerMaskVetoAlgoTrigTrivialProducer L1GtTriggerMaskVetoTechTrigTrivialProducer L1GtTriggerMenuXmlProducer L1MuGMTParametersProducer L1MuGMTScalesProducer L1MuTriggerPtScaleProducer L1MuTriggerScalesProducer L1ObjectKeysOnlineProdBase L1RPCConeDefinitionProducer L1ScalesTrivialProducer L1SubsystemKeysOnlineProd L1TriggerKeyDummyProd L1TriggerKeyListDummyProd L1TriggerKeyOnlineProd magneticfield::AutoMagneticFieldESProducer magneticfield::ParametrizedMagneticFieldProducer magneticfield::UniformMagneticFieldESProducer magneticfield::VolumeBasedMagneticFieldESProducer MagneticFieldMapESProducer MeasurementTrackerESProducer MisalignedMuonESProducer MisalignedTrackerESProducer MRHChi2MeasurementEstimatorESProducer MultiRecHitCollectorESProducer MultiTrackFilterCollectorESProducer MuonAssociatorESProducer MuonCkfTrajectoryBuilderESProducer MuonDetLayerGeometryESProducer MuonNumberingInitialization MuonRoadTrajectoryBuilderESProducer MuonTransientTrackingRecHitBuilderESProducer NavigationSchoolESProducer ParametersDefinerForTPESProducer PhysicsTools::MVAComputerESSourceBase PixelCPEGenericESProducer PixelCPETemplateRecoESProducer PixelToFEDAssociateFromAsciiESProducer PixelToLNKAssociateFromAsciiESProducer prodname PropagatorWithMaterialESProducer RCTConfigProducers RingESSource RingMakerESProducer RoadMapESSource RoadMapMakerESProducer RPCConeBuilder RPCGeometryESModule RPCPerformanceESSource RPCTriggerBxOrConfig RPCTriggerConfig RPCTriggerHsbConfig RPCTriggerHwConfig SeedingLayersESProducer SiPixelFakeCPEGenericErrorParmESSource SiPixelFakeGainESSource SiPixelFakeGainForHLTESSource SiPixelFakeGainOfflineESSource SiPixelFakeLorentzAngleESSource SiPixelFakeQualityESSource SiPixelFakeTemplateDBObjectESSource SiPixelTemplateDBObjectESProducer sistrip::MeasureLA SiStripConnectivity SiStripDelayESProducer SiStripFedCablingESProducer SiStripGainESProducerTemplate< TDependentRecord, TInputRecord > SiStripGainESSource SiStripHashedDetIdESProducer SiStripHashedDetIdESProducer SiStripNoiseESSource SiStripPedestalsESSource SiStripQualityESProducer SiStripQualityFakeESSource SiStripRecHitMatcherESProducer SiStripRegionConnectivity SiStripTemplateEmptyFakeESSource< TObject, TRecord > SiStripTemplateFakeESSource< TObject, TRecord, TService > SiTrackerMultiRecHitUpdatorESProducer SiTrackerMultiRecHitUpdatorMTFESProducer SmartPropagatorESProducer SteppingHelixPropagatorESProducer StraightLinePropagatorESProducer StringResolutionProviderESProducer StripCPEESProducer TestCaloAlignmentEP TGeoMgrFromDdd TkTransientTrackingRecHitBuilderESProducer TrackerDigiGeometryESModule TrackerGeometricDetESModule TrackerGeometricDetExtraESModule TrackerInteractionGeometryESProducer TrackerRecoGeometryESProducer TrackingRecHitPropagatorESProducer TrajectoryCleanerESProducer TrajectoryFilterESProducer TransientTrackBuilderESProducer TSCBLBuilderNoMaterialESProducer TSCBLBuilderWithPropagatorESProducer XMLIdealGeometryESProducer XMLIdealGeometryESSource ZdcHardcodeGeometryEP

List of all members.

Public Types

typedef std::vector< std::pair
< DataKey, boost::shared_ptr
< DataProxy > > > 
KeyedProxies
typedef std::vector
< EventSetupRecordKey
Keys
typedef std::map
< EventSetupRecordKey,
KeyedProxies
RecordProxies

Public Member Functions

 DataProxyProvider ()
const ComponentDescriptiondescription () const
bool isUsingRecord (const EventSetupRecordKey &) const
const KeyedProxieskeyedProxies (const EventSetupRecordKey &iRecordKey) const
virtual void newInterval (const EventSetupRecordKey &iRecordType, const ValidityInterval &iInterval)=0
 called when a new interval of validity occurs for iRecordType
void resetProxies (const EventSetupRecordKey &iRecordType)
void resetProxiesIfTransient (const EventSetupRecordKey &iRecordType)
void setAppendToDataLabel (const edm::ParameterSet &)
void setDescription (const ComponentDescription &iDescription)
std::set< EventSetupRecordKeyusingRecords () const
virtual ~DataProxyProvider ()

Protected Member Functions

void eraseAll (const EventSetupRecordKey &iRecordKey)
 deletes all the Proxies in aStream
void invalidateProxies (const EventSetupRecordKey &iRecordKey)
virtual void registerProxies (const EventSetupRecordKey &iRecordKey, KeyedProxies &aProxyList)=0
template<class T >
void usingRecord ()
void usingRecordWithKey (const EventSetupRecordKey &)

Private Member Functions

 DataProxyProvider (const DataProxyProvider &)
const DataProxyProvideroperator= (const DataProxyProvider &)

Private Attributes

std::string appendToDataLabel_
ComponentDescription description_
RecordProxies recordProxies_

Detailed Description

Definition at line 41 of file DataProxyProvider.h.


Member Typedef Documentation

typedef std::vector<std::pair<DataKey, boost::shared_ptr<DataProxy> > > edm::eventsetup::DataProxyProvider::KeyedProxies

Definition at line 47 of file DataProxyProvider.h.

Definition at line 45 of file DataProxyProvider.h.

Definition at line 48 of file DataProxyProvider.h.


Constructor & Destructor Documentation

DataProxyProvider::DataProxyProvider ( )

Definition at line 33 of file DataProxyProvider.cc.

DataProxyProvider::~DataProxyProvider ( ) [virtual]

Definition at line 42 of file DataProxyProvider.cc.

{
}
edm::eventsetup::DataProxyProvider::DataProxyProvider ( const DataProxyProvider ) [private]

Member Function Documentation

const ComponentDescription& edm::eventsetup::DataProxyProvider::description ( ) const [inline]
void edm::eventsetup::DataProxyProvider::eraseAll ( const EventSetupRecordKey iRecordKey) [protected]

deletes all the Proxies in aStream

void DataProxyProvider::invalidateProxies ( const EventSetupRecordKey iRecordKey) [protected]

Definition at line 69 of file DataProxyProvider.cc.

References recordProxies_.

Referenced by FWLiteESSource::newInterval(), edm::ESProxyFactoryProducer::newInterval(), CondDBESSource::newInterval(), and resetProxies().

{
   KeyedProxies& proxyList((*(recordProxies_.find(iRecordKey))).second) ;
   KeyedProxies::iterator finished(proxyList.end()) ;
   for (KeyedProxies::iterator keyedProxy(proxyList.begin()) ;
         keyedProxy != finished ;
         ++keyedProxy) {
      (*((*keyedProxy).second)).invalidate() ;
   }
   
}
bool DataProxyProvider::isUsingRecord ( const EventSetupRecordKey iKey) const

Definition at line 116 of file DataProxyProvider.cc.

References recordProxies_.

{
   return recordProxies_.end() != recordProxies_.find(iKey);
}
const DataProxyProvider::KeyedProxies & DataProxyProvider::keyedProxies ( const EventSetupRecordKey iRecordKey) const

Definition at line 136 of file DataProxyProvider.cc.

References appendToDataLabel_, description(), recordProxies_, registerProxies(), edm::eventsetup::swap(), and cond::rpcobtemp::temp.

{
   RecordProxies::const_iterator itFind = recordProxies_.find(iRecordKey);
   assert(itFind != recordProxies_.end());
   
   if(itFind->second.empty()) {
      //delayed registration
      KeyedProxies& proxies = const_cast<KeyedProxies&>(itFind->second);
      const_cast<DataProxyProvider*>(this)->registerProxies(iRecordKey,
                                                            proxies);

      bool mustChangeLabels = (0 != appendToDataLabel_.size());
      for(KeyedProxies::iterator itProxy = proxies.begin(), itProxyEnd = proxies.end();
          itProxy != itProxyEnd;
          ++itProxy) {
        itProxy->second->setProviderDescription(&description());
        if( mustChangeLabels ) {
          //Using swap is fine since
          // 1) the data structure is not a map and so we have not sorted on the keys
          // 2) this is the first time filling this so no outside agency has yet seen
          //   the label and therefore can not be dependent upon its value
          std::string temp(std::string(itProxy->first.name().value())+appendToDataLabel_);
          DataKey newKey(itProxy->first.type(),temp.c_str());
          swap(itProxy->first,newKey);
        }
      }
   }
   
   return itFind->second;
}
virtual void edm::eventsetup::DataProxyProvider::newInterval ( const EventSetupRecordKey iRecordType,
const ValidityInterval iInterval 
) [pure virtual]

called when a new interval of validity occurs for iRecordType

Implemented in CondDBESSource, edm::ESProxyFactoryProducer, and FWLiteESSource.

const DataProxyProvider& edm::eventsetup::DataProxyProvider::operator= ( const DataProxyProvider ) [private]
virtual void edm::eventsetup::DataProxyProvider::registerProxies ( const EventSetupRecordKey iRecordKey,
KeyedProxies aProxyList 
) [protected, pure virtual]
void DataProxyProvider::resetProxies ( const EventSetupRecordKey iRecordType)

Definition at line 82 of file DataProxyProvider.cc.

References invalidateProxies().

Referenced by edm::eventsetup::EventSetupRecordProvider::resetProxies().

{
  invalidateProxies(iRecordKey);
}
void DataProxyProvider::resetProxiesIfTransient ( const EventSetupRecordKey iRecordType)

Definition at line 88 of file DataProxyProvider.cc.

References recordProxies_.

Referenced by edm::eventsetup::EventSetupRecordProvider::resetProxies(), and edm::eventsetup::EventSetupRecordProvider::resetTransients().

{
   KeyedProxies& proxyList((*(recordProxies_.find(iRecordKey))).second) ;
   KeyedProxies::iterator finished(proxyList.end()) ;
   for (KeyedProxies::iterator keyedProxy(proxyList.begin()) ;
        keyedProxy != finished ;
        ++keyedProxy) {
      (*((*keyedProxy).second)).resetIfTransient() ;
   }
   
}
void DataProxyProvider::setAppendToDataLabel ( const edm::ParameterSet iToAppend)

This method is only to be called by the framework, it sets the string which will be appended to the labels of all data products being produced

Definition at line 101 of file DataProxyProvider.cc.

References appendToDataLabel_, edm::ParameterSet::exists(), and edm::ParameterSet::getParameter().

Referenced by edm::eventsetup::ComponentMaker< edm::eventsetup::LooperMakerTraits, TType >::setPostConstruction().

{
  std::string oldValue( appendToDataLabel_);
  //this can only be changed once and the default value is the empty string
  assert(0 == oldValue.size());
  
  const std::string kParamName("appendToDataLabel");
  if(iToAppend.exists(kParamName) ) {    
    appendToDataLabel_ = iToAppend.getParameter<std::string>(kParamName);
  }
}
void edm::eventsetup::DataProxyProvider::setDescription ( const ComponentDescription iDescription) [inline]
template<class T >
void edm::eventsetup::DataProxyProvider::usingRecord ( ) [inline, protected]

Definition at line 83 of file DataProxyProvider.h.

References usingRecordWithKey().

                         {
         usingRecordWithKey(EventSetupRecordKey::makeKey<T>());
      }
std::set< EventSetupRecordKey > DataProxyProvider::usingRecords ( ) const

Definition at line 122 of file DataProxyProvider.cc.

References recordProxies_.

{
   std::set<EventSetupRecordKey> returnValue;
   for(RecordProxies::const_iterator itRecProxies = recordProxies_.begin(),
        itRecProxiesEnd = recordProxies_.end();
        itRecProxies != itRecProxiesEnd;
        ++itRecProxies) {
      returnValue.insert(returnValue.end(), itRecProxies->first);
   }
   //copy_all(keys_, std::inserter(returnValue, returnValue.end()));
   return returnValue;
}   
void DataProxyProvider::usingRecordWithKey ( const EventSetupRecordKey iKey) [protected]

Definition at line 62 of file DataProxyProvider.cc.

References recordProxies_.

Referenced by CondDBESSource::CondDBESSource(), FWLiteESSource::delaySettingRecords(), and usingRecord().

{
   recordProxies_[iKey];
   //keys_.push_back(iKey);
}

Member Data Documentation

Definition at line 105 of file DataProxyProvider.h.

Referenced by keyedProxies(), and setAppendToDataLabel().

Definition at line 104 of file DataProxyProvider.h.

Referenced by description(), and setDescription().