labelRanges Class Reference

A list of labelRange. More...

Inheritance diagram for labelRanges:
[legend]
Collaboration diagram for labelRanges:
[legend]

Classes

class  const_iterator
 Forward input iterator with const access. More...
 

Public Member Functions

 labelRanges ()=default
 Default construct. More...
 
 labelRanges (const label nElem)
 Construct given size. More...
 
 labelRanges (Istream &is)
 Construct from Istream. More...
 
bool found (const label value) const
 Return true if the value is found any of the sub-ranges. More...
 
bool add (const labelRange &range)
 Add the range to the list. More...
 
bool remove (const labelRange &range)
 Remove the range from the list. More...
 
const_iterator cbegin () const noexcept
 A const_iterator set to the beginning of the list. More...
 
const const_iterator cend () const noexcept
 A const_iterator set to beyond the end of the list. More...
 
const_iterator begin () const noexcept
 A const_iterator set to the beginning of the list. More...
 
const const_iterator end () const noexcept
 A const_iterator set to beyond the end of the list. More...
 

Friends

Istreamoperator>> (Istream &is, labelRanges &ranges)
 
Ostreamoperator<< (Ostream &os, const labelRanges &ranges)
 

Detailed Description

A list of labelRange.

Source files

Definition at line 59 of file labelRanges.H.

Constructor & Destructor Documentation

◆ labelRanges() [1/3]

labelRanges ( )
default

Default construct.

◆ labelRanges() [2/3]

labelRanges ( const label  nElem)
inlineexplicit

Construct given size.

Definition at line 31 of file labelRangesI.H.

◆ labelRanges() [3/3]

labelRanges ( Istream is)

Construct from Istream.

Definition at line 128 of file labelRanges.C.

Member Function Documentation

◆ found()

bool found ( const label  value) const
inline

Return true if the value is found any of the sub-ranges.

Definition at line 140 of file labelRangesI.H.

References range.

◆ add()

bool add ( const labelRange range)

Add the range to the list.

Definition at line 136 of file labelRanges.C.

References append(), IntRange< IntType >::clear(), forAll, labelRange::join(), labelRange::overlaps(), and range.

Here is the call graph for this function:

◆ remove()

bool remove ( const labelRange range)

Remove the range from the list.

Definition at line 196 of file labelRanges.C.

References IntRange< IntType >::clampSize(), labelRange::debug, Foam::endl(), IntRange< IntType >::first(), forAll, Foam::Info, IntRange< IntType >::last(), Foam::printRange(), range, and labelRange::reset().

Here is the call graph for this function:

◆ cbegin()

Foam::labelRanges::const_iterator cbegin ( ) const
inlinenoexcept

A const_iterator set to the beginning of the list.

Definition at line 113 of file labelRangesI.H.

◆ cend()

const Foam::labelRanges::const_iterator cend ( ) const
inlinenoexcept

A const_iterator set to beyond the end of the list.

Definition at line 120 of file labelRangesI.H.

◆ begin()

Foam::labelRanges::const_iterator begin ( ) const
inlinenoexcept

A const_iterator set to the beginning of the list.

Definition at line 127 of file labelRangesI.H.

◆ end()

const Foam::labelRanges::const_iterator end ( ) const
inlinenoexcept

A const_iterator set to beyond the end of the list.

Definition at line 134 of file labelRangesI.H.

Friends And Related Function Documentation

◆ operator>>

Istream & operator>> ( Istream is,
labelRanges ranges 
)
friend

◆ operator<<

Ostream & operator<< ( Ostream os,
const labelRanges ranges 
)
friend

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