Results of 1 - 1 of about 1 for Rocks (0.001 sec.)
- パイプ演算子 | PHP 8.3 9414
- パイプ演算子 PHP 8.5 以降では、callable に直接値を渡す演算子をサポートしています。 |> 演算子、または "パイプ" は、右辺にパラメータをひとつ取る callable を受け入れ、左辺値をそれに渡し、callable の結果を評価します。 右辺の callable は、有効な
... す。 たとえば、論理的には同じ意味になるコード片を2つ、以下に示します: 例2 |> の呼び出しをチェインさせる <?php $result = "PHP Rocks" |> htmlentities (...) |> str_split (...) |> (fn( $x ) => array_map ( strtoupper (...), $x )) |> (fn( $x ) => array_filter ... ( $x , fn( $v ) => $v != 'O' )) ; print_r ( $result ); $temp = "PHP Rocks" ; $temp = htmlentities ( $temp ); $temp = str_split ( $temp ); $temp = array_map ( strtoupper (...), $temp ); $temp = arr ...
-
https://man.mtool.work/php/8.3/language.operators.functional.html
PREV
1
NEXT