PODIO
v00-16-03
An Event-Data-Model Toolkit for High Energy Physics Experiments
Loading...
Searching...
No Matches
read.cpp
Go to the documentation of this file.
1
#include "
podio/ROOTReader.h
"
2
#include "
read_test.h
"
3
4
int
main
() {
5
auto
reader =
podio::ROOTReader
();
6
try
{
7
reader.openFile(
"example.root"
);
8
}
catch
(
const
std::runtime_error& e) {
9
std::cout <<
"File could not be opened, aborting."
<< std::endl;
10
return
1;
11
}
12
13
if
(reader.currentFileVersion() != podio::version::build_version) {
14
return
1;
15
}
16
17
run_read_test
(reader);
18
19
// jump back and forth a bit
20
run_read_test_event
(reader, 10);
21
run_read_test_event
(reader, 150);
22
run_read_test_event
(reader, 120);
23
run_read_test_event
(reader, 0);
24
25
reader.closeFile();
26
return
0;
27
}
ROOTReader.h
podio::ROOTReader
Definition:
ROOTReader.h:33
main
int main()
Definition:
read.cpp:4
read_test.h
run_read_test
void run_read_test(podio::IReader &reader)
Definition:
read_test.h:466
run_read_test_event
void run_read_test_event(podio::IReader &reader, unsigned event)
Definition:
read_test.h:497
podio-00-16-03
tests
read.cpp
Generated by
1.9.6