Ignore:
Timestamp:
Dec 5, 2001, 3:16:38 PM (24 years ago)
Author:
sandervl
Message:

preliminary changes for new overlapped io framework

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/hmfile.cpp

    r7474 r7549  
    1 /* $Id: hmfile.cpp,v 1.31 2001-11-28 23:33:36 phaller Exp $ */
     1/* $Id: hmfile.cpp,v 1.32 2001-12-05 14:16:01 sandervl Exp $ */
    22
    33/*
     
    5656 *****************************************************************************/
    5757
    58 DWORD HMDeviceFileClass::CreateFile (HANDLE        hHandle,
    59                                      LPCSTR        lpFileName,
     58DWORD HMDeviceFileClass::CreateFile (LPCSTR        lpFileName,
    6059                                     PHMHANDLEDATA pHMHandleData,
    6160                                     PVOID         lpSecurityAttributes,
     
    143142 *****************************************************************************/
    144143
    145 DWORD HMDeviceFileClass::OpenFile (HANDLE        hHandle,
    146                                    LPCSTR        lpszFileName,
     144DWORD HMDeviceFileClass::OpenFile (LPCSTR        lpszFileName,
    147145                                   PHMHANDLEDATA pHMHandleData,
    148146                                   OFSTRUCT      *pOFStruct,
     
    337335        duphdata.dwCreation = OPEN_EXISTING;
    338336
    339         if(CreateFile(0, srcfileinfo->lpszFileName, &duphdata,
     337        if(CreateFile(srcfileinfo->lpszFileName, &duphdata,
    340338                      srcfileinfo->lpSecurityAttributes, NULL) == NO_ERROR)
    341339        {
     
    436434                                 DWORD         nNumberOfBytesToRead,
    437435                                 LPDWORD       lpNumberOfBytesRead,
    438                                  LPOVERLAPPED  lpOverlapped)
     436                                 LPOVERLAPPED  lpOverlapped,
     437                                 LPOVERLAPPED_COMPLETION_ROUTINE  lpCompletionRoutine)
    439438{
    440439  LPVOID       lpRealBuf;
     
    501500}
    502501
    503 /*****************************************************************************
    504  * Name      : BOOL ReadFileEx
    505  * Purpose   : The ReadFileEx function reads data from a file asynchronously.
    506  *             It is designed solely for asynchronous operation, unlike the
    507  *             ReadFile function, which is designed for both synchronous and
    508  *             asynchronous operation. ReadFileEx lets an application perform
    509  *             other processing during a file read operation.
    510  *             The ReadFileEx function reports its completion status asynchronously,
    511  *             calling a specified completion routine when reading is completed
    512  *             and the calling thread is in an alertable wait state.
    513  * Parameters: HANDLE       hFile                handle of file to read
    514  *             LPVOID       lpBuffer             address of buffer
    515  *             DWORD        nNumberOfBytesToRead number of bytes to read
    516  *             LPOVERLAPPED lpOverlapped         address of offset
    517  *             LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine address of completion routine
    518  * Variables :
    519  * Result    : TRUE / FALSE
    520  * Remark    :
    521  * Status    : UNTESTED STUB
    522  *
    523  * Author    : Patrick Haller [Mon, 1998/06/15 08:00]
    524  *****************************************************************************/
    525 BOOL HMDeviceFileClass::ReadFileEx(PHMHANDLEDATA pHMHandleData,
    526                            LPVOID       lpBuffer,
    527                            DWORD        nNumberOfBytesToRead,
    528                            LPOVERLAPPED lpOverlapped,
    529                            LPOVERLAPPED_COMPLETION_ROUTINE  lpCompletionRoutine)
    530 {
    531   dprintf(("ERROR: ReadFileEx(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented.\n",
    532            pHMHandleData->hHMHandle,
    533            lpBuffer,
    534            nNumberOfBytesToRead,
    535            lpOverlapped,
    536            lpCompletionRoutine));
    537   return FALSE;
    538 }
    539 
    540502
    541503/*****************************************************************************
     
    559521                                    DWORD         nNumberOfBytesToWrite,
    560522                                    LPDWORD       lpNumberOfBytesWritten,
    561                                     LPOVERLAPPED  lpOverlapped)
     523                                    LPOVERLAPPED  lpOverlapped,
     524                                    LPOVERLAPPED_COMPLETION_ROUTINE  lpCompletionRoutine)
    562525{
    563526  LPVOID       lpRealBuf;
     
    621584}
    622585
    623 /*****************************************************************************
    624  * Name      : BOOL WriteFileEx
    625  * Purpose   : The WriteFileEx function writes data to a file. It is designed
    626  *             solely for asynchronous operation, unlike WriteFile, which is
    627  *             designed for both synchronous and asynchronous operation.
    628  *             WriteFileEx reports its completion status asynchronously,
    629  *             calling a specified completion routine when writing is completed
    630  *             and the calling thread is in an alertable wait state.
    631  * Parameters: HANDLE       hFile                handle of file to write
    632  *             LPVOID       lpBuffer             address of buffer
    633  *             DWORD        nNumberOfBytesToRead number of bytes to write
    634  *             LPOVERLAPPED lpOverlapped         address of offset
    635  *             LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine address of completion routine
    636  * Variables :
    637  * Result    : TRUE / FALSE
    638  * Remark    :
    639  * Status    : UNTESTED STUB
    640  *
    641  * Author    : Patrick Haller [Mon, 1998/06/15 08:00]
    642  *****************************************************************************/
    643 
    644 BOOL HMDeviceFileClass::WriteFileEx(PHMHANDLEDATA pHMHandleData,
    645                            LPVOID       lpBuffer,
    646                            DWORD        nNumberOfBytesToWrite,
    647                            LPOVERLAPPED lpOverlapped,
    648                            LPOVERLAPPED_COMPLETION_ROUTINE  lpCompletionRoutine)
    649 {
    650   dprintf(("ERROR: WriteFileEx(%08xh,%08xh,%08xh,%08xh,%08xh) not implemented.\n",
    651            pHMHandleData->hHMHandle,
    652            lpBuffer,
    653            nNumberOfBytesToWrite,
    654            lpOverlapped,
    655            lpCompletionRoutine));
    656   return FALSE;
    657 }
    658586
    659587/*****************************************************************************
Note: See TracChangeset for help on using the changeset viewer.