5 #ifndef STATE_MACHINE_CPP_ATTRIBUTE_TREE_H
6 #define STATE_MACHINE_CPP_ATTRIBUTE_TREE_H
18 template<
class HT,
class ...QT>
21 std::array<std::shared_ptr<AbstractLayer>,
sizeof...(QT) + 1> m_layers;
23 template<
unsigned int N,
class ...HX,
class ...QX>
25 m_layers[N] = std::shared_ptr<
Layer<HX...>>(t_head);
26 if constexpr (
sizeof...(QX) > 0) {
27 initialize<N + 1>(t_queue...);
34 return *m_layers[t_i].get();
38 AttributeTree() : m_layers({std::make_shared<HT>(), std::make_shared<QT>()... }) { }
41 initialize<0>(t_head, t_queue...);
47 #endif //STATE_MACHINE_CPP_ATTRIBUTE_TREE_H