All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GeometryConfigurationInfo.cxx
Go to the documentation of this file.
1 /**
2  * @file larcoreobj/SummaryData/GeometryConfigurationInfo.cxx
3  * @brief Description of the current configuration of detector geometry.
4  * @author Gianluca Petrillo (petrillo@slac.stanford.edu)
5  * @date May 13, 2020
6  * @see larcoreobj/SummaryData/GeometryConfigurationInfo.h
7  *
8  * This is a header-only library.
9  */
10 
12 
13 // C/C++ standard library
14 #include <ostream>
15 
16 
17 // -----------------------------------------------------------------------------
18 std::ostream& sumdata::operator<<
19  (std::ostream& out, sumdata::GeometryConfigurationInfo const& info)
20 {
21 
22  if (!info.isDataValid())
23  return out << "Invalid geometry configuration information" << std::endl;
24 
25  out << "Geometry information version: " << info.dataVersion;
26 
28  {
29  out
30  << "\nDetector name: '" << info.detectorName << "'"
31  ;
32  } // version >= 1
33 
35  {
36  out
37  << "\nFull configuration:"
38  << "\n" << std::string(80, '-')
39  << "\n" << info.geometryServiceConfiguration
40  << "\n" << std::string(80, '-')
41  ;
42  }
43 
45  out
46  << "\n[this version of code can't fully decode further information]";
47  }
48 
49  return out;
50 } // sumdata::operator<< (GeometryConfigurationInfo const&)
51 
52 
53 // -----------------------------------------------------------------------------
Description of the current configuration of detector geometry.
unsigned int DataVersion_t
Type used for the version of data.
Description of the current configuration of detector geometry.