I have been busy with other stuff, and I checked back on my onix project these days.
I really could use some senior advice with this :)
I created a custom renderer, that renders a simplified version of the onix model with serde::json and utoipa support (it will be part of a http/json interface). the onix model has zillions of value types, and i tried to flatten this monster a little bit.
the simplified model is created by a custom optimizer step.
I started of with the serde renderer, but I found that most of its internals are private. I went on copying tons of functions, that now breaks my neck when trying to update the xsd-parser.
at the end i need some custom serde annotations in the model + the mapping code that converts the simplified model to the xml version and back. is there a better way to handle this other than copying so much from the the private functions?
I'll attach an example of the mess I created, maybe i just got off on the wrong foot here
mapper.txt
I have been busy with other stuff, and I checked back on my onix project these days.
I really could use some senior advice with this :)
I created a custom renderer, that renders a simplified version of the onix model with serde::json and utoipa support (it will be part of a http/json interface). the onix model has zillions of value types, and i tried to flatten this monster a little bit.
the simplified model is created by a custom optimizer step.
I started of with the serde renderer, but I found that most of its internals are private. I went on copying tons of functions, that now breaks my neck when trying to update the xsd-parser.
at the end i need some custom serde annotations in the model + the mapping code that converts the simplified model to the xml version and back. is there a better way to handle this other than copying so much from the the private functions?
I'll attach an example of the mess I created, maybe i just got off on the wrong foot here
mapper.txt