code: @Override
      public void writeJson(Writer writer, Map<String, ?> value) throws IOException {
          if (writer == null) {
              throw new IllegalArgumentException("Writer must not be null");
          }
  
          JSONObject jsonObject = convertMapToJSONObject(value);
          writer.write(getJsonObjectManager().stringify(jsonObject));
          writer.close();
      }
docs: {@inheritDoc}