SliceList< T > Class Template Reference

A List with indirect slice addressing. More...

Inheritance diagram for SliceList< T >:
[legend]
Collaboration diagram for SliceList< T >:
[legend]

Public Member Functions

 SliceList (const UList< T > &values, const sliceRange &addr)
 Copy construct from values list and slicing. More...
 
const Addr & addressing () const
 The list addressing. More...
 
Addr & addressing ()
 The list addressing. More...
 
- Public Member Functions inherited from IndirectListBase< T, sliceRange >
 IndirectListBase ()=delete
 No null construct. More...
 
 IndirectListBase (const UList< T > &values, const sliceRange &addr)
 Store references to the values list and the addressing array. More...
 
label size () const
 The number of elements in the list. More...
 
bool empty () const
 True if the list is empty (ie, size() is zero). More...
 
bool uniform () const
 True if all entries have identical values, and list is non-empty. More...
 
Tfirst ()
 The first element of the list. More...
 
const Tfirst () const
 The first element of the list. More...
 
Tlast ()
 The last element of the list. More...
 
const Tlast () const
 The last element of the list. More...
 
const UList< T > & values () const
 The list of values (without addressing) More...
 
UList< T > & values ()
 The list of values (without addressing) More...
 
const sliceRangeaddressing () const
 The addressing used for the list. More...
 
label find (const T &val, const label start=0) const
 Find index of the first occurrence of the value. More...
 
label rfind (const T &val, const label pos=-1) const
 Find index of the last occurrence of the value. More...
 
bool found (const T &val, const label start=0) const
 True if the value if found in the list. Linear search. More...
 
List< Toperator() () const
 Return the addressed elements as a List. More...
 
Toperator[] (const label i)
 Non-const access to an element in the list. More...
 
const Toperator[] (const label i) const
 Const access to an element in the list. More...
 
void operator= (const T &val)
 Assign all addressed elements to the given value. More...
 
void operator= (const zero)
 Assignment of all entries to zero. More...
 
void operator= (const UList< T > &rhs)
 Deep copy values from a list of the addressed elements. More...
 
void operator= (const IndirectListBase< T, sliceRange > &rhs)
 Deep copy values from a list of the addressed elements. More...
 
void operator= (const IndirectListBase< T, AnyAddr > &rhs)
 Deep copy values from a list of the addressed elements. More...
 
iterator begin ()
 Return an iterator at begin of list. More...
 
const_iterator begin () const
 Return a const_iterator at end of list. More...
 
iterator end ()
 Return an iterator at end of list. More...
 
const_iterator end () const
 Return a const_iterator at end of list. More...
 
const_iterator cbegin () const
 Return a const_iterator at begin of list. More...
 
const_iterator cend () const
 Return a const_iterator at end of list. More...
 
OstreamwriteList (Ostream &os, const label shortLen=0) const
 Write List, with line-breaks in ASCII when length exceeds shortLen. More...
 

Additional Inherited Members

- Public Types inherited from IndirectListBase< T, sliceRange >
typedef T value_type
 Type of values the list contains. More...
 
typedef Tpointer
 The pointer type for non-const access to value_type items. More...
 
typedef Treference
 The type used for storing into value_type objects. More...
 
typedef label size_type
 The type to represent the size of a UList. More...
 
typedef label difference_type
 The difference between iterator objects. More...
 
typedef sliceRange addressing_type
 The addressing type (non-stl definition) More...
 
- Public Attributes inherited from IndirectListBase< T, sliceRange >
const typedef Tconst_pointer
 The pointer type for const access to value_type items. More...
 
const typedef Tconst_reference
 The type used for reading from constant value_type objects. More...
 
- Protected Member Functions inherited from IndirectListBase< T, sliceRange >
void copyList (const ListType &rhs)
 Copy values The number of elements in the list. More...
 

Detailed Description

template<class T>
class Foam::SliceList< T >

A List with indirect slice addressing.

Source files

Definition at line 53 of file SliceList.H.

Constructor & Destructor Documentation

◆ SliceList()

SliceList ( const UList< T > &  values,
const sliceRange addr 
)
inline

Copy construct from values list and slicing.

Definition at line 63 of file SliceList.H.

Member Function Documentation

◆ addressing() [1/2]

const Addr& addressing
inline

The list addressing.

Definition at line 80 of file IndirectListAddressing.H.

◆ addressing() [2/2]

Addr& addressing
inline

The list addressing.

Definition at line 86 of file IndirectListAddressing.H.


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