src/model/ControllerWaterCoil.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 MODEL_CONTROLLERWATERCOIL_HPP | ||
| 7 | #define MODEL_CONTROLLERWATERCOIL_HPP | ||
| 8 | |||
| 9 | #include "ModelAPI.hpp" | ||
| 10 | #include "HVACComponent.hpp" | ||
| 11 | |||
| 12 | namespace openstudio { | ||
| 13 | |||
| 14 | namespace model { | ||
| 15 | |||
| 16 | class Node; | ||
| 17 | |||
| 18 | namespace detail { | ||
| 19 | |||
| 20 | class ControllerWaterCoil_Impl; | ||
| 21 | class CoilCoolingWater_Impl; | ||
| 22 | class CoilHeatingWater_Impl; | ||
| 23 | class CoilSystemCoolingWater_Impl; | ||
| 24 | class CoilSystemCoolingWaterHeatExchangerAssisted_Impl; | ||
| 25 | |||
| 26 | } // namespace detail | ||
| 27 | |||
| 28 | /** ControllerWaterCoil is a HVACComponent that wraps the OpenStudio IDD object | ||
| 29 | * 'OS:Controller:WaterCoil'. */ | ||
| 30 | class MODEL_API ControllerWaterCoil : public HVACComponent | ||
| 31 | { | ||
| 32 | public: | ||
| 33 | /** @name Constructors and Destructors */ | ||
| 34 | //@{ | ||
| 35 | |||
| 36 | 2551 | virtual ~ControllerWaterCoil() override = default; | |
| 37 | // Default the copy and move operators because the virtual dtor is explicit | ||
| 38 | 5 | ControllerWaterCoil(const ControllerWaterCoil& other) = default; | |
| 39 | 1228 | ControllerWaterCoil(ControllerWaterCoil&& other) = default; | |
| 40 | ✗ | ControllerWaterCoil& operator=(const ControllerWaterCoil&) = default; | |
| 41 | ✗ | ControllerWaterCoil& operator=(ControllerWaterCoil&&) = default; | |
| 42 | |||
| 43 | //@} | ||
| 44 | /** @name Static Methods */ | ||
| 45 | //@{ | ||
| 46 | |||
| 47 | static IddObjectType iddObjectType(); | ||
| 48 | |||
| 49 | static std::vector<std::string> validControlVariableValues(); | ||
| 50 | |||
| 51 | static std::vector<std::string> validActionValues(); | ||
| 52 | |||
| 53 | static std::vector<std::string> validActuatorVariableValues(); | ||
| 54 | |||
| 55 | //@} | ||
| 56 | /** @name Getters */ | ||
| 57 | //@{ | ||
| 58 | |||
| 59 | boost::optional<HVACComponent> waterCoil() const; | ||
| 60 | |||
| 61 | boost::optional<std::string> controlVariable() const; // Shouldn't return an optional, has a default | ||
| 62 | bool isControlVariableDefaulted() const; | ||
| 63 | |||
| 64 | boost::optional<std::string> action() const; // Has no default and is required... | ||
| 65 | |||
| 66 | boost::optional<std::string> actuatorVariable() const; // Shouldn't return an optional, has a default | ||
| 67 | bool isActuatorVariableDefaulted() const; | ||
| 68 | |||
| 69 | boost::optional<Node> sensorNode() const; | ||
| 70 | |||
| 71 | boost::optional<Node> actuatorNode() const; | ||
| 72 | |||
| 73 | boost::optional<double> controllerConvergenceTolerance() const; | ||
| 74 | |||
| 75 | bool isControllerConvergenceToleranceDefaulted() const; | ||
| 76 | |||
| 77 | bool isControllerConvergenceToleranceAutosized() const; | ||
| 78 | |||
| 79 | boost::optional<double> maximumActuatedFlow() const; | ||
| 80 | |||
| 81 | bool isMaximumActuatedFlowAutosized() const; | ||
| 82 | |||
| 83 | double minimumActuatedFlow() const; | ||
| 84 | |||
| 85 | bool isMinimumActuatedFlowDefaulted() const; | ||
| 86 | |||
| 87 | //@} | ||
| 88 | /** @name Setters */ | ||
| 89 | //@{ | ||
| 90 | |||
| 91 | bool setControlVariable(const std::string& controlVariable); | ||
| 92 | |||
| 93 | void resetControlVariable(); | ||
| 94 | |||
| 95 | bool setAction(const std::string& action); | ||
| 96 | |||
| 97 | void resetAction(); | ||
| 98 | |||
| 99 | bool setActuatorVariable(const std::string& actuatorVariable); | ||
| 100 | |||
| 101 | void resetActuatorVariable(); | ||
| 102 | |||
| 103 | bool setSensorNode(const Node& node); | ||
| 104 | |||
| 105 | bool setActuatorNode(const Node& node); | ||
| 106 | |||
| 107 | bool setControllerConvergenceTolerance(double controllerConvergenceTolerance); | ||
| 108 | |||
| 109 | void resetControllerConvergenceTolerance(); | ||
| 110 | |||
| 111 | void autosizeControllerConvergenceTolerance(); | ||
| 112 | |||
| 113 | bool setMaximumActuatedFlow(double maximumActuatedFlow); | ||
| 114 | |||
| 115 | void resetMaximumActuatedFlow(); | ||
| 116 | |||
| 117 | void autosizeMaximumActuatedFlow(); | ||
| 118 | |||
| 119 | bool setMinimumActuatedFlow(double minimumActuatedFlow); | ||
| 120 | |||
| 121 | void resetMinimumActuatedFlow(); | ||
| 122 | |||
| 123 | //@} | ||
| 124 | /** @name Other */ | ||
| 125 | //@{ | ||
| 126 | |||
| 127 | boost::optional<double> autosizedControllerConvergenceTolerance() const; | ||
| 128 | |||
| 129 | boost::optional<double> autosizedMaximumActuatedFlow() const; | ||
| 130 | |||
| 131 | //@} | ||
| 132 | protected: | ||
| 133 | /// @cond | ||
| 134 | using ImplType = detail::ControllerWaterCoil_Impl; | ||
| 135 | |||
| 136 | friend class detail::ControllerWaterCoil_Impl; | ||
| 137 | |||
| 138 | friend class Model; | ||
| 139 | |||
| 140 | friend class openstudio::IdfObject; | ||
| 141 | |||
| 142 | // Classes that need to instantiate it | ||
| 143 | friend class openstudio::model::detail::CoilCoolingWater_Impl; | ||
| 144 | friend class openstudio::model::detail::CoilHeatingWater_Impl; | ||
| 145 | friend class openstudio::model::detail::CoilSystemCoolingWater_Impl; | ||
| 146 | friend class openstudio::model::detail::CoilSystemCoolingWaterHeatExchangerAssisted_Impl; | ||
| 147 | |||
| 148 | explicit ControllerWaterCoil(const Model& model); | ||
| 149 | |||
| 150 | explicit ControllerWaterCoil(std::shared_ptr<detail::ControllerWaterCoil_Impl> impl); | ||
| 151 | |||
| 152 | /// @endcond | ||
| 153 | private: | ||
| 154 | REGISTER_LOGGER("openstudio.model.ControllerWaterCoil"); | ||
| 155 | }; | ||
| 156 | |||
| 157 | /** \relates ControllerWaterCoil*/ | ||
| 158 | using OptionalControllerWaterCoil = boost::optional<ControllerWaterCoil>; | ||
| 159 | |||
| 160 | /** \relates ControllerWaterCoil*/ | ||
| 161 | using ControllerWaterCoilVector = std::vector<ControllerWaterCoil>; | ||
| 162 | |||
| 163 | } // namespace model | ||
| 164 | |||
| 165 | } // namespace openstudio | ||
| 166 | |||
| 167 | #endif // MODEL_CONTROLLERWATERCOIL_HPP | ||
| 168 |