You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by ro...@locus.apache.org on 2000/01/18 00:55:29 UTC
cvs commit: xml-xalan/c/src/XercesParserLiaison XercesParserLiaison.cpp
robweir 00/01/17 15:55:29
Modified: c/samples/XPathWrapper XPathWrapper.cpp
c/src/TestXPath TestXPath.cpp
c/src/XPath XPathSupport.hpp XPathSupportDefault.cpp
XPathSupportDefault.hpp
c/src/XSLT Stylesheet.cpp Stylesheet.hpp
StylesheetHandler.cpp StylesheetHandler.hpp
StylesheetRoot.cpp StylesheetRoot.hpp
XSLTEngineImpl.cpp XSLTEngineImpl.hpp
XSLTInputSource.hpp
c/src/XercesParserLiaison XercesParserLiaison.cpp
Log:
get Xalan to compile with recent Xerces changes:
1. URLInputStream and MemBufInputSource have moved
to the framework directory.
2. class URL is now called class XMLURL. Method getURL() is
now getURLText().
Revision Changes Path
1.2 +2 -2 xml-xalan/c/samples/XPathWrapper/XPathWrapper.cpp
Index: XPathWrapper.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/samples/XPathWrapper/XPathWrapper.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XPathWrapper.cpp 1999/12/18 19:47:46 1.1
+++ XPathWrapper.cpp 2000/01/17 23:55:22 1.2
@@ -9,7 +9,7 @@
#include <dom/DOM_Document.hpp>
#include <dom/DOM_Element.hpp>
#include <dom/DOM_NodeList.hpp>
-#include <internal/URLInputSource.hpp>
+#include <framework/URLInputSource.hpp>
#include <PlatformSupport/DirectoryEnumerator.hpp>
#include <PlatformSupport/DOMStringHelper.hpp>
#include <DOMSupport/DOMSupportDefault.hpp>
@@ -24,7 +24,7 @@
#include <XMLSupport/FormatterToXML.hpp>
#include <XercesParserLiaison/XercesParserLiaison.hpp>
-#include <internal/MemBufInputSource.hpp>
+#include <framework/MemBufInputSource.hpp>
#include "XPathWrapper.hpp"
1.2 +1 -1 xml-xalan/c/src/TestXPath/TestXPath.cpp
Index: TestXPath.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/TestXPath/TestXPath.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- TestXPath.cpp 1999/12/18 19:47:52 1.1
+++ TestXPath.cpp 2000/01/17 23:55:23 1.2
@@ -67,7 +67,7 @@
#include <dom/DOM_Document.hpp>
#include <dom/DOM_Element.hpp>
#include <dom/DOM_NodeList.hpp>
-#include <internal/URLInputSource.hpp>
+#include <framework/URLInputSource.hpp>
1.2 +3 -3 xml-xalan/c/src/XPath/XPathSupport.hpp
Index: XPathSupport.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XPath/XPathSupport.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XPathSupport.hpp 1999/12/18 19:47:55 1.1
+++ XPathSupport.hpp 2000/01/17 23:55:23 1.2
@@ -76,7 +76,7 @@
class DocumentHandler;
-class URL;
+class XMLURL;
@@ -160,7 +160,7 @@
*/
virtual DOM_Document
parseXML(
- const URL& url,
+ const XMLURL& url,
DocumentHandler& docHandler,
const DOM_Document& styleDoc) const = 0;
@@ -178,7 +178,7 @@
* @exception XSLProcessorException thrown if the active ProblemListener and XMLParserLiaison decide
* the error condition is severe enough to halt processing.
*/
- virtual URL*
+ virtual XMLURL*
getURLFromString(
const DOMString& urlString,
const DOMString& base) const = 0;
1.3 +2 -2 xml-xalan/c/src/XPath/XPathSupportDefault.cpp
Index: XPathSupportDefault.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XPath/XPathSupportDefault.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- XPathSupportDefault.cpp 2000/01/07 21:25:33 1.2
+++ XPathSupportDefault.cpp 2000/01/17 23:55:23 1.3
@@ -175,7 +175,7 @@
DOM_Document
XPathSupportDefault::parseXML(
- const URL& /* url */,
+ const XMLURL& /* url */,
DocumentHandler& /* docHandler */,
const DOM_Document& /* styleDoc */) const
{
@@ -194,7 +194,7 @@
-URL*
+XMLURL*
XPathSupportDefault::getURLFromString(
const DOMString& /* urlString */,
const DOMString& /* base */) const
1.2 +2 -2 xml-xalan/c/src/XPath/XPathSupportDefault.hpp
Index: XPathSupportDefault.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XPath/XPathSupportDefault.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XPathSupportDefault.hpp 1999/12/18 19:47:55 1.1
+++ XPathSupportDefault.hpp 2000/01/17 23:55:24 1.2
@@ -152,7 +152,7 @@
*/
virtual DOM_Document
parseXML(
- const URL& url,
+ const XMLURL& url,
DocumentHandler& docHandler,
const DOM_Document& styleDoc) const;
@@ -170,7 +170,7 @@
* @exception XSLProcessorException thrown if the active ProblemListener and XMLParserLiaison decide
* the error condition is severe enough to halt processing.
*/
- virtual URL*
+ virtual XMLURL*
getURLFromString(
const DOMString& urlString,
const DOMString& base) const;
1.2 +4 -4 xml-xalan/c/src/XSLT/Stylesheet.cpp
Index: Stylesheet.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/Stylesheet.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Stylesheet.cpp 1999/12/18 19:48:04 1.1
+++ Stylesheet.cpp 2000/01/17 23:55:24 1.2
@@ -119,7 +119,7 @@
// FileNotFoundException, IOException, SAXException
{
// Java: second argument null
- URL* u = m_processor->getURLFromString(m_baseIdent, DOMString());
+ XMLURL* u = m_processor->getURLFromString(m_baseIdent, DOMString());
if (u != 0)
{
@@ -1083,8 +1083,8 @@
{
XSLTEngineImpl::SourceDocumentsMapType sourceDocs =
m_processor->getSourceDocsTable();
- URL* url = m_processor->getURLFromString(m_baseIdent, styleBaseURI);
- sourceDocs.insert(XSLTEngineImpl::SourceDocumentsMapType::value_type(url->getURL(),
+ XMLURL* url = m_processor->getURLFromString(m_baseIdent, styleBaseURI);
+ sourceDocs.insert(XSLTEngineImpl::SourceDocumentsMapType::value_type(url->getURLText(),
DOM_UnimplementedDocument(m_stylesheetRoot)));
// @@ TODO: Include base dirs are lost right now... need to fix this.
@@ -1094,7 +1094,7 @@
for(it = m_imports.begin(); it != m_imports.end(); it++)
{
Stylesheet &stylesheet = (**it);
- stylesheet.addToDocTables(DOMString(url->getURL()));
+ stylesheet.addToDocTables(DOMString(url->getURLText()));
}
}
delete url;
1.2 +2 -2 xml-xalan/c/src/XSLT/Stylesheet.hpp
Index: Stylesheet.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/Stylesheet.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Stylesheet.hpp 1999/12/18 19:48:04 1.1
+++ Stylesheet.hpp 2000/01/17 23:55:25 1.2
@@ -72,7 +72,7 @@
#include <dom/DOM_Node.hpp>
#include <dom/DOMString.hpp>
-#include <util/URL.hpp>
+#include <util/XMLURL.hpp>
#include "KeyTable.hpp"
#include "ElemTemplate.hpp"
@@ -161,7 +161,7 @@
*/
typedef std::vector<Stylesheet*> StylesheetVectorType;
- typedef std::vector<URL> URLStackType;
+ typedef std::vector<XMLURL> URLStackType;
typedef std::vector<NameSpace> NamespaceVectorType;
typedef std::vector<NamespaceVectorType> NamespacesStackType;
1.2 +7 -7 xml-xalan/c/src/XSLT/StylesheetHandler.cpp
Index: StylesheetHandler.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/StylesheetHandler.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- StylesheetHandler.cpp 1999/12/18 19:48:04 1.1
+++ StylesheetHandler.cpp 2000/01/17 23:55:25 1.2
@@ -1044,14 +1044,14 @@
const DOMString href = atts.getValue(i);
- const URL& hrefUrl = *(m_processor.getURLFromString(href, m_stylesheet.getBaseIdentifier()));
+ const XMLURL& hrefUrl = *(m_processor.getURLFromString(href, m_stylesheet.getBaseIdentifier()));
StylesheetRoot::ImportStackType& importStack = m_stylesheet.getStylesheetRoot()->getImportStack();
if(stackContains(importStack, hrefUrl))
{
- DOMString msg(DOMString(hrefUrl.getURL()) + " is directly or indirectly importing itself!");
+ DOMString msg(DOMString(hrefUrl.getURLText()) + " is directly or indirectly importing itself!");
throw SAXException(toCharArray(msg));
}
@@ -1065,7 +1065,7 @@
StylesheetHandler tp(m_processor, *pImportedStylesheet);
- pImportedStylesheet->setBaseIdentifier(hrefUrl.getURL());
+ pImportedStylesheet->setBaseIdentifier(hrefUrl.getURLText());
m_processor.parseXML(hrefUrl, &tp, DOM_UnimplementedDocument(pImportedStylesheet));
@@ -1095,13 +1095,13 @@
*/
bool StylesheetHandler::stackContains(const Stylesheet::URLStackType& stack,
- const URL& url) const
+ const XMLURL& url) const
{
int n = stack.size();
bool contains = false;
for(int i = 0; i < n; i++)
{
- URL url2 = stack[i];
+ XMLURL url2 = stack[i];
if(url2 == url)
{
contains = true;
@@ -1150,11 +1150,11 @@
const DOMString href = atts.getValue(i);
- const URL* hrefUrl = m_processor.getURLFromString(href, m_stylesheet.getIncludeStack().back().getURL());
+ const XMLURL* hrefUrl = m_processor.getURLFromString(href, m_stylesheet.getIncludeStack().back().getURLText());
if(stackContains(m_stylesheet.getIncludeStack(), *hrefUrl))
{
- DOMString msg(DOMString(hrefUrl->getURL()) + " is directly or indirectly including itself!");
+ DOMString msg(DOMString(hrefUrl->getURLText()) + " is directly or indirectly including itself!");
throw SAXException(toCharArray(msg));
}
1.2 +1 -1 xml-xalan/c/src/XSLT/StylesheetHandler.hpp
Index: StylesheetHandler.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/StylesheetHandler.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- StylesheetHandler.hpp 1999/12/18 19:48:05 1.1
+++ StylesheetHandler.hpp 2000/01/17 23:55:25 1.2
@@ -263,7 +263,7 @@
/**
* Test to see if the stack contains the given URL.
*/
- bool stackContains(const Stylesheet::URLStackType& stack, const URL& url) const;
+ bool stackContains(const Stylesheet::URLStackType& stack, const XMLURL& url) const;
protected:
1.2 +2 -2 xml-xalan/c/src/XSLT/StylesheetRoot.cpp
Index: StylesheetRoot.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/StylesheetRoot.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- StylesheetRoot.cpp 1999/12/18 19:48:05 1.1
+++ StylesheetRoot.cpp 2000/01/17 23:55:25 1.2
@@ -109,10 +109,10 @@
// For some reason, the imports aren't working right if I
// don't set the baseIdent to full url. I think this is OK,
// and probably safer and faster in general.
- URL* url = m_processor->getURLFromString(m_baseIdent, DOMString());
+ XMLURL* url = m_processor->getURLFromString(m_baseIdent, DOMString());
if (url != 0)
{
- m_baseIdent = url->getURL();
+ m_baseIdent = url->getURLText();
delete url;
url = m_processor->getURLFromString(m_baseIdent, DOMString());
if (url != 0)
1.2 +3 -3 xml-xalan/c/src/XSLT/StylesheetRoot.hpp
Index: StylesheetRoot.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/StylesheetRoot.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- StylesheetRoot.hpp 1999/12/18 19:48:05 1.1
+++ StylesheetRoot.hpp 2000/01/17 23:55:25 1.2
@@ -58,7 +58,7 @@
#define XALAN_STYLESHEETROOT_HEADER_GUARD
/**
- * $Id: StylesheetRoot.hpp,v 1.1 1999/12/18 19:48:05 robweir Exp $
+ * $Id: StylesheetRoot.hpp,v 1.2 2000/01/17 23:55:25 robweir Exp $
*
* $State: Exp $
*
@@ -76,7 +76,7 @@
#include "ElemTemplate.hpp"
-#include <util/URL.hpp>
+#include <util/XMLURL.hpp>
#include <XMLSupport/FormatterToHTML.hpp>
#include <XMLSupport/FormatterToText.hpp>
@@ -149,7 +149,7 @@
/**
* A stack to keep track of URLs.
*/
- typedef std::vector<URL> ImportStackType;
+ typedef std::vector<XMLURL> ImportStackType;
/**
* Return the output method that was specified in the stylesheet.
1.3 +14 -14 xml-xalan/c/src/XSLT/XSLTEngineImpl.cpp
Index: XSLTEngineImpl.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTEngineImpl.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- XSLTEngineImpl.cpp 2000/01/07 21:25:34 1.2
+++ XSLTEngineImpl.cpp 2000/01/17 23:55:25 1.3
@@ -55,7 +55,7 @@
* <http://www.apache.org/>.
*/
/**
- * $Id: XSLTEngineImpl.cpp,v 1.2 2000/01/07 21:25:34 robweir Exp $
+ * $Id: XSLTEngineImpl.cpp,v 1.3 2000/01/17 23:55:25 robweir Exp $
*
* $State: Exp $
*
@@ -130,7 +130,7 @@
#include <sax/SaxException.hpp>
#include <util/StdOut.hpp>
#include <util/PlatformUtils.hpp>
-#include <internal/URLInputSource.hpp>
+#include <framework/URLInputSource.hpp>
#include "Arg.hpp"
#include "ContextMarker.hpp"
@@ -518,9 +518,9 @@
{
try
{
- std::auto_ptr<URL> url(getURLFromString(xsldocURLString));
+ std::auto_ptr<XMLURL> url(getURLFromString(xsldocURLString));
- XSLTInputSource input(url->getURL(), 0);
+ XSLTInputSource input(url->getURLText(), 0);
return processStylesheet(&input);
}
catch(SAXException& se)
@@ -642,12 +642,12 @@
}
-DOM_Document XSLTEngineImpl::parseXML(const URL& url,
+DOM_Document XSLTEngineImpl::parseXML(const XMLURL& url,
DocumentHandler* docHandler,
const DOM_Document& docToRegister)
{
// java: url.toExternalForm();
- const DOMString& urlString = url.getURL();
+ const DOMString& urlString = url.getURLText();
DOM_Document doc;
const SourceDocumentsMapType::iterator it = m_sourceDocs.find(urlString);
if(it != m_sourceDocs.end())
@@ -656,7 +656,7 @@
return doc;
}
// java: url.toString()
- XSLTInputSource inputSource(url.getURL());
+ XSLTInputSource inputSource(url.getURLText());
if(0 != docHandler)
m_parserLiaison.parseXMLStream(inputSource, *docHandler);
else
@@ -789,9 +789,9 @@
StylesheetHandler stylesheetProcessor(*this, *stylesheet);
- URL* xslURL = getURLFromString(xslURLString, xmlBaseIdent);
+ XMLURL* xslURL = getURLFromString(xslURLString, xmlBaseIdent);
- XSLTInputSource inputSource(xslURL->getURL());
+ XSLTInputSource inputSource(xslURL->getURLText());
// java: m_parserLiaison.setDocumentHandler(stylesheetProcessor);
// m_parserLiaison.parse(inputSource);
m_parserLiaison.parseXMLStream(inputSource, stylesheetProcessor);
@@ -3486,7 +3486,7 @@
-URL* XSLTEngineImpl::getURLFromString (const DOMString& urlString)
+XMLURL* XSLTEngineImpl::getURLFromString (const DOMString& urlString)
// throws MalformedURLException
/*
* Create an URL as a file: protocol by constructing fully qualified name
@@ -3494,7 +3494,7 @@
* NOTE: caller owns memory
*/
{
- URL* url = new URL();
+ XMLURL* url = new XMLURL();
try
{
url->setURL(c_wstr(urlString));
@@ -3505,8 +3505,8 @@
DOMString fullpath("file:///");
try
{
- XMLCh* lastPart = XMLPlatformUtils::getBasePath(c_wstr(urlString));
- fullpath += lastPart;
+// XMLCh* lastPart = XMLPlatformUtils::getBasePath(c_wstr(urlString));
+// fullpath += lastPart;
fullpath += urlString;
url->setURL(c_wstr(fullpath));
}
@@ -3519,7 +3519,7 @@
return url;
}
-URL* XSLTEngineImpl::getURLFromString(const DOMString& urlString, const DOMString& base)
+XMLURL* XSLTEngineImpl::getURLFromString(const DOMString& urlString, const DOMString& base)
{
if (isEmpty(base))
return getURLFromString(urlString);
1.2 +5 -5 xml-xalan/c/src/XSLT/XSLTEngineImpl.hpp
Index: XSLTEngineImpl.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTEngineImpl.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XSLTEngineImpl.hpp 1999/12/18 19:48:05 1.1
+++ XSLTEngineImpl.hpp 2000/01/17 23:55:25 1.2
@@ -59,7 +59,7 @@
/**
*
- * $Id: XSLTEngineImpl.hpp,v 1.1 1999/12/18 19:48:05 robweir Exp $
+ * $Id: XSLTEngineImpl.hpp,v 1.2 2000/01/17 23:55:25 robweir Exp $
*
* $State: Exp $
*
@@ -142,7 +142,7 @@
#include <dom/DOM_Document.hpp>
#include <dom/DOM_Text.hpp>
#include <dom/DOMString.hpp>
-#include <util/URL.hpp>
+#include <util/XMLURL.hpp>
#include <sax/DocumentHandler.hpp>
@@ -388,7 +388,7 @@
* @exception SAXException thrown if the active ProblemListener and XMLParserLiaison decide
* the error condition is severe enough to halt processing.
*/
- DOM_Document parseXML(const URL& url,
+ DOM_Document parseXML(const XMLURL& url,
//@@ TODO: Fix this
#if 1
DocumentHandler* docHandler,
@@ -2067,10 +2067,10 @@
* Take a user string and try to parse XML, and also return
* the url.
*/
- URL*
+ XMLURL*
getURLFromString(const DOMString& urlString);
- URL*
+ XMLURL*
getURLFromString(const DOMString& urlString, const DOMString& base);
1.2 +1 -1 xml-xalan/c/src/XSLT/XSLTInputSource.hpp
Index: XSLTInputSource.hpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/XSLTInputSource.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XSLTInputSource.hpp 1999/12/18 19:48:05 1.1
+++ XSLTInputSource.hpp 2000/01/17 23:55:26 1.2
@@ -62,7 +62,7 @@
// Base include file. Must be first.
#include "XSLTDefinitions.hpp"
-#include <internal/URLInputSource.hpp>
+#include <framework/URLInputSource.hpp>
#include <dom/DOM_Node.hpp>
#include <sax/InputSource.hpp>
1.3 +1 -1 xml-xalan/c/src/XercesParserLiaison/XercesParserLiaison.cpp
Index: XercesParserLiaison.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XercesParserLiaison/XercesParserLiaison.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- XercesParserLiaison.cpp 2000/01/03 23:28:17 1.2
+++ XercesParserLiaison.cpp 2000/01/17 23:55:29 1.3
@@ -65,7 +65,7 @@
#include <parsers/DOMParser.hpp>
#include <parsers/SAXParser.hpp>
-#include <internal/URLInputSource.hpp>
+#include <framework/URLInputSource.hpp>
#include <sax/SAXParseException.hpp>