Week 7 - Model Refinement, Code Cleanup, and Solver Integration
In the past week, my main focus was on refining the model abstraction, further cleaning the codebase, and once again, integrate the CommonsMathSolver into the solver interface. Progress: Model Refinement with Built Flag: Added a built flag to AbstractLPModel to clearly indicate when the model is finalized. After calling build() , the flag is set to true . Any subsequent changes reset the flag to false until the model is rebuilt. This mechanism ensures clarity about the model's state throughout its lifecycle. Utility for Constraint Indices: Implemented a utility method that retrieves the index of a given constraint within the model. This allows adapters or other classes easy access to constraint indices without redundant logic. Continuous Integration Improvements: Ensured the CI pipeline via GitHub Actions runs all unit tests smoothly and without errors, providing instant feedback on new code contributions and pull requests. Explicit Double Types in Tests: Added ...