@@ -29,7 +29,6 @@ import com.google.firebase.firestore.util.Preconditions
2929import com.google.firestore.v1.Pipeline
3030import com.google.firestore.v1.Value
3131import kotlinx.coroutines.flow.Flow
32- import kotlinx.coroutines.flow.drop
3332import kotlinx.coroutines.flow.emptyFlow
3433import kotlinx.coroutines.flow.filter
3534import kotlinx.coroutines.flow.flow
@@ -727,15 +726,15 @@ private constructor(
727726 /* *
728727 * Creates [SampleStage] with size limited to number of documents.
729728 *
730- * The [documents ] parameter represents the target number of documents to produce and must be a
729+ * The [count ] parameter represents the target number of documents to produce and must be a
731730 * non-negative integer value. If the previous stage produces less than size documents, the
732731 * entire previous results are returned. If the previous stage produces more than size, this
733732 * outputs a sample of exactly size entries where any sample is equally likely.
734733 *
735- * @param documents The number of documents to emit.
736- * @return [SampleStage] with specified [documents ].
734+ * @param count The number of documents to emit.
735+ * @return [SampleStage] with specified [count ].
737736 */
738- @JvmStatic fun withDocLimit ( documents : Int ) = SampleStage (documents , Mode .DOCUMENTS )
737+ @JvmStatic fun withCount ( count : Int ) = SampleStage (count , Mode .DOCUMENTS )
739738 }
740739 override fun args (userDataReader : UserDataReader ): Sequence <Value > =
741740 sequenceOf(encodeValue(size), mode.proto)
0 commit comments