vertx / io.vertx.kotlin.ext.mongo / io.vertx.ext.mongo.MongoClient / countAwait

countAwait

suspend fun MongoClient.countAwait(collection: String, query: JsonObject): Long

Count matching documents in a collection.

Parameters

collection - the collection

query - query used to match documents

resultHandler - will be provided with the number of matching documents

Return