Completed
Pull Request — master (#12)
by
unknown
02:29
created
lib/Mongo/MongoCollection.php 1 patch
Doc Comments   +4 added lines, -5 removed lines patch added patch discarded remove patch
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
      * @throws MongoException if the inserted document is empty or if it contains zero-length keys. Attempting to insert an object with protected and private properties will cause a zero-length key error.
312 312
      * @throws MongoCursorException if the "w" option is set and the write fails.
313 313
      * @throws MongoCursorTimeoutException if the "w" option is set to a value greater than one and the operation takes longer than MongoCursor::$timeout milliseconds to complete. This does not kill the operation on the server, it is a client-side timeout. The operation in MongoCollection::$wtimeout is milliseconds.
314
-     * @return bool|array Returns an array containing the status of the insertion if the "w" option is set.
314
+     * @return MongoDB\InsertOneResult Returns an array containing the status of the insertion if the "w" option is set.
315 315
      */
316 316
     public function insert($a, array $options = array())
317 317
     {
@@ -324,7 +324,7 @@  discard block
 block discarded – undo
324 324
      * @param array $a An array of arrays.
325 325
      * @param array $options Options for the inserts.
326 326
      * @throws MongoCursorException
327
-     * @return mixed f "safe" is set, returns an associative array with the status of the inserts ("ok") and any error that may have occured ("err"). Otherwise, returns TRUE if the batch insert was successfully sent, FALSE otherwise.
327
+     * @return MongoDB\InsertManyResult f "safe" is set, returns an associative array with the status of the inserts ("ok") and any error that may have occured ("err"). Otherwise, returns TRUE if the batch insert was successfully sent, FALSE otherwise.
328 328
      */
329 329
     public function batchInsert(array $a, array $options = array())
330 330
     {
@@ -502,7 +502,7 @@  discard block
 block discarded – undo
502 502
      * @link http://www.php.net/manual/en/mongocollection.createindex.php
503 503
      * @param array $keys Field or fields to use as index.
504 504
      * @param array $options [optional] This parameter is an associative array of the form array("optionname" => <boolean>, ...).
505
-     * @return array Returns the database response.
505
+     * @return string|false Returns the database response.
506 506
      */
507 507
     public function createIndex(array $keys, array $options = array())
508 508
     {
@@ -595,7 +595,7 @@  discard block
 block discarded – undo
595 595
      * @throws MongoException if the inserted document is empty or if it contains zero-length keys. Attempting to insert an object with protected and private properties will cause a zero-length key error.
596 596
      * @throws MongoCursorException if the "w" option is set and the write fails.
597 597
      * @throws MongoCursorTimeoutException if the "w" option is set to a value greater than one and the operation takes longer than MongoCursor::$timeout milliseconds to complete. This does not kill the operation on the server, it is a client-side timeout. The operation in MongoCollection::$wtimeout is milliseconds.
598
-     * @return array|boolean If w was set, returns an array containing the status of the save.
598
+     * @return MongoDB\UpdateResult If w was set, returns an array containing the status of the save.
599 599
      * Otherwise, returns a boolean representing if the array was not empty (an empty array will not be inserted).
600 600
      */
601 601
     public function save($a, array $options = array())
@@ -719,7 +719,6 @@  discard block
 block discarded – undo
719 719
      * @link http://php.net/manual/en/mongodb.setwriteconcern.php
720 720
      * Set the write concern for this database
721 721
      * @param mixed $w <p>The write concern. This may be an integer denoting the number of servers required to acknowledge the write, or a string mode (e.g. "majority").</p>
722
-     * @param int $wtimeout[optional] <p>The maximum number of milliseconds to wait for the server to satisfy the write concern.</p>
723 722
      * @return boolean Returns <b>TRUE</b> on success, or <b>FALSE</b> otherwise.
724 723
      */
725 724
     public function setWriteConcern($w, $wtimeout = null)
Please login to merge, or discard this patch.
lib/Mongo/MongoClient.php 1 patch
Doc Comments   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
      * Lists all of the databases available
245 245
      *
246 246
      * @link http://php.net/manual/en/mongoclient.listdbs.php
247
-     * @return array Returns an associative array containing three fields. The first field is databases, which in turn contains an array. Each element of the array is an associative array corresponding to a database, giving the database's name, size, and if it's empty. The other two fields are totalSize (in bytes) and ok, which is 1 if this method ran successfully.
247
+     * @return MongoDB\Model\DatabaseInfoLegacyIterator Returns an associative array containing three fields. The first field is databases, which in turn contains an array. Each element of the array is an associative array corresponding to a database, giving the database's name, size, and if it's empty. The other two fields are totalSize (in bytes) and ok, which is 1 if this method ran successfully.
248 248
      */
249 249
     public function listDBs()
250 250
     {
@@ -303,7 +303,6 @@  discard block
 block discarded – undo
303 303
      * @link http://php.net/manual/en/mongoclient.setwriteconcern.php
304 304
      * Set the write concern for this database
305 305
      * @param mixed $w <p>The write concern. This may be an integer denoting the number of servers required to acknowledge the write, or a string mode (e.g. "majority").</p>
306
-     * @param int $wtimeout[optional] <p>The maximum number of milliseconds to wait for the server to satisfy the write concern.</p>
307 306
      * @return boolean Returns <b>TRUE</b> on success, or <b>FALSE</b> otherwise.
308 307
      */
309 308
     public function setWriteConcern($w, $wtimeout = null)
Please login to merge, or discard this patch.