Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
garsoft
SummaryDataProducts
RunData.cxx
Go to the documentation of this file.
1
////////////////////////////////////////////////////////////////////////
2
/// \file RunData.cxx
3
///
4
/// Definition of object to store run related information
5
///
6
/// \version $Id: RunData.cxx,v 1.1.1.1 2011/03/03 00:19:49 brebel Exp $
7
/// \author brebel@fnal.gov
8
////////////////////////////////////////////////////////////////////////
9
10
#include "
SummaryDataProducts/RunData.h
"
11
#include <stdexcept>
// std::runtime_error
12
13
namespace
gar
{
14
namespace
sumdata
{
15
16
//---------------------------------------------------------
17
RunData::RunData
()
18
: fDetName(
"nodetectorname"
)
19
{
20
}
21
22
//---------------------------------------------------------
23
RunData::RunData
(
std::string
const
& detectorName)
24
:
fDetName
(detectorName)
25
{
26
}
27
28
//---------------------------------------------------------
29
void
RunData::aggregate
(
RunData
const
&
other
) {
30
31
// Each run is required to have the same detector name.
32
// This might be a problem for Monte Carlo jobs which tend to use the same
33
// run number for everything.
34
if
(other.
DetName
() !=
DetName
()) {
35
throw
std::runtime_error(
"The same run sees different detector setups: '"
36
+
DetName
() +
"' and '"
+ other.
DetName
()
37
);
38
}
39
}
// RunData::aggregate()
40
41
}
42
}
gar::sumdata::RunData::RunData
RunData()
Definition:
RunData.cxx:17
gar::sumdata::RunData::DetName
std::string const & DetName() const
Definition:
RunData.h:41
string
std::string string
Definition:
nybbler.cc:12
gar::sumdata::RunData::aggregate
void aggregate(RunData const &other)
Definition:
RunData.cxx:29
gar::sumdata::RunData::fDetName
std::string fDetName
detector name
Definition:
RunData.h:26
RunData.h
fhicl::other
Definition:
exception.h:26
gar
General GArSoft Utilities.
Definition:
anatest_module.cc:57
gar::sumdata::RunData
Definition:
RunData.h:17
sumdata
Definition:
GeometryConfigurationInfo.h:19
Generated by
1.8.11