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

Refactor Formulation classes to reduce duplication and over-compilation #770

Merged
merged 8 commits into from
Mar 25, 2024

Conversation

PhilMiller
Copy link
Contributor

@PhilMiller PhilMiller commented Mar 20, 2024

Additions

  • Bmi_Module_Formulation.cpp created to receive code moved out of Bmi_Module_Formulation.hpp

Removals

  • Duplicate implementations of get_output_header_line and get_output_line_for_timestep are moved up to Bmi_Module_Formulation from the language-specific classes
  • Inclusion of language-specific adapter and formulation classes removed from files that didn't need them

Changes

  • De-template Bmi_Module_Formulation from previously taking the concrete type of the underlying adapter class

Testing

  1. ctest
  2. CI

Checklist

  • PR has an informative and human-readable title
  • Changes are limited to a single goal (no scope creep)
  • Code can be automatically merged (no conflicts)
  • Code follows project standards (link if applicable)
  • Passes all existing automated tests
  • Any change in functionality is tested
  • New functions are documented (with a description, list of inputs, and expected output)
  • Placeholder code is flagged / future todos are captured in comments
  • Project documentation has been updated (including the "Unreleased" section of the CHANGELOG)
  • Reviewers requested with the Reviewers tool ➡️

@PhilMiller PhilMiller force-pushed the phil/refactor-output branch from 30f42d9 to d4be5a8 Compare March 20, 2024 18:39
@PhilMiller PhilMiller changed the title reafctor: Move Formulation::get_output_line_for_timestep implementati… Refactor Formulation classes to reduce duplication and over-compilation Mar 20, 2024
@PhilMiller PhilMiller force-pushed the phil/refactor-output branch from a6a4a03 to 670fe65 Compare March 21, 2024 20:24
@PhilMiller
Copy link
Contributor Author

I recommend that this be reviewed commit-by-commit to make things much more comprehensible.

@PhilMiller PhilMiller marked this pull request as ready for review March 21, 2024 20:56
Copy link
Contributor

@program-- program-- left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think @hellkite500 wants to review first before merging, but this looks great to me!

@PhilMiller PhilMiller merged commit 3dcc58b into NOAA-OWP:master Mar 25, 2024
19 checks passed
@PhilMiller PhilMiller deleted the phil/refactor-output branch March 25, 2024 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants