You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by db...@apache.org on 2002/01/22 19:50:55 UTC

cvs commit: xml-xalan/c/Tests/Transformer Transformer.dsp

dbertoni    02/01/22 10:50:55

  Modified:    c/Tests/Compare compare.dsp
               c/Tests/Dom2Dom Dom2Dom.dsp dom2dom.cpp
               c/Tests/Errortests Errortests.cpp Errortests.dsp
               c/Tests/Extensions extensions.dsp
               c/Tests/InputSource inputsource.dsp
               c/Tests/Memory Memory.dsp Stressmem.cpp
               c/Tests/Params Params.dsp
               c/Tests/PerfT perft.cpp
               c/Tests/Performance perf.cpp perf.dsp
               c/Tests/Transformer Transformer.dsp
  Log:
  Major clean-up.
  
  Revision  Changes    Path
  1.3       +3 -3      xml-xalan/c/Tests/Compare/compare.dsp
  
  Index: compare.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Compare/compare.dsp,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- compare.dsp	27 Aug 2001 15:08:23 -0000	1.2
  +++ compare.dsp	22 Jan 2002 18:50:54 -0000	1.3
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.2       +5 -5      xml-xalan/c/Tests/Dom2Dom/Dom2Dom.dsp
  
  Index: Dom2Dom.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Dom2Dom/Dom2Dom.dsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Dom2Dom.dsp	12 Jun 2001 19:43:08 -0000	1.1
  +++ Dom2Dom.dsp	22 Jan 2002 18:50:54 -0000	1.2
  @@ -8,12 +8,12 @@
   !MESSAGE This is not a valid makefile. To build this project using NMAKE,
   !MESSAGE use the Export Makefile command and run
   !MESSAGE 
  -!MESSAGE NMAKE /f "dom2dom.mak".
  +!MESSAGE NMAKE /f "Dom2Dom.mak".
   !MESSAGE 
   !MESSAGE You can specify a configuration when running NMAKE
   !MESSAGE by defining the macro CFG on the command line. For example:
   !MESSAGE 
  -!MESSAGE NMAKE /f "dom2dom.mak" CFG="dom2dom - Win32 Debug"
  +!MESSAGE NMAKE /f "Dom2Dom.mak" CFG="dom2dom - Win32 Debug"
   !MESSAGE 
   !MESSAGE Possible choices for configuration are:
   !MESSAGE 
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.4       +29 -22    xml-xalan/c/Tests/Dom2Dom/dom2dom.cpp
  
  Index: dom2dom.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Dom2Dom/dom2dom.cpp,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- dom2dom.cpp	6 Nov 2001 15:12:39 -0000	1.3
  +++ dom2dom.cpp	22 Jan 2002 18:50:54 -0000	1.4
  @@ -69,9 +69,9 @@
   #endif
   
   #include <sax/SAXException.hpp>
  -
   #include <util/PlatformUtils.hpp>
   
  +
   #include <PlatformSupport/DOMStringHelper.hpp>
   #include <PlatformSupport/XalanOutputStreamPrintWriter.hpp>
   #include <PlatformSupport/XalanFileOutputStream.hpp>
  @@ -86,12 +86,10 @@
   #include <XalanTransformer/XalanTransformer.hpp>
   #include <XalanTransformer/XalanCompiledStylesheetDefault.hpp>
   
  -#include <XMLFileReporter.hpp>
  -#include <FileUtility.hpp>
  -#include <HarnessInit.hpp>
  +#include <Harness/XMLFileReporter.hpp>
  +#include <Harness/FileUtility.hpp>
  +#include <Harness/HarnessInit.hpp>
   
  -//#include <parsers/DOMParser.hpp>
  -//#include <dom/DOM_Node.hpp>
   
   #include <XercesParserLiaison/XercesDOMSupport.hpp>
   #include <XercesParserLiaison/XercesParserLiaison.hpp>
  @@ -117,12 +115,15 @@
   		 << endl;
   }
   
  +
  +
   bool
  -getParams(int argc, 
  -		  const char*	argv[],
  -		  FileUtility& f,
  -		  XalanDOMString& basedir,
  -		  XalanDOMString& outdir)
  +getParams(
  +			int					argc, 
  +			const char*			argv[],
  +			FileUtility&		f,
  +			XalanDOMString&		basedir,
  +			XalanDOMString&		outdir)
   {
   	bool fSuccess = true;	// Used to continue argument loop
   	bool fSetOut = true;	// Set default output directory
  @@ -135,10 +136,10 @@
   	}
   	else
   	{
  -		if (f.checkDir(pathSep + XalanDOMString(argv[1])))
  +		if (f.checkDir(FileUtility::s_pathSep + XalanDOMString(argv[1])))
   		{
   			assign(basedir, XalanDOMString(argv[1]));
  -			insert(basedir, 0, pathSep);
  +			insert(basedir, 0, FileUtility::s_pathSep);
   		}
   		else
   		{
  @@ -179,17 +180,20 @@
   	// Do we need to set the default output directory??
   	if (fSetOut)
   	{
  -		unsigned int ii = lastIndexOf(basedir,charAt(pathSep,0));
  +		unsigned int ii = lastIndexOf(basedir,charAt(FileUtility::s_pathSep,0));
   		outdir = substring(basedir, 0, ii+1);
   		append(outdir,XalanDOMString("Dom2Dom-RESULTS\\"));
   		f.checkAndCreateDir(outdir);
   	}
   	
   	// Add the path seperator to the end of the base directory
  -	append(basedir, pathSep);
  +	append(basedir, FileUtility::s_pathSep);
  +
   	return fSuccess;
   }
   
  +
  +
   FormatterListener* 
   getXMLFormatter(bool					shouldWriteXMLHeader,
   				bool					stripCData,
  @@ -240,6 +244,8 @@
   		return formatter;
   }
   
  +
  +
   int
   main(
   		  int			argc,
  @@ -252,15 +258,14 @@
   	_CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR);
   #endif
   
  +	HarnessInit		xmlPlatformUtils;
  +
   	FileUtility		f;
   
   	XalanDOMString  category;	// Test all of base dir by default
   	XalanDOMString  baseDir;	
   	XalanDOMString  outputRoot;
   	
  -	const XalanDOMString mimeEncoding(XALAN_STATIC_UCODE_STRING("UTF-8"));
  -	const XalanDOMString encoding(XALAN_STATIC_UCODE_STRING("UTF-8"));
  -
   	if (getParams(argc, argv, f, baseDir, outputRoot) == true)
   	{
   
  @@ -273,7 +278,7 @@
   		// Defined basic constants for file manipulation 
   
   		const XalanDOMString  resultFilePrefix("dom2dom");
  -		const XalanDOMString  resultsFile(outputRoot + resultFilePrefix + UniqRunid + XMLSuffix);
  +		const XalanDOMString  resultsFile(outputRoot + resultFilePrefix + UniqRunid + FileUtility::s_xmlSuffix);
   		
   		XMLFileReporter	logFile(resultsFile);
   		logFile.logTestFileInit("Dom2Dom Testing: Treating all inputs and outputs as DOM's. ");
  @@ -281,7 +286,6 @@
   		try
   		{
   			// Call the static initializers...
  -			HarnessInit xmlPlatformUtils;
   			XalanTransformer::initialize();
   
   			{
  @@ -305,9 +309,9 @@
   					cout << files[i] << endl;
   
   					// Set up the input/output files.
  -					const XalanDOMString  theXSLFile= baseDir + xMan + pathSep + files[i];
  +					const XalanDOMString  theXSLFile= baseDir + xMan + FileUtility::s_pathSep + files[i];
   					const XalanDOMString  theXMLFile = f.generateFileName(theXSLFile,"xml");
  -					const XalanDOMString  theOutput =  outputRoot + xMan + pathSep + files[i]; 
  +					const XalanDOMString  theOutput =  outputRoot + xMan + FileUtility::s_pathSep + files[i]; 
   					const XalanDOMString  theOutputFile = f.generateFileName(theOutput, "out");
   
   					// Use a Xerces Dom document to create the XSLTResultTarget. 
  @@ -341,6 +345,9 @@
   						}
   						else
   						{
  +							const XalanDOMString	mimeEncoding(XALAN_STATIC_UCODE_STRING("UTF-8"));
  +							const XalanDOMString	encoding(XALAN_STATIC_UCODE_STRING("UTF-8"));
  +
   							XalanFileOutputStream myOutput(theOutputFile);
   							XalanOutputStreamPrintWriter myResultWriter(myOutput);
   							FormatterListener* theFormatter = getXMLFormatter(true,true,true,false,
  
  
  
  1.9       +55 -33    xml-xalan/c/Tests/Errortests/Errortests.cpp
  
  Index: Errortests.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Errortests/Errortests.cpp,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- Errortests.cpp	20 Dec 2001 16:34:59 -0000	1.8
  +++ Errortests.cpp	22 Jan 2002 18:50:54 -0000	1.9
  @@ -55,39 +55,53 @@
    * <http://www.apache.org/>.
    */
   
  +#include <cstdio>
  +
  +#if defined(XALAN_OLD_STREAM_HEADERS)
  +#include <iostream.h>
  +#include <strstream.h>
  +#else
   #include <iostream>
   #include <strstream>
  -#include <stdio.h>
  -#include <direct.h>
  +#endif
   
   #if !defined(XALAN_NO_NAMESPACES)
   	using std::cerr;
   	using std::cout;
  -	using std::cin;
  +//	using std::cin;
   	using std::endl;
  -	using std::ifstream;
  -	using std::ios_base;
  -	using std::ostrstream;
  -	using std::string;
   #endif
   
  -// XERCES HEADERS...
  -//	Are included by HarnessInit.hpp
  +
   
   // XALAN HEADERS...
  -//	Are included by FileUtility.hpp
  +#include <PlatformSupport/DOMStringHelper.hpp>
  +
  +
  +
  +#include <XalanSourceTree/FormatterToSourceTree.hpp>
  +#include <XalanSourceTree/XalanSourceTreeDOMSupport.hpp>
  +#include <XalanSourceTree/XalanSourceTreeParserLiaison.hpp>
  +
  +
  +
  +#include <XalanTransformer/XalanTransformer.hpp>
  +
  +
  +
  +#include <Harness/XMLFileReporter.hpp>
  +#include <Harness/FileUtility.hpp>
  +#include <Harness/HarnessInit.hpp>
  +
   
  -// HARNESS HEADERS...
  -#include <XMLFileReporter.hpp>
  -#include <FileUtility.hpp>
  -#include <HarnessInit.hpp>
   
   #if defined(XALAN_NO_NAMESPACES)
  -	typedef map<XalanDOMString, XalanDOMString, less<XalanDOMString> >	Hashtable;
  +typedef map<XalanDOMString, XalanDOMString, less<XalanDOMString> >	Hashtable;
   #else
  -	typedef std::map<XalanDOMString, XalanDOMString>  Hashtable;
  +typedef std::map<XalanDOMString, XalanDOMString>  Hashtable;
   #endif
   
  +
   // This is here for memory leak testing. 
   #if !defined(NDEBUG) && defined(_MSC_VER)
   #include <crtdbg.h>
  @@ -98,12 +112,12 @@
   	0
   };
   
  -FileUtility		h;
  +
   
   void
  -setHelp()
  +setHelp(FileUtility&	h)
   {
  -	h.args.help << endl
  +	h.args.getHelpStream() << endl
   		 << "errortests dir [-sub -out]"
   		 << endl
   		 << endl
  @@ -115,10 +129,12 @@
   		 << endl;
   }
   
  +
  +
   inline bool
   checkForExclusion(XalanDOMString currentFile)
   {
  -	for (int i=0; excludeStylesheets[i] != 0; i++)
  +	for (int i = 0; excludeStylesheets[i] != 0; i++)
   	{	
   		if (equals(currentFile, XalanDOMString(excludeStylesheets[i])))
   		{
  @@ -129,6 +145,8 @@
   	return false;
   }
   
  +
  +
   int
   main(int			argc,
   	 const char*	argv[])
  @@ -140,16 +158,19 @@
   #endif
   
   	HarnessInit xmlPlatformUtils;
  -	XalanTransformer::initialize();
   
  +	FileUtility		h;
  +
  +	// Set the program help string,  then get the command line parameters.
  +	//
  +	setHelp(h);
  +
  +	bool	setGold = false;
  +
  +	if (h.getParams(argc, argv, "ERR-RESULTS", setGold) == true)
   	{
  -		int theResult;	
  -		bool setGold = false;
  +		XalanTransformer::initialize();
   
  -		// Set the program help string,  then get the command line parameters.
  -		//
  -		setHelp();
  -		if (h.getParams(argc, argv, "ERR-RESULTS", setGold) == true)
   		{
   			//
   			// Call the static initializers for xerces and xalan, and create a transformer
  @@ -167,7 +188,7 @@
   
   			// Defined basic constants for file manipulation and open results file
   			const XalanDOMString  resultFilePrefix("cpperr");
  -			const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + XMLSuffix);
  +			const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + FileUtility::s_xmlSuffix);
   
   
   			XMLFileReporter	logFile(resultsFile);
  @@ -212,12 +233,12 @@
   					if (checkForExclusion(currentFile))
   						continue;
   
  -					const XalanDOMString  theXSLFile= h.args.base + currentDir + pathSep + currentFile;
  +					const XalanDOMString  theXSLFile= h.args.base + currentDir + FileUtility::s_pathSep + currentFile;
   					const XalanDOMString  theXMLFile = h.generateFileName(theXSLFile,"xml");
  -					XalanDOMString  theGoldFile = h.args.gold + currentDir + pathSep + currentFile;
  +					XalanDOMString  theGoldFile = h.args.gold + currentDir + FileUtility::s_pathSep + currentFile;
   					theGoldFile = h.generateFileName(theGoldFile, "out");
   
  -					const XalanDOMString  outbase =  h.args.output + currentDir + pathSep + currentFile; 
  +					const XalanDOMString  outbase =  h.args.output + currentDir + FileUtility::s_pathSep + currentFile; 
   					const XalanDOMString  theOutputFile = h.generateFileName(outbase, "out");
   
   					const XSLTInputSource	xslInputSource(c_wstr(theXSLFile));
  @@ -259,9 +280,10 @@
   
   					// Perform One transform using parsed stylesheet and parsed xml source, report results...
   					// 
  -					theResult = 0;
   					cout << "TRANSFORMING: " << currentFile << endl;
  -					theResult = xalan.transform(*parsedSource, compiledSS, resultFile);
  +
  +					const int	theResult = xalan.transform(*parsedSource, compiledSS, resultFile);
  +
   					if (theResult != 0)
   					{
   						cout << "FAILED to transform stylesheet for " << currentFile << endl;
  
  
  
  1.2       +3 -3      xml-xalan/c/Tests/Errortests/Errortests.dsp
  
  Index: Errortests.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Errortests/Errortests.dsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Errortests.dsp	14 Sep 2001 21:03:46 -0000	1.1
  +++ Errortests.dsp	22 Jan 2002 18:50:54 -0000	1.2
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.2       +3 -3      xml-xalan/c/Tests/Extensions/extensions.dsp
  
  Index: extensions.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Extensions/extensions.dsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- extensions.dsp	17 Jul 2001 16:42:47 -0000	1.1
  +++ extensions.dsp	22 Jan 2002 18:50:54 -0000	1.2
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.2       +3 -3      xml-xalan/c/Tests/InputSource/inputsource.dsp
  
  Index: inputsource.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/InputSource/inputsource.dsp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- inputsource.dsp	20 Jun 2001 21:06:00 -0000	1.1
  +++ inputsource.dsp	22 Jan 2002 18:50:54 -0000	1.2
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.10      +3 -3      xml-xalan/c/Tests/Memory/Memory.dsp
  
  Index: Memory.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Memory/Memory.dsp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- Memory.dsp	7 Jun 2001 16:28:52 -0000	1.9
  +++ Memory.dsp	22 Jan 2002 18:50:54 -0000	1.10
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /MDd /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.19      +64 -47    xml-xalan/c/Tests/Memory/Stressmem.cpp
  
  Index: Stressmem.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Memory/Stressmem.cpp,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- Stressmem.cpp	13 Dec 2001 20:25:23 -0000	1.18
  +++ Stressmem.cpp	22 Jan 2002 18:50:54 -0000	1.19
  @@ -57,7 +57,7 @@
   #include <iostream>
   #include <strstream>
   #include <stdio.h>
  -#include <direct.h>
  +//#include <direct.h>
   
   // This is here for memory leak testing. 
   #if !defined(NDEBUG) && defined(_MSC_VER)
  @@ -68,14 +68,14 @@
   
   #include <util/PlatformUtils.hpp>
   
  -#include <XSLT/XSLTInputSource.hpp>
  -#include <XSLT/XSLTResultTarget.hpp>
  +//#include <XSLT/XSLTInputSource.hpp>
  +//#include <XSLT/XSLTResultTarget.hpp>
   
   #include <XalanTransformer/XalanTransformer.hpp>
   
  -#include <XMLFileReporter.hpp>
  -#include <FileUtility.hpp>
  -#include <HarnessInit.hpp>
  +#include <Harness/XMLFileReporter.hpp>
  +#include <Harness/FileUtility.hpp>
  +#include <Harness/HarnessInit.hpp>
   
   
   
  @@ -85,8 +85,8 @@
   	using std::endl;
   #endif
   
  -FileUtility			h;
  -	
  +
  +
   static const char* const	excludeStylesheets[] =
   {
   //	"impincl16.xml",
  @@ -94,8 +94,9 @@
   };
   
   
  +
   inline bool
  -checkForExclusion(XalanDOMString currentFile)
  +checkForExclusion(const XalanDOMString&		currentFile)
   {
   	for (int i = 0; excludeStylesheets[i] != 0; ++i)
   	{	
  @@ -108,10 +109,12 @@
   	return false;
   }
   
  +
  +
   void
  -setHelp()
  +setHelp(FileUtility&	h)
   {
  -	h.args.help << endl
  +	h.args.getHelpStream() << endl
   		 << "stressmem dirname [-out -sub]"
   		 << endl
   		 << endl
  @@ -123,6 +126,8 @@
   		 << endl;
   }
   
  +
  +
   int
   main(int			argc,
   	 const char*	argv[])
  @@ -135,32 +140,40 @@
   
   	// Set the program help string,  then get the command line parameters.
   	//
  -	setHelp();
  -	bool setGold = false;
  -	bool foundDir = false;
  -
  -	if (h.getParams(argc, argv, "MEM-RESULTS", setGold) == true)
  +	try
   	{
  -		// Get the list of Directories that are below perf
  -		const FileNameVectorType	dirs = h.getDirectoryNames(h.args.base);
  +		HarnessInit		xmlPlatformUtils;
   
  -		// Generate Unique Run id. (Only used to name the result logfile.)
  -		const XalanDOMString UniqRunid = h.generateUniqRunid();
  +		FileUtility		h;
   
  -		// Defined basic constants for file manipulation 
  +		setHelp(h);
   
  -		const XalanDOMString  resultFilePrefix(XalanDOMString("cpp-mem"));
  -		const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + XMLSuffix);
  -		
  -		XMLFileReporter	logFile(resultsFile);
  -		logFile.logTestFileInit("Memory Testing - Memory leaks detected during ConformanceTests. ");
  +		bool setGold = false;
   
  -		try
  +		if (h.getParams(argc, argv, "MEM-RESULTS", setGold) == true)
   		{
  +			// Get the list of Directories that are below perf
  +			const FileNameVectorType	dirs = h.getDirectoryNames(h.args.base);
  +
  +			// Generate Unique Run id. (Only used to name the result logfile.)
  +			const XalanDOMString		UniqRunid = h.generateUniqRunid();
  +
  +			// Defined basic constants for file manipulation 
  +
  +			const XalanDOMString  resultFilePrefix(XalanDOMString("cpp-mem"));
  +			const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + FileUtility::s_xmlSuffix);
  +
  +			XMLFileReporter		logFile(resultsFile);
  +
  +			logFile.logTestFileInit("Memory Testing - Memory leaks detected during ConformanceTests. ");
  +
   			// Call the static initializers...
  -			HarnessInit xmlPlatformUtils;
   			XalanTransformer::initialize();
  +
  +			try
   			{
  +				bool foundDir = false;
  +
   				XalanTransformer		transformEngine;
   
   				for(FileNameVectorType::size_type	j = 0; j < dirs.size(); ++j)
  @@ -171,7 +184,7 @@
   					{
   						continue;
   					}					
  -					
  +						
   					// Check that output directory is there.
   					const XalanDOMString  theOutputDir = h.args.output + dirs[j];
   					h.checkAndCreateDir(theOutputDir);
  @@ -187,20 +200,19 @@
   							logFile.logTestCaseInit(files[i]);
   							cout << files[i] << endl;
   
  -
  -							const XalanDOMString  theXSLFile= h.args.base + dirs[j] + pathSep + files[i];
  +							const XalanDOMString  theXSLFile = h.args.base + dirs[j] + FileUtility::s_pathSep + files[i];
   							const XalanDOMString  theXMLFile = h.generateFileName(theXSLFile,"xml");
  -							const XalanDOMString  theOutput =  h.args.output + dirs[j] + pathSep + files[i]; 
  +							const XalanDOMString  theOutput =  h.args.output + dirs[j] + FileUtility::s_pathSep + files[i]; 
   							const XalanDOMString  theOutputFile = h.generateFileName(theOutput, "out");
   
   							// Do a total end to end transform with no pre parsing of either xsl or xml files.
  -							XSLTResultTarget		theResultTarget(theOutputFile);
  +							const XSLTResultTarget	theResultTarget(theOutputFile);
   
   							const XSLTInputSource	xslInputSource(c_wstr(theXSLFile));
   							const XSLTInputSource	xmlInputSource(c_wstr(theXMLFile));
   
  -							int	theResult =
  -								transformEngine.transform(xmlInputSource, xslInputSource, theResultTarget);
  +							const int	theResult =
  +									transformEngine.transform(xmlInputSource, xslInputSource, theResultTarget);
   
   							if(theResult != 0)
   							{
  @@ -214,22 +226,27 @@
   						}
   					}
   				}
  -			}
   
  -			// Check to see if -sub cmd-line directory was processed correctly.
  -			if (!foundDir)
  +				// Check to see if -sub cmd-line directory was processed correctly.
  +				if (!foundDir)
  +				{
  +					cout << "Specified test directory: \"" << c_str(TranscodeToLocalCodePage(h.args.sub)) << "\" not found" << endl;
  +				}
  +
  +				logFile.logTestFileClose("Memory Testing: ", "Done");
  +				logFile.close();
  +			}
  +			catch(...)
   			{
  -				cout << "Specified test directory: \"" << c_str(TranscodeToLocalCodePage(h.args.sub)) << "\" not found" << endl;
  +				cerr << "Exception caught!!!" << endl << endl;
   			}
  -			XalanTransformer::terminate();
  -			logFile.logTestFileClose("Memory Testing: ", "Done");
  -			logFile.close();
  -
  -		}
  -		catch(...)
  -		{
  -			cerr << "Exception caught!!!" << endl << endl;
   		}
  +
  +		XalanTransformer::terminate();
  +	}
  +	catch(...)
  +	{
  +		cerr << "Initialization failed!!!" << endl << endl;
   	}
   
   	return 0;
  
  
  
  1.3       +3 -3      xml-xalan/c/Tests/Params/Params.dsp
  
  Index: Params.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Params/Params.dsp,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Params.dsp	7 Jun 2001 16:28:56 -0000	1.2
  +++ Params.dsp	22 Jan 2002 18:50:54 -0000	1.3
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /W4 /GR /GX /Od /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "_WINDOWS" /D "_CONSOLE" /D "WIN32" /D "_DEBUG" /D "_MBCS" /YX /FD /GZ /c
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
   BSC32=bscmake.exe
  @@ -93,7 +93,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.12      +1 -2      xml-xalan/c/Tests/PerfT/perft.cpp
  
  Index: perft.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/PerfT/perft.cpp,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- perft.cpp	13 Dec 2001 20:26:11 -0000	1.11
  +++ perft.cpp	22 Jan 2002 18:50:55 -0000	1.12
  @@ -68,7 +68,6 @@
   	using std::ifstream;
   	using std::ios_base;
   	using std::ostrstream;
  -	using std::string;
   #endif
   
   // XALAN HEADERS...
  @@ -137,7 +136,7 @@
   void
   setHelp()
   {
  -	h.args.help << endl
  +	h.args.getHelpStream() << endl
   		 << "Perft dir [-out -sub -i -iter]"
   		 << endl
   		 << endl
  
  
  
  1.29      +41 -30    xml-xalan/c/Tests/Performance/perf.cpp
  
  Index: perf.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Performance/perf.cpp,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -r1.28 -r1.29
  --- perf.cpp	13 Dec 2001 20:25:48 -0000	1.28
  +++ perf.cpp	22 Jan 2002 18:50:55 -0000	1.29
  @@ -89,19 +89,15 @@
   #include <XSLT/XSLTProcessorEnvSupportDefault.hpp>
   #include <XSLT/XSLTResultTarget.hpp>  
   
  -#include <XMLFileReporter.hpp>
  -#include <FileUtility.hpp>
  -#include <HarnessInit.hpp>
  +#include <Harness/XMLFileReporter.hpp>
  +#include <Harness/FileUtility.hpp>
  +#include <Harness/HarnessInit.hpp>
  +
   
   #if !defined(XALAN_NO_NAMESPACES)
   	using std::cerr;
   	using std::cout;
  -	using std::cin;
   	using std::endl;
  -	using std::ifstream;
  -	using std::ios_base;
  -	using std::ostrstream;
  -	using std::string;
   #endif
   
   
  @@ -112,10 +108,8 @@
   #endif
   
   
  -FileUtility h;
  -
   
  -const char* const 	excludeStylesheets[] =
  +	const char* const 	excludeStylesheets[] =
   {
   	"large-evans_large.xsl",
   	0
  @@ -123,7 +117,7 @@
   
   
   inline bool
  -checkForExclusion(XalanDOMString currentFile)
  +checkForExclusion(const XalanDOMString&		currentFile)
   {
   
   		for (int i=0; excludeStylesheets[i] != 0; i++)
  @@ -170,6 +164,7 @@
   }
   
   
  +
   inline double
   calculateAvgTime(
   			clock_t		accTime,
  @@ -180,6 +175,8 @@
   	return double(accTime) / theIterationCount;
   }
   
  +
  +
   inline double
   calculateAverageElapsedTime( 
   			clock_t			theStartTime,
  @@ -191,6 +188,8 @@
   	return calculateElapsedTime(theStartTime, theEndTime) / theIterationCount;
   }
   
  +
  +
   inline clock_t
   transformWUnparsedSource(const XalanDOMString&	theFileName,
   				 XSLTProcessor&			theProcessor,
  @@ -198,36 +197,43 @@
   				 XSLTResultTarget&	theResults,
   				 StylesheetExecutionContextDefault&  theExecutionContext)
   {
  -	const XSLTInputSource	csSourceXML(c_wstr(theFileName));	// Creates source document
  +	const XSLTInputSource	csSourceXML(c_wstr(theFileName));
  +
   	theProcessor.setStylesheetRoot(theStylesheetRoot);
   
   	const clock_t startTime = clock();
  +
   	theProcessor.process(csSourceXML, theResults, theExecutionContext);
  -	const clock_t endTime = clock();
   
  -	return endTime - startTime;
  +	return clock() - startTime;
   
   }
   
  +
  +
   inline clock_t
  -transformWParsedSource(XalanNode*		theParsedSource,
  -				 XSLTProcessor&			theProcessor,
  -				 const StylesheetRoot*	theStylesheetRoot,
  -				 XSLTResultTarget&		theResults,
  -				 StylesheetExecutionContextDefault&  theExecutionContext)
  +transformWParsedSource(
  +			XalanNode*							theParsedSource,
  +			XSLTProcessor&						theProcessor,
  +			const StylesheetRoot*				theStylesheetRoot,
  +			XSLTResultTarget&					theResults,
  +			StylesheetExecutionContextDefault&	theExecutionContext)
   {
   	// Put the parsed document into an XSLTInputSource, 
   	// and set stylesheet root in the processor
   	const XSLTInputSource	csSourceDocument(theParsedSource);
  +
   	theProcessor.setStylesheetRoot(theStylesheetRoot);
   
   	const clock_t startTime = clock();
  +
   	theProcessor.process(csSourceDocument, theResults, theExecutionContext);
  -	const clock_t endTime = clock();
   	
  -	return endTime - startTime;
  -
  +	return clock() - startTime;
   }
  +
  +
  +
   inline long
   eTOeTransform(const XSLTInputSource&		inputSource, 
   	        const XSLTInputSource&			stylesheetSource,
  @@ -248,10 +254,11 @@
   }
   
   
  +
   void
  -setHelp()
  +setHelp(FileUtility&	h)
   {
  -	h.args.help << endl
  +	h.args.getHelpStream() << endl
   		 << "Perf dir [-out -sub -i -iter]"
   		 << endl
   		 << endl
  @@ -277,14 +284,19 @@
   	_CrtSetReportFile(_CRT_WARN, _CRTDBG_FILE_STDERR);
   #endif
   
  +
   	const XalanDOMString	processorType(XALAN_STATIC_UCODE_STRING("XalanC"));
   	long iterCount;			// Default number of iterations
   	bool skip = true;		// Default will skip long tests
   	bool setGold = false;
   
  +	HarnessInit		xmlPlatformUtils;
  +
  +	FileUtility		h;
  +
   	// Set the program help string,  then get the command line parameters.
   	//
  -	setHelp();
  +	setHelp(h);
   
   	if (h.getParams(argc, argv, "PERF-RESULTS", setGold) == true)
   	{
  @@ -292,7 +304,7 @@
   		// Generate Unique Run id and processor info
   		const XalanDOMString UniqRunid = h.generateUniqRunid();
   		const XalanDOMString  resultFilePrefix(XalanDOMString("cpp"));
  -		const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + XMLSuffix);
  +		const XalanDOMString  resultsFile(h.args.output + resultFilePrefix + UniqRunid + FileUtility::s_xmlSuffix);
   
   		XMLFileReporter	logFile(resultsFile);
   		logFile.logTestFileInit("Performance Testing - Reports performance times for single transform, and average for multiple transforms using compiled stylesheet");
  @@ -303,7 +315,6 @@
   			// Having xmlplatformutils in it's own class like this means that if there are
   			// exceptions then terminate() is sure to run because it will automatically get
   			// cleaned up when this instance goes out of scope.
  -			HarnessInit xmlPlatformUtils;
   			bool foundDir = false;	// Flag indicates directory found. Used in conjunction with -sub cmd-line arg.
   			{
   				XSLTInit	theInit;  
  @@ -342,10 +353,10 @@
   								continue;
   						}
   
  -						const XalanDOMString  theXSLFile= h.args.base + dirs[j] + pathSep + files[i];
  +						const XalanDOMString  theXSLFile= h.args.base + dirs[j] + FileUtility::s_pathSep + files[i];
   						const XalanDOMString  theXMLFile = h.generateFileName(theXSLFile,"xml");
   
  -						const XalanDOMString  theOutput =  h.args.output + dirs[j] + pathSep + files[i]; 
  +						const XalanDOMString  theOutput =  h.args.output + dirs[j] + FileUtility::s_pathSep + files[i]; 
   						const XalanDOMString  theOutputFile = h.generateFileName(theOutput, "out");
   
   
  
  
  
  1.11      +3 -3      xml-xalan/c/Tests/Performance/perf.dsp
  
  Index: perf.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Performance/perf.dsp,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- perf.dsp	7 Jun 2001 16:29:02 -0000	1.10
  +++ perf.dsp	22 Jan 2002 18:50:55 -0000	1.11
  @@ -43,7 +43,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
  -# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  @@ -68,7 +68,7 @@
   # PROP Ignore_Export_Lib 0
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  -# ADD CPP /nologo /MDd /W4 /Gm /GR /GX /Zi /Od /Gf /Gy /I "..\..\src\\" /I "..\..\..\..\xml-xerces\c\src\\" /I "..\harness\\" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
  +# ADD CPP /nologo /MDd /W4 /Gm /GR /GX /Zi /Od /Gf /Gy /I "..\..\..\..\xml-xerces\c\src\\" /I "..\..\src\\" /I ".." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
   # SUBTRACT CPP /X
   # ADD BASE RSC /l 0x409 /d "_DEBUG"
   # ADD RSC /l 0x409 /d "_DEBUG"
  @@ -96,7 +96,7 @@
   # PROP Target_Dir ""
   # ADD BASE CPP /nologo /MD /W4 /GR /GX /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT BASE CPP /YX
  -# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I "..\harness\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
  +# ADD CPP /nologo /MD /W4 /GR /GX /Zi /O2 /Ob2 /I "..\..\..\..\xml-xerces\c\src" /I "..\..\src\\" /I ".." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
   # SUBTRACT CPP /YX
   # ADD BASE RSC /l 0x409 /d "NDEBUG"
   # ADD RSC /l 0x409 /d "NDEBUG"
  
  
  
  1.3       +1 -1      xml-xalan/c/Tests/Transformer/Transformer.dsp
  
  Index: Transformer.dsp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/Tests/Transformer/Transformer.dsp,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Transformer.dsp	7 Jun 2001 16:29:09 -0000	1.2
  +++ Transformer.dsp	22 Jan 2002 18:50:55 -0000	1.3
  @@ -111,7 +111,7 @@
   # ADD BSC32 /nologo
   LINK32=link.exe
   # ADD BASE LINK32 ..\..\..\..\xml-xerces\c\Build\Win32\VC6\Release\xerces-c_1.lib ..\..\Build\Win32\VC6\Release\*.lib /nologo /stack:0x1f4000 /subsystem:console /pdb:none /machine:I386
  -# ADD LINK32 ..\..\..\..\xml-xerces\c\Build\Win32\VC6\Release\xerces-c_1.lib..\..\Build\Win32\VC6\Release.symbols\*.lib /nologo /stack:0x1f4000 /subsystem:console /pdb:none /debug /machine:I386 /fixed:no
  +# ADD LINK32 ..\..\..\..\xml-xerces\c\Build\Win32\VC6\Release\xerces-c_1.lib ..\..\Build\Win32\VC6\Release.symbols\XalanDOMS.lib ..\..\Build\Win32\VC6\Release.symbols\XSLTS.lib  ..\..\Build\Win32\VC6\Release.symbols\XalanTransformerS.lib /nologo /stack:0x1f4000 /subsystem:console /pdb:none /debug /machine:I386 /fixed:no
   
   !ENDIF 
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org