Loading...
Searching...
No Matches
sliceRange::indexer Class Reference

A value indexer, for iteration or generation. More...

#include <sliceRange.H>

Inheritance diagram for sliceRange::indexer:

Public Types

typedef label value_type
typedef label difference_type
typedef const label * pointer
typedef label reference

Public Member Functions

constexpr indexer () noexcept
 Default construct with zero value and stride = 1.
constexpr indexer (const label val, const label stride) noexcept
 Construct with specified value and stride.
constexpr label value () const noexcept
 The current value.
constexpr label stride () const noexcept
 The stride.
constexpr label value (const label n) const noexcept
 Value with offset.
void prev () noexcept
 Decrement value.
void prev (const label n) noexcept
 Decrease value.
void next () noexcept
 Increment value.
void next (const label n) noexcept
 Increase value.
constexpr label operator* () const noexcept
 Return the value.
label operator() () noexcept
 Apply a postfix increment and return the current value.

Detailed Description

A value indexer, for iteration or generation.

Definition at line 291 of file sliceRange.H.

Member Typedef Documentation

◆ value_type

typedef label value_type

Definition at line 306 of file sliceRange.H.

◆ difference_type

typedef label difference_type

Definition at line 307 of file sliceRange.H.

◆ pointer

typedef const label* pointer

Definition at line 308 of file sliceRange.H.

◆ reference

typedef label reference

Definition at line 309 of file sliceRange.H.

Constructor & Destructor Documentation

◆ indexer() [1/2]

indexer ( )
inlineconstexprnoexcept

Default construct with zero value and stride = 1.

Definition at line 84 of file sliceRangeI.H.

References Foam::noexcept.

◆ indexer() [2/2]

indexer ( const label val,
const label stride )
inlineconstexprnoexcept

Construct with specified value and stride.

Definition at line 91 of file sliceRangeI.H.

References Foam::noexcept, and stride().

Here is the call graph for this function:

Member Function Documentation

◆ value() [1/2]

◆ stride()

◆ value() [2/2]

label value ( const label n) const
inlineconstexprnoexcept

Value with offset.

Definition at line 344 of file sliceRange.H.

References n.

◆ prev() [1/2]

◆ prev() [2/2]

void prev ( const label n)
inlinenoexcept

Decrease value.

Definition at line 357 of file sliceRange.H.

References n.

◆ next() [1/2]

◆ next() [2/2]

void next ( const label n)
inlinenoexcept

Increase value.

Definition at line 367 of file sliceRange.H.

References n.

◆ operator*()

label operator* ( ) const
inlineconstexprnoexcept

Return the value.

Definition at line 375 of file sliceRange.H.

References Foam::noexcept.

◆ operator()()

Foam::label operator() ( )
inlinenoexcept

Apply a postfix increment and return the current value.

This operator definition is required for a generator - see std::generate()

Definition at line 103 of file sliceRangeI.H.

References next(), and Foam::noexcept.

Here is the call graph for this function:

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