casacore
Loading...
Searching...
No Matches
casacore::ArrayBaseAccessor< T > Class Template Reference

Axis independent base for the ArrayAccessor classes. More...

#include <ArrayAccessor.h>

Public Member Functions

void operator+= (const size_t ix)
 Iterator-like operations.
void operator-= (const size_t ix)
void operator++ ()
void operator++ (int)
void operator-- ()
void operator-- (int)
const T & operator* () const
 Dereferencing.
T & operator* ()
T * data ()
const Array< T > & baseArray ()
size_t step ()
const T & operator[] (const int ix) const
 Index along current axis.
T & operator[] (const int ix)
const T * end ()
 End of index on line.
const T * end (const int n)
const T * begin ()
 Start of index on line.
const T * begin (const int n)
const T * rend ()
 End when reverse indexing.
const T * rend (const int n)
const T * rbegin ()
 Begin when reverse indexing.
const T * rbegin (const int n)

Protected Member Functions

 ArrayBaseAccessor ()
 Default constructor (for use in e.g.
 ArrayBaseAccessor (const Array< T > &arr)
 Construct from an Array.
 ArrayBaseAccessor (const Array< T > &arr, const size_t ax)
 ArrayBaseAccessor (const ArrayBaseAccessor< T > &other)
 Copy constructor (copy semantics).
 ArrayBaseAccessor (const ArrayBaseAccessor< T > &other, const size_t ax)
 ~ArrayBaseAccessor ()
 Destructor.
ArrayBaseAccessor & operator= (const ArrayBaseAccessor< T > &other)
 Assignment (copy semantics).
void init (const Array< T > &arr)
 (Re-)initialize from Array
void init (const Array< T > &arr, const size_t ax)
void init (const size_t ax)

Protected Attributes

const Array< T > * arrayPtr_p
 The pointer to belonging array.
size_t axis_p
 Current run-time axis.
T * ptr_p
 Current access pointer.
int step_p
 The increment to go from one point along an axis, to the next.
const T * begin_p
 The start element of array.
const T * end_p
 The one element beyond last on line.

Detailed Description

template<class T>
class casacore::ArrayBaseAccessor< T >

Axis independent base for the ArrayAccessor classes.

Intended use:

Internal

Synopsis

The ArrayBaseAccessor class implements the axis independent parts of the ArrayAccessor class. It can only be used from the ArrayAccessor class.

Definition at line 62 of file ArrayAccessor.h.

Constructor & Destructor Documentation

◆ ArrayBaseAccessor() [1/5]

◆ ArrayBaseAccessor() [2/5]

template<class T>
casacore::ArrayBaseAccessor< T >::ArrayBaseAccessor ( const Array< T > & arr)
inlineexplicitprotected

Construct from an Array.

Definition at line 70 of file ArrayAccessor.h.

References arrayPtr_p, axis_p, begin_p, data(), end_p, ptr_p, and step_p.

◆ ArrayBaseAccessor() [3/5]

template<class T>
casacore::ArrayBaseAccessor< T >::ArrayBaseAccessor ( const Array< T > & arr,
const size_t ax )
inlineprotected

Definition at line 79 of file ArrayAccessor.h.

References arrayPtr_p, axis_p, begin_p, data(), end_p, ptr_p, and step_p.

◆ ArrayBaseAccessor() [4/5]

template<class T>
casacore::ArrayBaseAccessor< T >::ArrayBaseAccessor ( const ArrayBaseAccessor< T > & other)
inlineprotected

Copy constructor (copy semantics).

Definition at line 91 of file ArrayAccessor.h.

References ArrayBaseAccessor(), arrayPtr_p, axis_p, begin_p, end_p, ptr_p, and step_p.

◆ ArrayBaseAccessor() [5/5]

template<class T>
casacore::ArrayBaseAccessor< T >::ArrayBaseAccessor ( const ArrayBaseAccessor< T > & other,
const size_t ax )
inlineprotected

Definition at line 100 of file ArrayAccessor.h.

References ArrayBaseAccessor(), arrayPtr_p, axis_p, begin_p, end_p, ptr_p, and step_p.

◆ ~ArrayBaseAccessor()

template<class T>
casacore::ArrayBaseAccessor< T >::~ArrayBaseAccessor ( )
inlineprotected

Destructor.

Definition at line 113 of file ArrayAccessor.h.

Member Function Documentation

◆ baseArray()

template<class T>
const Array< T > & casacore::ArrayBaseAccessor< T >::baseArray ( )
inline

Definition at line 159 of file ArrayAccessor.h.

References arrayPtr_p.

◆ begin() [1/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::begin ( )
inline

Start of index on line.

Definition at line 177 of file ArrayAccessor.h.

References begin_p.

◆ begin() [2/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::begin ( const int n)
inline

Definition at line 178 of file ArrayAccessor.h.

References begin_p, and step_p.

◆ data()

template<class T>
T * casacore::ArrayBaseAccessor< T >::data ( )
inline

Definition at line 158 of file ArrayAccessor.h.

References ptr_p.

Referenced by ArrayBaseAccessor(), and ArrayBaseAccessor().

◆ end() [1/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::end ( )
inline

End of index on line.

Definition at line 171 of file ArrayAccessor.h.

References end_p.

◆ end() [2/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::end ( const int n)
inline

Definition at line 172 of file ArrayAccessor.h.

References end_p, and step_p.

◆ init() [1/3]

template<class T>
void casacore::ArrayBaseAccessor< T >::init ( const Array< T > & arr)
inlineprotected

◆ init() [2/3]

template<class T>
void casacore::ArrayBaseAccessor< T >::init ( const Array< T > & arr,
const size_t ax )
inlineprotected

Definition at line 130 of file ArrayAccessor.h.

References arrayPtr_p, axis_p, and ptr_p.

◆ init() [3/3]

template<class T>
void casacore::ArrayBaseAccessor< T >::init ( const size_t ax)
inlineprotected

Definition at line 135 of file ArrayAccessor.h.

References arrayPtr_p, axis_p, and ptr_p.

◆ operator*() [1/2]

template<class T>
T & casacore::ArrayBaseAccessor< T >::operator* ( )
inline

Definition at line 157 of file ArrayAccessor.h.

References ptr_p.

◆ operator*() [2/2]

template<class T>
const T & casacore::ArrayBaseAccessor< T >::operator* ( ) const
inline

Dereferencing.

Definition at line 156 of file ArrayAccessor.h.

References ptr_p.

◆ operator++() [1/2]

template<class T>
void casacore::ArrayBaseAccessor< T >::operator++ ( )
inline

Definition at line 148 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator++() [2/2]

template<class T>
void casacore::ArrayBaseAccessor< T >::operator++ ( int )
inline

Definition at line 149 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator+=()

template<class T>
void casacore::ArrayBaseAccessor< T >::operator+= ( const size_t ix)
inline

Iterator-like operations.

Definition at line 146 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator--() [1/2]

template<class T>
void casacore::ArrayBaseAccessor< T >::operator-- ( )
inline

Definition at line 150 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator--() [2/2]

template<class T>
void casacore::ArrayBaseAccessor< T >::operator-- ( int )
inline

Definition at line 151 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator-=()

template<class T>
void casacore::ArrayBaseAccessor< T >::operator-= ( const size_t ix)
inline

Definition at line 147 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator=()

◆ operator[]() [1/2]

template<class T>
T & casacore::ArrayBaseAccessor< T >::operator[] ( const int ix)
inline

Definition at line 166 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ operator[]() [2/2]

template<class T>
const T & casacore::ArrayBaseAccessor< T >::operator[] ( const int ix) const
inline

Index along current axis.

Definition at line 165 of file ArrayAccessor.h.

References ptr_p, and step_p.

◆ rbegin() [1/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::rbegin ( )
inline

Begin when reverse indexing.

Definition at line 189 of file ArrayAccessor.h.

References end_p, and step_p.

◆ rbegin() [2/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::rbegin ( const int n)
inline

Definition at line 190 of file ArrayAccessor.h.

References end_p, and step_p.

◆ rend() [1/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::rend ( )
inline

End when reverse indexing.

Definition at line 183 of file ArrayAccessor.h.

References begin_p, and step_p.

◆ rend() [2/2]

template<class T>
const T * casacore::ArrayBaseAccessor< T >::rend ( const int n)
inline

Definition at line 184 of file ArrayAccessor.h.

References begin_p, and step_p.

◆ step()

template<class T>
size_t casacore::ArrayBaseAccessor< T >::step ( )
inline

Definition at line 160 of file ArrayAccessor.h.

References step_p.

Member Data Documentation

◆ arrayPtr_p

template<class T>
const Array<T>* casacore::ArrayBaseAccessor< T >::arrayPtr_p
protected

The pointer to belonging array.

Definition at line 196 of file ArrayAccessor.h.

Referenced by ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), baseArray(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), init(), init(), init(), casacore::ArrayAccessor< T, Axis< U > >::initOff(), casacore::ArrayAccessor< T, AxisN >::initOff(), casacore::ArrayAccessor< T, Axis< U > >::initStep(), casacore::ArrayAccessor< T, AxisN >::initStep(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), operator=(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), and casacore::ArrayAccessor< T, AxisN >::prev().

◆ axis_p

◆ begin_p

◆ end_p

◆ ptr_p

template<class T>
T* casacore::ArrayBaseAccessor< T >::ptr_p
protected

Current access pointer.

Definition at line 200 of file ArrayAccessor.h.

Referenced by ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), ArrayBaseAccessor(), data(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, Axis< U > >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), casacore::ArrayAccessor< T, AxisN >::index(), init(), init(), init(), casacore::ArrayAccessor< T, Axis< U > >::initStep(), casacore::ArrayAccessor< T, AxisN >::initStep(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, Axis< U > >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, AxisN >::next(), casacore::ArrayAccessor< T, Axis< U > >::operator!=(), casacore::ArrayAccessor< T, Axis< U > >::operator!=(), casacore::ArrayAccessor< T, AxisN >::operator!=(), casacore::ArrayAccessor< T, AxisN >::operator!=(), operator*(), operator*(), operator++(), operator++(), operator+=(), operator--(), operator--(), operator-=(), operator=(), casacore::ArrayAccessor< T, Axis< U > >::operator==(), casacore::ArrayAccessor< T, Axis< U > >::operator==(), casacore::ArrayAccessor< T, AxisN >::operator==(), casacore::ArrayAccessor< T, AxisN >::operator==(), operator[](), operator[](), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, Axis< U > >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, AxisN >::prev(), casacore::ArrayAccessor< T, Axis< U > >::reset(), casacore::ArrayAccessor< T, Axis< U > >::reset(), casacore::ArrayAccessor< T, AxisN >::reset(), and casacore::ArrayAccessor< T, AxisN >::reset().

◆ step_p


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