38#ifndef __BASE_TEMPERATURE_HH__
39#define __BASE_TEMPERATURE_HH__
The class stores temperatures in Kelvin and provides helper methods to convert to/from Celsius.
friend constexpr Temperature operator/(const Temperature &lhs, const double &rhs)
double toFahrenheit() const
Temperature & operator+=(const Temperature &rhs)
friend std::ostream & operator<<(std::ostream &out, const Temperature &t)
static Temperature fromCelsius(double _value)
constexpr bool operator>(const Temperature &rhs) const
constexpr double toKelvin() const
constexpr Temperature(double _value=0.0)
Explicit constructor assigning a value.
constexpr bool operator<=(const Temperature &rhs) const
constexpr double toCelsius() const
constexpr Temperature operator-(const Temperature &rhs) const
double value
Temperature in Kelvin.
Temperature & operator/=(const double &rhs)
constexpr bool operator<(const Temperature &rhs) const
Temperature & operator-=(const Temperature &rhs)
friend constexpr Temperature operator*(const Temperature &lhs, const double &rhs)
constexpr bool operator!=(const Temperature &rhs) const
static Temperature fromFahrenheit(double _value)
constexpr bool operator==(const Temperature &rhs) const
Temperature & operator*=(const double &rhs)
constexpr Temperature operator+(const Temperature &rhs) const
static Temperature fromKelvin(double _value)
constexpr bool operator>=(const Temperature &rhs) const
Temp operator/(Temp l, Temp r)
Temp operator*(Temp l, Temp r)
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.