PhoenixPresentation  2.0.0
Set of cmake function to automate presentation generation
data_stream_include.h
Go to the documentation of this file.
1 /***************************************
2  Auteur : Pierre Aubert
3  Mail : pierre.aubert@lapp.in2p3.fr
4  Licence : CeCILL-C
5 ****************************************/
6 
7 #ifndef __DATA_STREAM_INCLUDE_H__
8 #define __DATA_STREAM_INCLUDE_H__
9 
10 #include <string.h>
11 #include <cstdint>
12 #include <string>
13 #include <map>
14 #include <vector>
15 #include <list>
16 #include <iostream>
17 
18 namespace DataStreamMode{
22  WRITE
23  };
24 }
25 
26 typedef uint8_t DataStreamType;
27 typedef std::vector<DataStreamType> DataStreamMsg;
29 
31 template<typename Stream, DataStreamMode::DataStreamMode Mode, typename T>
32 struct DataStream{
34 
37  static bool data_stream(Stream & ds, T & data){
38  return false;
39  }
41 
45  static bool data_stream(size_t & ds, T * data, size_t nbElement){
46  return false;
47  }
48 };
49 
50 #include "data_stream_file_simple_type.h"
51 
52 #endif
53 
54 
55 
56 
std::vector< DataStreamType > DataStreamMsg
uint8_t DataStreamType
DataStreamType * DataStreamIter
Generic DataStream class.
static bool data_stream(size_t &ds, T *data, size_t nbElement)
Dummy function to catch if a type is not specialised.
static bool data_stream(Stream &ds, T &data)
Dummy function to catch if a type is not specialised.