Inheritance diagram for Array:
Definition at line 44 of file Array.H.
STL integration | |
typedef T | value_type |
typedef value_type * | pointer |
typedef const value_type * | const_pointer |
typedef value_type & | reference |
typedef const value_type & | const_reference |
typedef ptrdiff_t | difference_type |
typedef size_t | size_type |
typedef pointer | iterator |
typedef const_pointer | const_iterator |
typedef std::reverse_iterator< iterator > | reverse_iterator |
typedef std::reverse_iterator< const_iterator > | const_reverse_iterator |
iterator | begin () |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
reverse_iterator | rbegin () |
reverse_iterator | rend () |
const_reverse_iterator | rbegin () const |
const_reverse_iterator | rend () const |
Public Member Functions | |
Array (const int size) | |
Array (const int size, const T &value) | |
Array (const Array< T > &array) | |
~Array () | |
Assignment | |
Array< T > & | operator= (const Array< T > &array) |
Assign one array to another. | |
Array< T > & | operator= (const T &value) |
Assign a value to all elements of the array. | |
Element access | |
reference | operator[] (const size_type index) |
const_reference | operator[] (const size_type index) const |
reference | operator() (const size_type index) |
const_reference | operator() (const size_type index) const |
Sizes | |
size_type | size () const |
Private Attributes | |
size_type | m_size |
T * | m_data |
typedef T value_type |
typedef value_type* pointer |
typedef const value_type* const_pointer |
typedef value_type& reference |
typedef const value_type& const_reference |
typedef ptrdiff_t difference_type |
typedef const_pointer const_iterator |
typedef std::reverse_iterator<iterator> reverse_iterator |
typedef std::reverse_iterator<const_iterator> const_reverse_iterator |
Array | ( | const int | size | ) | [inline, explicit] |
Array | ( | const int | size, | |
const T & | value | |||
) | [inline] |
~Array | ( | ) | [inline] |
Assign one array to another.
If the array being assigned from is larger than the array being assigned to, data block holding the array will be deleted and reallocated.
[in] | array | The array to be assigned from. |
Array<T>& operator= | ( | const T & | value | ) | [inline] |
iterator begin | ( | ) | [inline] |
iterator end | ( | ) | [inline] |
const_iterator begin | ( | ) | const [inline] |
const_iterator end | ( | ) | const [inline] |
reverse_iterator rbegin | ( | ) | [inline] |
reverse_iterator rend | ( | ) | [inline] |
const_reverse_iterator rbegin | ( | ) | const [inline] |
const_reverse_iterator rend | ( | ) | const [inline] |
Reimplemented in Ring.
Definition at line 114 of file Array.H.
References assert_range, m_data, and m_size.
Referenced by LocalRing::operator[](), and Ring::operator[]().
const_reference operator[] | ( | const size_type | index | ) | const [inline] |
Reimplemented in Ring.
Definition at line 117 of file Array.H.
References assert_range, m_data, and m_size.
Referenced by NdPoint::distance().
const_reference operator() | ( | const size_type | index | ) | const [inline] |
size_type size | ( | ) | const [inline] |
Definition at line 127 of file Array.H.
Referenced by Array(), end(), operator()(), operator=(), operator[](), and size().
T* m_data [private] |
Definition at line 128 of file Array.H.
Referenced by Array(), begin(), end(), operator()(), operator=(), operator[](), and ~Array().