Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends

internal::TableBaseAccessors::Accessor< N, T, C, P > Class Template Reference

List of all members.

Public Types

typedef Types< N, T, C >::TableType TableType
typedef Types< N, T, C >::iterator iterator
typedef Types< N, T, C >
::const_iterator 
const_iterator

Public Member Functions

 Accessor (const Accessor &a)
Accessor< N, T, C, P-1 > operator[] (const unsigned int i) const

Static Public Member Functions

::ExceptionBaseExcIndexRange (int arg1, int arg2, int arg3) throw (errortext << "Index " << N-P+1 << "has a value of " << arg1 << " but needs to be in the range [" << arg2 << "," << arg3 << "[" )

Private Member Functions

 Accessor (const TableType &table, const iterator data)
 Accessor ()

Private Attributes

const TableTypetable
const iterator data

Friends

class ::Table
class Accessor
class ::Table< N, T >
class Accessor< N, T, C, P+1 >

Detailed Description

template<int N, typename T, bool C, unsigned int P>
class internal::TableBaseAccessors::Accessor< N, T, C, P >

Definition at line 150 of file table.h.


Member Typedef Documentation

template<int N, typename T, bool C, unsigned int P>
typedef Types<N,T,C>::TableType internal::TableBaseAccessors::Accessor< N, T, C, P >::TableType

Definition at line 153 of file table.h.

template<int N, typename T, bool C, unsigned int P>
typedef Types<N,T,C>::iterator internal::TableBaseAccessors::Accessor< N, T, C, P >::iterator

Definition at line 155 of file table.h.

template<int N, typename T, bool C, unsigned int P>
typedef Types<N,T,C>::const_iterator internal::TableBaseAccessors::Accessor< N, T, C, P >::const_iterator

Definition at line 156 of file table.h.


Constructor & Destructor Documentation

template<int N, typename T, bool C, unsigned int P>
internal::TableBaseAccessors::Accessor< N, T, C, P >::Accessor ( const TableType table,
const iterator  data 
) [private]

Constructor. Take a pointer to the table object to know about the sizes of the various dimensions, and a pointer to the subset of data we may access.

template<int N, typename T, bool C, unsigned int P>
internal::TableBaseAccessors::Accessor< N, T, C, P >::Accessor (  ) [private]

Default constructor. Not needed, and invisible, so private.

template<int N, typename T, bool C, unsigned int P>
internal::TableBaseAccessors::Accessor< N, T, C, P >::Accessor ( const Accessor< N, T, C, P > &  a )

Copy constructor. This constructor is public so that one can pass sub-tables to functions as arguments, as in f(table[i]).

Using this constructor is risky if accessors are stored longer than the table it points to. Don't do this.


Member Function Documentation

template<int N, typename T, bool C, unsigned int P>
Accessor<N,T,C,P-1> internal::TableBaseAccessors::Accessor< N, T, C, P >::operator[] ( const unsigned int  i ) const

Index operator. Performs a range check.

template<int N, typename T, bool C, unsigned int P>
::ExceptionBase& internal::TableBaseAccessors::Accessor< N, T, C, P >::ExcIndexRange ( int  arg1,
int  arg2,
int  arg3 
) throw (errortext << "Index " << N-P+1 << "has a value of " << arg1 << " but needs to be in the range [" << arg2 << "," << arg3 << "[" ) [static]

Exception for range check. Do not use global exception since this way we can output which index is the wrong one.


Friends And Related Function Documentation

template<int N, typename T, bool C, unsigned int P>
friend class ::Table [friend]

Definition at line 227 of file table.h.

template<int N, typename T, bool C, unsigned int P>
friend class Accessor [friend]

Definition at line 229 of file table.h.

template<int N, typename T, bool C, unsigned int P>
friend class ::Table< N, T > [friend]

Definition at line 231 of file table.h.

template<int N, typename T, bool C, unsigned int P>
friend class Accessor< N, T, C, P+1 > [friend]

Definition at line 232 of file table.h.


Member Data Documentation

template<int N, typename T, bool C, unsigned int P>
const TableType& internal::TableBaseAccessors::Accessor< N, T, C, P >::table [private]

Store the data given to the constructor. There are no non-const member functions of this class, so there is no reason not to make these elements constant.

Definition at line 219 of file table.h.

template<int N, typename T, bool C, unsigned int P>
const iterator internal::TableBaseAccessors::Accessor< N, T, C, P >::data [private]

Definition at line 220 of file table.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

deal.II documentation generated on Fri Feb 3 2012 06:04:14 by doxygen 1.7.2