#include <SharedResourcesRegistry.h>
Public Member Functions | |
SharedResourcesAcquirer | createAcquirer (std::vector< std::string > const &) const |
std::pair< SharedResourcesAcquirer, std::shared_ptr< std::recursive_mutex > > | createAcquirerForSourceDelayedReader () |
const SharedResourcesRegistry & | operator= (const SharedResourcesRegistry &)=delete |
void | registerSharedResource (const std::string &) |
A resource name must be registered before it can be used in the createAcquirer call. More... | |
SharedResourcesRegistry (const SharedResourcesRegistry &)=delete | |
Static Public Member Functions | |
static SharedResourcesRegistry * | instance () |
Static Public Attributes | |
static const std::string | kLegacyModuleResourceName {"__legacy__"} |
All legacy modules share this resource. More... | |
Private Member Functions | |
SharedResourcesRegistry () | |
~SharedResourcesRegistry ()=default | |
Private Attributes | |
unsigned int | nLegacy_ |
edm::propagate_const< std::shared_ptr< SerialTaskQueue > > | queueForDelayedReader_ |
edm::propagate_const< std::shared_ptr< std::recursive_mutex > > | resourceForDelayedReader_ |
std::map< std::string, std::pair< std::shared_ptr< SerialTaskQueue >, unsigned int > > | resourceMap_ |
Friends | |
class | ::testSharedResourcesRegistry |
Definition at line 39 of file SharedResourcesRegistry.h.
|
delete |
|
private |
Definition at line 30 of file SharedResourcesRegistry.cc.
|
privatedefault |
SharedResourcesAcquirer SharedResourcesRegistry::createAcquirer | ( | std::vector< std::string > const & | resourceNames | ) | const |
Definition at line 75 of file SharedResourcesRegistry.cc.
References cms::cuda::assert(), spr::find(), kLegacyModuleResourceName, eostools::move(), Skims_PA_cff::name, and resourceMap_.
Referenced by edm::one::impl::SharedResourcesUser< T >::createAcquirer().
std::pair< SharedResourcesAcquirer, std::shared_ptr< std::recursive_mutex > > SharedResourcesRegistry::createAcquirerForSourceDelayedReader | ( | ) |
Definition at line 64 of file SharedResourcesRegistry.cc.
References edm::get_underlying(), eostools::move(), queueForDelayedReader_, and resourceForDelayedReader_.
Referenced by edm::DelayedReaderThrowingSource::DelayedReaderThrowingSource(), edm::PoolSource::PoolSource(), and edm::RootDelayedReader::RootDelayedReader().
|
static |
Definition at line 25 of file SharedResourcesRegistry.cc.
Referenced by edm::one::impl::SharedResourcesUser< T >::createAcquirer(), edm::DelayedReaderThrowingSource::DelayedReaderThrowingSource(), edm::PoolSource::PoolSource(), edm::RootDelayedReader::RootDelayedReader(), edm::ESProducer::updateLookup(), edm::one::impl::SharedResourcesUser< T >::usesResource(), and edm::ESProducer::usesResources().
|
delete |
void SharedResourcesRegistry::registerSharedResource | ( | const std::string & | resourceName | ) |
A resource name must be registered before it can be used in the createAcquirer call.
Definition at line 32 of file SharedResourcesRegistry.cc.
References kLegacyModuleResourceName, nLegacy_, resourceMap_, and mitigatedMETSequence_cff::U.
Referenced by edm::one::impl::SharedResourcesUser< T >::usesResource().
|
friend |
Definition at line 42 of file SharedResourcesRegistry.h.
|
static |
All legacy modules share this resource.
Definition at line 56 of file SharedResourcesRegistry.h.
Referenced by createAcquirer(), registerSharedResource(), and edm::one::impl::SharedResourcesUser< T >::usesResource().
|
private |
Definition at line 80 of file SharedResourcesRegistry.h.
Referenced by registerSharedResource().
|
private |
Definition at line 78 of file SharedResourcesRegistry.h.
Referenced by createAcquirerForSourceDelayedReader().
|
private |
Definition at line 76 of file SharedResourcesRegistry.h.
Referenced by createAcquirerForSourceDelayedReader().
|
private |
Definition at line 74 of file SharedResourcesRegistry.h.
Referenced by createAcquirer(), and registerSharedResource().