Firionus / opengdtf

Abandoned! - A starting point for a useful GDTF Rust library
MIT License
4 stars 0 forks source link

Better Architectural Approaches #4

Open Firionus opened 1 year ago

Firionus commented 1 year ago

So working with the library as I built it is sometimes pretty cumbersome. Some reasons:

A better way might be:

Problem: How to know the file location in later validation steps? -> Either attach a file location to everything, or use roxmltree and attach an original node reference to everything with which we can later retrieve the position. Or stick with the current architecture, but it is one-way only and hard to later extend to be two-way.

Althought it seems like the first step could be done with quick-xml serde-derive, it (probably?) wouldn't support the lenient error handling of opengdtf. I think we'd have to write our own serde or quick-xml code.

But this might come with its own issues. Just wanted to write down that thought.