code: private void readFromStream(InputStream in) throws IOException {
          document = DocumentFactory.newDocument(Json.read(in));
      }
docs: Reads document content from the stream.
  
  @param in input stream.
  @throws IOException