I’m making simple paint program, and in that program users are able to save their work into XML files; there are two different schemas for these XML files.
When it comes to load, I want my program to understand both schemas. That is, for the program to read a file without first knowing which of the schemas the file uses.
How should I handle this problem ?
I’d simply try to read enforcing one schema, and if it fails to validate fall back to the other one.