roo_quantity
API Documentation for roo_quantity
Loading...
Searching...
No Matches
roo_quantity::Pressure Class Reference

Representation of pressure, internally stored as floating-point Pascals. More...

#include <pressure.h>

Public Member Functions

 Pressure ()
 Creates a pressure object representing an 'unknown' pressure.
 
float inGigaPascals () const
 Returns the pressure in GigaPascals.
 
float inMegaPascals () const
 Returns the pressure in MegaPascals.
 
float inBars () const
 Returns the pressure in bars.
 
float inKiloPascals () const
 Returns the pressure in kiloPascals.
 
float inHectoPascals () const
 Returns the pressure in HectoPascals.
 
float inPascals () const
 Returns the pressure in Pascals.
 
float inMilliPascals () const
 Returns the pressure in milliPascals.
 
float inMicroPascals () const
 Returns the pressure in microPascals.
 
float inPSI () const
 Returns the pressure in PSI (pound per square inch).
 
bool isUnknown () const
 Returns whether the object represents an unknown pressure.
 
bool operator< (const Pressure &other) const
 
bool operator== (const Pressure &other) const
 
bool operator> (const Pressure &other) const
 
bool operator<= (const Pressure &other) const
 
bool operator>= (const Pressure &other) const
 
bool operator!= (const Pressure &other) const
 
Pressureoperator+= (const Pressure &other)
 
Pressureoperator-= (const Pressure &other)
 
Pressureoperator*= (float multi)
 
Pressureoperator/= (float div)
 

Friends

Pressure UnknownPressure ()
 Returns a pressure object representing an unknown pressure.
 
Pressure PressureInPascals (float)
 Returns a pressure object equivalent to the specified pressure expressed in Pascals.
 

Detailed Description

Representation of pressure, internally stored as floating-point Pascals.

Definition at line 22 of file pressure.h.

Constructor & Destructor Documentation

◆ Pressure()

roo_quantity::Pressure::Pressure ( )
inline

Creates a pressure object representing an 'unknown' pressure.

Definition at line 25 of file pressure.h.

Member Function Documentation

◆ inBars()

float roo_quantity::Pressure::inBars ( ) const
inline

Returns the pressure in bars.

Definition at line 34 of file pressure.h.

◆ inGigaPascals()

float roo_quantity::Pressure::inGigaPascals ( ) const
inline

Returns the pressure in GigaPascals.

Definition at line 28 of file pressure.h.

◆ inHectoPascals()

float roo_quantity::Pressure::inHectoPascals ( ) const
inline

Returns the pressure in HectoPascals.

Definition at line 40 of file pressure.h.

◆ inKiloPascals()

float roo_quantity::Pressure::inKiloPascals ( ) const
inline

Returns the pressure in kiloPascals.

Definition at line 37 of file pressure.h.

◆ inMegaPascals()

float roo_quantity::Pressure::inMegaPascals ( ) const
inline

Returns the pressure in MegaPascals.

Definition at line 31 of file pressure.h.

◆ inMicroPascals()

float roo_quantity::Pressure::inMicroPascals ( ) const
inline

Returns the pressure in microPascals.

Definition at line 49 of file pressure.h.

◆ inMilliPascals()

float roo_quantity::Pressure::inMilliPascals ( ) const
inline

Returns the pressure in milliPascals.

Definition at line 46 of file pressure.h.

◆ inPascals()

float roo_quantity::Pressure::inPascals ( ) const
inline

◆ inPSI()

float roo_quantity::Pressure::inPSI ( ) const
inline

Returns the pressure in PSI (pound per square inch).

Definition at line 52 of file pressure.h.

◆ isUnknown()

bool roo_quantity::Pressure::isUnknown ( ) const
inline

Returns whether the object represents an unknown pressure.

Definition at line 55 of file pressure.h.

◆ operator!=()

bool roo_quantity::Pressure::operator!= ( const Pressure other) const
inline

Definition at line 77 of file pressure.h.

◆ operator*=()

Pressure & roo_quantity::Pressure::operator*= ( float  multi)
inline

Definition at line 91 of file pressure.h.

◆ operator+=()

Pressure & roo_quantity::Pressure::operator+= ( const Pressure other)
inline

Definition at line 81 of file pressure.h.

References inPascals().

◆ operator-=()

Pressure & roo_quantity::Pressure::operator-= ( const Pressure other)
inline

Definition at line 86 of file pressure.h.

References inPascals().

◆ operator/=()

Pressure & roo_quantity::Pressure::operator/= ( float  div)
inline

Definition at line 96 of file pressure.h.

◆ operator<()

bool roo_quantity::Pressure::operator< ( const Pressure other) const
inline

Definition at line 57 of file pressure.h.

◆ operator<=()

bool roo_quantity::Pressure::operator<= ( const Pressure other) const
inline

Definition at line 69 of file pressure.h.

◆ operator==()

bool roo_quantity::Pressure::operator== ( const Pressure other) const
inline

Definition at line 61 of file pressure.h.

◆ operator>()

bool roo_quantity::Pressure::operator> ( const Pressure other) const
inline

Definition at line 65 of file pressure.h.

◆ operator>=()

bool roo_quantity::Pressure::operator>= ( const Pressure other) const
inline

Definition at line 73 of file pressure.h.

Friends And Related Symbol Documentation

◆ PressureInPascals

Pressure PressureInPascals ( float  pressure)
friend

Returns a pressure object equivalent to the specified pressure expressed in Pascals.

Definition at line 158 of file pressure.h.

◆ UnknownPressure

Pressure UnknownPressure ( )
friend

Returns a pressure object representing an unknown pressure.

Definition at line 124 of file pressure.h.


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