… | |
… | |
389 | |
389 | |
390 | The instrument to do that is called a "condition variable", so called |
390 | The instrument to do that is called a "condition variable", so called |
391 | because they represent a condition that must become true. |
391 | because they represent a condition that must become true. |
392 | |
392 | |
393 | Condition variables can be created by calling the C<< AnyEvent->condvar |
393 | Condition variables can be created by calling the C<< AnyEvent->condvar |
394 | |
|
|
395 | >> method, usually without arguments. The only argument pair allowed is |
394 | >> method, usually without arguments. The only argument pair allowed is |
396 | |
395 | |
397 | C<cb>, which specifies a callback to be called when the condition variable |
396 | C<cb>, which specifies a callback to be called when the condition variable |
398 | becomes true, with the condition variable as the first argument (but not |
397 | becomes true, with the condition variable as the first argument (but not |
399 | the results). |
398 | the results). |