jaxb entity print out as xml
- by Cristian Boariu
Hi,
I have a class, let's say User adnotated with @XmlRootElement, with some properties (name, surname etc).
I use this class for REST operations, as application/xml.
The client will POST User class so i want to keep the values in the log.
Is there any method in jax-ws to prints out this object as xml?
For instance: log.info("Customers sent a USER"+user.whichMethod());
Customer sent a User
<user> <name>cristi</name> <surname>kevin</surname> </user>
Thanks.