bool PeopleDefinition_Impl::setNumberOfPeopleCalculationMethod(const std::string& method, double floorArea) { std::string wmethod(method); boost::to_lower(wmethod); if (wmethod == "people") { return setNumberofPeople(getNumberOfPeople(floorArea)); } else if (wmethod == "people/area") { return setPeopleperSpaceFloorArea(getPeoplePerFloorArea(floorArea)); } else if (wmethod == "area/person") { return setSpaceFloorAreaperPerson(getFloorAreaPerPerson(floorArea)); } return false; }
bool SteamEquipmentDefinition_Impl::setDesignLevelCalculationMethod(const std::string& method, double floorArea, double numPeople) { std::string wmethod(method); boost::to_lower(wmethod); if (wmethod == "equipmentlevel") { return setDesignLevel(getDesignLevel(floorArea,numPeople)); } else if (wmethod == "watts/area") { return setWattsperSpaceFloorArea(getPowerPerFloorArea(floorArea,numPeople)); } else if (wmethod == "watts/person") { return setWattsperPerson(getPowerPerPerson(floorArea,numPeople)); } return false; }
bool InternalMassDefinition_Impl::setDesignLevelCalculationMethod(const std::string& method, double floorArea, double numPeople) { std::string wmethod(method); boost::to_lower(wmethod); if (wmethod == "surfacearea") { return setSurfaceArea(getSurfaceArea(floorArea,numPeople)); } else if (wmethod == "surfacearea/area") { return setSurfaceAreaperSpaceFloorArea(getSurfaceAreaPerFloorArea(floorArea,numPeople)); } else if (wmethod == "surfacearea/person") { return setSurfaceAreaperPerson(getSurfaceAreaPerPerson(floorArea,numPeople)); } return false; }