Windows C++ Library
Public Member Functions | Protected Attributes | Friends
CBuffer Class Reference

#include <Buffer.hpp>

List of all members.

Public Member Functions

 CBuffer ()
 CBuffer (size_t nSize)
 CBuffer (const void *pData, size_t nSize)
 CBuffer (HGLOBAL hGlobal)
 CBuffer (const CBuffer &oRHS)
 ~CBuffer ()
size_t Size () const
const void * Buffer () const
void Get (void *pData, size_t nSize, size_t nOffset=0) const
void Size (size_t nSize)
void * Buffer ()
void Set (const void *pData, size_t nSize, size_t nOffset=0)
CBufferoperator= (const CBuffer &oRHS)
bool operator== (const CBuffer &oRHS) const
bool operator!= (const CBuffer &oRHS) const
HGLOBAL ToGlobal () const
CString ToString (TextFormat eFormat) const
 Convert the entire buffer to a string.
void FromString (const CString &str, TextFormat eFormat, bool bIncNull=true)
 Fill the buffer with the contents of a string.

Protected Attributes

size_t m_nSize
void * m_pBuffer

Friends

void operator>> (WCL::IInputStream &rStream, CBuffer &rBuffer)
void operator<< (WCL::IOutputStream &rStream, const CBuffer &rBuffer)

Constructor & Destructor Documentation

CBuffer::CBuffer ( size_t  nSize)
CBuffer::CBuffer ( const void *  pData,
size_t  nSize 
)
CBuffer::CBuffer ( HGLOBAL  hGlobal) [explicit]
CBuffer::CBuffer ( const CBuffer oRHS)

Member Function Documentation

size_t CBuffer::Size ( ) const [inline]
const void * CBuffer::Buffer ( ) const [inline]
void CBuffer::Get ( void *  pData,
size_t  nSize,
size_t  nOffset = 0 
) const
void CBuffer::Size ( size_t  nSize)
void * CBuffer::Buffer ( ) [inline]
void CBuffer::Set ( const void *  pData,
size_t  nSize,
size_t  nOffset = 0 
)
CBuffer & CBuffer::operator= ( const CBuffer oRHS)
bool CBuffer::operator== ( const CBuffer oRHS) const
bool CBuffer::operator!= ( const CBuffer oRHS) const [inline]
HGLOBAL CBuffer::ToGlobal ( ) const
CString CBuffer::ToString ( TextFormat  eFormat) const

Convert the entire buffer to a string.

void CBuffer::FromString ( const CString str,
TextFormat  eFormat,
bool  bIncNull = true 
)

Fill the buffer with the contents of a string.


Friends And Related Function Documentation

void operator>> ( WCL::IInputStream rStream,
CBuffer rBuffer 
) [friend]
void operator<< ( WCL::IOutputStream rStream,
const CBuffer rBuffer 
) [friend]

Member Data Documentation

size_t CBuffer::m_nSize [protected]
void* CBuffer::m_pBuffer [protected]

The documentation for this class was generated from the following files: