분류 전체보기
-
Completion Port(Overlapped) - Win32Platform/소켓 2009. 4. 21. 22:04
CreateIoCompletionPort() PostQueuedCompletionStatus() GetQueuedCompletionStatus() WSAGetOverlappedResult() BindIoCompletionCallback() // Windows 2000 #define MAX_COMPLETION_THREAD_COUNT 32 // Maximum number of completion threads allowed // // Function: HandleIo // // Description: // This function handles the IO on a socket. In the event of a receive, the // completed receive is posted again. For..
-
Overlapped(Asynchronous) IO - Win32Platform/소켓 2009. 4. 21. 20:52
IO 완료를 이벤트나 완료 루틴으로 통보받을 수 있다. Alertable State // IO 루틴을 호출한 스레드?? SleepEx() WaitForSingleObjectEx() WaitForMultipleObjectsEx() MsgWaitForMultipleObjectsEx() SignalObjectAndWait() AcceptEx() GetAcceptExSockaddrs() WSASend() 오버랩드 IO를 수행하려면 여섯번 째(lpOverlapped), 일곱번 째(lpCompletionROUTINE) 인자를 사용한다. WSASendTo() WSARecv() WSARecvFrom() WSAGetOverlappedResult() // // This is our per I/O data. It descr..
-
WSAEventSelect() - IO 멀티플렉싱(Win32)Platform/소켓 2009. 4. 18. 22:13
WSACreateEvent() WSACloseEvent() WSAResetEvent() WSAEventSelect() IO 호출에 블록되기 전에 소켓 이벤트를 이벤트로 비동기적으로 통보 받을 수 있다. 비동기 데이타 송수신이 제공되는 것은 아니다. FD_CLOSE FD_ACCEPT FD_READ FD_WRITE WaitForSingleObject() WaitForMultipleObjects() MsgWaitForMultipleObjects() SignalObjectAndWait() WSAWaitForMultipleEvents() #include #include #include #define BUFSIZE 100 void CompressSockets(SOCKET* hSockArray, int omitInd..
-
WSAAsyncSelect() - IO 멀티플렉싱(Win32)Platform/소켓 2009. 4. 18. 17:25
WSAAsyncSelect() 소켓 이벤트를 윈도우 메시지로 비동기적으로 통보 받을 수 있기 때문에 IO 호출에 블록되는 것을 피할 수 있다. 비동기 데이타 송수신이 제공되는 것은 아니다. FD_CLOSE FD_ACCEPT FD_READ FD_WRITE // // Function: FindSocketObj // // Description: // Search through the lsit of socket objects for the object matching // the socket handle supplied. Return the object if found; NULL otherwise. // SOCKET_OBJ *FindSocketObj(SOCKET s) { SOCKET_OBJ *ptr=NULL; ..
-
MASM프로그래밍 언어/설정 2009. 4. 13. 00:32
MASM(the Microsoft Macro Assembler) preserves the historical INTEL notation for writing x86 assembler MASM Version 5.1 In MASM version 5.1 the assembler is MASM.EXE. the file name for the assembler was changed to ML.EXE in 1991 with the release of MASM version 6.0 the last seperate release of MASM 6.11d as a commercial product Microsoft released version 6.11d in 1993 including 32 bit Windows ope..
-
디바이스 콘텍스트 - Win32GUI/GDI 2009. 4. 9. 01:32
윈도우즈는 디바이스 콘텍스트의 수를 제한한다. 디바이스 컨텍스트 객체가 파괴될 때, 이와 관련된 모든 GDI 객체의 선택이 해제된다. // ??? WM_PAINT 메시지가 발생하였을 때 HDC hDC; PAINTSTRUCT ps; hDC = BeginPaint(hWnd, &ps); // DC의 핸들을 얻는다. // DC 핸들을 가지고 작업을 한다. EndPaint(hWnd, &ps); // 사용 후에는 DC를 반드시 반환한다. 윈도우의 클라이언트 영역에 그리(출력)고자 할 때 HDC hDC; hDC = GetDC(hWnd); // DC의 핸들을 얻는다. // DC 핸들을 가지고 작업을 한다. ReleaseDC(hWnd, hDC); // 사용 후에는 DC를 반드시 반환한다. 윈도우 클라이언트 영역뿐만 아니..