Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LinearizerConcept.hpp
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file LinearizerConcept.hpp
1 // This file is part of the Acts project.
2 //
3 // Copyright (C) 2019 CERN for the benefit of the Acts project
4 //
5 // This Source Code Form is subject to the terms of the Mozilla Public
6 // License, v. 2.0. If a copy of the MPL was not distributed with this
7 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 
9 #pragma once
10 
19 
20 namespace Acts {
21 
22 namespace Concepts {
23 namespace Linearizer {
24 
25 template <typename T>
26 using propagator_t = typename T::Propagator_t;
27 template <typename T>
28 using state_t = typename T::State;
29 
30 METHOD_TRAIT(linTrack_t, linearizeTrack);
31 
32 // clang-format off
33  template <typename S>
35 
36  constexpr static bool linTrack_exists = has_method<const S, Result<LinearizedTrack>,
37  linTrack_t, const BoundTrackParameters&,
38  double,
39  const Surface&,
40  const Acts::GeometryContext&,
42  typename S::State&>;
43 
44  static_assert(linTrack_exists, "linearizeTrack method not found");
45 
46  constexpr static bool propagator_exists = exists<propagator_t, S>;
47  static_assert(propagator_exists, "Propagator type not found");
48 
49  constexpr static bool state_exists = exists<state_t, S>;
50  static_assert(state_exists, "State type not found");
51 
52  constexpr static bool value = require<linTrack_exists,
54  state_exists>;
55  };
56 // clang-format on
57 
58 } // namespace Linearizer
59 } // namespace Concepts
60 
61 template <typename fitter>
62 constexpr bool LinearizerConcept =
64 
65 } // namespace Acts