GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 100.0% 1 / 0 / 1
Functions: 100.0% 1 / 0 / 1
Branches: -% 0 / 0 / 0

src/utilities/units/TemperatureUnit_Impl.hpp
Line Branch Exec Source
1 /***********************************************************************************************************************
2 * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC.
3 * See also https://openstudio.net/license
4 ***********************************************************************************************************************/
5
6 #ifndef UTILITIES_UNITS_TEMPERATUREUNIT_IMPL_HPP
7 #define UTILITIES_UNITS_TEMPERATUREUNIT_IMPL_HPP
8
9 #include "../UtilitiesAPI.hpp"
10 #include "Unit_Impl.hpp"
11
12 namespace openstudio {
13 namespace detail {
14
15 /** TemperatureUnit_Impl is a Unit_Impl that is the implementation class for TemperatureUnit.*/
16 class UTILITIES_API TemperatureUnit_Impl : public Unit_Impl
17 {
18 public:
19 /** @name Constructors and Destructors */
20 //@{
21
22 3366 virtual ~TemperatureUnit_Impl() override = default;
23
24 //@}
25 /** @name Mathematical Operators */
26 //@{
27
28 bool isAbsolute() const;
29
30 void setAsAbsolute();
31
32 void setAsRelative();
33
34 virtual bool operator==(const Unit& rUnit) const override;
35
36 virtual void operator*=(const Unit& rUnit) override;
37
38 virtual void operator/=(const Unit& rUnit) override;
39
40 //@}
41 protected:
42 bool m_absolute;
43
44 TemperatureUnit_Impl(bool absolute, int scaleExponent, const std::string& prettyString, int numBaseUnits, UnitSystem system);
45
46 TemperatureUnit_Impl(bool absolute, const std::string& scaleAbbreviation, const std::string& prettyString, int numBaseUnits, UnitSystem system);
47
48 private:
49 REGISTER_LOGGER("openstudio.units.TemperatureUnit");
50 };
51
52 } // namespace detail
53
54 } // namespace openstudio
55
56 #endif // UTILITIES_UNITS_TEMPERATUREUNIT_IMPL_HPP
57