CMS 3D CMS Logo

FEDRawData.h
Go to the documentation of this file.
1 #ifndef FEDRawData_FEDRawData_h
2 #define FEDRawData_FEDRawData_h
3 
16 #include <vector>
17 #include <cstddef>
18 
19 class FEDRawData {
20 public:
21  typedef std::vector<unsigned char> Data;
22  typedef Data::iterator iterator;
23 
25  FEDRawData();
26 
30  FEDRawData(size_t newsize, size_t wordsize = 8);
31 
33  FEDRawData(const FEDRawData &);
34 
36  FEDRawData &operator=(const FEDRawData &) = default;
37 
39  ~FEDRawData();
40 
42  const unsigned char *data() const;
43 
45  unsigned char *data();
46 
48  size_t size() const { return data_.size(); }
49 
52  void resize(size_t newsize, size_t wordsize = 8);
53 
54 private:
56 };
57 
58 #endif
size_t size() const
Lenght of the data buffer in bytes.
Definition: FEDRawData.h:48
FEDRawData()
Default ctor.
Definition: FEDRawData.cc:14
std::vector< unsigned char > Data
Definition: FEDRawData.h:21
Data data_
Definition: FEDRawData.h:55
void resize(size_t newsize, size_t wordsize=8)
Definition: FEDRawData.cc:28
FEDRawData & operator=(const FEDRawData &)=default
Assignment operator.
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.
Definition: FEDRawData.cc:24
~FEDRawData()
Dtor.
Definition: FEDRawData.cc:23
Data::iterator iterator
Definition: FEDRawData.h:22