Tekkaman

导航

 

CompletionPort

1、CreateIoCompletionPort。此方法用于创建与绑定。此方法调用后,socket即退出,只能通过CompletionKey来辨认是哪个socket的消息。

  

  CompletionKey是自定义数据,用于区分FileHandle。

  NumberOfConcurrentThreads [in]

  The maximum number of threads that the operating system can allow to concurrently process I/O completion packets for the I/O completion port. This parameter is ignored if the ExistingCompletionPortparameter is not NULL.

  If this parameter is zero, the system allows as many concurrently running threads as there are processors in the system.

参考:https://msdn.microsoft.com/en-us/library/windows/desktop/aa363862(v=vs.85).aspx

2、GetQueuedCompletionStatus。 

  

  Returns nonzero (TRUE) if successful or zero (FALSE) otherwise.

参考:https://msdn.microsoft.com/en-us/library/windows/desktop/aa364986(v=vs.85).aspx

 

posted on 2015-10-01 11:03  Tekkaman  阅读(154)  评论(0编辑  收藏  举报