@@ -126,6 +126,9 @@ |
||
| 126 | 126 | ); |
| 127 | 127 | } |
| 128 | 128 | |
| 129 | + /** |
|
| 130 | + * @param resource $handle |
|
| 131 | + */ |
|
| 129 | 132 | private function writeFromRessource($handle) |
| 130 | 133 | { |
| 131 | 134 | |
@@ -106,7 +106,6 @@ discard block |
||
| 106 | 106 | * @link http://php.net/manual/en/mongogridfs.find.php |
| 107 | 107 | * @param array $query The query |
| 108 | 108 | * @param array $fields Fields to return |
| 109 | - * @param array $options Options for the find command |
|
| 110 | 109 | * @return MongoGridFSCursor A MongoGridFSCursor |
| 111 | 110 | */ |
| 112 | 111 | public function find(array $query = [], array $fields = []) |
@@ -155,7 +154,7 @@ discard block |
||
| 155 | 154 | * @param string $filename The name of the file |
| 156 | 155 | * @param array $extra Other metadata to add to the file saved |
| 157 | 156 | * @param array $options An array of options for the insert operations executed against the chunks and files collections. |
| 158 | - * @return mixed Returns the _id of the saved object |
|
| 157 | + * @return MongoId Returns the _id of the saved object |
|
| 159 | 158 | */ |
| 160 | 159 | public function put($filename, array $extra = [], array $options = []) |
| 161 | 160 | { |
@@ -190,7 +189,7 @@ discard block |
||
| 190 | 189 | * @param string $bytes A string of bytes to store |
| 191 | 190 | * @param array $extra Other metadata to add to the file saved |
| 192 | 191 | * @param array $options Options for the store. "safe": Check that this store succeeded |
| 193 | - * @return mixed The _id of the object saved |
|
| 192 | + * @return MongoId The _id of the object saved |
|
| 194 | 193 | */ |
| 195 | 194 | public function storeBytes($bytes, array $extra = [], array $options = []) |
| 196 | 195 | { |
@@ -214,7 +213,7 @@ discard block |
||
| 214 | 213 | * @param string $filename The name of the file |
| 215 | 214 | * @param array $extra Other metadata to add to the file saved |
| 216 | 215 | * @param array $options Options for the store. "safe": Check that this store succeeded |
| 217 | - * @return mixed Returns the _id of the saved object |
|
| 216 | + * @return MongoId Returns the _id of the saved object |
|
| 218 | 217 | * @throws MongoGridFSException |
| 219 | 218 | * @throws Exception |
| 220 | 219 | */ |
@@ -265,7 +264,7 @@ discard block |
||
| 265 | 264 | * @link http://www.php.net/manual/en/mongogridfs.storeupload.php |
| 266 | 265 | * @param string $name The name attribute of the uploaded file, from <input type="file" name="something"/>. |
| 267 | 266 | * @param array $metadata An array of extra fields for the uploaded file. |
| 268 | - * @return mixed Returns the _id of the uploaded file. |
|
| 267 | + * @return null|MongoId Returns the _id of the uploaded file. |
|
| 269 | 268 | * @throws MongoGridFSException |
| 270 | 269 | */ |
| 271 | 270 | public function storeUpload($name, array $metadata = []) |
@@ -388,7 +387,7 @@ discard block |
||
| 388 | 387 | /** |
| 389 | 388 | * Returns the MD5 string for a file previously stored to the database |
| 390 | 389 | * |
| 391 | - * @param $id |
|
| 390 | + * @param MongoId $id |
|
| 392 | 391 | * @return string |
| 393 | 392 | */ |
| 394 | 393 | private function getMd5ForFile($id) |