Template Numerical Library version\ main:52827a2
Loading...
Searching...
No Matches
TNL::Containers::StaticNDArray< Value, SizesHolder, Permutation, Index > Class Template Reference

Static N-dimensional array. More...

#include <TNL/Containers/NDArray.h>

Inheritance diagram for TNL::Containers::StaticNDArray< Value, SizesHolder, Permutation, Index >:
Collaboration diagram for TNL::Containers::StaticNDArray< Value, SizesHolder, Permutation, Index >:

Public Member Functions

NDArrayStorageoperator= (const NDArrayStorage &other)=default
 Copy-assignment operator for deep-copying data from another array. Mismatched sizes cause reallocations.
 
template<typename OtherArray >
NDArrayStorageoperator= (const OtherArray &other)
 Templated copy-assignment operator for deep-copying data from another array.
 
NDArrayStorageoperator= (NDArrayStorage &&) noexcept(false)=default
 Move-assignment operator for acquiring data from rvalues.
 
constexpr void setValue (Value value)
 Sets all elements of the array to given value.
 
- Public Member Functions inherited from TNL::Containers::ConstStaticSizesHolder< typename SizesHolder::IndexType, SizesHolder::getDimension(), 0 >
__cuda_callable__ typename SizesHolder::IndexType getSize () const
 
__cuda_callable__ typename SizesHolder::IndexType operator[] (typename SizesHolder::IndexType level) const
 Returns the dynamic size along a specific axis. It is always equal to the static size.
 

Additional Inherited Members

- Public Types inherited from TNL::Containers::ConstStaticSizesHolder< typename SizesHolder::IndexType, SizesHolder::getDimension(), 0 >
using IndexType
 
- Static Public Member Functions inherited from TNL::Containers::ConstStaticSizesHolder< typename SizesHolder::IndexType, SizesHolder::getDimension(), 0 >
static constexpr std::size_t getDimension ()
 
static constexpr std::size_t getStaticSize ()
 
static constexpr typename SizesHolder::IndexType getStaticSize (typename SizesHolder::IndexType level)
 Returns the static size of a specific dimension identified by a runtime parameter level.
 

Detailed Description

template<typename Value, typename SizesHolder, typename Permutation = std::make_index_sequence< SizesHolder::getDimension() >, typename Index = typename SizesHolder::IndexType>
class TNL::Containers::StaticNDArray< Value, SizesHolder, Permutation, Index >

Static N-dimensional array.

Template Parameters
ValueType of the values stored in the array.
SizesHolderInstance of SizesHolder that will represent the array sizes.
PermutationPermutation that will be applied to indices when accessing the array elements. The identity permutation is used by default.
IndexType of indices used for addressing the array elements.

See also the Users' Guide.


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