Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-03 08:20:41

0001 #ifndef __PRDFBUFFER_H
0002 #define __PRDFBUFFER_H
0003 
0004 #include "buffer.h"
0005 #include "phenixTypes.h"
0006 #include "BufferConstants.h"
0007 #include "Event.h"
0008 
0009 
0010 
0011 #ifndef __CINT__
0012 class WINDOWSEXPORT prdfBuffer : public buffer {
0013 #else
0014   class  prdfBuffer : public buffer  {
0015 #endif
0016 
0017 public:
0018 
0019   //** Constructors
0020 
0021   prdfBuffer();
0022   prdfBuffer( PHDWORD *array, const int length);
0023    ~prdfBuffer();
0024 
0025   //  this creates a new event on the next address
0026   Event * getEvent();
0027 
0028   int getBufferSequence() const; 
0029  
0030   int * getEventData();
0031 
0032   int isGood() const { return is_good; } ;
0033 
0034   int buffer_swap();
0035   int frame_swap(PHDWORD * fp, const int eventlength);
0036 
0037 protected:
0038   typedef struct 
0039   { 
0040     unsigned int Length;
0041     unsigned int ID;
0042     int Bufseq;
0043     int Runnr;
0044     PHDWORD data[1];
0045   } *buffer_ptr;
0046 
0047   buffer_ptr bptr;
0048   PHDWORD *data_ptr;
0049   int buffer_size;
0050   int max_length;
0051   int current_index;
0052   int is_good;
0053 };
0054 
0055 #endif