json « jersey « Java Enterprise Q&A





1. How to reuse Jersey's JSON/JAXB for serialization?    stackoverflow.com

I have a JAX-RS REST service implemented using Jersey. One of the cool features of JAX-RS/Jersey is how easily a POJO can be turned into a REST service, simply by sprinkling ...

2. Consuming JSON object in Jersey service    stackoverflow.com

I've been Googling my butt off trying to find out how to do this: I have a Jersey REST service. The request that invokes the REST service contains a JSON object. ...

3. Good tutorial for jsonlib and jersey    stackoverflow.com

Hi I want to use jsonlib(for mashalling) and jersey(for mapping). But i wasn't able to find a good tutorial. Any help?

4. Can I get normal pojo as json object in RESTful-jersey    stackoverflow.com

I am implementing jersey restful web service to get application/json mime type from the java bean classes. Given below is the resource class code

    @GET
   ...

5. Jersey Viewable: how to return JSON from Viewable?    stackoverflow.com

I am new to Jersy Viewable. Can some one help me how to return JSON reponse in Jersey Viewable ?

6. Parent tag is missing from JSON    stackoverflow.com

I have this DTO to be converted to XML/JSON and send response to client from my web service. We are using Jersey.

@XmlRootElement(name = "response")
public class Response {

@XmlValue
private String value="true";
}
It is getting ...

7. How do I use the Jersey JSON POJO support?    stackoverflow.com

I have an object that I'd like to serve in JSON as a RESTful resource. I have Jersey's JSON POJO support turned on like so (in web.xml):

<servlet>  
   ...

8. JSON data problem    stackoverflow.com

I am implementing RESTful Jersey application. If I have a car bean:

@XmlRootElement
class Car{
  private String id;
  private String name;

  //... GETTER & SETTER 
}
My CarResource.java:
    @GET
 ...

9. Issue : Serializing using Jersey, Deserializing JSON using gson    stackoverflow.com

I have been using Jersey for REST API and returning JSON. On client side I am using google-gson. While deserializing JSON, I am getting following error.

com.google.gson.JsonParseException: The ...





10. Convert JSON to POJO    stackoverflow.com

I'm using Jersey for REST WS, and I get my response as JSON. I want to transform this response to a POJO. How to do it ? Thnx

11. Jax-rs unmarshal json - custom type    stackoverflow.com

Using jax-rs, I'm not sure how to manually unmarshal JSON into my custom Java objects. From my browser I'm sending a simple put request with the following JSON:

{"myDate":{"dayOfMonth":23, "monthOfYear":7, "year":2011}}
On the server ...

12. Jersey JSON key/value order    stackoverflow.com

I'm building a Java REST Web App with use of Jersey to get JSON data output. I ran into a problem with ordering of the key/value pairs. I want it to be this ...

13. Properly return org.w3c.dom.Document as JSON using Jersey    stackoverflow.com

I have a function which returns type org.w3c.dom.Document, and my Jersey resource lets it return either as XML or JSON. It returns the XML fine, however, for JSON, it returns ...

14. JSON as tree in Jersey    stackoverflow.com

I'm not really a big fan of maintaining a number of POJOs for an API that I'm working on. I'm thinking that (in some cases at least), it would be preferable ...

15. namespace causes unmarshal to fail with JSON    stackoverflow.com

I have a problem where a JSON response is not converted to an object while testing a resource with the jersey test suite. This problem does not occur on e.g. a ...

16. using jersey and json like curl    stackoverflow.com

I created a class to run a query using json jersey, here is the description of the class:

Client  client = Client.create();
WebResource webResource=client.resource("http://localhost:9090/entityhub/site/reegle/query");     


String select = ...





17. REST webservice using jersey push JSON object    stackoverflow.com

I am trying to create RESTful webservice that will take input as JSON and method would be PUT. How can I do this? I also need to create client for ...