package io.vertx.groovy.ext.mongo;
public class MongoService_GroovyExtension {
  public static io.vertx.ext.mongo.MongoService save(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> document, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.save(collection,
      document != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(document) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.String> ar) {
        resultHandler.handle(ar.map(event -> event));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService saveWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> document, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.saveWithOptions(collection,
      document != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(document) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.String> ar) {
        resultHandler.handle(ar.map(event -> event));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService insert(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> document, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.insert(collection,
      document != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(document) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.String> ar) {
        resultHandler.handle(ar.map(event -> event));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService insertWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> document, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.insertWithOptions(collection,
      document != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(document) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.String>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.String> ar) {
        resultHandler.handle(ar.map(event -> event));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService update(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.update(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService updateCollection(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.updateCollection(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService updateWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.updateWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      options != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService updateCollectionWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.updateCollectionWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      options != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService replace(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> replace, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.replace(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      replace != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(replace) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService replaceDocuments(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> replace, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.replaceDocuments(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      replace != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(replace) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService replaceWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> replace, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.replaceWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      replace != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(replace) : null,
      options != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService replaceDocumentsWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> replace, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.replaceDocumentsWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      replace != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(replace) : null,
      options != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientUpdateResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService bulkWrite(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.List<java.util.Map<String, Object>> operations, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.bulkWrite(collection,
      operations != null ? operations.stream().map(elt -> elt != null ? new io.vertx.ext.mongo.BulkOperation(io.vertx.core.impl.ConversionHelper.toJsonObject(elt)) : null).collect(java.util.stream.Collectors.toList()) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientBulkWriteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientBulkWriteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService bulkWriteWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.List<java.util.Map<String, Object>> operations, java.util.Map<String, Object> bulkWriteOptions, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.bulkWriteWithOptions(collection,
      operations != null ? operations.stream().map(elt -> elt != null ? new io.vertx.ext.mongo.BulkOperation(io.vertx.core.impl.ConversionHelper.toJsonObject(elt)) : null).collect(java.util.stream.Collectors.toList()) : null,
      bulkWriteOptions != null ? new io.vertx.ext.mongo.BulkWriteOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(bulkWriteOptions)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientBulkWriteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientBulkWriteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService find(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<java.util.Map<String, Object>>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.find(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<io.vertx.core.json.JsonObject>>>() {
      public void handle(io.vertx.core.AsyncResult<java.util.List<io.vertx.core.json.JsonObject>> ar) {
        resultHandler.handle(ar.map(event -> event != null ? event.stream().map(elt -> io.vertx.core.impl.ConversionHelper.fromJsonObject(elt)).collect(java.util.stream.Collectors.toList()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<java.util.Map<String, Object>>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      options != null ? new io.vertx.ext.mongo.FindOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<io.vertx.core.json.JsonObject>>>() {
      public void handle(io.vertx.core.AsyncResult<java.util.List<io.vertx.core.json.JsonObject>> ar) {
        resultHandler.handle(ar.map(event -> event != null ? event.stream().map(elt -> io.vertx.core.impl.ConversionHelper.fromJsonObject(elt)).collect(java.util.stream.Collectors.toList()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOne(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> fields, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOne(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      fields != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(fields) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndUpdate(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndUpdate(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndUpdateWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, java.util.Map<String, Object> findOptions, java.util.Map<String, Object> updateOptions, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndUpdateWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      findOptions != null ? new io.vertx.ext.mongo.FindOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(findOptions)) : null,
      updateOptions != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(updateOptions)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndReplace(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> replace, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndReplace(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      replace != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(replace) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndReplaceWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> update, java.util.Map<String, Object> findOptions, java.util.Map<String, Object> updateOptions, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndReplaceWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      update != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(update) : null,
      findOptions != null ? new io.vertx.ext.mongo.FindOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(findOptions)) : null,
      updateOptions != null ? new io.vertx.ext.mongo.UpdateOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(updateOptions)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndDelete(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndDelete(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService findOneAndDeleteWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, java.util.Map<String, Object> findOptions, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.findOneAndDeleteWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      findOptions != null ? new io.vertx.ext.mongo.FindOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(findOptions)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService count(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Long>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.count(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Long>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Long> ar) {
        resultHandler.handle(ar.map(event -> event));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService remove(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.remove(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeDocuments(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeDocuments(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeDocumentsWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeDocumentsWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeOne(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeOne(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeDocument(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeDocument(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeOneWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeOneWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService removeDocumentWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> query, io.vertx.ext.mongo.WriteOption writeOption, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.removeDocumentWithOptions(collection,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      writeOption,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.ext.mongo.MongoClientDeleteResult> ar) {
        resultHandler.handle(ar.map(event -> event != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(event.toJson()) : null));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService createIndex(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> key, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.createIndex(collection,
      key != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(key) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService createIndexWithOptions(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.util.Map<String, Object> key, java.util.Map<String, Object> options, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.createIndexWithOptions(collection,
      key != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(key) : null,
      options != null ? new io.vertx.ext.mongo.IndexOptions(io.vertx.core.impl.ConversionHelper.toJsonObject(options)) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<java.lang.Void>>() {
      public void handle(io.vertx.core.AsyncResult<java.lang.Void> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService listIndexes(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.listIndexes(collection,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonArray(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService runCommand(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String commandName, java.util.Map<String, Object> command, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.Map<String, Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.runCommand(commandName,
      command != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(command) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonObject(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService distinct(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.lang.String fieldName, java.lang.String resultClassname, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.distinct(collection,
      fieldName,
      resultClassname,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonArray(event)));
      }
    } : null));
    return j_receiver;
  }
  public static io.vertx.ext.mongo.MongoService distinctWithQuery(io.vertx.ext.mongo.MongoService j_receiver, java.lang.String collection, java.lang.String fieldName, java.lang.String resultClassname, java.util.Map<String, Object> query, io.vertx.core.Handler<io.vertx.core.AsyncResult<java.util.List<Object>>> resultHandler) {
    io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.distinctWithQuery(collection,
      fieldName,
      resultClassname,
      query != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(query) : null,
      resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray>>() {
      public void handle(io.vertx.core.AsyncResult<io.vertx.core.json.JsonArray> ar) {
        resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromJsonArray(event)));
      }
    } : null));
    return j_receiver;
  }
}