« HRTime\StopWatch::getLastElapsedTicks
HRTime\StopWatch::isRunning »

HRTime\StopWatch::getLastElapsedTime

(PECL hrtime >= 0.4.3)

HRTime\StopWatch::getLastElapsedTime — 最後のインターバルの経過時間を取得する

説明

public function HRTime\StopWatch::getLastElapsedTime(int $unit = ?): float

直前に閉じたインターバルの経過時間を取得します。

パラメータ

unit

HRTime\Unit 定数で表される時間単位。デフォルトは HRTime\Unit::SECOND です。

戻り値

経過時間を示す float を返します。

関連キーワード:
HRTime   StopWatch   経過   時間   インターバル   最後   getLastElapsedTime   unit   float   Unit   getLastElapsedTicks   isRunning   hrtime   定数   時間単位
関連する関数・ページ:
hrtime-stopwatch.getelapsedtime   class.hrtime-stopwatch   hrtime-stopwatch.getlastelapsedticks   book.hrtime   hrtime-stopwatch.getelapsedticks   hrtime-stopwatch.isrunning