![]() |
ICF 3.1.1.10
Technical documentation of ICF Libraries
|
Multidimensional array with fixed number of dimensions. More...
#include <TArray.h>
Classes | |
| class | iterator |
Public Types | |
| typedef TIndex< Dimensions > | IndexType |
| typedef TIndex< Dimensions > | SizesType |
| typedef Element | ElementType |
Public Member Functions | |
| TArray () | |
| TArray (TArray &&array)=default | |
| TArray (const TArray &array)=default | |
| TArray (const SizesType &sizes) | |
| void | Reset () |
| Removes all elements and set all sizes to 0. | |
| bool | IsEmpty () const |
| Check if this array has no elements. | |
| bool | IsDimensionsCountFixed () const |
| Check, if number dimensions is fixed. | |
| int | GetDimensionsCount () const |
| Get number of dimensions of this array. | |
| bool | SetDimensionsCount (int count) |
| Set number of dimensions of this array. | |
| const SizesType & | GetSizes () const |
| Get list of all sizes. | |
| bool | SetSizes (const SizesType &sizes) |
| Set list of all sizes. | |
| int | GetSize (int dimension) const |
| Get size of array for specified dimension. | |
| bool | SetSize (int dimension, int size) |
| Set size of array for specified dimension. | |
| const Element & | GetAt (const IndexType &index) const |
| Get element stored at specified index. | |
| Element & | GetAtRef (const IndexType &index) |
| Get reference to element stored at specified index. | |
| void | SetAt (const IndexType &index, const Element &value) |
| Set element at specified index. | |
| void | SetAllElements (const Element &value) |
| Set some value to all elements. | |
| iterator | begin () const |
| Get begin value of element access iterator. | |
| const iterator & | end () const |
| Get end value of element access iterator. | |
| TArray & | operator= (TArray &&array)=default |
| TArray & | operator= (const TArray &array)=default |
| bool | operator== (const TArray< Element, Dimensions > &value) const |
| bool | operator!= (const TArray< Element, Dimensions > &value) const |
| const Element & | operator[] (const IndexType &index) const |
| Element & | operator[] (const IndexType &index) |
Protected Types | |
| typedef std::vector< Element > | Elements |
Protected Member Functions | |
| int | GetElementIndex (const IndexType &index) const |
| Get index of element in one dimensional array. | |
| void | UpdateElementsSize () |
| Update size of elements to size changes. | |
| void | DeepCopy (const Elements &elements, const SizesType &sizes) |
Protected Attributes | |
| SizesType | m_sizes |
| Elements | m_elements |
Multidimensional array with fixed number of dimensions.
|
protected |
| Element istd::TArray< Element, Dimensions >::ElementType |
| TIndex<Dimensions> istd::TArray< Element, Dimensions >::IndexType |
| TIndex<Dimensions> istd::TArray< Element, Dimensions >::SizesType |
| istd::TArray< Element, Dimensions >::TArray | ( | ) |
|
default |
|
default |
|
explicit |
Definition at line 335 of file TArray.h.
References istd::TArray< Element, Dimensions >::UpdateElementsSize().
| TArray< Element, Dimensions >::iterator istd::TArray< Element, Dimensions >::begin | ( | ) | const |
|
protected |
| const TArray< Element, Dimensions >::iterator & istd::TArray< Element, Dimensions >::end | ( | ) | const |
|
inline |
Get element stored at specified index.
Definition at line 235 of file TArray.h.
References istd::TIndex< Dimensions >::IsInside().
Referenced by imath::TMultidimensionalPolynomial< Dimensions, Element >::ApproximateCoefficientsFromFulcrums(), and imath::CSampledFunction2d::GetSampleValue().
|
inline |
Get reference to element stored at specified index.
Definition at line 247 of file TArray.h.
References istd::TIndex< Dimensions >::IsInside().
|
inline |
|
inlineprotected |
|
inline |
|
inline |
Get list of all sizes.
Definition at line 218 of file TArray.h.
Referenced by imath::TMultidimensionalPolynomial< Dimensions, Element >::ApproximateCoefficientsFromFulcrums(), imath::CSampledFunction2d::GetGridSize2d(), imath::CSampledFunction2d::GetSampleValue(), istd::TArray< Element, Dimensions >::iterator::iterator(), and imath::CSampledFunction2d::SetSampleValue().
|
inline |
| bool istd::TArray< Element, Dimensions >::IsEmpty | ( | ) | const |
Check if this array has no elements.
Definition at line 190 of file TArray.h.
References istd::TIndex< Dimensions >::IsSizeEmpty().
| bool istd::TArray< Element, Dimensions >::operator!= | ( | const TArray< Element, Dimensions > & | value | ) | const |
Definition at line 397 of file TArray.h.
References istd::TArray< Element, Dimensions >::m_elements, and istd::TArray< Element, Dimensions >::m_sizes.
|
default |
|
default |
| bool istd::TArray< Element, Dimensions >::operator== | ( | const TArray< Element, Dimensions > & | value | ) | const |
Definition at line 390 of file TArray.h.
References istd::TArray< Element, Dimensions >::m_elements, and istd::TArray< Element, Dimensions >::m_sizes.
Referenced by istd::TArray< Element, Dimensions >::iterator::operator!=().
|
inline |
|
inline |
| void istd::TArray< Element, Dimensions >::Reset | ( | ) |
| void istd::TArray< Element, Dimensions >::SetAllElements | ( | const Element & | value | ) |
|
inline |
Set element at specified index.
Definition at line 259 of file TArray.h.
References istd::TIndex< Dimensions >::IsInside().
Referenced by imath::TMultidimensionalPolynomial< Dimensions, Element >::ApproximateCoefficientsFromFulcrums(), and imath::CSampledFunction2d::SetSampleValue().
|
inline |
Set number of dimensions of this array.
This is only dummy method, to provide methods compatibility with template implementations.
| count | number of dimensions will be set. |
| bool istd::TArray< Element, Dimensions >::SetSize | ( | int | dimension, |
| int | size ) |
| bool istd::TArray< Element, Dimensions >::SetSizes | ( | const SizesType & | sizes | ) |
Set list of all sizes.
Definition at line 352 of file TArray.h.
Referenced by imath::TMultidimensionalPolynomial< Dimensions, Element >::ApproximateCoefficientsFromFulcrums().
|
protected |
Update size of elements to size changes.
Definition at line 406 of file TArray.h.
Referenced by istd::TArray< Element, Dimensions >::TArray().
|
protected |
Definition at line 180 of file TArray.h.
Referenced by istd::TArray< Element, Dimensions >::operator!=(), and istd::TArray< Element, Dimensions >::operator==().
|
protected |
Definition at line 179 of file TArray.h.
Referenced by ialgo::TGeneralHoughSpace< Dimensions, Element >::CombineWithSpace(), istd::TArray< Element, Dimensions >::operator!=(), and istd::TArray< Element, Dimensions >::operator==().
© Witold Gantzke and Kirill Lepskiy