OpenKalman
triangular_adapter.hpp
Go to the documentation of this file.
1 /* This file is part of OpenKalman, a header-only C++ library for
2  * Kalman filters and other recursive filters.
3  *
4  * Copyright (c) 2019-2023 Christopher Lee Ogden <ogden@gatech.edu>
5  *
6  * This Source Code Form is subject to the terms of the Mozilla Public
7  * License, v. 2.0. If a copy of the MPL was not distributed with this
8  * file, You can obtain one at https://mozilla.org/MPL/2.0/.
9  */
10 
16 #ifndef OPENKALMAN_TRIANGULAR_ADAPTER_HPP
17 #define OPENKALMAN_TRIANGULAR_ADAPTER_HPP
18 
19 
20 namespace OpenKalman
21 {
22 #ifndef __cpp_concepts
23  namespace detail
24  {
25  template<typename T, typename = void>
26  struct is_triangular_adapter : std::false_type {};
27 
28  template<typename T>
29  struct is_triangular_adapter<T, std::enable_if_t<interface::indexible_object_traits<std::decay_t<T>>::is_triangular_adapter>>
30  : std::true_type {};
31  }
32 #endif
33 
34 
41  template<typename T>
42 #ifdef __cpp_concepts
44 #else
45  constexpr bool triangular_adapter = detail::is_triangular_adapter<T>::value and has_nested_object<T> and
46 #endif
47  has_nested_object<T>;
48 
49 
50 } // namespace OpenKalman
51 
52 #endif //OPENKALMAN_TRIANGULAR_ADAPTER_HPP
Definition: indexible_object_traits.hpp:36
Definition: tuple_reverse.hpp:103
constexpr bool triangular_adapter
Specifies that a type is a triangular adapter of triangle type triangle_type.
Definition: triangular_adapter.hpp:45
The root namespace for OpenKalman.
Definition: basics.hpp:34
Definition: triangular_adapter.hpp:26