Flair
Framework Libre Air
IODataElement.h
Go to the documentation of this file.
1 // %flair:license{
2 // This file is part of the Flair framework distributed under the
3 // CECILL-C License, Version 1.0.
4 // %flair:license}
13 #ifndef IODATAELEMENT_H
14 #define IODATAELEMENT_H
15 
16 #include "io_data.h"
17 
18 namespace flair {
19 namespace core {
20 
21 class DataType;
22 
27 class IODataElement : public Object {
28 public:
35  IODataElement(const io_data *parent, std::string name)
36  : Object(parent, name) {
37  this->parent = parent;
38  }
39  size_t Size() const { return size; }
40 
41  virtual void CopyData(char *dst) const = 0;
42 
48  virtual DataType const &GetDataType(void) const = 0;
49 
50 protected:
51  size_t size;
52 
53 private:
54  const io_data *parent;
55 };
56 
57 } // end namespace core
58 } // end namespace flair
59 
60 #endif // IODATAELEMENT_H
Abstract class for data types.
Definition: io_data.h:94
IODataElement(const io_data *parent, std::string name)
Constructor.
Definition: IODataElement.h:35
Base class for all Framework's classes.
Definition: Object.h:83
namespace of the flair Framework
Definition: Ahrs.h:19
Abstract class for data types.
virtual DataType const & GetDataType(void) const =0
DataType.
Abstract class for accessing an element of an io_data.
Definition: IODataElement.h:27