title: Java Map to JSON string
body: <p>I need to convert a map to JSON string, I am using a third-party library and one of the classes in it has a field of type <code>Map&lt;String, Object&gt;</code> I need to convert that map to JSON string and send it to its destination. All works ok until I put a string into that map as a value i.e. if that <code>Object</code> in the map is a <code>String</code> then I end up having four double quotes (<code>""value""</code>) in the final JSON string I get from <code>jackson</code>'s <code>OBJECT_MAPPER.writeValueAsString(str)</code> method. </p>
  
  <p>e.g. the following this map:</p>
  
  <p><code>map.put("key", "value")</code> of type <code>Map&lt;String, Object&gt;</code> will result in <code>{"key" : ""value""}</code> which obviously is not a JSON string, any idea how to resolve this without writing a custom method to check types and solve the issue?</p>