I use Spring, Jersey and Jackson to provide an API that produces JSON.
My @Component has a @Get method that returns Response.ok(entity).build().
That output is very compact. How do I make that output pretty / formatted?
来源:https://stackoverflow.com/questions/6176881/how-do-i-make-jacksons-build-method-pretty-print-its-json-output