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.

65 lines
1.2 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1997 - 1997
  6. //
  7. // File: zstrt.cpp
  8. //
  9. //--------------------------------------------------------------------------
  10. //
  11. // ZSTRT.CPP
  12. //
  13. #include <iostream>
  14. #include <fstream>
  15. #include <stdarg.h>
  16. #include <stdio.h>
  17. #include "zstrt.h"
  18. ZSTRT ZSREF::Zsempty;
  19. void STZSTR :: Dump () const
  20. {
  21. STZSTR_BASE::const_iterator mpzi = IterBegin();
  22. STZSTR_BASE::const_iterator mpziend = IterEnd();
  23. for ( UINT i = 0; mpzi != mpziend ; mpzi++, i++ )
  24. {
  25. const ZSTRT & zsr = *mpzi;
  26. cout << "STZSTR #"
  27. << i
  28. << ": ";
  29. (*mpzi).Dump();
  30. cout << "\n";
  31. }
  32. }
  33. void ZSTRT :: Dump () const
  34. {
  35. cout << "("
  36. << CRef()
  37. << ") \""
  38. << Szc()
  39. << "\"";
  40. }
  41. //
  42. // Clone the contents of another string table into this one
  43. //
  44. void STZSTR :: Clone ( const STZSTR & stzstr )
  45. {
  46. assert( & stzstr != this ); // Guarantee source != target
  47. STZSTR_BASE::const_iterator mpzi = stzstr.IterBegin();
  48. STZSTR_BASE::const_iterator mpziend = stzstr.IterEnd();
  49. for ( UINT i = 0; mpzi != mpziend ; mpzi++, i++ )
  50. {
  51. const ZSTRT & zsr = *mpzi;
  52. Zsref( zsr.Szc() );
  53. }
  54. }