编程学问
  • 文章
  • 问题
  • 读书
  • 关于
  • 登录
  • « Ds\Set::remove
  • Ds\Set::reversed »
  • PHP Manual
  • Set
  • Reverses the set in-place

Ds\Set::reverse

(PECL ds >= 1.0.0)

Ds\Set::reverse — Reverses the set in-place

说明

public Ds\Set::reverse ( void ) : void

Reverses the set in-place.

参数

此函数没有参数。

返回值

没有返回值。

范例

Example #1 Ds\Set::reverse() example

<?php
$set 
= new \Ds\Set(["a", "b", "c"]);
$set->reverse();

print_r($set);
?>

以上例程的输出类似于:

Ds\Set Object
(
    [0] => c
    [1] => b
    [2] => a
)
相关文章
php datetime set state 魔术方法处理函数php deque reverses the deque in placephp map reverses the map in placephp sequence reverses the sequence in placephp set reverses the set in placephp set sorts the set in placephp vector reverses the vector in placephp gd 和图像处理 函数 set the clipping rectanglephp 多字节字符串 函数 set/get character encoding for multibyte regexphp pdf 函数 place table on pagephp pdf 函数 set flatnessphp imagick set colorspacephp imagickdraw set the polygon fill rule to be used by the clipping pathphp intlbreakiterator set the text being scannedphp memcached set a new expiration on an itemphp solrquery returns whether or not to include the upper bound term in the result setphp sphinxclient set grouping attributephp sqlite3result closes the result setphp swoole atomic set a new value to the atomic object.php swoole client set the swoole client parameters before the connection is established.
关注编程学问公众号
编程学问网 湘ICP备20001732号