--- cvsroot/EV/EV.pm 2007/11/02 11:02:22 1.22 +++ cvsroot/EV/EV.pm 2007/11/02 20:21:33 1.23 @@ -152,9 +152,13 @@ its name, e.g. EV::io has a non-starting variant EV::io_ns and so on. Please note that a watcher will automatically be stopped when the watcher -object is returned, so you I to keep the watcher objects returned by +object is destroyed, so you I to keep the watcher objects returned by the constructors. +Also, all methods changing some aspect of a watcher (->set, ->priority, +->fh and so on) automatically stop and start it again if it is active, +which means pending events get lost. + =head2 WATCHER TYPES Now lets move to the existing watcher types and asociated methods. @@ -186,8 +190,20 @@ =item $old_cb = $w->cb ($new_cb) -Queries the callback on the watcher and optionally changes it. You cna do -this at any time. +Queries the callback on the watcher and optionally changes it. You can do +this at any time without the watcher restarting. + +=item $current_priority = $w->priority + +=item $old_priority = $w->priority ($new_priority) + +Queries the priority on the watcher and optionally changes it. Pending +watchers with higher priority will be invoked first. The valid range of +priorities lies between EV::MAXPRI (default 3) and EV::MINPRI (default +-3). If the priority is outside this range it will automatically be +normalised to the nearest valid priority. + +The default priority of any newly-created weatcher is 0. =item $w->trigger ($revents)