I want to invalid json string convert to map on java.
target string like this. (without quotes on key)
{depth=2, url=google.com}
i try this
ObjectMapper mapper = new ObjectMapper();
String dataJson = ABOVE_INVALID_JSON_STRING;
Map<String, String> dataMap = mapper.readValue(dataJson, Map.class);
error
com.fasterxml.jackson.core.JsonParseException: Unexpected character ('d' (code 100)): was expecting double-quote to start field name
at [Source: (String)"{depth=2, url=...; line: 1, column: 3]
i know that string is invalid json. but i think that easy way exist what i don't know.