home *** CD-ROM | disk | FTP | other *** search
/ Using Visual Basic 5 (Platinum Edition) / vb5.iso / ACTIVEX / SRDVID / DATA.1 / castring.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-07-10  |  1.2 KB  |  43 lines

  1. /////////////////////////////////////////////////////////////////////////////
  2. //
  3. // CAnyString.h : Interface of the CAnyString class
  4. //
  5. /////////////////////////////////////////////////////////////////////////////
  6. //
  7. //  (C) Copyright Black Diamond Consulting, Inc 1996. All rights reserved.
  8. //
  9. //    You have a royalty-free right to use, modify, reproduce and 
  10. //    distribute the Sample Files (and/or any modified version) in 
  11. //    any way you find useful, provided that you agree that Black 
  12. //    Diamond Consulting has no warranty obligations or liability
  13. //    for any Sample Application Files which are modified. 
  14. //
  15. //    Revision History:
  16. //
  17. /////////////////////////////////////////////////////////////////////////////
  18.  
  19. #define __CWSTRING_H__
  20.  
  21. class CAnyString : public CObject
  22. {
  23. protected:
  24.     WCHAR*    m_pwchar;
  25.     char*    m_pchar;
  26.  
  27. public:
  28.     CAnyString();
  29.     CAnyString( const WCHAR* pwchar );
  30.     CAnyString( const char* pchar );
  31.     ~CAnyString();
  32.  
  33.     const CAnyString& operator=( const WCHAR* pwchar );
  34.     const CAnyString& operator=( const char* pchar );
  35.  
  36.     operator WCHAR*() const    { return m_pwchar; }
  37.     operator char*() const    { return m_pchar; }
  38.  
  39. protected:
  40.     void Reset();
  41.  
  42. };
  43.