usdot-fhwa-stol / carma-streets

CARMA Streets is a component of CARMA ecosystem, which enables such a coordination among different transportation users. This component provides an interface for CDA participants to interact with the road infrastructure. Doxygen Source Code Documentation: https://usdot-fhwa-stol.github.io/documentation/carma-streets/
10 stars 10 forks source link

Add separate functions for required and optional properties in JSON Utils #355

Open paulbourelly999 opened 1 year ago

paulbourelly999 commented 1 year ago

Summary

Using a bool parameter to indicate whether property is required forces every returned property to be wrapped in a std::optional. This requires additional value() calls which make the code more verbose and harder to read.

Reasoning for new functionality

Make code more readable and less verbose