From: fotis Date: Mon, 11 Sep 2000 10:08:02 +0000 (+0000) Subject: fix: this patch by Karen Lease adds some sophistication to the file name handling... X-Git-Tag: pre-columns~188 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=cebdc98c1d6a674adb8a7e80400301478399a4c5;p=xmlgraphics-fop.git fix: this patch by Karen Lease adds some sophistication to the file name handling of XalanCommandLine, so this should work now like Xalan's git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@193692 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/org/apache/fop/apps/XalanCommandLine.java b/src/org/apache/fop/apps/XalanCommandLine.java index d5bb418b0..7df56cf18 100644 --- a/src/org/apache/fop/apps/XalanCommandLine.java +++ b/src/org/apache/fop/apps/XalanCommandLine.java @@ -71,6 +71,7 @@ import java.io.FileNotFoundException; import java.net.URL; // Xalan +import org.apache.xalan.xpath.xml.XMLParserLiaison; import org.apache.xalan.xslt.XSLTInputSource; import org.apache.xalan.xslt.XSLTProcessor; import org.apache.xalan.xslt.XSLTProcessorFactory; @@ -204,8 +205,17 @@ public class XalanCommandLine { XSLTProcessor processor = XSLTProcessorFactory.getProcessor(); // Create the 3 objects the XSLTProcessor needs to perform the transformation. - XSLTInputSource xmlSource = new XSLTInputSource (args[0]); - XSLTInputSource xslSheet = new XSLTInputSource (args[1]); + // Fix up the args... + XMLParserLiaison xmlPL = processor.getXMLProcessorLiaison(); + URL urlTmp = xmlPL.getURLFromString(args[0], null); + System.err.println("XML File: " + args[0]); + System.err.println("URL: " + urlTmp); + XSLTInputSource xmlSource = new XSLTInputSource (urlTmp.toString()); + urlTmp = xmlPL.getURLFromString(args[1], null); + System.err.println("XSL File: " + args[1]); + System.err.println("URL: " + urlTmp); + XSLTInputSource xslSheet = new XSLTInputSource (urlTmp.toString()); + XSLTResultTarget xmlResult = new XSLTResultTarget (writer); // Perform the transformation.