OSVR-Core  0.6-1962-g59773924
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Transform.h
Go to the documentation of this file.
1 
11 // Copyright 2015 Sensics, Inc.
12 // TypePack is part of OSVR-Core.
13 //
14 // Use, modification and distribution is subject to the
15 // Boost Software License, Version 1.0. (See accompanying
16 // file LICENSE_1_0.txt or copy at
17 // http://www.boost.org/LICENSE_1_0.txt)
18 
19 #ifndef INCLUDED_Transform_h_GUID_901ECEAD_C608_4DAE_CA89_CE3C6EF135B6
20 #define INCLUDED_Transform_h_GUID_901ECEAD_C608_4DAE_CA89_CE3C6EF135B6
21 
22 // Internal Includes
23 #include "Apply.h"
24 #include "List.h"
25 #include "T.h"
26 
27 // Library/third-party includes
28 // - none
29 
30 // Standard includes
31 // - none
32 
33 namespace osvr {
34 namespace typepack {
35 
36  namespace detail {
37 
39  template <typename List, typename Fun> struct transform_;
40  template <typename... Ts, typename Fun>
41  struct transform_<list<Ts...>, Fun> {
44  template <typename T> struct apply_workaround {
45  using type = typepack::apply<Fun, T>;
46  };
48  };
49  } // namespace detail
50 
53  template <typename List, typename Fun>
55 } // namespace typepack
56 } // namespace osvr
57 #endif // INCLUDED_Transform_h_GUID_901ECEAD_C608_4DAE_CA89_CE3C6EF135B6
Header.
The main namespace for all C++ elements of the framework, internal and external.
Definition: ClientKit.h:31
A wrapper for a template parameter pack of types.
Definition: List.h:52
typename F::template apply< Args...> apply
Apply an alias class.
Definition: Apply.h:44
t_< detail::transform_< List, Fun >> transform
Definition: Transform.h:54
Header.
The trait used to implement the alias typepack::transform.
Definition: Transform.h:39
Header.
typename T::type t_
A convenience alias template to extract the nested type within the supplied T.
Definition: T.h:52