Skip to content

Commit 01bc039

Browse files
committed
Added API docs linking to estimatedDocumentCount
SCALA-529
1 parent cff1822 commit 01bc039

File tree

1 file changed

+18
-6
lines changed

1 file changed

+18
-6
lines changed

driver/src/main/scala/org/mongodb/scala/MongoCollection.scala

+18-6
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
213213
/**
214214
* Counts the number of documents in the collection.
215215
*
216-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
216+
* '''Note:'''
217+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
218+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
217219
*
218220
* {{{
219221
* +-------------+--------------------------------+
@@ -236,7 +238,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
236238
/**
237239
* Counts the number of documents in the collection according to the given options.
238240
*
239-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
241+
* '''Note:'''
242+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
243+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
240244
*
241245
* {{{
242246
* +-------------+--------------------------------+
@@ -260,7 +264,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
260264
/**
261265
* Counts the number of documents in the collection according to the given options.
262266
*
263-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
267+
* '''Note:'''
268+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
269+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
264270
*
265271
* {{{
266272
* +-------------+--------------------------------+
@@ -285,7 +291,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
285291
/**
286292
* Counts the number of documents in the collection.
287293
*
288-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
294+
* '''Note:'''
295+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
296+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
289297
*
290298
* {{{
291299
* +-------------+--------------------------------+
@@ -310,7 +318,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
310318
/**
311319
* Counts the number of documents in the collection according to the given options.
312320
*
313-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
321+
* '''Note:'''
322+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
323+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
314324
*
315325
* {{{
316326
* +-------------+--------------------------------+
@@ -336,7 +346,9 @@ case class MongoCollection[TResult](private val wrapped: JMongoCollection[TResul
336346
/**
337347
* Counts the number of documents in the collection according to the given options.
338348
*
339-
* '''Note:''' When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
349+
* '''Note:'''
350+
* For a fast count of the total documents in a collection see [[estimatedDocumentCount()]]
351+
* When migrating from `count()` to `countDocuments()` the following query operators must be replaced:
340352
*
341353
* {{{
342354
* +-------------+--------------------------------+

0 commit comments

Comments
 (0)