Loading...
Searching...
No Matches
BiIndirectList< T > Class Template Reference

Indexes into negList (negative index) or posList (zero or positive index). More...

#include <BiIndirectList.H>

Public Member Functions

 BiIndirectList (const UList< T > &posList, const UList< T > &negList, const labelUList &addr)
 Construct given the complete lists and the addressing array.
 BiIndirectList (const UList< T > &posList, const UList< T > &negList, labelList &&addr)
 Construct given the complete list and by transferring addressing.
bool empty () const noexcept
 True if the list is empty (ie, size() is zero).
label size () const noexcept
 The number of elements in the list.
const UList< T > & posList () const noexcept
 The list of positive values (without addressing).
const UList< T > & negList () const noexcept
 The list of negative values (without addressing).
const labelListaddressing () const noexcept
 The addressing used for the list.
void resetAddressing (const labelUList &addr)
 Copy reset addressing.
void resetAddressing (labelList &&addr)
 Move reset addressing.
List< Tlist () const
 Return the addressed elements as a List.
List< Toperator() () const
 Return the addressed elements as a List.
Toperator[] (const label i)
 Return non-const access to an element.
const Toperator[] (const label i) const
 Return const access to an element.
void operator= (const UList< T > &ae)
 Assignment to UList of addressed elements.
void operator= (const T &val)
 Assignment of all entries to the given value.

Static Public Member Functions

static label posIndex (const label i) noexcept
 Calculate index given whether index is into posList or negList.
static label negIndex (const label i) noexcept

Detailed Description

template<class T>
class Foam::BiIndirectList< T >

Indexes into negList (negative index) or posList (zero or positive index).

Source files

Definition at line 48 of file BiIndirectList.H.

Constructor & Destructor Documentation

◆ BiIndirectList() [1/2]

template<class T>
BiIndirectList ( const UList< T > & posList,
const UList< T > & negList,
const labelUList & addr )
inline

Construct given the complete lists and the addressing array.

Definition at line 25 of file BiIndirectListI.H.

References negList(), posList(), and Foam::T().

Here is the call graph for this function:

◆ BiIndirectList() [2/2]

template<class T>
BiIndirectList ( const UList< T > & posList,
const UList< T > & negList,
labelList && addr )
inline

Construct given the complete list and by transferring addressing.

Definition at line 39 of file BiIndirectListI.H.

References negList(), posList(), and Foam::T().

Here is the call graph for this function:

Member Function Documentation

◆ empty()

template<class T>
bool empty ( ) const
inlinenoexcept

True if the list is empty (ie, size() is zero).

Definition at line 89 of file BiIndirectList.H.

References Foam::noexcept.

◆ size()

template<class T>
label size ( ) const
inlinenoexcept

The number of elements in the list.

Definition at line 94 of file BiIndirectList.H.

References Foam::noexcept.

Referenced by list().

Here is the caller graph for this function:

◆ posList()

template<class T>
const UList< T > & posList ( ) const
inlinenoexcept

The list of positive values (without addressing).

Definition at line 99 of file BiIndirectList.H.

References Foam::noexcept.

Referenced by BiIndirectList(), and BiIndirectList().

Here is the caller graph for this function:

◆ negList()

template<class T>
const UList< T > & negList ( ) const
inlinenoexcept

The list of negative values (without addressing).

Definition at line 104 of file BiIndirectList.H.

References Foam::noexcept.

Referenced by BiIndirectList(), and BiIndirectList().

Here is the caller graph for this function:

◆ addressing()

template<class T>
const labelList & addressing ( ) const
inlinenoexcept

The addressing used for the list.

Definition at line 109 of file BiIndirectList.H.

References Foam::noexcept.

◆ posIndex()

template<class T>
label posIndex ( const label i)
inlinestaticnoexcept

Calculate index given whether index is into posList or negList.

Definition at line 114 of file BiIndirectList.H.

◆ negIndex()

template<class T>
label negIndex ( const label i)
inlinestaticnoexcept

Definition at line 115 of file BiIndirectList.H.

◆ resetAddressing() [1/2]

template<class T>
void resetAddressing ( const labelUList & addr)
inline

Copy reset addressing.

Definition at line 55 of file BiIndirectListI.H.

◆ resetAddressing() [2/2]

template<class T>
void resetAddressing ( labelList && addr)
inline

Move reset addressing.

Definition at line 62 of file BiIndirectListI.H.

◆ list()

template<class T>
Foam::List< T > list ( ) const
inline

Return the addressed elements as a List.

Definition at line 69 of file BiIndirectListI.H.

References forAll, operator[](), and size().

Referenced by operator()().

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

◆ operator()()

template<class T>
List< T > operator() ( ) const
inline

Return the addressed elements as a List.

Definition at line 141 of file BiIndirectList.H.

References list().

Here is the call graph for this function:

◆ operator[]() [1/2]

template<class T>
T & operator[] ( const label i)
inline

Return non-const access to an element.

Definition at line 85 of file BiIndirectListI.H.

References Foam::T().

Referenced by list(), operator=(), and operator=().

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

◆ operator[]() [2/2]

template<class T>
const T & operator[] ( const label i) const
inline

Return const access to an element.

Definition at line 94 of file BiIndirectListI.H.

References Foam::T().

Here is the call graph for this function:

◆ operator=() [1/2]

template<class T>
void operator= ( const UList< T > & ae)
inline

Assignment to UList of addressed elements.

Definition at line 103 of file BiIndirectListI.H.

References Foam::abort(), Foam::FatalError, FatalErrorInFunction, forAll, operator[](), and UList< T >::size().

Here is the call graph for this function:

◆ operator=() [2/2]

template<class T>
void operator= ( const T & val)
inline

Assignment of all entries to the given value.

Definition at line 122 of file BiIndirectListI.H.

References forAll, operator[](), and Foam::T().

Here is the call graph for this function:

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