Re: Marshalling POJO class to JSON String formatted output

2012-11-26 Thread Martin Stiborský
Sorry guys, lazy, tired me, not thinking before asking. Of courser there is byte[] in the body... for (Exchange receivedExchange : receivedExchanges) { String json = new String((byte[]) receivedExchange.getIn().getBody(), "UTF-8"); System.out.println("JSON String: " + json)

Marshalling POJO class to JSON String formatted output

2012-11-26 Thread Martin Stiborský
Hello guys, I'd like to ask you, I have a POJO classes, holding data representation of various kinds of data entities. Output of my Camel routes is JSON String returned to browser as response. I thought it would be easy to marshall POJO to JSON formatted String with Jackson, but I have something wr