title: Jackson convert from json string to Java object results in default object
body: <p>I am trying to convert json string to Java object. Everything goes fine, object is created but it's properties are not passed. This results in an empty (default) object. What am I missing?</p>
  
  <p>Here is a Java object model:</p>
  
  <pre><code>public class LetterCounts implements Serializable {
  
      private String UserId;
      private int Total;
      private int UnRead;
      private int Flagged;
      private boolean Deleted;
  
      public LetterCounts(){
      }
      //getters and setters
  }
  </code></pre>
  
  <p>Here is my code snippet:</p>
  
  <pre><code>ObjectMapper mapper = new ObjectMapper();
  mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
  T returnValue = mapper.readValue(sb.toString(), clazz);
  </code></pre>
  
  <p>Here clazz is the name of the class i need to convert to (LetterCounts in this case) sb is a StringBuilder, which is as follows:</p>
  
  <pre><code>{"$id":"1","UserId":"users_1","Total":30,"UnRead":13,"Flagged":17,"Deleted":false}
  </code></pre>
  
  <p>If I use gson for deserialization, it works well. But I need to use jackson converter.</p>