code: @Deprecated
      @Override
      @SuppressWarnings({ "unchecked", "rawtypes" })
      public void serializeObject(JsonWriteGenericRecord record, String fieldName, String typeName, Object obj) {
          try {
              if (obj == null) {
                  record.getGenerator().writeObjectField(fieldName, null);
                  return;
              }
              if (isPrimitive(obj.getClass())) {
                  serializePrimitive(record, fieldName, obj);
                  return;
              }
              record.getGenerator().writeFieldName(fieldName);
              record.getGenerator().writeStartObject();
  
              NFTypeSerializer fieldSerializer = getSerializer(typeName);
              JsonWriteGenericRecord fieldRecord = new JsonWriteGenericRecord(record.getGenerator());
              fieldSerializer.serialize(obj, fieldRecord);
              record.getGenerator().writeEndObject();
          } catch (Exception ex) {
              throw new RuntimeException(ex);
          }
      }
docs: /*
  @Deprecated instead use serializeObject(HashGenericRecord rec, String fieldName, Object obj)