Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-02 08:21:01

0001 #ifndef __DAQ_DEVICE_FILE__
0002 #define __DAQ_DEVICE_FILE__
0003 
0004 
0005 #include <daq_device.h>
0006 #include <stdio.h>
0007 #include <string>
0008 
0009 class daq_device_file: public  daq_device {
0010 
0011 
0012 public:
0013 
0014   daq_device_file (const int eventtype,
0015            const int subeventid, const char * fn,
0016            const int delete_flag = 0,
0017            const int maxlength = 4*1024);
0018 
0019 
0020 
0021   ~daq_device_file();
0022 
0023 
0024   void identify(std::ostream& os = std::cout) const;
0025 
0026   int max_length(const int etype) const;
0027 
0028   // functions to do the work
0029 
0030   int put_data(const int etype, int * adr, const int length);
0031 
0032 private:
0033   int m_eventType;
0034   int m_subeventid;
0035   std::string filename;
0036   int _maxlength;
0037   int _delete_flag;
0038 
0039 };
0040 
0041 
0042 #endif