Public Member Functions | Friends | List of all members
objectHit Class Reference

This class describes a combination of target object index and success flag. Behaves somewhat like std::optional. More...

Public Member Functions

constexpr objectHit () noexcept
 
 objectHit (const bool success, const label index) noexcept
 
 objectHit (Istream &is)
 
bool hit () const noexcept
 
label index () const noexcept
 
label hitObject () const noexcept
 
void reset () noexcept
 
void setHit () noexcept
 
void setMiss () noexcept
 

Friends

Ostreamoperator<< (Ostream &os, const objectHit &obj)
 

Detailed Description

This class describes a combination of target object index and success flag. Behaves somewhat like std::optional.

Definition at line 44 of file objectHit.H.

Constructor & Destructor Documentation

◆ objectHit() [1/3]

constexpr objectHit ( )
inlineconstexprnoexcept

Definition at line 60 of file objectHit.H.

◆ objectHit() [2/3]

objectHit ( const bool  success,
const label  index 
)
inlinenoexcept

Definition at line 67 of file objectHit.H.

◆ objectHit() [3/3]

objectHit ( Istream is)
inlineexplicit

Definition at line 74 of file objectHit.H.

Member Function Documentation

◆ hit()

bool hit ( ) const
inlinenoexcept

Definition at line 86 of file objectHit.H.

Referenced by Foam::operator==().

Here is the caller graph for this function:

◆ index()

label index ( ) const
inlinenoexcept

Definition at line 92 of file objectHit.H.

◆ hitObject()

label hitObject ( ) const
inlinenoexcept

Definition at line 98 of file objectHit.H.

Referenced by Foam::operator==().

Here is the caller graph for this function:

◆ reset()

void reset ( )
inlinenoexcept

Definition at line 107 of file objectHit.H.

◆ setHit()

void setHit ( )
inlinenoexcept

Definition at line 114 of file objectHit.H.

◆ setMiss()

void setMiss ( )
inlinenoexcept

Definition at line 120 of file objectHit.H.

Friends And Related Function Documentation

◆ operator<<

Ostream& operator<< ( Ostream os,
const objectHit obj 
)
friend

Definition at line 128 of file objectHit.H.


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