![]() |
|
|||
File indexing completed on 2024-04-06 12:12:04
0001 #ifndef FWCore_Framework_ModuleTypeResolverMaker_h 0002 #define FWCore_Framework_ModuleTypeResolverMaker_h 0003 0004 #include "FWCore/Framework/interface/ModuleTypeResolverBase.h" 0005 0006 namespace edm { 0007 class ParameterSet; 0008 0009 /** 0010 * This class hierarchy implements an abstract factory pattern for 0011 * the creation of module type resolver objects (derived from 0012 * ModuleTypeResolverBase). This pattern allows the use of 0013 * information in the module PSet in the module type resolver in a 0014 * way that the PSet is parsed only once per module instance. 0015 * 0016 * Per-module setting is useful e.g. in the Alpaka use case to be 0017 * able to set the Alpaka backend separately for each module. This 0018 * ability is useful to have e.g. automatically-selected modules and 0019 * modules set to explicitly use a host backend in the same job for 0020 * physics comparisons, or for testing. 0021 * 0022 * A derived class of this abstract base class is meant to be owned 0023 * by the EventProcessor (or equivalent). The concrete object can be 0024 * created with a plugin factory (in case of EventProcessor the 0025 * plugin name comes from the configuration). The class provides a 0026 * factory function to create a concrete ModuleTypeResolverBase 0027 * object based on the module PSet. 0028 */ 0029 class ModuleTypeResolverMaker { 0030 public: 0031 virtual ~ModuleTypeResolverMaker() = default; 0032 0033 /** 0034 * This function creates an implementation of the ModuleTypeResolverBase class based on the module PSet. 0035 * 0036 * The return value reflects that the implementation 0037 * ModuleTypeResolverMaker may cache the ModuleTypeResolverBase objects if it 0038 * wants to. 0039 */ 0040 virtual std::shared_ptr<ModuleTypeResolverBase const> makeResolver(edm::ParameterSet const& modulePSet) const = 0; 0041 }; 0042 } // namespace edm 0043 0044 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.2.1 LXR engine. The LXR team |
![]() ![]() |