Repository navigation
Implementation of suggestions arising from pmslavin's review - #16
Open
OliverWoolland wants to merge 3 commits into
Open
OliverWoolland wants to merge 3 commits into
OliverWoolland wants to merge 3 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Discussion thread documenting suggested changes here: #9
Major changes:
Deferred:
Copilot summary
This pull request introduces several improvements and refactorings to the RO-Crate C++ library. The most significant changes include the introduction of a centralized error handling mechanism, improved error messages, and a switch to using unordered maps for better performance. Additionally, the CMake configuration has been updated to use a newer version and to fetch Catch2 via
FetchContentfor testing. The serialization and deserialization logic for RO-Crate entities has also been refactored for clarity and robustness.Error handling improvements:
ErrorCodeenum and a centralizederror_messagefunction to standardize and clarify error messages throughout the codebase. All exceptions now use these error codes and message templates, often withstd::formatfor dynamic values. [1] [2] [3] [4] [5] [6] [7]Performance and data structure updates:
std::mapwithstd::unordered_mapfor entity and property storage to improve lookup performance inPropertiesandEntityRegister. [1] [2]Serialization and deserialization refactor:
to_jsonandfrom_jsonfunctions, improving code clarity and separation of concerns. Error handling for file I/O and JSON parsing is now more robust and uses the new error handling system. [1] [2]Build system improvements:
find_packagetoFetchContent, ensuring consistent and up-to-date dependency management for tests. [1] [2]These changes collectively improve maintainability, reliability, and performance of the RO-Crate library.