Array implementation specific to 1D Arrays.
More...
#include </home/docs/checkouts/readthedocs.org/user_builds/axom/checkouts/v0.6.1/src/axom/core/ArrayBase.hpp>
template<typename T, typename ArrayType>
class axom::ArrayBase< T, 1, ArrayType >
Array implementation specific to 1D Arrays.
◆ ArrayBase() [1/2]
template<typename T , typename ArrayType >
◆ ArrayBase() [2/2]
template<typename T , typename ArrayType >
template<typename OtherArrayType >
◆ push_back() [1/2]
template<typename T , typename ArrayType >
Push a value to the back of the array.
- Parameters
-
[in] | value | the value to be added to the back. |
- Note
- Reallocation is done if the new size will exceed the capacity.
◆ push_back() [2/2]
template<typename T , typename ArrayType >
Push a value to the back of the array.
- Parameters
-
[in] | value | the value to move to the back. |
- Note
- Reallocation is done if the new size will exceed the capacity.
◆ emplace_back()
template<typename T , typename ArrayType >
template<typename... Args>
Inserts new element at the end of the Array.
- Parameters
-
[in] | args | the arguments to forward to constructor of the element. |
- Note
- Reallocation is done if the new size will exceed the capacity.
-
The size increases by 1.
◆ shape()
template<typename T , typename ArrayType >
Returns the dimensions of the Array.
◆ operator[]() [1/2]
template<typename T , typename ArrayType >
Accessor, returns a reference to the given value. For multidimensional arrays, indexes into the (flat) raw data.
- Parameters
-
[in] | idx | the position of the value to return. |
- Note
- equivalent to *(array.data() + idx).
- Precondition
- 0 <= idx < m_num_elements
◆ operator[]() [2/2]
template<typename T , typename ArrayType >
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
◆ swap()
template<typename T , typename ArrayType >
Swaps two ArrayBases No member data, so this is a no-op.
◆ insert()
template<typename T , typename ArrayType >
template<typename OtherArrayType >
Appends an Array to the end of the calling object.
- Parameters
-
[in] | other | The Array to append |
- Note
- Reallocation is done if the new size will exceed the capacity.
◆ blockSize()
template<typename T , typename ArrayType >
Returns the minimum "chunk size" that should be allocated.
References AXOM_HOST_DEVICE.
The documentation for this class was generated from the following file:
- /home/docs/checkouts/readthedocs.org/user_builds/axom/checkouts/v0.6.1/src/axom/core/ArrayBase.hpp