110 catch (std::bad_alloc
const&) {
124 catch (std::out_of_range
const&) {
151 std::vector<int> intData(5, 0);
154 for (
unsigned int i = 0; i < 10; ++i) {
158 intTotal += intData.at(i);
170 using OneMebibyte = std::array<unsigned char, 1048576U>;
172 std::vector<OneMebibyte> manyMebibytes;
175 mf::LogVerbatim(
"Exploder") <<
"Now allocating: " << manyMebibytes.max_size() <<
" x " 176 <<
sizeof(OneMebibyte) <<
" bytes";
177 manyMebibytes.resize(manyMebibytes.max_size());
MaybeLogger_< ELseverityLevel::ELsev_info, true > LogVerbatim
Exploder(Parameters const &config)
Constructor.
static unsigned int throwOutOfRange()
Throws a std::length_error exception.
fhicl::Atom< bool > ManageArtException
fhicl::Atom< bool > ManageBadAlloc
virtual void analyze(art::Event const &) override
Executes the iterations.
EDAnalyzer(fhicl::ParameterSet const &pset)
#define DEFINE_ART_MODULE(klass)
static void throwBadAlloc()
Throws a std::out_of_range exception.
cet::coded_exception< errors::ErrorCodes, ExceptionDetail::translate > Exception
LArSoft-specific namespace.
fhicl::Atom< bool > ManageOutOfRange
static void throwArtException()
Throws a std::out_of_range exception.