次の方法で共有


Overlapped Completion Indication Mechanisms (Windows Embedded CE 6.0)

1/6/2010

The particular overlapped I/O completion indication to be used for a given overlapped operation is determined by whether the application supplies a pointer to a completion function, whether a WSAOVERLAPPED structure is referenced, and by the value of the hEvent member within the WSAOVERLAPPED structure, if it is supplied. The following table summarizes the completion semantics for an overlapped socket and shows the various combinations of lpOverlapped, hEvent, and lpCompletionRoutine.

LpOverlapped HEvent lpCompletionRoutine Completion indication

NULL

Not applicable

Ignored

Operation completes synchronously. It behaves as if it were a nonoverlapped socket.

!NULL

NULL

NULL

Operation completes overlapped, but there is no Winsock 2.2 -supported completion mechanism. The completion port mechanism (if supported) can be used in this case. Otherwise, there is no completion notification.

!NULL

!NULL

NULL

Operation completes overlapped, notification by signaling event object.

!NULL

Ignored

!NULL

Operation completes overlapped, notification by scheduling completion routine.

See Also

Concepts

Winsock Overlapped I/O and Event Objects