MCPcopy Create free account
hub / github.com/NatLabRockies/OpenStudio / system

Method system

src/model/RefrigerationSecondarySystem.cpp:702–717  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

700 }
701
702 boost::optional<RefrigerationSystem> RefrigerationSecondarySystem_Impl::system() const {
703 boost::optional<RefrigerationSystem> result;
704
705 auto refrigerationSecondarySystem = this->getObject<RefrigerationSecondarySystem>();
706 for (const RefrigerationSystem& refrigerationSystem : this->model().getConcreteModelObjects<RefrigerationSystem>()) {
707 RefrigerationSecondarySystemVector refrigerationSecondarySystems = refrigerationSystem.secondarySystemLoads();
708 if (!refrigerationSecondarySystems.empty()
709 && std::find(refrigerationSecondarySystems.begin(), refrigerationSecondarySystems.end(), refrigerationSecondarySystem)
710 != refrigerationSecondarySystems.end()) {
711 result = refrigerationSystem;
712 break;
713 }
714 }
715
716 return result;
717 }
718
719 void RefrigerationSecondarySystem_Impl::removeFromSystem() {
720 if (boost::optional<RefrigerationSystem> refrigerationSystem = this->system()) {

Callers 1

removeFromSystemMethod · 0.95

Calls 5

secondarySystemLoadsMethod · 0.80
beginMethod · 0.80
modelMethod · 0.45
emptyMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected