instant Class Reference

An instant of time. Contains the time value and name. More...

Classes

class  less
 Less function class used in sorting instants. More...
 

Public Member Functions

 instant ()
 Construct null. More...
 
 instant (const scalar, const word &)
 Construct from components. More...
 
 instant (const scalar)
 Construct from time value. More...
 
 instant (const word &)
 Construct from word. More...
 
scalar value () const
 Value (const access) More...
 
scalar & value ()
 Value (non-const access) More...
 
const wordname () const
 Name (const access) More...
 
wordname ()
 Name (non-const access) More...
 
bool equal (const scalar) const
 Comparison used for instants to be equal. More...
 

Static Public Attributes

static const char *const typeName = "instant"
 

Friends

bool operator== (const instant &, const instant &)
 
bool operator!= (const instant &, const instant &)
 
bool operator< (const instant &, const instant &)
 
bool operator> (const instant &, const instant &)
 
Istreamoperator>> (Istream &, instant &)
 
Ostreamoperator<< (Ostream &, const instant &)
 

Detailed Description

An instant of time. Contains the time value and name.

Source files

Definition at line 66 of file instant.H.

Constructor & Destructor Documentation

◆ instant() [1/4]

instant ( )

Construct null.

Definition at line 35 of file instant.C.

◆ instant() [2/4]

instant ( const scalar  val,
const word tname 
)

Construct from components.

Definition at line 38 of file instant.C.

◆ instant() [3/4]

instant ( const scalar  val)
explicit

Construct from time value.

Definition at line 44 of file instant.C.

◆ instant() [4/4]

instant ( const word tname)
explicit

Construct from word.

Definition at line 50 of file instant.C.

Member Function Documentation

◆ value() [1/2]

scalar value ( ) const
inline

Value (const access)

Definition at line 114 of file instant.H.

Referenced by instant::less::operator()(), timeSelector::selected(), and Time::setTime().

Here is the caller graph for this function:

◆ value() [2/2]

scalar& value ( )
inline

Value (non-const access)

Definition at line 120 of file instant.H.

◆ name() [1/2]

const word& name ( ) const
inline

Name (const access)

Definition at line 126 of file instant.H.

Referenced by Time::setTime().

Here is the caller graph for this function:

◆ name() [2/2]

word& name ( )
inline

Name (non-const access)

Definition at line 132 of file instant.H.

References instant::equal(), instant::operator!=, instant::operator<, instant::operator<<, instant::operator==, instant::operator>, and instant::operator>>.

Here is the call graph for this function:

◆ equal()

bool equal ( const scalar  b) const

Comparison used for instants to be equal.

Definition at line 59 of file instant.C.

Referenced by Time::findInstancePath(), masterUncollatedFileOperation::findInstancePath(), instant::name(), Foam::operator==(), and masterUncollatedFileOperation::readObjects().

Here is the caller graph for this function:

Friends And Related Function Documentation

◆ operator==

bool operator== ( const instant ,
const instant  
)
friend

Referenced by instant::name(), and Foam::operator!=().

◆ operator!=

bool operator!= ( const instant ,
const instant  
)
friend

Referenced by instant::name().

◆ operator<

bool operator< ( const instant ,
const instant  
)
friend

Referenced by instant::name().

◆ operator>

bool operator> ( const instant ,
const instant  
)
friend

Referenced by instant::name().

◆ operator>>

Istream& operator>> ( Istream ,
instant  
)
friend

Referenced by instant::name().

◆ operator<<

Ostream& operator<< ( Ostream ,
const instant  
)
friend

Referenced by instant::name().

Member Data Documentation

◆ typeName

const char *const typeName = "instant"
static

Definition at line 91 of file instant.H.


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