I was wondering if there was a way for class generated by JAXB2 to find its parent in the data tree?
I'm trying to write functions to find the target of an XPath reference. To resolve a relative path I need to be able to move both up and down the data tree created by the unmarshalling.
At the moment I'm planning to add a parent attribute to the superclass of the generated classes, and then walk the tree immediately after unmarshalling setting this attribute. However if there's an easier way to do this I'd be grateful for any hints.