src/energyplus/ForwardTranslator/ForwardTranslateDaylightingDeviceLightWell.cpp
| 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 | #include "../ForwardTranslator.hpp" | ||
| 7 | |||
| 8 | #include "../../model/DaylightingDeviceLightWell.hpp" | ||
| 9 | #include "../../model/SubSurface.hpp" | ||
| 10 | |||
| 11 | #include <utilities/idd/DaylightingDevice_LightWell_FieldEnums.hxx> | ||
| 12 | #include "../../utilities/idd/IddEnums.hpp" | ||
| 13 | #include <utilities/idd/IddEnums.hxx> | ||
| 14 | |||
| 15 | using namespace openstudio::model; | ||
| 16 | |||
| 17 | using namespace std; | ||
| 18 | |||
| 19 | namespace openstudio { | ||
| 20 | |||
| 21 | namespace energyplus { | ||
| 22 | |||
| 23 | 1 | boost::optional<IdfObject> ForwardTranslator::translateDaylightingDeviceLightWell(model::DaylightingDeviceLightWell& modelObject) { | |
| 24 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | IdfObject idfObject = createRegisterAndNameIdfObject(openstudio::IddObjectType::DaylightingDevice_LightWell, modelObject); |
| 25 | |||
| 26 |
1/1✓ Branch 1 taken 1 time.
|
1 | SubSurface subSurface = modelObject.subSurface(); |
| 27 |
2/3✓ Branch 1 taken 1 time.
✓ Branch 3 taken 1 time.
✗ Branch 4 not taken.
|
2 | if (boost::optional<IdfObject> subSurf = translateAndMapModelObject(subSurface)) { |
| 28 |
3/3✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
|
1 | idfObject.setString(DaylightingDevice_LightWellFields::ExteriorWindowName, subSurf->nameString()); |
| 29 | 1 | } | |
| 30 | |||
| 31 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | idfObject.setDouble(DaylightingDevice_LightWellFields::HeightofWell, modelObject.heightofWell()); |
| 32 | |||
| 33 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | idfObject.setDouble(DaylightingDevice_LightWellFields::PerimeterofBottomofWell, modelObject.perimeterofBottomofWell()); |
| 34 | |||
| 35 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | idfObject.setDouble(DaylightingDevice_LightWellFields::AreaofBottomofWell, modelObject.areaofBottomofWell()); |
| 36 | |||
| 37 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | idfObject.setDouble(DaylightingDevice_LightWellFields::VisibleReflectanceofWellWalls, modelObject.visibleReflectanceofWellWalls()); |
| 38 | |||
| 39 |
1/1✓ Branch 1 taken 1 time.
|
2 | return idfObject; |
| 40 | 1 | } | |
| 41 | |||
| 42 | } // namespace energyplus | ||
| 43 | |||
| 44 | } // namespace openstudio | ||
| 45 |