ReactOS 0.4.16-dev-117-g38f21f9
CPipe.h
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Automatic Testing Utility
3 * LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
4 * PURPOSE: Class that manages an unidirectional anonymous byte stream pipe
5 * COPYRIGHT: Copyright 2015 Thomas Faber (thomas.faber@reactos.org)
6 * Copyright 2019 Colin Finck (colin@reactos.org)
7 */
8
9class CPipe
10{
11private:
13
17
18public:
19 CPipe();
20 ~CPipe();
21
22 void CloseReadPipe();
23 void CloseWritePipe();
24
25 bool Peek(PVOID Buffer, DWORD BufferSize, PDWORD BytesRead, PDWORD TotalBytesAvailable);
26 DWORD Read(PVOID Buffer, DWORD NumberOfBytesToRead, PDWORD NumberOfBytesRead, DWORD TimeoutMilliseconds);
27 bool Write(LPCVOID Buffer, DWORD NumberOfBytesToWrite, PDWORD NumberOfBytesWritten);
28
29 friend class CPipedProcess;
30};
Definition: bufpool.h:45
Definition: CPipe.h:10
HANDLE m_hWritePipe
Definition: CPipe.h:16
bool Write(LPCVOID Buffer, DWORD NumberOfBytesToWrite, PDWORD NumberOfBytesWritten)
Definition: CPipe.cpp:232
void CloseWritePipe()
Definition: CPipe.cpp:98
~CPipe()
Definition: CPipe.cpp:74
bool Peek(PVOID Buffer, DWORD BufferSize, PDWORD BytesRead, PDWORD TotalBytesAvailable)
Definition: CPipe.cpp:129
static LONG m_lPipeCount
Definition: CPipe.h:12
OVERLAPPED m_ReadOverlapped
Definition: CPipe.h:14
CPipe()
Definition: CPipe.cpp:17
void CloseReadPipe()
Definition: CPipe.cpp:86
HANDLE m_hReadPipe
Definition: CPipe.h:15
unsigned long DWORD
Definition: ntddk_ex.h:95
DWORD * PDWORD
Definition: pedump.c:68
long LONG
Definition: pedump.c:60
_In_ BOOLEAN Read
Definition: strmini.h:479
_Must_inspect_result_ _In_ WDFIOTARGET _In_opt_ WDFREQUEST _In_opt_ PWDF_MEMORY_DESCRIPTOR _In_opt_ PLONGLONG _In_opt_ PWDF_REQUEST_SEND_OPTIONS _Out_opt_ PULONG_PTR BytesRead
Definition: wdfiotarget.h:870
_In_ WDFMEMORY _Out_opt_ size_t * BufferSize
Definition: wdfmemory.h:254
CONST void * LPCVOID
Definition: windef.h:191