libpniio
vector_format.hpp
Go to the documentation of this file.
1 //
2 // (c) Copyright 2015 DESY, Eugen Wintersberger <eugen.wintersberger@desy.de>
3 //
4 // This file is part of libpniio.
5 //
6 // libpniio is free software: you can redistribute it and/or modify
7 // it under the terms of the GNU General Public License as published by
8 // the Free Software Foundation, either version 2 of the License, or
9 // (at your option) any later version.
10 //
11 // libpniio is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with libpniio. If not, see <http://www.gnu.org/licenses/>.
18 // ===========================================================================
19 //
20 // Created on: Sep 08, 2015
21 // Author: Eugen Wintersberger <eugen.wintersberger@desy.de>
22 //
23 //
24 #pragma once
25 
26 #include <pni/core/types.hpp>
27 #include <pni/core/type_erasures.hpp>
28 #include <vector>
29 #include "../container_io_config.hpp"
30 
31 
32 namespace pni{
33 namespace io{
34 
35 #define DECLARE_VECTOR_FORMAT(type)\
36  pni::core::string format(const std::vector<type> &v,\
37  const container_io_config &config = \
38  container_io_config())
39 
40 
41  DECLARE_VECTOR_FORMAT(pni::core::uint8);
42  DECLARE_VECTOR_FORMAT(pni::core::int8);
43  DECLARE_VECTOR_FORMAT(pni::core::uint16);
44  DECLARE_VECTOR_FORMAT(pni::core::int16);
45  DECLARE_VECTOR_FORMAT(pni::core::uint32);
46  DECLARE_VECTOR_FORMAT(pni::core::int32);
47  DECLARE_VECTOR_FORMAT(pni::core::uint64);
48  DECLARE_VECTOR_FORMAT(pni::core::int64);
49 
50  DECLARE_VECTOR_FORMAT(pni::core::float32);
51  DECLARE_VECTOR_FORMAT(pni::core::float64);
52  DECLARE_VECTOR_FORMAT(pni::core::float128);
53 
54  DECLARE_VECTOR_FORMAT(pni::core::complex32);
55  DECLARE_VECTOR_FORMAT(pni::core::complex64);
56  DECLARE_VECTOR_FORMAT(pni::core::complex128);
57 
58  DECLARE_VECTOR_FORMAT(pni::core::bool_t);
59 
60  DECLARE_VECTOR_FORMAT(pni::core::value);
61 
62 }
63 }
DECLARE_VECTOR_FORMAT(pni::core::uint8)
Definition: cbf_reader.hpp:41