#include <iostream>
#include <utility>
#include <cstdlib>
#include <string>
#include <set>
#include <boost/program_options.hpp>
#include "FWCore/PluginManager/interface/PluginManager.h"
#include "FWCore/PluginManager/interface/standard.h"
Go to the source code of this file.
|
int | main (int argc, char **argv) |
|
◆ main()
int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 15 of file dump.cc.
References dir2webdir::argc, GCPpyPlots::argv, edmplugin::PluginManager::categoryToInfos(), DMR_cfg::cerr, edmplugin::standard::config(), edmplugin::PluginManager::configure(), gather_cfg::cout, submitPVResolutionJobs::desc, relativeConstraints::error, cppFunctionSkipper::exception, edmplugin::PluginManager::get(), kHelpCommandOpt, kHelpOpt, AlcaSiPixelAliHarvester0T_cff::options, crabTemplate::pluginName, writedatasetfile::run, and AlCaHLTBitMon_QueryRunRegistry::string.
16 using namespace boost::program_options;
18 static const char*
const kFilesOpt =
"files";
19 static const char*
const kFilesCommandOpt =
"files,f";
20 static const char*
const kAllFilesOpt =
"all_files";
21 static const char*
const kAllFilesCommandOpt =
"all_files,a";
22 static const char*
const kHelpOpt =
"help";
26 descString +=
" [options]";
27 descString +=
"\nAllowed options";
28 options_description
desc(descString);
31 "list the file from which a plugin will come")(kAllFilesCommandOpt,
32 "list all the files to which a plugin is registered")
40 }
catch (
const error& iException) {
50 bool printFiles =
false;
51 if (vm.count(kFilesOpt)) {
55 bool printAllFiles =
false;
56 if (vm.count(kAllFilesOpt)) {
61 int returnValue = EXIT_SUCCESS;
70 for (CatToInfos::const_iterator it = catToInfos.begin(), itEnd = catToInfos.end(); it != itEnd; ++it) {
71 std::cout <<
"Category " << it->first <<
":" << std::endl;
73 for (edmplugin::PluginManager::Infos::const_iterator itInfo = it->second.begin(), itInfoEnd = it->second.end();
80 std::cout <<
" " << itInfo->loadable_.string() << std::endl;
83 }
else if (printAllFiles) {
84 std::cout <<
" " << itInfo->loadable_.string() << std::endl;
89 std::cerr <<
"Caught exception " << iException.what() << std::endl;
90 returnValue = EXIT_FAILURE;
const CategoryToInfos & categoryToInfos() const
std::map< std::string, Infos > CategoryToInfos
dictionary config
Read in AllInOne config in JSON format.
static const char *const kHelpCommandOpt
static const char *const kHelpOpt
static PluginManager * get()