OPAL (Object Oriented Parallel Accelerator Library) 2022.1
OPAL
Public Types | Public Member Functions | Protected Attributes | List of all members
FArray1D< T, N > Class Template Reference

A templated representation for one-dimensional arrays. More...

#include <FArray1D.h>

Inheritance diagram for FArray1D< T, N >:
Inheritance graph
[legend]

Public Types

typedef T value_type
 The value type of this array. More...
 
typedef T * iterator
 Iterator for the array. More...
 
typedef const T * const_iterator
 Iterator for constant array. More...
 

Public Member Functions

 FArray1D ()
 Default constructor. More...
 
 FArray1D (const T &t)
 Constructor. More...
 
 FArray1D (const FArray1D &)
 Copy constructor. More...
 
 FArray1D (const std::initializer_list< T > &)
 Consructor with initializer list (needs C++11) (see http://en.cppreference.com/w/cpp/utility/initializer_list) More...
 
const FArray1Doperator= (const FArray1D &)
 Assignment. More...
 
T & operator() (int n)
 Get element. More...
 
const T & operator() (int n) const
 Get element. More...
 
T & operator[] (int n)
 Get element. More...
 
const T & operator[] (int n) const
 Get element. More...
 
iterator begin ()
 Get iterator pointing to beginning of array. More...
 
iterator end ()
 Get iterator pointing past end of array. More...
 
const_iterator begin () const
 Get iterator pointing to beginning of array. More...
 
const_iterator end () const
 Get iterator pointing past end of array. More...
 
int size () const
 Get array size. More...
 

Protected Attributes

data [N]
 

Detailed Description

template<class T, int N>
class FArray1D< T, N >

A templated representation for one-dimensional arrays.

Definition at line 39 of file FArray1D.h.

Member Typedef Documentation

◆ const_iterator

template<class T , int N>
typedef const T* FArray1D< T, N >::const_iterator

Iterator for constant array.

Definition at line 50 of file FArray1D.h.

◆ iterator

template<class T , int N>
typedef T* FArray1D< T, N >::iterator

Iterator for the array.

Definition at line 47 of file FArray1D.h.

◆ value_type

template<class T , int N>
typedef T FArray1D< T, N >::value_type

The value type of this array.

Definition at line 44 of file FArray1D.h.

Constructor & Destructor Documentation

◆ FArray1D() [1/4]

template<class T , int N>
FArray1D< T, N >::FArray1D

Default constructor.

Definition at line 119 of file FArray1D.h.

References begin(), end(), and Attrib::Legacy::Distribution::T.

Here is the call graph for this function:

◆ FArray1D() [2/4]

template<class T , int N>
FArray1D< T, N >::FArray1D ( const T &  t)
explicit

Constructor.

Definition at line 131 of file FArray1D.h.

References begin(), and end().

Here is the call graph for this function:

◆ FArray1D() [3/4]

template<class T , int N>
FArray1D< T, N >::FArray1D ( const FArray1D< T, N > &  rhs)

Copy constructor.

Definition at line 125 of file FArray1D.h.

References FArray1D< T, N >::begin(), begin(), and FArray1D< T, N >::end().

Here is the call graph for this function:

◆ FArray1D() [4/4]

template<class T , int N>
FArray1D< T, N >::FArray1D ( const std::initializer_list< T > &  init)

Consructor with initializer list (needs C++11) (see http://en.cppreference.com/w/cpp/utility/initializer_list)

Definition at line 138 of file FArray1D.h.

References begin(), end(), and Attrib::Legacy::Distribution::T.

Here is the call graph for this function:

Member Function Documentation

◆ begin() [1/2]

template<class T , int N>
FArray1D< T, N >::iterator FArray1D< T, N >::begin
inline

◆ begin() [2/2]

template<class T , int N>
FArray1D< T, N >::const_iterator FArray1D< T, N >::begin
inline

Get iterator pointing to beginning of array.

Definition at line 204 of file FArray1D.h.

◆ end() [1/2]

template<class T , int N>
FArray1D< T, N >::iterator FArray1D< T, N >::end
inline

◆ end() [2/2]

template<class T , int N>
FArray1D< T, N >::const_iterator FArray1D< T, N >::end
inline

Get iterator pointing past end of array.

Definition at line 210 of file FArray1D.h.

◆ operator()() [1/2]

template<class T , int N>
T & FArray1D< T, N >::operator() ( int  n)

Get element.

Definition at line 174 of file FArray1D.h.

◆ operator()() [2/2]

template<class T , int N>
const T & FArray1D< T, N >::operator() ( int  n) const

Get element.

Definition at line 183 of file FArray1D.h.

◆ operator=()

template<class T , int N>
const FArray1D< T, N > & FArray1D< T, N >::operator= ( const FArray1D< T, N > &  rhs)

Assignment.

Definition at line 155 of file FArray1D.h.

References FArray1D< T, N >::begin(), begin(), and FArray1D< T, N >::end().

Here is the call graph for this function:

◆ operator[]() [1/2]

template<class T , int N>
T & FArray1D< T, N >::operator[] ( int  n)
inline

Get element.

Definition at line 162 of file FArray1D.h.

◆ operator[]() [2/2]

template<class T , int N>
const T & FArray1D< T, N >::operator[] ( int  n) const
inline

Get element.

Definition at line 168 of file FArray1D.h.

◆ size()

template<class T , int N>
int FArray1D< T, N >::size
inline

Get array size.

Definition at line 216 of file FArray1D.h.

Referenced by scaled_norm().

Member Data Documentation

◆ data

template<class T , int N>
T FArray1D< T, N >::data[N]
protected

Definition at line 111 of file FArray1D.h.


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