File view_vector.hpp¶
Typedefs
-
template<typename T>
class Vector : public View<T>¶ - #include <view_vector.hpp>
A one-dimensional view that provides access to values stored in a pre-allocated array of a specific size.
- Template Parameters:
T – The type of the values, the view provides access to
Subclassed by IndexableViewDecorator< Vector >, BinaryDokVectorAllocator< Vector >, BinnedVectorDecorator< Vector >, IterableIndexedVectorDecorator< Vector >, ResizableVectorDecorator< Vector >
Public Functions
-
inline Vector(T *array, std::initializer_list<uint32> dimensions)¶
- Parameters:
array – A pointer to an array of template type
T
that stores the values, the view should provide access todimensions – The number of elements in each dimension of the view
-
inline Vector(T *array, uint32 numElements)¶
- Parameters:
array – A pointer to an array of template type
T
that stores the values, the view should provide access tonumElements – The number of elements in the view
-
inline Vector(const Vector<T> &other)¶
- Parameters:
other – A const reference to an object of type
Vector
that should be copied
-
inline Vector(Vector<T> &&other)¶
- Parameters:
other – A reference to an object of type
Vector
that should be moved
-
inline virtual ~Vector() override¶
-
inline View<T>::const_iterator cend() const¶
Returns a
const_iterator
to the end of the vector.- Returns:
A
const_iterator
to the end
-
inline View<T>::iterator end()¶
Returns an
iterator
to the end of the vector.- Returns:
An
iterator
to the end
-
inline void clear()¶
Sets all values stored in the view to zero.
-
template<typename View>
class VectorDecorator : public ViewDecorator<View>¶ - #include <view_vector.hpp>
A vector that is backed by a one-dimensional view of a specific size.
- Template Parameters:
View – The type of view, the vector is backed by
Subclassed by ResizableVectorDecorator< VectorDecorator< ResizableVector< float64 > > >
-
template<typename Vector>
class IterableVectorDecorator : public IndexableViewDecorator<Vector>¶ - #include <view_vector.hpp>
Provides access via iterators to the values stored in a vector.
- Template Parameters:
Vector – The type of the vector
Subclassed by ResizableVectorDecorator< DenseVectorDecorator< ResizableVector< uint32 > > >, ResizableVectorDecorator< DenseVectorDecorator< ResizableVector< T > > >, CoverageMask, DenseVector< T >, DenseWeightVector< T >
Public Functions
-
inline IterableVectorDecorator(typename Vector::view_type &&view)¶
- Parameters:
view – The view, the vector should be backed by
-
inline virtual ~IterableVectorDecorator() override¶
-
inline IndexableViewDecorator<Vector>::const_iterator cend() const¶
Returns a
const_iterator
to the end of the vector.- Returns:
A
const_iterator
to the end
-
inline IndexableViewDecorator<Vector>::iterator end()¶
Returns an
iterator
to the end of the vector.- Returns:
An
iterator
to the end