Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

TET::Mesh::Oriented_List< DimensionT, StorageT > Class Template Reference

A list of oriented primitives that make up a mesh. More...

#include <tetmeshorientedlist.h>

Inheritance diagram for TET::Mesh::Oriented_List< DimensionT, StorageT >:

Inheritance graph
[legend]
Collaboration diagram for TET::Mesh::Oriented_List< DimensionT, StorageT >:

Collaboration graph
[legend]
List of all members.

Public Member Functions


Detailed Description

template<class DimensionT, class StorageT>
class TET::Mesh::Oriented_List< DimensionT, StorageT >

A list of oriented primitives that make up a mesh.

See also:
List
Author:
Jens Hannemann
Id
tetmeshorientedlist.h,v 1.19.2.1 2001/09/17 14:58:26 jh Exp

Definition at line 44 of file tetmeshorientedlist.h.


Constructor & Destructor Documentation

template<class DimensionT, class StorageT>
TET::Mesh::Oriented_List< DimensionT, StorageT >::Oriented_List< DimensionT, StorageT >  ) 
 

Default constructor.

By default, the list is created in fast_insertion() mode, as it is most desirable during mesh setup. After setup completion, you can reduce memory requirements by disabling fast_insertion().

template<class DimensionT, class StorageT>
TET::Mesh::Oriented_List< DimensionT, StorageT >::Oriented_List< DimensionT, StorageT > const bool  fast_insert  ) 
 

Constructor to set list into given insertion mode.

Using this constructor, you can determine whether the list will be created in fast or slow insertion mode.

Parameters:
fast_insert determine insertion mode of the list

template<class DimensionT, class StorageT>
TET::Mesh::Oriented_List< DimensionT, StorageT >::~Oriented_List< DimensionT, StorageT >  )  [virtual]
 

Destructor.

Deletes internal map if list was in fast_insertion() mode.


Member Function Documentation

template<class DimensionT, class StorageT>
StorageT TET::Mesh::Oriented_List< DimensionT, StorageT >::insert const DimensionT &  element  ) 
 

Insert new element into list.

When an element is added, it is checked whether it is already contained in the list thus preventing multiple identical entries. The index into the list is returned for later reference.

The returned index will be negative, if the element itself is not in the list, but the flipped element (which points in the opposite direction) is. This way, only one bit is needed to store the information about an element's direction. For this to work, the elements must provide a member function named flip(), which returns the flipped element.

If the list is in in fast insertion mode, insertion will be done in logarithmic time, otherwise in linear time.

Parameters:
element element to be added
Returns:
index of element in list (negative, if element in list is flipped)

Definition at line 143 of file tetmeshorientedlist.h.

template<class DimensionT, class StorageT>
DimensionT TET::Mesh::Oriented_List< DimensionT, StorageT >::operator[] const StorageT  index  )  const
 

Unchecked random access.

As orientation information is indicated by the sign of the given index, the index must not be zero.

Parameters:
index number of element to be retrieved
Precondition:
non-zero index: index!=0
Returns:
copy of element

Definition at line 129 of file tetmeshorientedlist.h.


The documentation for this class was generated from the following file:
Generated on Sun Apr 25 11:59:27 2004 for TETlib by doxygen 1.3.6