@@ -352,8 +352,37 @@ public function bzmpop(float $timeout, array $keys, string $from, int $count = 1
352352 */
353353 public function zmpop (array $ keys , string $ from , int $ count = 1 ): Redis |array |null |false ;
354354
355+ /**
356+ * Pop one or more elements from one or more Redis LISTs, blocking up to a specified timeout when
357+ * no elements are available.
358+ *
359+ * @see https://redis.io/commands/blmpop
360+ *
361+ * @param float $timeout The number of seconds Redis will block when no elements are available.
362+ * @param array $keys One or more Redis LISTs to pop from.
363+ * @param string $from The string 'LEFT' or 'RIGHT' (case insensitive), telling Redis whether
364+ * to pop elements from the beginning or end of the LISTs.
365+ * @param int $count Pop up to how many elements at once.
366+ *
367+ * @return Redis|array|null|false One or more elements popped from the list(s) or false if all LISTs
368+ * were empty.
369+ */
355370 public function blmpop (float $ timeout , array $ keys , string $ from , int $ count = 1 ): Redis |array |null |false ;
356371
372+ /**
373+ * Pop one or more elements off of one or more Redis LISTs.
374+ *
375+ * @see https://redis.io/commands/lmpop
376+ *
377+ * @param array $keys An array with one or more Redis LIST key names.
378+ * @param string $from The string 'LEFT' or 'RIGHT' (case insensitive), telling Redis whether to pop\
379+ * elements from the beginning or end of the LISTs.
380+ * @param int $count The maximum number of elements to pop at once.
381+ *
382+ * @return Redis|array|null|false One or more elements popped from the LIST(s) or false if all the LISTs
383+ * were empty.
384+ *
385+ */
357386 public function lmpop (array $ keys , string $ from , int $ count = 1 ): Redis |array |null |false ;
358387
359388 /**
@@ -849,6 +878,18 @@ public function pubsub(string $command, mixed $arg = null): mixed;
849878
850879 public function punsubscribe (array $ patterns ): Redis |array |bool ;
851880
881+ /**
882+ * Pop one or more elements from the end of a Redis LIST.
883+ *
884+ * @see https://redis.io/commands/rpop
885+ *
886+ * @param string $key A redis LIST key name.
887+ * @param int $count The maximum number of elements to pop at once.
888+ *
889+ * NOTE: The `count` argument requires Redis >= 6.2.0
890+ *
891+ * @return Redis|array|string|bool One ore more popped elements or false if all were empty.
892+ */
852893 public function rPop (string $ key , int $ count = 0 ): Redis |array |string |bool ;
853894
854895 /** @return string|Redis */
@@ -868,7 +909,19 @@ public function restore(string $key, int $timeout, string $value, ?array $option
868909
869910 public function role (): mixed ;
870911
871- public function rpoplpush (string $ src , string $ dst ): Redis |string |false ;
912+ /**
913+ * Atomically pop an element off the end of a Redis LIST and push it to the beginning of
914+ * another.
915+ *
916+ * @see https://redis.io/commands/rpoplpush
917+ *
918+ * @param string $srckey The source key to pop from.
919+ * @param string $dstkey The destination key to push to.
920+ *
921+ * @return Redis|string|false The popped element or false if the source key was empty.
922+ *
923+ */
924+ public function rpoplpush (string $ srckey , string $ dstkey ): Redis |string |false ;
872925
873926 public function sAdd (string $ key , mixed $ value , mixed ...$ other_values ): Redis |int |false ;
874927
0 commit comments