« PHP 8.3 Manual トップ
著作権 »
per page, with , order by , clip by
Results of 1 - 10 of about 17 for EvTimer (0.002 sec.)
EvTimer::createStopped — Creates EvTimer stopped watcher object | PHP 8.3 12449
EvTimer::createStopped (PECL ev >= 0.2.0) EvTimer::createStopped — Creates EvTimer stopped watcher object 説明 final public static function EvTimer::createStopped ( float $after , float $repeat , callable $callback , mixed $data = null , in ... t $priority = 0 ): EvTimer Creates EvTimer stopped watcher object. Unlike EvTimer::__construct() , this method doesn't start the watcher automaticall ... y. callback See Watcher callbacks . data Custom data associated with the watcher. priority Watcher priority 戻り値 Returns EvTimer watcher object on success. 例 例1 Monitor changes of /var/log/messages. Avoid missing updates by means of one second delay ... <?php $timer = EvTimer :: createStopped ( 0. , 1.02 , function ( $w ) { $w -> stop (); $stat = $w -> data ; // 1 second after the most recent cha ...
https://man.mtool.work/php/8.3/evtimer.createstopped.html
EvLoop::timer — Creates EvTimer watcher object associated with the current even... 11500
EvLoop::timer (PECL ev >= 0.2.0) EvLoop::timer — Creates EvTimer watcher object associated with the current event loop instance 説明 final public function EvLoop::timer ( float $after , float $repeat , callable $callback , mixed $data = nul ... l , int $priority = 0 ): EvTimer Creates EvTimer watcher object associated with the current event loop instance パラメータ All parameters have the same mea ... ning as for EvTimer::__construct() 戻り値 Returns EvTimer object on success 参考 EvTimer::__construct() - Constructs an EvTimer watcher object ...
https://man.mtool.work/php/8.3/evloop.timer.html
The EvTimer class | PHP 8.3 11052
The EvTimer class (PECL ev >= 0.2.0) はじめに EvTimer watchers are simple relative timers that generate an event after a given time, and optionally repeating in regular intervals after that. The timers are based on real time, that is, if on ... akes longer than those 10 seconds to do) the timer will not fire more than once per event loop iteration. クラス概要 class EvTimer extends EvWatcher { /* プロパティ */ public $ repeat ; public $ remaining ; /* 継承したプロパティ */ public $ is_active ; ... tic function createStopped ( float $after , float $repeat , callable $callback , mixed $data = null , int $priority = 0 ): EvTimer public function set ( float $after , float $repeat ): void /* 継承したメソッド */ public function EvWatcher::clear (): int ... ive to the current event loop time, otherwise it's the timeout value currently configured. That is, after instantiating an EvTimer with an after value of 5.0 and repeat value of 7.0 , remaining returns 5.0 . When the timer is started and one second pass ...
https://man.mtool.work/php/8.3/class.evtimer.html
EvTimer::__construct — Constructs an EvTimer watcher object | PHP 8.3 11052
EvTimer::__construct (PECL ev >= 0.2.0) EvTimer::__construct — Constructs an EvTimer watcher object 説明 public function EvTimer::__construct ( float $after , float $repeat , callable $callback , mixed $data = null , int $priority = 0 ) Con ... structs an EvTimer watcher object. パラメータ after Configures the timer to trigger after after seconds. repeat If repeat is 0.0 , then it wi ... e watcher. priority Watcher priority 例 例1 Simple timers <?php // Create and start timer firing after 2 seconds $w1 = new EvTimer ( 2 , 0 , function () { echo "2 seconds elapsed\n" ; }); // Create and launch timer firing after 2 seconds repeating each ... second // until we manually stop it $w2 = new EvTimer ( 2 , 1 , function ( $w ) { echo "is called every second, is launched after 2 seconds\n" ; echo "iteration = " , Ev :: ite ...
https://man.mtool.work/php/8.3/evtimer.construct.html
Ev | PHP 8.3 8966
Ev はじめに この拡張モジュールは、 » libev ライブラリへのインターフェイスを提供します。 このライブラリは、C で書かれたハイパフォーマンスで高機能なイベントループです。 注意 : この拡張モジュールは Windows 環境では利用できません。 Libev はイベ ... current event loop instance EvLoop::stop — Stops the event loop EvLoop::suspend — Suspend the loop EvLoop::timer — Creates EvTimer watcher object associated with the current event loop instance EvLoop::verify — Performs internal consistency checks(for d ... revious set of values returned by EvStat::attr EvStat::set — Configures the watcher EvStat::stat — Initiates the stat call EvTimer — The EvTimer class EvTimer::again — Restarts the timer watcher EvTimer::__construct — Constructs an EvTimer watcher objec ... t EvTimer::createStopped — Creates EvTimer stopped watcher object EvTimer::set — Configures the watcher EvWatcher — The EvWatcher cl ...
https://man.mtool.work/php/8.3/book.ev.html
EvTimer::set — Configures the watcher | PHP 8.3 8742
EvTimer::set (PECL ev >= 0.2.0) EvTimer::set — Configures the watcher 説明 public function EvTimer::set ( float $after , float $repeat ): void Configures the watcher パラメータ after Configures the timer to trigger after after seconds. repe ...
https://man.mtool.work/php/8.3/evtimer.set.html
EvTimer::again — Restarts the timer watcher | PHP 8.3 8604
EvTimer::again (PECL ev >= 0.2.0) EvTimer::again — Restarts the timer watcher 説明 public function EvTimer::again (): void This will act as if the timer timed out and restart it again if it is repeating. The exact semantics are: if the time ...
https://man.mtool.work/php/8.3/evtimer.again.html
EvPeriodic::createStopped — Create a stopped EvPeriodic watcher | PHP 8.3 7931
EvPeriodic::createStopped (PECL ev >= 0.2.0) EvPeriodic::createStopped — Create a stopped EvPeriodic watcher 説明 final public static function EvPeriodic::createStopped ( float $offset , float $interval , callable $reschedule_cb , callable ... 戻り値 Returns EvPeriodic watcher object on success. 参考 EvPeriodic::__construct() - Constructs EvPeriodic watcher object EvTimer::createStopped() - Creates EvTimer stopped watcher object 他のマニュアルの関連ページ Docker Swarm の再スケジュール・ポリシ ...
https://man.mtool.work/php/8.3/evperiodic.createstopped.html
例 | PHP 8.3 7897
例 例1 タイマーのサンプル <?php // タイマーを作り、2 秒後に起動します $w1 = new EvTimer ( 2 , 0 , function () { echo "2 seconds elapsed\n" ; }); // タイマーを作って 2 秒後に起動させ、その後は // 手で止めるまで 1 秒おきに繰り返します $w2 = n ... ew EvTimer ( 2 , 1 , function ( $w ) { echo "is called every second, is launched after 2 seconds\n" ; echo "iteration = " , Ev :: ite ... ion () >= 10 and $w -> stop (); }); // 停止状態のタイマーを作ります。開始させるまでは非アクティブになります。 $w_stopped = EvTimer :: createStopped ( 10 , 5 , function( $w ) { echo "Callback of a timer created as stopped\n" ; // 2 回繰り返したあとでウォ ... watcher and try to handle the same events, but don't block\n" ; $w2 -> again (); Ev :: run ( Ev :: RUN_NOWAIT ); $w = new EvTimer ( 10 , 0 , function() {}); echo "Running a blocking loop\n" ; Ev :: run (); echo "END\n" ; ?> 上の例の出力は、 たとえば以下 ...
https://man.mtool.work/php/8.3/ev.examples.html
The EvLoop class | PHP 8.3 7569
The EvLoop class (PECL ev >= 0.2.0) はじめに Represents an event loop that is always distinct from the default loop . Unlike the default loop , it cannot handle EvChild watchers. Having threads we have to create a loop per thread, and use t ... inal public function timer ( float $after , float $repeat , callable $callback , mixed $data = null , int $priority = 0 ): EvTimer public function verify (): void } プロパティ data Custom data attached to loop backend Readonly . The backend flags indica ... EvIo events, so more events can be handled per iteration, at the cost of increasing latency. Timeouts (both EvPeriodic and EvTimer ) will not be affected. Setting this to a non-zero value will introduce an additional sleep() call into most loop iteratio ... current event loop instance EvLoop::stop — Stops the event loop EvLoop::suspend — Suspend the loop EvLoop::timer — Creates EvTimer watcher object associated with the current event loop instance EvLoop::verify — Performs internal consistency checks(for d ...
https://man.mtool.work/php/8.3/class.evloop.html
PREV 1 2 NEXT