FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

LPtrList< LListBase, T > Class Template Reference

Template class for non-intrusive linked PtrLists. More...

#include <OpenFOAM/LPtrList.H>


Detailed Description

template<class LListBase, class T>
class Foam::LPtrList< LListBase, T >

Template class for non-intrusive linked PtrLists.

Source files

Definition at line 70 of file LPtrList.H.

Inheritance diagram for LPtrList< LListBase, T >:
Collaboration diagram for LPtrList< LListBase, T >:

List of all members.

Classes

class  const_iterator
 An STL-conforming const_iterator. More...
class  iterator
 An STL-conforming iterator. More...

Public Types

typedef T &  reference
 Type that can be used for storing into LPtrList::value_type.
typedef T &  const_reference
 Type that can be used for storing into constant.
typedef LListBase::iterator  LListBase_iterator
typedef LListBase::const_iterator  LListBase_const_iterator

Public Member Functions

 LPtrList ()
 Null construct.
 LPtrList (T *a)
 Construct given initial T.
template<class INew >
 LPtrList (Istream &, const INew &)
 Construct from Istream using given Istream constructor class.
 LPtrList (Istream &)
 Construct from Istream using default Istream constructor class.
 LPtrList (const LPtrList &)
 Construct as copy.
 ~LPtrList ()
T &  first ()
 Return the first entry added.
const T &  first () const
 Return const access to the first entry added.
T &  last ()
 Return the last entry added.
const T &  last () const
 Return const access to the last entry added.
bool  eraseHead ()
 Remove the head element from the list and delete the pointer.
void  clear ()
 Clear the contents of the list.
void  transfer (LPtrList< LListBase, T > &)
 Transfer the contents of the argument into this List.
void  operator= (const LPtrList< LListBase, T > &)
 Assign copy.

Friends

class  iterator
class  const_iterator
Istream &  operator>> (Istream &, LPtrList< LListBase, T > &)
Ostream &  operator (Ostream &, const LPtrList< LListBase, T > &)

Member Typedef Documentation

typedef T& reference

Type that can be used for storing into LPtrList::value_type.

objects.

Reimplemented from LList< LListBase, T * >.

Definition at line 172 of file LPtrList.H.

typedef T& const_reference

Type that can be used for storing into constant.

LPtrList::value_type objects.

Reimplemented from LList< LListBase, T * >.

Definition at line 176 of file LPtrList.H.

typedef LListBase::iterator LListBase_iterator

Reimplemented from LList< LListBase, T * >.

Definition at line 181 of file LPtrList.H.

typedef LListBase::const_iterator LListBase_const_iterator

Reimplemented from LList< LListBase, T * >.

Definition at line 217 of file LPtrList.H.


Constructor & Destructor Documentation

LPtrList (  ) [inline]

Null construct.

Definition at line 95 of file LPtrList.H.

LPtrList ( T *   a  ) [inline]

Construct given initial T.

Definition at line 99 of file LPtrList.H.

LPtrList ( Istream &   is,
const INew &   iNew  
)

Construct from Istream using given Istream constructor class.

Definition at line 145 of file LPtrListIO.C.

LPtrList ( Istream &   is  )

Construct from Istream using default Istream constructor class.

Definition at line 152 of file LPtrListIO.C.

LPtrList ( const LPtrList< LListBase, T > &    )

Construct as copy.

~LPtrList (  )

Definition at line 45 of file LPtrList.C.

References clear().


Member Function Documentation

T& first (  ) [inline]

Return the first entry added.

Reimplemented from LList< LListBase, T * >.

Definition at line 125 of file LPtrList.H.

Referenced by LPtrList< DLListBase, phase >::first().

const T& first (  ) const [inline]

Return const access to the first entry added.

Reimplemented from LList< LListBase, T * >.

Definition at line 131 of file LPtrList.H.

T& last (  ) [inline]

Return the last entry added.

Reimplemented from LList< LListBase, T * >.

Definition at line 137 of file LPtrList.H.

Referenced by LPtrList< DLListBase, phase >::last().

const T& last (  ) const [inline]

Return const access to the last entry added.

Reimplemented from LList< LListBase, T * >.

Definition at line 143 of file LPtrList.H.

bool eraseHead (  )

Remove the head element from the list and delete the pointer.

Definition at line 54 of file LPtrList.C.

References T.

void clear (  )

Clear the contents of the list.

Reimplemented from LList< LListBase, T * >.

Reimplemented in DictionaryBase< DLPtrList< phase >, phase >, and DictionaryBase< DLPtrList< T >, T >.

Definition at line 70 of file LPtrList.C.

References clear().

Referenced by Foam::operator>>().

void transfer ( LPtrList< LListBase, T > &   lst  )

Transfer the contents of the argument into this List.

and annull the argument list.

Definition at line 83 of file LPtrList.C.

References clear().

void operator= ( const LPtrList< LListBase, T > &   lst  )

Assign copy.

Definition at line 93 of file LPtrList.C.

References append(), and clear().


Friends And Related Function Documentation

friend class iterator [friend]

Reimplemented from LList< LListBase, T * >.

Definition at line 85 of file LPtrList.H.

friend class const_iterator [friend]

Reimplemented from LList< LListBase, T * >.

Definition at line 88 of file LPtrList.H.

Istream& operator>> ( Istream &   ,
LPtrList< LListBase, T > &    
) [friend]
Ostream& operator ( Ostream &   ,
const LPtrList< LListBase, T > &    
) [friend]

The documentation for this class was generated from the following files:
  • src/OpenFOAM/containers/LinkedLists/accessTypes/LPtrList/LPtrList.H
  • src/OpenFOAM/containers/LinkedLists/accessTypes/LPtrList/LPtrList.C
  • src/OpenFOAM/containers/LinkedLists/accessTypes/LPtrList/LPtrListIO.C