Cloudy
Spectral Synthesis Code for Astrophysics
Loading...
Searching...
No Matches
basic_pntr< T, lgBC > Class Template Reference

#include <container_classes.h>

Inheritance diagram for basic_pntr< T, lgBC >:

Public Types

typedef random_access_iterator_tag iterator_category
 
typedef T value_type
 
typedef T & reference
 
typedef const T & const_reference
 
typedef T * pointer
 
typedef const T * const_pointer
 
typedef size_t size_type
 
typedef ptrdiff_t difference_type
 

Public Member Functions

 basic_pntr (T *p0, T *p1, T *p2)
 
 basic_pntr (T *p0)
 
 basic_pntr ()
 
basic_pntroperator= (const basic_pntr &)=default
 
 basic_pntr (const basic_pntr &t)=default
 
basic_pntroperator++ ()
 
basic_pntroperator-- ()
 
basic_pntroperator+= (const ptrdiff_t n)
 
basic_pntroperator-= (const ptrdiff_t n)
 
T & operator* () const
 
T * operator-> () const
 
T & operator[] (const ptrdiff_t n) const
 
bool operator== (const basic_pntr &t) const
 
bool operator!= (const basic_pntr &t) const
 
bool operator< (const basic_pntr &t) const
 
bool operator<= (const basic_pntr &t) const
 
bool operator> (const basic_pntr &t) const
 
bool operator>= (const basic_pntr &t) const
 

Protected Member Functions

 ~basic_pntr ()
 

Private Member Functions

T * p_index_checked (const ptrdiff_t n) const
 
void p_set_vals (T *p0, T *p1, T *p2)
 

Private Attributes

T * p_p [p_nd]
 

Static Private Attributes

static const int p_nd = lgBC ? 3 : 1
 

Detailed Description

template<class T, bool lgBC>
class basic_pntr< T, lgBC >

basic_pntr - base class for generalization of normal pointers that enables bounds checking it comes with the full set of operators that you would expect for a random access pointer

Member Typedef Documentation

◆ const_pointer

template<class T, bool lgBC>
typedef const T* basic_pntr< T, lgBC >::const_pointer

◆ const_reference

template<class T, bool lgBC>
typedef const T& basic_pntr< T, lgBC >::const_reference

◆ difference_type

template<class T, bool lgBC>
typedef ptrdiff_t basic_pntr< T, lgBC >::difference_type

◆ iterator_category

template<class T, bool lgBC>
typedef random_access_iterator_tag basic_pntr< T, lgBC >::iterator_category

◆ pointer

template<class T, bool lgBC>
typedef T* basic_pntr< T, lgBC >::pointer

◆ reference

template<class T, bool lgBC>
typedef T& basic_pntr< T, lgBC >::reference

◆ size_type

template<class T, bool lgBC>
typedef size_t basic_pntr< T, lgBC >::size_type

◆ value_type

template<class T, bool lgBC>
typedef T basic_pntr< T, lgBC >::value_type

Constructor & Destructor Documentation

◆ basic_pntr() [1/4]

◆ basic_pntr() [2/4]

template<class T, bool lgBC>
basic_pntr< T, lgBC >::basic_pntr ( T * p0)
inline

References NULL, and p_set_vals().

Here is the call graph for this function:

◆ basic_pntr() [3/4]

template<class T, bool lgBC>
basic_pntr< T, lgBC >::basic_pntr ( )
inline

References NULL, and p_set_vals().

Here is the call graph for this function:

◆ basic_pntr() [4/4]

template<class T, bool lgBC>
basic_pntr< T, lgBC >::basic_pntr ( const basic_pntr< T, lgBC > & t)
default

References basic_pntr().

Here is the call graph for this function:

◆ ~basic_pntr()

template<class T, bool lgBC>
basic_pntr< T, lgBC >::~basic_pntr ( )
inlineprotected

Member Function Documentation

◆ operator!=()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator!= ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator*()

template<class T, bool lgBC>
T & basic_pntr< T, lgBC >::operator* ( ) const
inline

References p_index_checked().

Referenced by const_pntr< T, lgBC >::operator*().

Here is the call graph for this function:

◆ operator++()

template<class T, bool lgBC>
basic_pntr & basic_pntr< T, lgBC >::operator++ ( )
inline

References basic_pntr(), and p_p.

Referenced by const_pntr< T, lgBC >::operator++(), and pntr< T, lgBC >::operator++().

Here is the call graph for this function:

◆ operator+=()

template<class T, bool lgBC>
basic_pntr & basic_pntr< T, lgBC >::operator+= ( const ptrdiff_t n)
inline

References basic_pntr(), and p_p.

Referenced by const_pntr< T, lgBC >::operator+=().

Here is the call graph for this function:

◆ operator--()

template<class T, bool lgBC>
basic_pntr & basic_pntr< T, lgBC >::operator-- ( )
inline

References basic_pntr(), and p_p.

Referenced by const_pntr< T, lgBC >::operator--(), and pntr< T, lgBC >::operator--().

Here is the call graph for this function:

◆ operator-=()

template<class T, bool lgBC>
basic_pntr & basic_pntr< T, lgBC >::operator-= ( const ptrdiff_t n)
inline

References basic_pntr(), and p_p.

Referenced by const_pntr< T, lgBC >::operator-=().

Here is the call graph for this function:

◆ operator->()

template<class T, bool lgBC>
T * basic_pntr< T, lgBC >::operator-> ( ) const
inline

References p_index_checked().

Referenced by const_pntr< T, lgBC >::operator->().

Here is the call graph for this function:

◆ operator<()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator< ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator<=()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator<= ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator=()

template<class T, bool lgBC>
basic_pntr & basic_pntr< T, lgBC >::operator= ( const basic_pntr< T, lgBC > & )
default

References basic_pntr().

Here is the call graph for this function:

◆ operator==()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator== ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator>()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator> ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator>=()

template<class T, bool lgBC>
bool basic_pntr< T, lgBC >::operator>= ( const basic_pntr< T, lgBC > & t) const
inline

References basic_pntr(), and p_p.

Here is the call graph for this function:

◆ operator[]()

template<class T, bool lgBC>
T & basic_pntr< T, lgBC >::operator[] ( const ptrdiff_t n) const
inline

References p_index_checked().

Referenced by const_pntr< T, lgBC >::operator[]().

Here is the call graph for this function:

◆ p_index_checked()

template<class T, bool lgBC>
T * basic_pntr< T, lgBC >::p_index_checked ( const ptrdiff_t n) const
inlineprivate

References OUT_OF_RANGE(), and p_p.

Referenced by operator*(), operator->(), and operator[]().

Here is the call graph for this function:

◆ p_set_vals()

template<class T, bool lgBC>
void basic_pntr< T, lgBC >::p_set_vals ( T * p0,
T * p1,
T * p2 )
inlineprivate

References p_p.

Referenced by basic_pntr(), basic_pntr(), and basic_pntr().

Member Data Documentation

◆ p_nd

template<class T, bool lgBC>
const int basic_pntr< T, lgBC >::p_nd = lgBC ? 3 : 1
staticprivate

◆ p_p


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