UCompactListList< T > Class Template Reference

Unallocated base class of CompactListList. More...

Inheritance diagram for UCompactListList< T >:

Public Member Functions

 UCompactListList ()
 Null constructor. More...
 
 UCompactListList (const UList< label > &offsets, const UList< T > &m)
 Construct from components. More...
 
label size () const
 Return the primary size, i.e. the number of rows. More...
 
bool empty () const
 Return true if the number of rows is zero. More...
 
const UList< label > & offsets () const
 Return the offset table (= size()+1) More...
 
UList< label > & offsets ()
 Return non-const access to the offset table. More...
 
const UList< T > & m () const
 Return the packed matrix of data. More...
 
UList< T > & m ()
 Return non-const access to the packed matrix of data. More...
 
void shallowCopy (const UCompactListList< T > &)
 Copy the ULists, but not the underlying data. More...
 
void deepCopy (const UCompactListList< T > &)
 Copy the underlying data. More...
 
label index (const label row, const label col) const
 Return index into m. More...
 
label whichRow (const label index) const
 Get row for index into m. More...
 
label whichColumn (const label row, const label index) const
 Get column index (j) given above row. More...
 
labelList sizes () const
 Return sizes (to be used e.g. for construction) More...
 
template<class Container = List<T>>
List< Container > list () const
 Convert to List<Container> More...
 
UList< Toperator[] (const label i)
 Return subscript-checked row as UList. More...
 
const UList< Toperator[] (const label i) const
 Return const subscript-checked row as UList. More...
 
Toperator() (const label i, const label j)
 Return subscript-checked element. More...
 
const Toperator() (const label i, const label j) const
 Return const subscript-checked element. More...
 
void operator= (const T &)
 Assignment of all entries to the given value. More...
 
template<class Container >
Foam::List< Container > list () const
 

Static Public Member Functions

static const UCompactListList< T > & null ()
 Return a null UCompactListList. More...
 
template<class ListType , class ListListType >
static void setSizeToListList (ListType &offsets, ListType &m, const ListListType &ll)
 Set the sizes to match that of the given list-list. More...
 
template<class ListType , class ListListType >
static void setSizeAndValuesToListList (ListType &offsets, ListType &m, const ListListType &ll)
 Set the sizes and values to match that of the given list-list. More...
 

Friends

Ostreamoperator (Ostream &, const UCompactListList< T > &)
 

Detailed Description

template<class T>
class Foam::UCompactListList< T >

Unallocated base class of CompactListList.

Source files

Definition at line 57 of file UCompactListList.H.

Constructor & Destructor Documentation

◆ UCompactListList() [1/2]

Null constructor.

Definition at line 32 of file UCompactListListI.H.

◆ UCompactListList() [2/2]

UCompactListList ( const UList< label > &  offsets,
const UList< T > &  m 
)
inline

Construct from components.

Definition at line 40 of file UCompactListListI.H.

Member Function Documentation

◆ null()

const Foam::UCompactListList< T > & null
inlinestatic

Return a null UCompactListList.

Definition at line 55 of file UCompactListListI.H.

◆ setSizeToListList()

void setSizeToListList ( ListType &  offsets,
ListType &  m,
const ListListType &  ll 
)
static

Set the sizes to match that of the given list-list.

Definition at line 32 of file UCompactListList.C.

References forAll.

Referenced by CompactListList< T >::setSize().

Here is the caller graph for this function:

◆ setSizeAndValuesToListList()

void setSizeAndValuesToListList ( ListType &  offsets,
ListType &  m,
const ListListType &  ll 
)
static

Set the sizes and values to match that of the given list-list.

Definition at line 55 of file UCompactListList.C.

References forAll, and k.

Referenced by CompactListList< T >::CompactListList().

Here is the caller graph for this function:

◆ size()

Foam::label size
inline

Return the primary size, i.e. the number of rows.

Definition at line 62 of file UCompactListListI.H.

Referenced by decompositionMethod::calcCellCells(), and get_num_edges_list().

Here is the caller graph for this function:

◆ empty()

bool empty
inline

Return true if the number of rows is zero.

Definition at line 69 of file UCompactListListI.H.

◆ offsets() [1/2]

const Foam::UList< Foam::label > & offsets
inline

Return the offset table (= size()+1)

Definition at line 77 of file UCompactListListI.H.

Referenced by decompositionMethod::calcCellCells().

Here is the caller graph for this function:

◆ offsets() [2/2]

Foam::UList< Foam::label > & offsets
inline

Return non-const access to the offset table.

Definition at line 84 of file UCompactListListI.H.

◆ m() [1/2]

const Foam::UList< T > & m
inline

Return the packed matrix of data.

Definition at line 91 of file UCompactListListI.H.

Referenced by decompositionMethod::calcCellCells(), cellEdgeAddressingData::cellEdgeAddressingData(), and get_edge_list().

Here is the caller graph for this function:

◆ m() [2/2]

Foam::UList< T > & m
inline

Return non-const access to the packed matrix of data.

Definition at line 99 of file UCompactListListI.H.

◆ shallowCopy()

void shallowCopy ( const UCompactListList< T > &  l)
inline

Copy the ULists, but not the underlying data.

Definition at line 106 of file UCompactListListI.H.

Referenced by CompactListList< T >::clear(), CompactListList< label >::CompactListList(), CompactListList< T >::CompactListList(), CompactListList< T >::setSize(), and CompactListList< T >::transfer().

Here is the caller graph for this function:

◆ deepCopy()

void deepCopy ( const UCompactListList< T > &  l)
inline

Copy the underlying data.

Definition at line 117 of file UCompactListListI.H.

◆ index()

Foam::label index ( const label  row,
const label  col 
) const
inline

Return index into m.

Definition at line 128 of file UCompactListListI.H.

◆ whichRow()

Foam::label whichRow ( const label  index) const
inline

Get row for index into m.

Definition at line 139 of file UCompactListListI.H.

◆ whichColumn()

Foam::label whichColumn ( const label  row,
const label  index 
) const
inline

Get column index (j) given above row.

Definition at line 153 of file UCompactListListI.H.

◆ sizes()

Return sizes (to be used e.g. for construction)

Definition at line 78 of file UCompactListList.C.

References forAll, and List< T >::size().

Referenced by get_num_edges_list().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ list() [1/2]

List<Container> list ( ) const

Convert to List<Container>

Referenced by multiLevelDecomp::decompose(), renumberMethod::renumber(), CuthillMcKeeRenumber::renumber(), and springRenumber::renumber().

Here is the caller graph for this function:

◆ operator[]() [1/2]

Foam::UList< T > operator[] ( const label  i)
inline

Return subscript-checked row as UList.

Definition at line 166 of file UCompactListListI.H.

◆ operator[]() [2/2]

const Foam::UList< T > operator[] ( const label  i) const
inline

Return const subscript-checked row as UList.

Definition at line 178 of file UCompactListListI.H.

References Foam::T().

Here is the call graph for this function:

◆ operator()() [1/2]

T & operator() ( const label  i,
const label  j 
)
inline

Return subscript-checked element.

Definition at line 193 of file UCompactListListI.H.

◆ operator()() [2/2]

const T & operator() ( const label  i,
const label  j 
) const
inline

Return const subscript-checked element.

Definition at line 204 of file UCompactListListI.H.

◆ operator=()

void operator= ( const T t)
inline

Assignment of all entries to the given value.

Definition at line 215 of file UCompactListListI.H.

◆ list() [2/2]

Foam::List<Container> list ( ) const

Definition at line 95 of file UCompactListList.C.

References forAll.

Friends And Related Function Documentation

◆ operator

Ostream& operator ( Ostream ,
const UCompactListList< T > &   
)
friend

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