title: Getting error A message body writer for Java class java.util.ArrayList/List<java.lang.String> was not found
body: <p>well this has been posted a lot of time here but no solution worked for me...<br>
  i can avoid this error by making a wrapper class but it only returned  </p>
  
  <p><code>&lt;/stringWrapper&gt;</code>    </p>
  
  <p>what am i doing wrong ?</p>
  
  <p>StringWrapper class:</p>
  
  <pre><code>import java.util.ArrayList;
  import java.util.List;
  import javax.xml.bind.annotation.XmlRootElement;
  
  @XmlRootElement
  public class StringWrapper {
      public StringWrapper (){}
  
      List&lt;String&gt; list=new ArrayList&lt;String&gt;();
  
      public void add(String s){ 
          list.add(s);
      }
  }
  </code></pre>
  
  <p>code :</p>
  
  <pre><code>     @Path("/xml")
       @GET
       @Produces({MediaType.APPLICATION_XML,MediaType.APPLICATION_JSON})
       public StringWrapper mystring(){
          StringWrapper thestring=new StringWrapper();
          thestring.add("a");
          thestring.add("a");
          return thestring;
       }
  </code></pre>
  
  <p>Java Rest webservice using Jersey.</p>