home     download     screen shots     bugs     mailing list     example output     generated MFC docs     help     tools and utilities


 Overview   Project   Class   Tree   Index 
MFC Class Library
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

MFC
Class CString

   in AFX.H

class CString


Field Summary
protected LPTSTR m_pchData
          
 
Constructor Summary
CString( LPCWSTR lpsz )
          
CString( const CString& stringSrc )
          
CString( TCHAR ch, int nRepeat = 1 )
          
CString( LPCSTR lpsz )
          
CString()
          
CString( LPCSTR lpch, int nLength )
          
CString( LPCWSTR lpch, int nLength )
          
CString( const unsigned char* psz )
          
~CString()
          
 
Method Summary
protected void AllocBeforeWrite( int nLen )
          
protected void AllocBuffer( int nLen )
          
protected void AllocCopy( CString& dest, int nCopyLen, int nCopyIndex, int nExtraLen ) const
          
 BSTR AllocSysString() const
          
 void AnsiToOem()
          
protected void AssignCopy( int nSrcLen, LPCTSTR lpszSrcData )
          
 int Collate( LPCTSTR lpsz ) const
          
 int CollateNoCase( LPCTSTR lpsz ) const
          
 int Compare( LPCTSTR lpsz ) const
          
 int CompareNoCase( LPCTSTR lpsz ) const
          
protected void ConcatCopy( int nSrc1Len, LPCTSTR lpszSrc1Data, int nSrc2Len, LPCTSTR lpszSrc2Data )
          
protected void ConcatInPlace( int nSrcLen, LPCTSTR lpszSrcData )
          
protected void CopyBeforeWrite()
          
 int Delete( int nIndex, int nCount = 1 )
          
 void Empty()
          
 int Find( TCHAR ch ) const
          
 int Find( LPCTSTR lpszSub ) const
          
 int Find( TCHAR ch, int nStart ) const
          
 int Find( LPCTSTR lpszSub, int nStart ) const
          
 int FindOneOf( LPCTSTR lpszCharSet ) const
          
 void AFX_CDECL Format( LPCTSTR lpszFormat,... )
          
 void AFX_CDECL Format( UINT nFormatID,... )
          
 void AFX_CDECL FormatMessage( UINT nFormatID,... )
          
 void AFX_CDECL FormatMessage( LPCTSTR lpszFormat,... )
          
 void FormatV( LPCTSTR lpszFormat, va_list argList )
          
protected static void FASTCALL FreeData( CStringData* pData )
          
 void FreeExtra()
          
 int GetAllocLength() const
          
 TCHAR GetAt( int nIndex ) const
          
 LPTSTR GetBuffer( int nMinBufLength )
          
 LPTSTR GetBufferSetLength( int nNewLength )
          
protected CStringData* GetData() const
          
 int GetLength() const
          
protected void Init()
          
 int Insert( int nIndex, LPCTSTR pstr )
          
 int Insert( int nIndex, TCHAR ch )
          
 BOOL IsEmpty() const
          
 CString Left( int nCount ) const
          
 BOOL LoadString( UINT nID )
          
 LPTSTR LockBuffer()
          
 operator LPCTSTR() const
          
 void MakeLower()
          
 void MakeReverse()
          
 void MakeUpper()
          
 CString Mid( int nFirst, int nCount ) const
          
 CString Mid( int nFirst ) const
          
 void OemToAnsi()
          
 const CString& operator+=( TCHAR ch )
          
 const CString& operator+=( const CString& string )
          
 const CString& operator+=( LPCTSTR lpsz )
          
 const CString& operator=( LPCSTR lpsz )
          
 const CString& operator=( const CString& stringSrc )
          
 const CString& operator=( LPCWSTR lpsz )
          
 const CString& operator=( TCHAR ch )
          
 const CString& operator=( const unsigned char* psz )
          
 TCHAR operator[]( int nIndex ) const
          
protected void Release()
          
protected static void PASCAL Release( CStringData* pData )
          
 void ReleaseBuffer( int nNewLength =-1 )
          
 int Remove( TCHAR chRemove )
          
 int Replace( LPCTSTR lpszOld, LPCTSTR lpszNew )
          
 int Replace( TCHAR chOld, TCHAR chNew )
          
 int ReverseFind( TCHAR ch ) const
          
 CString Right( int nCount ) const
          
protected static int PASCAL SafeStrlen( LPCTSTR lpsz )
          
 void SetAt( int nIndex, TCHAR ch )
          
 BSTR SetSysString( BSTR* pbstr ) const
          
 CString SpanExcluding( LPCTSTR lpszCharSet ) const
          
 CString SpanIncluding( LPCTSTR lpszCharSet ) const
          
 void TrimLeft()
          
 void TrimLeft( LPCTSTR lpszTargets )
          
 void TrimLeft( TCHAR chTarget )
          
 void TrimRight( LPCTSTR lpszTargets )
          
 void TrimRight( TCHAR chTarget )
          
 void TrimRight()
          
 void UnlockBuffer()
          
 

Field Detail

m_pchData

protected LPTSTR m_pchData;


Constructor Detail

CString

public CString( LPCWSTR lpsz );

CString

public CString( const CString& stringSrc );

CString

public CString( TCHAR ch, int nRepeat = 1 );

CString

public CString( LPCSTR lpsz );

CString

public CString();

CString

public CString( LPCSTR lpch, int nLength );

CString

public CString( LPCWSTR lpch, int nLength );

CString

public CString( const unsigned char* psz );

~CString

public ~CString();


Method Detail

AllocBeforeWrite

protected void AllocBeforeWrite( int nLen );

AllocBuffer

protected void AllocBuffer( int nLen );

AllocCopy

protected void AllocCopy( CString& dest, int nCopyLen, int nCopyIndex, int nExtraLen ) const;

AllocSysString

public BSTR AllocSysString() const;

AnsiToOem

public void AnsiToOem();

AssignCopy

protected void AssignCopy( int nSrcLen, LPCTSTR lpszSrcData );

Collate

public int Collate( LPCTSTR lpsz ) const;

CollateNoCase

public int CollateNoCase( LPCTSTR lpsz ) const;

Compare

public int Compare( LPCTSTR lpsz ) const;

CompareNoCase

public int CompareNoCase( LPCTSTR lpsz ) const;

ConcatCopy

protected void ConcatCopy( int nSrc1Len, LPCTSTR lpszSrc1Data, int nSrc2Len, LPCTSTR lpszSrc2Data );

ConcatInPlace

protected void ConcatInPlace( int nSrcLen, LPCTSTR lpszSrcData );

CopyBeforeWrite

protected void CopyBeforeWrite();

Delete

public int Delete( int nIndex, int nCount = 1 );

Empty

public void Empty();

Find

public int Find( TCHAR ch ) const;

Find

public int Find( LPCTSTR lpszSub ) const;

Find

public int Find( TCHAR ch, int nStart ) const;

Find

public int Find( LPCTSTR lpszSub, int nStart ) const;

FindOneOf

public int FindOneOf( LPCTSTR lpszCharSet ) const;

Format

public void AFX_CDECL Format( LPCTSTR lpszFormat,... );

Format

public void AFX_CDECL Format( UINT nFormatID,... );

FormatMessage

public void AFX_CDECL FormatMessage( UINT nFormatID,... );

FormatMessage

public void AFX_CDECL FormatMessage( LPCTSTR lpszFormat,... );

FormatV

public void FormatV( LPCTSTR lpszFormat, va_list argList );

FreeData

protected static void FASTCALL FreeData( CStringData* pData );

FreeExtra

public void FreeExtra();

GetAllocLength

public int GetAllocLength() const;

GetAt

public TCHAR GetAt( int nIndex ) const;

GetBuffer

public LPTSTR GetBuffer( int nMinBufLength );

GetBufferSetLength

public LPTSTR GetBufferSetLength( int nNewLength );

GetData

protected CStringData* GetData() const;

GetLength

public int GetLength() const;

Init

protected void Init();

Insert

public int Insert( int nIndex, LPCTSTR pstr );

Insert

public int Insert( int nIndex, TCHAR ch );

IsEmpty

public BOOL IsEmpty() const;

Left

public CString Left( int nCount ) const;

LoadString

public BOOL LoadString( UINT nID );

LockBuffer

public LPTSTR LockBuffer();

LPCTSTR

public operator LPCTSTR() const;

MakeLower

public void MakeLower();

MakeReverse

public void MakeReverse();

MakeUpper

public void MakeUpper();

Mid

public CString Mid( int nFirst, int nCount ) const;

Mid

public CString Mid( int nFirst ) const;

OemToAnsi

public void OemToAnsi();

operator+=

public const CString& operator+=( TCHAR ch );

operator+=

public const CString& operator+=( const CString& string );

operator+=

public const CString& operator+=( LPCTSTR lpsz );

operator=

public const CString& operator=( LPCSTR lpsz );

operator=

public const CString& operator=( const CString& stringSrc );

operator=

public const CString& operator=( LPCWSTR lpsz );

operator=

public const CString& operator=( TCHAR ch );

operator=

public const CString& operator=( const unsigned char* psz );

operator[]

public TCHAR operator[]( int nIndex ) const;

Release

protected void Release();

Release

protected static void PASCAL Release( CStringData* pData );

ReleaseBuffer

public void ReleaseBuffer( int nNewLength =-1 );

Remove

public int Remove( TCHAR chRemove );

Replace

public int Replace( LPCTSTR lpszOld, LPCTSTR lpszNew );

Replace

public int Replace( TCHAR chOld, TCHAR chNew );

ReverseFind

public int ReverseFind( TCHAR ch ) const;

Right

public CString Right( int nCount ) const;

SafeStrlen

protected static int PASCAL SafeStrlen( LPCTSTR lpsz );

SetAt

public void SetAt( int nIndex, TCHAR ch );

SetSysString

public BSTR SetSysString( BSTR* pbstr ) const;

SpanExcluding

public CString SpanExcluding( LPCTSTR lpszCharSet ) const;

SpanIncluding

public CString SpanIncluding( LPCTSTR lpszCharSet ) const;

TrimLeft

public void TrimLeft();

TrimLeft

public void TrimLeft( LPCTSTR lpszTargets );

TrimLeft

public void TrimLeft( TCHAR chTarget );

TrimRight

public void TrimRight( LPCTSTR lpszTargets );

TrimRight

public void TrimRight( TCHAR chTarget );

TrimRight

public void TrimRight();

UnlockBuffer

public void UnlockBuffer();

 Overview   Project   Class   Tree   Index 
MFC Class Library
CppDoc v2.3.1
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD