FEI Package Browser (Single Doxygen Collection) Version of the Day
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | List of all members
snl_fei::RaggedTable< MAP_TYPE, SET_TYPE > Class Template Reference

#include <snl_fei_RaggedTable.hpp>

Inheritance diagram for snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >:
Inheritance graph
[legend]

Public Types

typedef MAP_TYPE map_type
 
typedef SET_TYPE row_type
 
typedef MAP_TYPE::iterator iterator
 

Public Member Functions

 RaggedTable (int firstKey, int lastKey)
 
 RaggedTable (const RaggedTable< MAP_TYPE, SET_TYPE > &src)
 
virtual ~RaggedTable ()
 
void addDiagonals (int numIndices, const int *indices)
 
void addIndices (int row, int numIndices, const int *indices)
 
void addIndices (int numRows, const int *rows, int numIndices, const int *indices)
 
MAP_TYPE & getMap ()
 
const MAP_TYPE & getMap () const
 
SET_TYPE * getRow (int row)
 
iterator begin ()
 
iterator end ()
 
bool equal (const RaggedTable< MAP_TYPE, SET_TYPE > &rhs, bool quiet=true) const
 
- Public Member Functions inherited from fei::IndexTable
 IndexTable ()
 
virtual ~IndexTable ()
 
virtual void addDiagonals (int numIndices, const int *indices)=0
 
virtual void addIndices (int row, int numIndices, const int *indices)=0
 
virtual void addIndices (int numRows, const int *rows, int numIndices, const int *indices)=0
 

Private Attributes

MAP_TYPE map_
 
fei_Pool_alloc< SET_TYPE > poolAllocatorSet_
 
SET_TYPE dummy
 

Detailed Description

template<typename MAP_TYPE, typename SET_TYPE>
class snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >

Data-structure that accumulates row-column indices into a ragged table, useful for building a matrix-graph and other concepts where keys are mapped to lists of values. This class can use various maps as the underlying data-holders. Useful because specialized maps and sets are defined in fei to take advantage of data that contains significant chunks of contiguous indices.

Definition at line 29 of file snl_fei_RaggedTable.hpp.

Member Typedef Documentation

◆ map_type

template<typename MAP_TYPE , typename SET_TYPE >
typedef MAP_TYPE snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::map_type

alias for MAP_TYPE

Definition at line 41 of file snl_fei_RaggedTable.hpp.

◆ row_type

template<typename MAP_TYPE , typename SET_TYPE >
typedef SET_TYPE snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::row_type

alias for SET_TYPE

Definition at line 44 of file snl_fei_RaggedTable.hpp.

◆ iterator

template<typename MAP_TYPE , typename SET_TYPE >
typedef MAP_TYPE::iterator snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::iterator

let 'iterator' be an alias for MAP_TYPE's iterator

Definition at line 72 of file snl_fei_RaggedTable.hpp.

Constructor & Destructor Documentation

◆ RaggedTable() [1/2]

template<typename MAP_TYPE , typename SET_TYPE >
snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::RaggedTable ( int  firstKey,
int  lastKey 
)
inline

Constructor

Definition at line 90 of file snl_fei_RaggedTable.hpp.

◆ RaggedTable() [2/2]

template<typename MAP_TYPE , typename SET_TYPE >
snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::RaggedTable ( const RaggedTable< MAP_TYPE, SET_TYPE > &  src)
inline

Copy constructor

Definition at line 99 of file snl_fei_RaggedTable.hpp.

◆ ~RaggedTable()

template<typename MAP_TYPE , typename SET_TYPE >
snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::~RaggedTable
virtual

Definition at line 106 of file snl_fei_RaggedTable.hpp.

Member Function Documentation

◆ addDiagonals()

template<typename MAP_TYPE , typename SET_TYPE >
void snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::addDiagonals ( int  numIndices,
const int *  indices 
)
inlinevirtual

add entries to the diagonal of the table

Implements fei::IndexTable.

Definition at line 218 of file snl_fei_RaggedTable.hpp.

◆ addIndices() [1/2]

template<typename MAP_TYPE , typename SET_TYPE >
void snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::addIndices ( int  row,
int  numIndices,
const int *  indices 
)
inlinevirtual

◆ addIndices() [2/2]

template<typename MAP_TYPE , typename SET_TYPE >
void snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::addIndices ( int  numRows,
const int *  rows,
int  numIndices,
const int *  indices 
)
inlinevirtual

add a list of indices to several specified rows

Implements fei::IndexTable.

Definition at line 147 of file snl_fei_RaggedTable.hpp.

References snl_fei::MapTraits< MAP_TYPE >::insert(), snl_fei::SetTraits< SET_TYPE >::insert(), and snl_fei::MapTraits< MAP_TYPE >::lower_bound().

◆ getMap() [1/2]

template<typename MAP_TYPE , typename SET_TYPE >
MAP_TYPE & snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::getMap
inline

◆ getMap() [2/2]

template<typename MAP_TYPE , typename SET_TYPE >
const MAP_TYPE & snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::getMap
inline

obtain internal map attribute

Definition at line 189 of file snl_fei_RaggedTable.hpp.

◆ getRow()

template<typename MAP_TYPE , typename SET_TYPE >
RaggedTable< MAP_TYPE, SET_TYPE >::row_type * snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::getRow ( int  row)
inline

obtain specified row from internal map attribute

Definition at line 196 of file snl_fei_RaggedTable.hpp.

◆ begin()

template<typename MAP_TYPE , typename SET_TYPE >
RaggedTable< MAP_TYPE, SET_TYPE >::iterator snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::begin
inline

◆ end()

template<typename MAP_TYPE , typename SET_TYPE >
RaggedTable< MAP_TYPE, SET_TYPE >::iterator snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::end
inline

◆ equal()

template<typename MAP_TYPE , typename SET_TYPE >
bool snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::equal ( const RaggedTable< MAP_TYPE, SET_TYPE > &  rhs,
bool  quiet = true 
) const

Member Data Documentation

◆ map_

template<typename MAP_TYPE , typename SET_TYPE >
MAP_TYPE snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::map_
private

◆ poolAllocatorSet_

template<typename MAP_TYPE , typename SET_TYPE >
fei_Pool_alloc<SET_TYPE> snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::poolAllocatorSet_
private

◆ dummy

template<typename MAP_TYPE , typename SET_TYPE >
SET_TYPE snl_fei::RaggedTable< MAP_TYPE, SET_TYPE >::dummy
private

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