Skip to content

Commit 9b21941

Browse files
committed
Document _id and metadata options for GridFS upload methods
1 parent 5f09883 commit 9b21941

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/GridFS/Bucket.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,9 +265,14 @@ public function openDownloadStreamByName($filename, array $options = [])
265265
*
266266
* Supported options:
267267
*
268+
* * _id (mixed): File document identifier. Defaults to a new ObjectId.
269+
*
268270
* * chunkSizeBytes (integer): The chunk size in bytes. Defaults to the
269271
* bucket's chunk size.
270272
*
273+
* * metadata (document): User data for the "metadata" field of the files
274+
* collection document.
275+
*
271276
* @param string $filename Filename
272277
* @param array $options Upload options
273278
* @return resource
@@ -322,9 +327,14 @@ public function rename($id, $newFilename)
322327
*
323328
* Supported options:
324329
*
330+
* * _id (mixed): File document identifier. Defaults to a new ObjectId.
331+
*
325332
* * chunkSizeBytes (integer): The chunk size in bytes. Defaults to the
326333
* bucket's chunk size.
327334
*
335+
* * metadata (document): User data for the "metadata" field of the files
336+
* collection document.
337+
*
328338
* @param string $filename Filename
329339
* @param resource $source Readable stream
330340
* @param array $options Stream options

0 commit comments

Comments
 (0)