BOSS
7.1.2
BESIII Offline Software System
Loading...
Searching...
No Matches
DistBoss/RootFile/RootFile-00-00-05/test/test.cxx
Go to the documentation of this file.
1
#include "
RootFile/RootFileWriter.h
"
2
#include <fstream>
3
#include <stdlib.h>
4
5
int
main
(
int
argc,
char
* argv[])
6
{
7
if
( argc != 2 ) {
8
std::cout <<
"Usage: "
<< argv[0] <<
" input.file"
<< std::endl;
9
exit(0);
10
}
11
12
char
buf[512*1024];
13
std::ifstream ifs(argv[1], std::ios::binary);
14
ifs.read(buf, 512*1024);
15
16
RootFileWriter
writer(
"test_out.root"
);
17
writer.
writeEvent
((
void
*)buf, ifs.gcount());
18
19
writer.
close
();
20
21
return
0;
22
}
RootFileWriter.h
RootFileWriter
Definition
RootFileWriter.h:12
RootFileWriter::close
int close()
Definition
RootFileWriter.cxx:92
RootFileWriter::writeEvent
int writeEvent(void *pevt, int size)
Definition
RootFileWriter.cxx:35
main
int main()
Definition
test_IFile.cxx:11
7.1.2
DistBoss
RootFile
RootFile-00-00-05
test
test.cxx
Generated by
1.12.0