Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 lines
1.0 KiB

  1. ////////////////////////////////////////////////////////////////////////////////////
  2. //
  3. // File: fileio.h
  4. //
  5. // History: 06-Apr-01 markder Created.
  6. //
  7. // Desc: This file contains classes to encapsulate MBCS and UNICODE files.
  8. //
  9. ////////////////////////////////////////////////////////////////////////////////////
  10. #ifndef __FILEIO_H__
  11. #define __FILEIO_H__
  12. class CTextFile : public CFile
  13. {
  14. public:
  15. CTextFile( LPCTSTR lpszFileName, UINT nOpenFlags );
  16. virtual void WriteString(LPCTSTR lpsz) = 0;
  17. };
  18. class CANSITextFile : public CTextFile
  19. {
  20. private:
  21. UINT m_dwCodePage;
  22. public:
  23. CANSITextFile(LPCTSTR lpszFileName, UINT dwCodePage, UINT nOpenFlags);
  24. virtual void WriteString(LPCTSTR lpsz);
  25. };
  26. class CUTF8TextFile : public CTextFile
  27. {
  28. public:
  29. CUTF8TextFile(LPCTSTR lpszFileName, UINT nOpenFlags);
  30. virtual void WriteString(LPCTSTR lpsz);
  31. };
  32. class CUTF16TextFile : public CTextFile
  33. {
  34. public:
  35. CUTF16TextFile(LPCTSTR lpszFileName, UINT nOpenFlags);
  36. virtual void WriteString(LPCTSTR lpsz);
  37. };
  38. #endif // __FILEIO_H__