28 NoProductErrorThrower(
const std::type_info& iType,
const char* iModule,
const char* iInstance,
const char* iProcess)
29 : type_(&iType),
module_(iModule), instance_(iInstance), process_(iProcess) {}
31 void throwIt()
const override {
34 <<
"A branch was found for \n type ='" <<
type.className() <<
"'\n module='" <<
module_
35 <<
"'\n productInstance='" << ((
nullptr != instance_) ? instance_ :
"") <<
"'\n process='"
36 << ((
nullptr != process_) ? process_ :
"")
38 "but no data is available for this Event";
43 const std::type_info* type_;
45 const char* instance_;
51 NoBranchErrorThrower(
const std::type_info& iType,
const char* iModule,
const char* iInstance,
const char* iProcess)
52 : type_(&iType),
module_(iModule), instance_(iInstance), process_(iProcess) {}
54 void throwIt()
const override {
57 <<
"No branch was found for \n type ='" <<
type.className() <<
"'\n module='" <<
module_
58 <<
"'\n productInstance='" << ((
nullptr != instance_) ? instance_ :
"") <<
"'\n process='"
59 << ((
nullptr != process_) ? process_ :
"") <<
"'";
65 const std::type_info* type_;
67 const char* instance_;
72 void throwIt()
const override {
throw cms::Exception(
"UnsetHandle") <<
"The fwlite::Handle was never set"; }
120 const char* iInstance,
121 const char* iProcess) {
122 return new NoBranchErrorThrower(iType, iModule, iInstance, iProcess);
127 const char* iInstance,
128 const char* iProcess) {
129 return new NoProductErrorThrower(iType, iModule, iInstance, iProcess);