FWCore
Utilities
src
ConvertException.cc
Go to the documentation of this file.
1
#include "
FWCore/Utilities/interface/ConvertException.h
"
2
#include "
FWCore/Utilities/interface/EDMException.h
"
3
4
#include <iostream>
5
6
namespace
edm
{
7
8
void
convertException::badAllocToEDM
() {
9
std::cerr
<<
"\nstd::bad_alloc exception"
<< std::endl;
10
edm::Exception
e
(
edm::errors::BadAlloc
);
11
e
<<
"A std::bad_alloc exception was thrown.\n"
12
<<
"The job has probably exhausted the virtual memory available to the process.\n"
;
13
throw
e
;
14
}
15
16
void
convertException::stdToEDM
(
std::exception
const
&
e
) {
17
edm::Exception
ex(
edm::errors::StdException
);
18
ex <<
"A std::exception was thrown.\n"
<<
e
.what();
19
throw
ex;
20
}
21
22
void
convertException::stringToEDM
(
std::string
&
s
) {
23
edm::Exception
e
(
edm::errors::BadExceptionType
);
24
e
<<
"A std::string was thrown as an exception.\n"
<<
s
;
25
throw
e
;
26
}
27
28
void
convertException::charPtrToEDM
(
char
const
*
c
) {
29
edm::Exception
e
(
edm::errors::BadExceptionType
);
30
e
<<
"A const char* was thrown as an exception.\n"
<<
c
;
31
throw
e
;
32
}
33
34
void
convertException::unknownToEDM
() {
35
edm::Exception
e
(
edm::errors::Unknown
);
36
e
<<
"An exception of unknown type was thrown.\n"
;
37
throw
e
;
38
}
39
}
// namespace edm
edm
HLT enums.
Definition:
AlignableModifier.h:19
edm::convertException::charPtrToEDM
void charPtrToEDM(char const *c)
Definition:
ConvertException.cc:28
edm::errors::Unknown
Definition:
EDMException.h:29
edm::convertException::unknownToEDM
void unknownToEDM()
Definition:
ConvertException.cc:34
edm::errors::BadExceptionType
Definition:
EDMException.h:31
edm::Exception
Definition:
EDMException.h:77
EDMException.h
alignCSCRings.s
s
Definition:
alignCSCRings.py:92
ConvertException.h
edm::convertException::stringToEDM
void stringToEDM(std::string &s)
Definition:
ConvertException.cc:22
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::convertException::stdToEDM
void stdToEDM(std::exception const &e)
Definition:
ConvertException.cc:16
cppFunctionSkipper.exception
exception
Definition:
cppFunctionSkipper.py:10
edm::convertException::badAllocToEDM
void badAllocToEDM()
Definition:
ConvertException.cc:8
edm::errors::StdException
Definition:
EDMException.h:28
HltBtagPostValidation_cff.c
c
Definition:
HltBtagPostValidation_cff.py:31
edm::errors::BadAlloc
Definition:
EDMException.h:30
EcnaPython_AdcPeg12_S1_10_R170298_1_0_150_Dee0.cerr
cerr
Definition:
EcnaPython_AdcPeg12_S1_10_R170298_1_0_150_Dee0.py:8
MillePedeFileConverter_cfg.e
e
Definition:
MillePedeFileConverter_cfg.py:37
Generated for CMSSW Reference Manual by
1.8.16