@@ -2235,13 +2235,22 @@ Documents.prototype.suggest = function suggestDocuments() {
2235
2235
} ;
2236
2236
2237
2237
/**
2238
- * The writeAll function writes documents to database using a passThrough stream.
2239
- * The concurrency is determined by the forestInfo retrieved.
2238
+ * The writeAll function writes one or more documents to database using a passThrough stream and optional options.
2239
+ * The optional options include onBatchSuccess, onBatchError, onCompletion, batchSize, concurrentRequests,
2240
+ * defaultMetadata and transform.
2240
2241
* @method documents#writeAll
2241
2242
* @since 2.8.0
2242
- * @param {string } options - Javascript literal object that configures the write operation.
2243
- * @returns {PassThrough stream } - a stream.Writable in object mode that receives document descriptor input from the
2244
- * application for writing to the database.
2243
+ * @param {function(progress, documents) } [onBatchSuccess] - Notifies other systems about batches written successfully.
2244
+ * @param {function(progress, documents, error) } [onBatchError] - Responds to any error while writing a batch of documents.
2245
+ * @param {function(summary) } [onCompletion] - Provides a summary of the results.
2246
+ * @param {Integer } [batchSize] - The number of documents in each batch.
2247
+ * @param {object[] } [concurrentRequests] - JavaScript object literal that controls the maximum number of concurrent
2248
+ * requests that can be pending at the same time. Valid keys are "multipleOf" and "multiplier".
2249
+ * @param {object[] } [defaultMetadata] - the metadata values applied to each document including collections,
2250
+ * permissions, properties, quality, and metadataValues.
2251
+ * @param {object[] } [transform] - transformSpecification applied to each document.
2252
+ * @returns {PassThrough|stream } - a stream.Writable in object mode that receives document descriptor input from the
2253
+ * application for writing to the database.
2245
2254
*/
2246
2255
Documents . prototype . writeAll = function writeAllDocuments ( options ) {
2247
2256
return writeAllDocumentsImpl . call (
0 commit comments