API  4.4
For C++ developers
OpenSim::ValueArray< T > Class Template Reference
+ Inheritance diagram for OpenSim::ValueArray< T >:

Public Member Functions

ValueArrayclone () const override
 
size_t size () const override
 Get the size of the array. More...
 
Value< T > & operator[] (size_t index) override
 Access an element of the array using its index. More...
 
const Value< T > & operator[] (size_t index) const override
 Access an element of the array using its index. More...
 
const std::vector< Value< T > > & get () const
 Get the underlying array. More...
 
std::vector< Value< T > > & upd ()
 Get the underlying array. More...
 
std::string toString (const size_t index) const override
 Get the value corresponding to the given index as string. More...
 
- Public Member Functions inherited from OpenSim::AbstractValueArray
 AbstractValueArray ()=default
 
 AbstractValueArray (const AbstractValueArray &)=default
 
 AbstractValueArray (AbstractValueArray &&)=default
 
AbstractValueArrayoperator= (const AbstractValueArray &)=default
 
AbstractValueArrayoperator= (AbstractValueArray &&)=default
 
virtual ~AbstractValueArray ()=default
 

Public Types

template<typename U >
using Value = SimTK::Value< U >
 
- Public Types inherited from OpenSim::AbstractValueArray
using AbstractValue = SimTK::AbstractValue
 

Member Typedef Documentation

◆ Value

template<typename T >
template<typename U >
using OpenSim::ValueArray< T >::Value = SimTK::Value<U>

Member Function Documentation

◆ clone()

template<typename T >
ValueArray* OpenSim::ValueArray< T >::clone ( ) const
inlineoverridevirtual

◆ get()

template<typename T >
const std::vector<Value<T> >& OpenSim::ValueArray< T >::get ( ) const
inline

Get the underlying array.

◆ operator[]() [1/2]

template<typename T >
Value<T>& OpenSim::ValueArray< T >::operator[] ( size_t  index)
inlineoverridevirtual

Access an element of the array using its index.

Exceptions
IndexOutOfRangeIf index is out of range.

Implements OpenSim::AbstractValueArray.

◆ operator[]() [2/2]

template<typename T >
const Value<T>& OpenSim::ValueArray< T >::operator[] ( size_t  index) const
inlineoverridevirtual

Access an element of the array using its index.

Exceptions
IndexOutOfRangeIf index is out of range.

Implements OpenSim::AbstractValueArray.

◆ size()

template<typename T >
size_t OpenSim::ValueArray< T >::size ( ) const
inlineoverridevirtual

Get the size of the array.

Implements OpenSim::AbstractValueArray.

◆ toString()

template<typename T >
std::string OpenSim::ValueArray< T >::toString ( const size_t  index) const
inlineoverridevirtual

Get the value corresponding to the given index as string.

Exceptions
IndexOutOfRangeIf indes is out of range.

Implements OpenSim::AbstractValueArray.

◆ upd()

template<typename T >
std::vector<Value<T> >& OpenSim::ValueArray< T >::upd ( )
inline

The documentation for this class was generated from the following file: