Skip to content

Commit

Permalink
Separated xml serialization model and data structures from CRTProtocol (
Browse files Browse the repository at this point in the history
#66)

This PR aims to make it easier to replace the xml serialization currently in place.
In order to avoid a circular dependencies we move structures previously defined in RTProtocol.h into Settings.h behind a new namespace qualisys_cpp_sdk. We declare a new serialization and deserialization interface in Settings.h and move the current xml serialization to MarkupSerializer.cpp

A side effect of moving the structures outside CRTProtocol is that enum constants are no longer reachable directly through the CRTProtocol namespace, instead they must be reached through their respective enum name.

Example:

CRTProtocol::RateAllFrames -> CRTProtocol::EStreamRate::RateAllFrames
alt
CRTProtocol::RateAllFrames -> qualisys_cpp_sdk::EStreamRate::RateAllFrames
Added two new interfaces to be implemented by a future serialization solution.
ISettingsSerializer
ISettingsDeserializer
We can consider removing the interfaces after the transition is done to a new serializer.
  • Loading branch information
qjgn authored Jan 30, 2025
1 parent 6a24ee2 commit 8709688
Show file tree
Hide file tree
Showing 12 changed files with 5,025 additions and 4,536 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/build/*
/out/*
CMakeSettings.json

# Prerequisites
*.d
Expand Down
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ add_library(${PROJECT_NAME}
Network.cpp
RTPacket.cpp
RTProtocol.cpp
Settings.cpp
MarkupSerializer.cpp
)

target_include_directories(${PROJECT_NAME} PUBLIC
Expand Down
Loading

0 comments on commit 8709688

Please sign in to comment.