Analysis Software
Documentation for
sPHENIX
simulation software
Home page
Related Pages
Modules
Namespaces
Classes
Files
Examples
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
prdfoStream.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file prdfoStream.h
1
#ifndef __PRDFOSTREAM_H
2
#define __PRDFOSTREAM_H
3
4
#include <EventTypes.h>
5
#include <
Event.h
>
6
#include <BufferConstants.h>
7
8
9
class
prdfoStream
{
10
11
public
:
12
13
//** Constructors
14
15
prdfoStream
(
const
char
*
filename
,
const
int
bufferlength = 4*1024*1024);
16
17
virtual
~prdfoStream
();
18
19
int
addEvent
(
Event
*);
20
21
int
is_defunct
()
const
{
return
defunct
; };
22
23
24
protected
:
25
26
// add an end-of-buffer
27
int
addEoB
();
28
29
// now the write routine
30
unsigned
int
writeout
();
31
32
int
prepare_next
(
const
int
iseq,
const
int
irun=0);
33
34
static
unsigned
int
writen
(
int
fd
,
char
*ptr,
const
unsigned
int
nbytes);
35
36
std::string
_filename
;
37
38
typedef
struct
39
{
40
int
Length
;
41
int
ID
;
42
int
Bufseq
;
43
int
Runnr
;
44
int
data
[1];
45
} *
buffer_ptr
;
46
47
int
has_buffer
;
48
int
buffer_sequence
;
49
50
buffer_ptr
bptr
;
51
int
*
data_ptr
;
52
int
current_index
;
53
int
max_length
;
54
int
max_size
;
55
int
left
;
56
int
has_end
;
57
58
int
fd
;
59
int
defunct
;
60
};
61
62
#endif
63
analysis
blob
master
TPC
groot
prdfoStream.h
Built by
Jin Huang
. updated:
Sat Feb 17 2024 22:17:58
using
1.8.2 with
sPHENIX GitHub integration