The C++ framework for developing highly scalable, high performance servers on Windows platforms.

CSimpleNamedPipeClient Class Reference
[Interprocess Communication]

Inheritance diagram for CSimpleNamedPipeClient:
Collaboration diagram for CSimpleNamedPipeClient:

List of all members.


Detailed Description

A wrapper around the Named Pipe API which makes it easy to manage named pipe clients.


Public Member Functions

 CSimpleNamedPipeClient (const Core::_tstring &name)
 Create a client to a named pipe that exists on this machine.
 CSimpleNamedPipeClient (const Core::_tstring &server, const Core::_tstring &name)
 Create a client to a named pipe that exists on the specified machine.
 CSimpleNamedPipeClient (const CSimpleNamedPipeClient &rhs)
CSimpleNamedPipeClientoperator= (const CSimpleNamedPipeClient &rhs)
bool Send (const void *pSendBuffer, DWORD sendBufferSize, Core::COverlapped &overlapped) const
 Send the data in the supplied buffer using the supplied COverlapped object for overlapped I/O notifications.
bool Receive (void *pReceiveBuffer, DWORD receiveBufferSize, Core::COverlapped &overlapped, DWORD *pBytesReceived) const
 Receive from the pipe into the supplied buffer using the supplied COverlapped object for overlapped I/O notifications.
bool SendAndReceive (const void *pSendBuffer, DWORD sendBufferSize, void *pReceiveBuffer, DWORD receiveBufferSize, Core::COverlapped &overlapped, DWORD *pBytesReceived) const
 Send the supplied send buffer and receive a response from the pipe into the receive buffer using the COverlapped object for overlapped I/O notifications.
DWORD GetOverlappedResult (Core::COverlapped &overlapped) const
 Call GetOverlappedResult on the supplied COverlapped object using the pipe's HANDLE and returns the number of bytes transferred. Throws an exception on failure.
bool CancelIo () const

Protected Attributes

CSmartHandle m_handle


Constructor & Destructor Documentation

CSimpleNamedPipeClient ( const Core::_tstring name  )  [explicit]

Create a client to a named pipe that exists on this machine.

CSimpleNamedPipeClient ( const Core::_tstring server,
const Core::_tstring name 
)

Create a client to a named pipe that exists on the specified machine.


Member Function Documentation

CSimpleNamedPipeClient& operator= ( const CSimpleNamedPipeClient rhs  ) 

bool Send ( const void *  pSendBuffer,
DWORD  sendBufferSize,
Core::COverlapped overlapped 
) const [inherited]

Send the data in the supplied buffer using the supplied COverlapped object for overlapped I/O notifications.

bool Receive ( void *  pReceiveBuffer,
DWORD  receiveBufferSize,
Core::COverlapped overlapped,
DWORD pBytesReceived 
) const [inherited]

Receive from the pipe into the supplied buffer using the supplied COverlapped object for overlapped I/O notifications.

bool SendAndReceive ( const void *  pSendBuffer,
DWORD  sendBufferSize,
void *  pReceiveBuffer,
DWORD  receiveBufferSize,
Core::COverlapped overlapped,
DWORD pBytesReceived 
) const [inherited]

Send the supplied send buffer and receive a response from the pipe into the receive buffer using the COverlapped object for overlapped I/O notifications.

DWORD GetOverlappedResult ( Core::COverlapped overlapped  )  const [inherited]

Call GetOverlappedResult on the supplied COverlapped object using the pipe's HANDLE and returns the number of bytes transferred. Throws an exception on failure.

bool CancelIo (  )  const [inherited]


Member Data Documentation

CSmartHandle m_handle [protected, inherited]


Generated on Sun Sep 12 19:11:47 2021 for The Server Framework - v7.4 by doxygen 1.5.3