« PHP 8.3 Manual トップ
著作権 »
per page, with , order by , clip by
Results of 1 - 10 of about 21 for intval (0.002 sec.)
intval — 変数の整数としての値を取得する | PHP 8.3 15458
intval (PHP 4, PHP 5, PHP 7, PHP 8) intval — 変数の整数としての値を取得する 説明 function intval ( mixed $value , int $base = 10 ): int 指定された値 base を基数(デフォルトは 10)とする、 value の int としての値を返します。 オブジェクトに intval ... す。32 ビットシステムでは、 最大の符号付き整数の範囲 -2147483648 ~ 2147483647 となります。 このため、そのようなシステムでは intval('1000000000000') は 2147483647 を返します。 64 ビットシステムにおける最大の符号付き整数は 9223372036854775807 となります。 ... 果は単に先頭の 整数部分にはなりません。大きな指数の場合はさらに PHP_INT_MAX にオーバーフローする可能性があります: <?php echo intval ( '42.42e42' ); // 9223372036854775807 on 64-bit systems ?> このような文字列がどのように解釈されるかについての詳細は、 数値 ... 説明 8.0.0 オブジェクトを指定して変換しようとした場合のエラーレベルが、 E_NOTICE から E_WARNING に変更されました。 例 例1 intval() の例 以下の例は 64 ビットシステムに基づきます。 <?php echo intval ( 42 ), PHP_EOL ; // 42 echo intval ( 4.7 ), PHP_EOL ; ...
https://man.mtool.work/php/8.3/function.intval.html
gmp_intval — GMP 数を整数に変換する | PHP 8.3 10875
gmp_intval (PHP 4 >= 4.0.4, PHP 5, PHP 7, PHP 8) gmp_intval — GMP 数を整数に変換する 説明 function gmp_intval ( GMP | int | string $num ): int この関数は、GMP 数を PHP ネイティブの整数に変換します。 パラメータ num GMP オブジェクト、 int 、 ... 動検出するとき ( base に 0 を指定したとき) と同じ方法で解釈されます。 戻り値 num を整数に変換した結果を返します。 例 例1 gmp_intval() の例 <?php // 正しい結果を表示します echo gmp_intval ( "2147483647" ) . "\n" ; // PHP の整数型の制限をこえているので、正 ... しい結果を表示しません echo gmp_intval ( "2147483648" ) . "\n" ; // 正しい結果を表示します echo gmp_strval ( "2147483648" ) . "\n" ; ?> 上の例の出力は以下となりま ...
https://man.mtool.work/php/8.3/function.gmp-intval.html
Other Changes | PHP 8.3 8372
Other Changes Core changes Core In case of a hard OOM (out of memory) condition, PHP now calls abort() instead of exit(1) , changing the exit code to 134 and possibly creating a core dump. The PHP_OS_FAMILY constant has an AIX value for whe ... map() , with multiple arrays passed array_product() and array_sum() , for integer-only arrays array_unshift() array_walk() intval() , for intval('0b...', 2) and intval('+0b...', 2) pathinfo() , when requesting a single component str_pad() str_repeat() ...
https://man.mtool.work/php/8.3/migration86.other-changes.html
新機能 | PHP 8.3 8219
新機能 定数式 数値や文字列リテラルと定数を、これまでのバージョンでは静的な値が想定されていた場面 (定数やプロパティの宣言、関数のデフォルト引数など) で、スカラー式として扱えるようになりました。 <?php const ONE = 1 ; const TWO = ONE * 2 ; cla ... なります。 <?php $a = gmp_init ( 42 ); $b = gmp_init ( 17 ); if ( version_compare ( PHP_VERSION , '5.6' , '<' )) { echo gmp_intval ( gmp_add ( $a , $b )), PHP_EOL ; echo gmp_intval ( gmp_add ( $a , 17 )), PHP_EOL ; echo gmp_intval ( gmp_add ( 42 , $b )) ...
https://man.mtool.work/php/8.3/migration56.new-features.html
Imagick::adaptiveThresholdImage — 輝度の範囲にもとづいて各ピクセルの閾値を選択... 8118
Imagick::adaptiveThresholdImage (PECL imagick 2, PECL imagick 3) Imagick::adaptiveThresholdImage — 輝度の範囲にもとづいて各ピクセルの閾値を選択する 説明 public function Imagick::adaptiveThresholdImage ( int $width , int $height , int $offse ... Path , $width , $height , $adaptiveOffset ) { $imagick = new \Imagick ( realpath ( $imagePath )); $adaptiveOffsetQuantum = intval ( $adaptiveOffset * \Imagick :: getQuantum ()); $imagick -> adaptiveThresholdImage ( $width , $height , $adaptiveOffsetQua ...
https://man.mtool.work/php/8.3/imagick.adaptivethresholdimage.html
ssh2_sftp — SFTP サブシステムを初期化する | PHP 8.3 8050
ssh2_sftp (PECL ssh2 >= 0.9.0) ssh2_sftp — SFTP サブシステムを初期化する 説明 function ssh2_sftp ( resource $session ): resource | false すでに接続された SSH2 サーバーから SFTP サブシステムを要求します。 パラメータ session ssh2_connect() の ... _password ( $connection , 'username' , 'password' ); $sftp = ssh2_sftp ( $connection ); $stream = fopen ( 'ssh2.sftp://' . intval ( $sftp ) . '/path/to/file' , 'r' ); ?> 参考 ssh2_scp_recv() - SCP 経由でファイルを要求する ssh2_scp_send() - SCP 経由でフ ...
https://man.mtool.work/php/8.3/function.ssh2-sftp.html
strval — 変数の文字列としての値を取得する | PHP 8.3 8000
strval (PHP 4, PHP 5, PHP 7, PHP 8) strval — 変数の文字列としての値を取得する 説明 function strval ( mixed $value ): string value の string としての値を 返します。文字列への変換の詳細については、 string の ドキュメントを参照ください。 この関 ... o strval (new StrValTest ); ?> 参考 boolval() - 変数の boolean としての値を取得する floatval() - 変数の float 値を取得する intval() - 変数の整数としての値を取得する settype() - 変数の型をセットする sprintf() - フォーマットされた文字列を返す number_form ...
https://man.mtool.work/php/8.3/function.strval.html
整数 | PHP 8.3 8000
整数 int は、ℤ = {..., -2, -1, 0, 1, 2, ...} という集合です。 参考 浮動小数点数 任意精度整数 / BCMath 任意精度整数 / GMP 構文 整数 (integer) は、10 進数(基数 10)、16 進数 (基数 16)、8 進数 (基数 8) あるいは 2 進数 (基数 2) 表記で指定可能です ... 、演算子、関数、制御構造が int 引数を必要とする場合、値は自動的に変換されるため、 キャストを使用する必要はありません。 関数 intval() を用いて値を整数に変換することも可能です。 resource を int に変換すると、その結果は一意なリソース番号となります。 これは ... mp ( foo ( 8.0 )); // PHP 8.1.0 より前でもあとでも、8 var_dump ((int) 8.1 ); // PHP 8.1.0 より前でもあとでも、8 var_dump ( intval ( 8.1 )); // PHP 8.1.0 より前でもあとでも、8 ?> float が整数の範囲 (通常は、32 ビットプラットフォームでは +/- 2.15e+9 = 2^ ...
https://man.mtool.work/php/8.3/language.types.integer.html
boolval — 変数の boolean としての値を取得する | PHP 8.3 7949
boolval (PHP 5 >= 5.5.0, PHP 7, PHP 8) boolval — 変数の boolean としての値を取得する 説明 function boolval ( mixed $value ): bool value の bool としての値を返します。 パラメータ value bool に変換したいスカラー値。 戻り値 value の bool として ... alse "string": true "0": false "1": true [1, 2]: true []: false stdClass: true 参考 floatval() - 変数の float 値を取得する intval() - 変数の整数としての値を取得する strval() - 変数の文字列としての値を取得する settype() - 変数の型をセットする is_bool() ...
https://man.mtool.work/php/8.3/function.boolval.html
floatval — 変数の float 値を取得する | PHP 8.3 7949
floatval (PHP 4 >= 4.2.0, PHP 5, PHP 7, PHP 8) floatval — 変数の float 値を取得する 説明 function floatval ( mixed $value ): float value の float 値を返します。 パラメータ value あらゆるスカラ型を指定できます。オブジェクトに floatval() を使 ... _value_of_var = floatval ( $var ); echo $float_value_of_var ; // 0 ?> 参考 boolval() - 変数の boolean としての値を取得する intval() - 変数の整数としての値を取得する strval() - 変数の文字列としての値を取得する settype() - 変数の型をセットする 型の相互変 ...
https://man.mtool.work/php/8.3/function.floatval.html
PREV 1 2 3 NEXT