Create a Document from a JSON String in Java OJAI

You can create a new JSON document in your Java OJAI client by passing a JSON string to the Connection.newDocument() method.

To create the following JSON document:


Call Connection.newDocument(), passing in a JSON string with escaped quotes:

Document pojoDoc = connection.newDocument(