|
The blo Library
|
Small 1D array, fixed size. More...
#include <Array1DFixed.h>
Public Member Functions | |
| Array1DFixed ()=default | |
| Default constructor. | |
| Array1DFixed (const T &val) | |
| Constructs array of specified value. | |
| Array1DFixed (const std::initializer_list< T > &list) | |
| Constructs array that is a copy of specified initializer list. | |
| Array1DFixed (const Array1DFixed< T, N > &rhs)=default | |
| Copy constructor. | |
| virtual | ~Array1DFixed ()=default |
| Destructor. | |
| Array1DFixed< T, N > & | operator= (const Array1DFixed< T, N > &rhs)=default |
| Copy assignment operator. | |
| T & | operator[] (int n) |
| Index array element. | |
| const T & | operator[] (int n) const |
| Index array element. | |
| T * | ptrData () |
| Retrieves the pointer to the beginning of the array. | |
| const T * | ptrData () const |
| Retrieves the pointer to the beginning of the array. | |
| void | set (const T &val) |
| Sets array elements to a value. | |
Static Public Member Functions | |
| static int | size () |
| Number of elements in the array. | |
| static int | len () |
| Length of the array. | |
| static int | stride2 () |
| Stride in bytes between the elements in the array. | |
Small 1D array, fixed size.
| T | Data type. |
| N | Array size. |
|
default |
Default constructor.
|
explicit |
Constructs array of specified value.
| val | Constant value to assign to each element in the array. |
| blo::Array1DFixed< T, N >::Array1DFixed | ( | const std::initializer_list< T > & | list | ) |
Constructs array that is a copy of specified initializer list.
| list | Initializer list. |
|
default |
Copy constructor.
|
virtualdefault |
Destructor.
|
static |
Length of the array.
|
default |
Copy assignment operator.
| T & blo::Array1DFixed< T, N >::operator[] | ( | int | n | ) |
Index array element.
| n | Index of the array. |
| const T & blo::Array1DFixed< T, N >::operator[] | ( | int | n | ) | const |
Index array element.
| n | Index of the array. |
| T * blo::Array1DFixed< T, N >::ptrData | ( | ) |
Retrieves the pointer to the beginning of the array.
| const T * blo::Array1DFixed< T, N >::ptrData | ( | ) | const |
Retrieves the pointer to the beginning of the array.
| void blo::Array1DFixed< T, N >::set | ( | const T & | val | ) |
Sets array elements to a value.
| val | Constant value to assign to each element in the array. |
|
static |
Number of elements in the array.
|
static |
Stride in bytes between the elements in the array.