| 368 | } |
| 369 | |
| 370 | boost::optional<HVACComponent> FanComponentModel_Impl::containingHVACComponent() const { |
| 371 | auto t_handle = handle(); |
| 372 | |
| 373 | // AirLoopHVACUnitarySystem |
| 374 | std::vector<AirLoopHVACUnitarySystem> airLoopHVACUnitarySystems = this->model().getConcreteModelObjects<AirLoopHVACUnitarySystem>(); |
| 375 | |
| 376 | for (const auto& airLoopHVACUnitarySystem : airLoopHVACUnitarySystems) { |
| 377 | if (boost::optional<HVACComponent> fan = airLoopHVACUnitarySystem.supplyFan()) { |
| 378 | if (fan->handle() == t_handle) { |
| 379 | return airLoopHVACUnitarySystem; |
| 380 | } |
| 381 | } |
| 382 | } |
| 383 | |
| 384 | return boost::none; |
| 385 | } |
| 386 | |
| 387 | boost::optional<ZoneHVACComponent> FanComponentModel_Impl::containingZoneHVACComponent() const { |
| 388 | |