I am trying to find a way to query a RNG schema while avoiding reinvention of the wheel, in order to answer basic questions such as: what elements are valid children of an XML instance element, what can/must be it's attributes and so on.
A post here raised my hopes of doing this with Jing/Trang, since I am already doing RNG validation with Jing, but after searching around I've found no source code examples which would confirm the claim and browsing API docs also did not help me much (which in turn also seems to be the only documentation bundled with Jing).
I'd really like to avoid parsing schema into my own object model to do these queries and it also seems kinda redundant since I know Jing must also be doing it somewhere. The question is how to obtain the information I require from it.
Is there another library I could use to query RNG schema from java code? Note that I'm not trying to validate instance files by using a schema, I am trying to query the schema itself.