source: rrlib_util/tTypeList.h @ 123:68ba619b821a

14.08
Last change on this file since 123:68ba619b821a was 98:ea0238bf0832, checked in by Tobias Föhst <foehst@…>, 6 years ago

Added and updated license information

File size: 3.5 KB
Line 
1//
2// You received this file as part of RRLib
3// Robotics Research Library
4//
5// Copyright (C) Finroc GbR (finroc.org)
6//
7// This program is free software; you can redistribute it and/or modify
8// it under the terms of the GNU General Public License as published by
9// the Free Software Foundation; either version 2 of the License, or
10// (at your option) any later version.
11//
12// This program is distributed in the hope that it will be useful,
13// but WITHOUT ANY WARRANTY; without even the implied warranty of
14// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15// GNU General Public License for more details.
16//
17// You should have received a copy of the GNU General Public License along
18// with this program; if not, write to the Free Software Foundation, Inc.,
19// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20//
21//----------------------------------------------------------------------
22/*!\file    rrlib/util/tTypeList.h
23 *
24 * \author  Tobias Foehst
25 *
26 * \date    2011-03-25
27 *
28 * \brief   Contains tTypeList
29 *
30 * \b tTypeList
31 *
32 */
33//----------------------------------------------------------------------
34#ifndef __rrlib__util__tTypeList_h__
35#define __rrlib__util__tTypeList_h__
36
37//----------------------------------------------------------------------
38// External includes (system with <>, local with "")
39//----------------------------------------------------------------------
40
41//----------------------------------------------------------------------
42// Internal includes with ""
43//----------------------------------------------------------------------
44#define __rrlib__util__type_list__include_guard__
45
46namespace rrlib
47{
48namespace util
49{
50template <typename ... TTypes>
51struct tTypeList;
52}
53}
54
55#include "rrlib/util/type_list/definitions.h"
56
57#include "rrlib/util/type_list/tSizeOf.h"
58#include "rrlib/util/type_list/tAt.h"
59#include "rrlib/util/type_list/tFind.h"
60#include "rrlib/util/type_list/tAppend.h"
61#include "rrlib/util/type_list/tAppendList.h"
62#include "rrlib/util/type_list/tRemove.h"
63#include "rrlib/util/type_list/tRemoveAll.h"
64#include "rrlib/util/type_list/tUnique.h"
65#include "rrlib/util/type_list/tReplace.h"
66#include "rrlib/util/type_list/tReplaceAll.h"
67#include "rrlib/util/type_list/tMostDerived.h"
68#include "rrlib/util/type_list/tDerivedToFront.h"
69
70#include "rrlib/util/type_list/tTypeListBase.h"
71
72#undef __rrlib__util__type_list__include_guard__
73
74//----------------------------------------------------------------------
75// Debugging
76//----------------------------------------------------------------------
77
78//----------------------------------------------------------------------
79// Namespace declaration
80//----------------------------------------------------------------------
81namespace rrlib
82{
83namespace util
84{
85
86//----------------------------------------------------------------------
87// Forward declarations / typedefs / enums
88//----------------------------------------------------------------------
89
90//----------------------------------------------------------------------
91// Class declaration
92//----------------------------------------------------------------------
93//!
94/*!
95 *
96 */
97template <typename THead, typename ... TTail>
98struct tTypeList<THead, TTail...> : public type_list::tTypeListBase<tTypeList<THead, TTail...>>
99{
100  typedef THead tHead;
101  typedef tTypeList<TTail...> tTail;
102};
103
104template <>
105struct tTypeList<> : public type_list::tTypeListBase<tTypeList<>>
106{};
107
108//----------------------------------------------------------------------
109// End of namespace declaration
110//----------------------------------------------------------------------
111}
112}
113
114#endif
Note: See TracBrowser for help on using the repository browser.