title: How to Convert a Properties Object to JSON Object with JAXB
body: <p>I want to accept and respond JSON objects in a REST Application. The data I need to send and receive are in a .properties file. I have already read them and are now in a <code>Properties</code> Object(From <code>java.util.Properties</code>). Is there a way to marshal and unmarshal <code>Properties</code> Objects, without implementing a new class?</p>
  
  <p>I am using Jax-rs API in a Weblogic server. </p>
  
  <pre><code>@POST
  @Path("{id}")
  @Produces(MediaType.APPLICATION_JSON)
  @Consumes(MediaType.APPLICATION_JSON)
  public JSONObject getbyID(@PathParam("id")JSONObject inputJsonObj) {
      //marshalling and unmarshalling goes here
  }
  </code></pre>