49 template <std::
size_t N>
51 template <std::
size_t N>
53 template <std::
size_t N>
55 template <std::
size_t N>
57 template <std::
size_t N>
59 template <std::
size_t N>
94 return std::shared_ptr<StateArray<N>>(
new StateArray<N>(*this));
98 virtual double&
value(
const std::size_t& _i)
override 104 virtual const double&
value(
const std::size_t& _i)
const override 137 template <
typename EnumStateVals>
180 template <EnumStateVals _i>
187 template <EnumStateVals _i>
199 template <
typename... NestedStates1>
201 template <
typename EnumStateVals1,
typename... NestedStates1>
203 template <
typename SubState>
208 #endif // STATE_ARRAY_H virtual ~StateArray()=default
std::shared_ptr< State > StateSPtr
std::unique_ptr< StateArray< N > const > StateArrayConstUPtr
constexpr auto asInt(Enumeration const value) -> typename std::underlying_type< Enumeration >::type
StateArray(State *_parent)
virtual StateSPtr cloneState() const override
Clone-to-base-class-ptr function.
double & value()
Scoped access (compile-time) to the values of the state object.
Extension of StateArray providing value access based on a scoped enumeration (compile-time).
virtual const double & value(const std::size_t &_i) const override
Const access state variable based on index _i.
std::array< double, N > values_
State array container.
virtual size_t valueSize() const override
Size of the state variables.
Extension of StateNestedSet providing sub-state access based on a scoped enumeration (compile-time)...
virtual double & value(const std::size_t &_i) override
Access state variable based on index _i.
Implementation of State being formed by tuple of substates.
const double & value() const
Const scoped access (compile-time) to the values of the state object.
Generic tree-like recursive structure that allows sub-structure access as well as ordered (array-like...
std::shared_ptr< StateArray< N > const > StateArrayConstSPtr
std::unique_ptr< StateArray< N >> StateArrayUPtr
const std::array< double, N > & valuesArray() const
Const reference to the variables array.
std::array< double, N > & valuesArray()
Reference to the state variables array.
virtual StateSPtr cloneState() const override
Clone-to-base-class-ptr function.
std::shared_ptr< StateArrayScoped< EnumStateVals > > cloneStateExt() const
Clone-to-this-class-ptr function.
StateArrayScoped(State *_parent)
StateArray & operator=(const StateArray &)=default
void callRootUpdateSize()
Calls (if present) the parent updateSize procedure. Otherwise performs root updateSize.
Implementation of State for a fixed size array of double values.
std::shared_ptr< StateArray< N >> StateArraySPtr