Joined: Mon Aug 27, 2007 11:11 pm Posts: 8 Location: Brisbane
|
Hibernate version: 3.0
I have a requirement to track changes made to a database object and I was thinking a nice way to do this would be to store the before and after state of the object as XML text in a change tracking table.
My application currently uses EntityMode.MAP to read and update my hibernate objects. When I do an update, I would like to get the DOM4J representation of the object that I already have loaded previously as a MAP.
Does hibernate provide a way for me to convert my MAP representation of an object into a DOM4J representation?
Currently I'm having to create a DOM4J session and perform another get on the object to get the DOM4J representation of the object. This is a hassle because before I do the get I need to create the identifier first as a DOM4J element. I'm not using the hibernate metadata to create this so its not bullet proof (ie. I'm just assuming each property is an element).
|
|