Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2007.04.08;
Скачать: CL | DM;

Вниз

WaitForMultipleObjects для произвольного количества объектов.   Найти похожие ветки 

 
Riply ©   (2007-03-20 00:56) [0]

Здравствуйте !
Допустим, у нас есть n > MAXIMUM_WAIT_OBJECTS объектов.
Надо организовать ожидание срабатывания хотя бы одного из них.
Как это лучше сделать ?
Мне, ничего, кроме организации новой нити для каждых «следующих» 64,
в голову не приходит :(


 
Джо ©   (2007-03-20 01:09) [1]

To wait on more than MAXIMUM_WAIT_OBJECTS handles, use one of the following methods:

Create a thread to wait on MAXIMUM_WAIT_OBJECTS handles, then wait on that thread plus the other handles. Use this technique to break the handles into groups of MAXIMUM_WAIT_OBJECTS.
Call RegisterWaitForSingleObject to wait on each handle. A wait thread from the thread pool waits on MAXIMUM_WAIT_OBJECTS registered objects and assigns a worker thread after the object is signaled or the time-out interval expires.

(c) MSDN.


 
Riply ©   (2007-03-20 01:26) [2]

>[1] Джо ©   (20.03.07 01:09)
Спасибо.
MSDN - у, тоже, спасибо :)



Страницы: 1 вся ветка

Текущий архив: 2007.04.08;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.045 c
15-1173765754
Layner
2007-03-13 09:02
2007.04.08
ADSL модем + Хаб + 2 ПК в интеренет, возможно?


2-1174118231
Boker
2007-03-17 10:57
2007.04.08
TImage - невозможна загрузка ...??


2-1173955723
Max459
2007-03-15 13:48
2007.04.08
Тень от формы.


2-1173896890
Malik
2007-03-14 21:28
2007.04.08
Проблема с Delphi


1-1171303374
tequilla4white
2007-02-12 21:02
2007.04.08
IXMLNode.Count возвращает неверное значение