Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E+ 9.3.0: Update ShadowCalculation to match object refactor in EnergyPlus #3913

Closed
wants to merge 18 commits into from

Conversation

jmarrec
Copy link
Collaborator

@jmarrec jmarrec commented Mar 10, 2020

Pull request overview

Pull Request Author

Add to this list or remove from it as applicable. This is a simple templated set of guidelines.

  • Model API Changes / Additions
  • Any new or modified fields have been implemented in the EnergyPlus ForwardTranslator (and ReverseTranslator as appropriate)
  • Model API methods are tested (in src/model/test)
  • EnergyPlus ForwardTranslator Tests (in src/energyplus/Test)
  • If a new object or method, added a test in NREL/OpenStudio-resources: Add explicit test for ShadowCalculation OpenStudio-resources#98
  • If needed, added VersionTranslation rules for the objects (src/osversion/VersionTranslator.cpp)
  • Checked behavior in OpenStudioApplication, adjusted policies as needed (src/openstudio_lib/library/OpenStudioPolicy.xml)
  • Verified that C# bindings built fine on Windows, partial classes used as needed, etc.
  • All new and existing tests passes
  • If methods have been deprecated, update rest of code to use the new methods

Labels:

  • If change to an IDD file, add the label IDDChange
  • If breaking existing API, add the label APIChange
  • If deemed ready, add label Pull Request - Ready for CI so that CI builds your PR

Review Checklist

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • Code Style, strip trailing whitespace, etc.
  • All related changes have been implemented: model changes, model tests, FT changes, FT tests, VersionTranslation, OS App
  • Labeling is ok
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified

@jmarrec jmarrec added Enhancement Request component - Model component - IDF Translation IDDChange APIChange A motivated non-backward compatible change that breaks the existing API and needs to be communicated labels Mar 10, 2020
@jmarrec jmarrec added this to the OpenStudio SDK 3.0.0 milestone Mar 10, 2020
@jmarrec jmarrec self-assigned this Mar 10, 2020
@jmarrec jmarrec requested a review from kbenne March 10, 2020 15:52
@jmarrec jmarrec force-pushed the 3908_ShadowCalculationRefactor branch from c992745 to 6f64f82 Compare March 11, 2020 10:08
@jmarrec jmarrec force-pushed the 3908_ShadowCalculationRefactor branch from 6f64f82 to 4787f5c Compare March 11, 2020 10:14
@jmarrec
Copy link
Collaborator Author

jmarrec commented Mar 11, 2020

Fixed the following C# swig problems (expected them since ThermalZone is swigged later in ModelHVAC.i) by using partial classes:

julien@build-vs (3908_ShadowCalculationRefactor *=)$ grep -R "SWIGTYPE_p" csharp_wrapper/generated_sources/OpenStudioModelSimulation/
csharp_wrapper/generated_sources/OpenStudioModelSimulation/ShadowCalculation.cs:196:  public SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t getShadingZoneGroup(uint groupIndex) {
csharp_wrapper/generated_sources/OpenStudioModelSimulation/ShadowCalculation.cs:197:    SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t ret = new SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t(OpenStudioModelSimulationPINVOKE.ShadowCalculation_getShadingZoneGroup(swigCPtr, groupIndex), true);
csharp_wrapper/generated_sources/OpenStudioModelSimulation/ShadowCalculation.cs:287:  public bool addShadingZoneGroup(SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t thermalZones) {
csharp_wrapper/generated_sources/OpenStudioModelSimulation/ShadowCalculation.cs:288:    bool ret = OpenStudioModelSimulationPINVOKE.ShadowCalculation_addShadingZoneGroup(swigCPtr, SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t.getCPtr(thermalZones));
csharp_wrapper/generated_sources/OpenStudioModelSimulation/SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t.cs:13:public class SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t {
csharp_wrapper/generated_sources/OpenStudioModelSimulation/SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t.cs:16:  internal SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t(global::System.IntPtr cPtr, bool futureUse) {
csharp_wrapper/generated_sources/OpenStudioModelSimulation/SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t.cs:20:  protected SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t() {
csharp_wrapper/generated_sources/OpenStudioModelSimulation/SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t.cs:24:  internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_std__vectorT_openstudio__model__ThermalZone_t obj) {

grep returns nothing after 4787f5c

@tijcolem tijcolem mentioned this pull request Mar 12, 2020
@jmarrec jmarrec deleted the 3908_ShadowCalculationRefactor branch March 13, 2020 08:15
jmarrec added a commit to openstudiocoalition/OpenStudioApplication that referenced this pull request Mar 16, 2020
jmarrec added a commit to openstudiocoalition/OpenStudioApplication that referenced this pull request Mar 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
APIChange A motivated non-backward compatible change that breaks the existing API and needs to be communicated component - IDF Translation component - Model Enhancement Request IDDChange
Projects
None yet
Development

Successfully merging this pull request may close these issues.

E+ 9.3.0: Update ShadowCalculation to match object refactor in EnergyPlus
1 participant