title: how to get parameters' value from curl in REST web service in java
body: <p>Do anyone know how to get parameters' values from curl command in REST web service using java.I have write a REST web service using jersey framework and java in NetBean IDE.
  This is my curl command to uplaod file without metadata:</p>
  
  <pre><code>curl -T C:\Users\Folders\a.jpg -H "Content-Type:application/vnd.org.snia.cdmi.dataobject" http://localhost:8080/users/folder/a.jpg 
  </code></pre>
  
  <p>This is my HttpPut method for upload</p>
  
  <pre><code>@PUT
  @Path("/{directory:.+}")
  public Response doPut(@PathParam("directory")String data,byte[]contents)
  {
  ..............
  }
  </code></pre>
  
  <p>This is my curl command to upload file with metadata</p>
  
  <pre><code>curl  --data " { "metadata" : "Username":"name"}" -T C:\Users\Folders\a.jpg -H "Content-Type:application/vnd.org.snia.cdmi.dataobject" http://localhost:8080/users/folder/a.jpg 
  </code></pre>
  
  <p>This is my HttpPut method for upload</p>
  
  <pre><code>@PUT
  @Path("/{direcotry:.+}")
  public Response doPut(@PathParam("directory")String data,byte[]contents,String meta)
  {
  ..............
  }
  </code></pre>
  
  <p>My question is when i upload file without metadata i can upload successfully. But when i add metadata i can't get the "--data" values from curl command in doPut method. How can I solve it?</p>