First part of Tomcat 7 compatibility.

* Added Juli to classpath for ecdc Tomcat start script. "ant start" works.
* Fixed error in web-sci.xml, added surrounding <jsp-config> tags tp taglib tags.
* Removed jd.sclt transformer (no longer maintained, latest release from 2003
* Removed XML factory implementation configuration using system wide environment variables (affecting and probably conflicting with other webapps in the container). Alternative configuration facility not yet implemented, using container fallback (which is saxon at the moment for xslt processor).

CCM is currently execting in TC 7 for the public site, content-center doesn't work in TC 7 for now (but in TC6 as previously).
 


git-svn-id: https://svn.libreccm.org/ccm/trunk@2644 8810af33-2d31-482b-a856-94f89814c4df
master
pb 2014-05-22 22:03:53 +00:00
parent 445cdef0dc
commit 7dd986442b
10 changed files with 167 additions and 170 deletions

View File

@ -50,8 +50,8 @@ import org.apache.log4j.Logger;
import org.w3c.dom.Document; import org.w3c.dom.Document;
/** /**
* A class for loading, caching and generally managing XSL templates * A class for loading, caching and generally managing XSL templates and
* and transformers. * transformers.
* *
* @author Dan Berrange * @author Dan Berrange
* @version $Id: XSLTemplate.java 1942 2009-05-29 07:53:23Z terry $ * @version $Id: XSLTemplate.java 1942 2009-05-29 07:53:23Z terry $
@ -317,8 +317,10 @@ public final class XSLTemplate {
* critical, because XSL files should always use * critical, because XSL files should always use
* relative imports, which implies all imported files * relative imports, which implies all imported files
* will be in the same URL space. * will be in the same URL space.
*
* @param os the output stream to write the ZIP to * @param os the output stream to write the ZIP to
* @param base the base directory in which the files will extract * @param base the base directory in which the files will extract
* @throws java.io.IOException
*/ */
public void toZIP(OutputStream os, public void toZIP(OutputStream os,
String base) String base)
@ -358,14 +360,17 @@ public final class XSLTemplate {
private static class Log4JErrorListener implements ErrorListener { private static class Log4JErrorListener implements ErrorListener {
@Override
public void warning(TransformerException e) throws TransformerException { public void warning(TransformerException e) throws TransformerException {
log(Level.WARN, e); log(Level.WARN, e);
} }
@Override
public void error(TransformerException e) throws TransformerException { public void error(TransformerException e) throws TransformerException {
log(Level.ERROR, e); log(Level.ERROR, e);
} }
@Override
public void fatalError(TransformerException e) throws public void fatalError(TransformerException e) throws
TransformerException { TransformerException {
log(Level.FATAL, e); log(Level.FATAL, e);

View File

@ -1,85 +0,0 @@
/*
* Copyright (C) 2003-2004 Red Hat Inc. All Rights Reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* as published by the Free Software Foundation; either version 2.1 of
* the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
package com.arsdigita.util.config;
import com.arsdigita.util.Assert;
import com.arsdigita.util.JavaPropertyReader;
import com.arsdigita.util.parameter.Parameter;
import com.arsdigita.util.parameter.ParameterLoader;
import com.arsdigita.util.parameter.ParameterValue;
import java.util.Properties;
import org.apache.log4j.Logger;
/**
* @deprecated Use {@link com.arsdigita.util.JavaPropertyReader}
* instead
*/
public class JavaPropertyLoader extends JavaPropertyReader
implements ParameterLoader {
public final static String versionId =
"$Id: JavaPropertyLoader.java 287 2005-02-22 00:29:02Z sskracic $" +
"$Author: sskracic $" +
"$DateTime: 2004/08/16 18:10:38 $";
private static final Logger s_log = Logger.getLogger
(JavaPropertyLoader.class);
private final Properties m_props;
/**
* Constructs a parameter loader that uses <code>props</code>.
*
* @param props The <code>Properties</code> object that stores
* property values; it cannot be null
*/
public JavaPropertyLoader(final Properties props) {
super(props);
m_props = props;
}
public final ParameterValue load(final Parameter param) {
if (s_log.isDebugEnabled()) {
s_log.debug("Loading " + param + " from " + this);
}
Assert.exists(param, Parameter.class);
final String key = param.getName();
if (m_props.containsKey(key)) {
final ParameterValue value = new ParameterValue();
value.setObject(param.read(this, value.getErrors()));
return value;
} else {
return null;
}
}
/**
* Returns a <code>String</code> representation of this object.
*
* @return super.toString() + ":" + properties.size()
*/
public String toString() {
return super.toString() + ":" + m_props.size();
}
}

View File

@ -48,15 +48,11 @@ import java.io.UnsupportedEncodingException;
* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ * ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
* *
* @author Patrick McNeill * @author Patrick McNeill
* @version ACS 4.5a
* @since ACS 4.5a * @since ACS 4.5a
* @version $Id: Document.java 287 2005-02-22 00:29:02Z sskracic $
*/ */
public class Document { public class Document {
public static final String versionId =
"$Id: Document.java 287 2005-02-22 00:29:02Z sskracic $"
+ " by $Author: sskracic $, "
+ "$DateTime: 2004/08/16 18:10:38 $";
private static final Logger s_log = private static final Logger s_log =
Logger.getLogger(Document.class.getName()); Logger.getLogger(Document.class.getName());
/** /**
@ -121,6 +117,7 @@ public class Document {
s_builder.setNamespaceAware(true); s_builder.setNamespaceAware(true);
s_db = new ThreadLocal() { s_db = new ThreadLocal() {
@Override
public Object initialValue() { public Object initialValue() {
try { try {
return s_builder.newDocumentBuilder(); return s_builder.newDocumentBuilder();
@ -140,6 +137,8 @@ public class Document {
/** /**
* Creates a new Document class with no root element. * Creates a new Document class with no root element.
*
* @throws javax.xml.parsers.ParserConfigurationException
*/ */
public Document() throws ParserConfigurationException { public Document() throws ParserConfigurationException {
DocumentBuilder db = (DocumentBuilder) s_db.get(); DocumentBuilder db = (DocumentBuilder) s_db.get();
@ -165,6 +164,7 @@ public class Document {
* Creates a new Document class with the given root element. * Creates a new Document class with the given root element.
* *
* @param rootNode the element to use as the root node * @param rootNode the element to use as the root node
* @throws javax.xml.parsers.ParserConfigurationException
*/ */
public Document(Element rootNode) throws ParserConfigurationException { public Document(Element rootNode) throws ParserConfigurationException {
DocumentBuilder db = (DocumentBuilder) s_db.get(); DocumentBuilder db = (DocumentBuilder) s_db.get();
@ -181,6 +181,10 @@ public class Document {
/** /**
* Creates a document from the passed in string that should * Creates a document from the passed in string that should
* be properly formatted XML * be properly formatted XML
*
* @param xmlString
* @throws javax.xml.parsers.ParserConfigurationException
* @throws org.xml.sax.SAXException
*/ */
public Document(String xmlString) public Document(String xmlString)
throws ParserConfigurationException, org.xml.sax.SAXException { throws ParserConfigurationException, org.xml.sax.SAXException {
@ -345,6 +349,7 @@ public class Document {
* without additional indenting. * without additional indenting.
* @return a String representation of <code>this</code>. * @return a String representation of <code>this</code>.
*/ */
@Override
public String toString() { public String toString() {
return toString(m_document, false); return toString(m_document, false);
} }

View File

@ -188,6 +188,9 @@ public class Element {
/** /**
* Copies the passed in element and all of its children to a new * Copies the passed in element and all of its children to a new
* Element. * Element.
*
* @param copyFrom
* @return
*/ */
public Element newChildElement(Element copyFrom) { public Element newChildElement(Element copyFrom) {
Assert.exists(copyFrom, Element.class); Assert.exists(copyFrom, Element.class);
@ -205,7 +208,11 @@ public class Element {
/** /**
* Copies the passed in element and all of its children to a new * Copies the passed in element and all of its children to a new
* Element using the passed-in name * Element using the passed-in name.
*
* @param name
* @param copyFrom
* @return
*/ */
public Element newChildElement(String name, Element copyFrom) { public Element newChildElement(String name, Element copyFrom) {
if (m_doc == null) { if (m_doc == null) {
@ -221,7 +228,12 @@ public class Element {
/** /**
* Copies the passed in element and all of its children to a new * Copies the passed in element and all of its children to a new
* Element using the passed-in name * Element using the passed-in name.
*
* @param name
* @param uri
* @param copyFrom
* @return
*/ */
public Element newChildElement(String name, String uri, Element copyFrom) { public Element newChildElement(String name, String uri, Element copyFrom) {
if (m_doc == null) { if (m_doc == null) {
@ -324,6 +336,8 @@ public class Element {
/** /**
* Returns the concatenation of all the text in all child nodes * Returns the concatenation of all the text in all child nodes
* of the current element. * of the current element.
*
* @return
*/ */
public String getText() { public String getText() {
StringBuilder result = new StringBuilder(); StringBuilder result = new StringBuilder();

View File

@ -59,6 +59,30 @@ import org.apache.log4j.Logger;
* modified by * modified by
* @author pboy * @author pboy
*/ */
// /////////////////////////////////////////////////////////////////////////////
//
// NOTE: The ServiceProviderInterface as implementet by the JaxP factory
// class newInstance() follow a specific search order as explained above.
// The META-INF directory MUST be found via ContextClasspathLoader, i.e. must
// be located in WEB-INF/classes/META-INF or in a jar-file at WEB-INF/lib (or
// in one of the locations searched by common class loader which is not useful)
// Therefore is is not possible to switch a factory implementation after
// deployment at runtime or webapp startup, because both locations are not meant
// to be changed after deployment of an application.
// The alternative instantiation using newInstance(ImplementationClass,
// LoaderClass) is no replacement, because developers may use newInstance()
// anyway and probably get an unintended implementation.
//
// Therefore we must engage a quick'nd dirty way to achieve the goal and mess
// around with the WEB-INF/classes directory, until a better solution will be
// available.
//
// /////////////////////////////////////////////////////////////////////////////
public class FactoriesSetup { public class FactoriesSetup {
private static final Logger s_log = Logger.getLogger private static final Logger s_log = Logger.getLogger
@ -71,12 +95,12 @@ public class FactoriesSetup {
* method which modifies the system.property. * method which modifies the system.property.
*/ */
public static void setupFactories() { public static void setupFactories() {
setupFactory("javax.xml.parsers.DocumentBuilderFactory", // setupFactory("javax.xml.parsers.DocumentBuilderFactory",
XMLConfig.getConfig().getDOMBuilderFactoryClassname()); // XMLConfig.getConfig().getDOMBuilderFactoryClassname());
setupFactory("javax.xml.parsers.SAXParserFactory", // setupFactory("javax.xml.parsers.SAXParserFactory",
XMLConfig.getConfig().getSAXParserFactoryClassname()); // XMLConfig.getConfig().getSAXParserFactoryClassname());
setupFactory("javax.xml.transform.TransformerFactory", // setupFactory("javax.xml.transform.TransformerFactory",
XMLConfig.getConfig().getXSLTransformerFactoryClassname()); // XMLConfig.getConfig().getXSLTransformerFactoryClassname());
} }
/* ************ internal worker methods section ************ */ /* ************ internal worker methods section ************ */
@ -97,8 +121,8 @@ public class FactoriesSetup {
if (s_log.isInfoEnabled()) { if (s_log.isInfoEnabled()) {
s_log.info("Setting " + name + " to " + impl); s_log.info("Setting " + name + " to " + impl);
} }
System.setProperty(name, // System.setProperty(name,
impl); // impl);
} else { } else {
if (s_log.isInfoEnabled()) { if (s_log.isInfoEnabled()) {
s_log.info("Leaving " + name + " as " + s_log.info("Leaving " + name + " as " +
@ -106,28 +130,5 @@ public class FactoriesSetup {
} }
} }
} }
/**
* Actually unfinished work.
*
* ToDo: Use an alternative Factory constructor of javax.xml. ... (e.g.
* DocumentBuilderFactory) which directly accepts a classname and a
* class loader, so we do not depend on a system wide configuration.
*
* @param impl the value of the class name of the factory to use
*/
// static void setupDomBuilderFactory( String implClass) {
// if (implClass != null) {
// if (s_log.isInfoEnabled()) {
// s_log.info("Setting " + name + " to " + impl);
// }
// System.setProperty(name,
// impl);
// } else {
// if (s_log.isInfoEnabled()) {
// s_log.info("Leaving " + name + " as " +
// System.getProperty(name));
// }
// }
// }
} }

View File

@ -42,7 +42,7 @@ import org.xml.sax.helpers.DefaultHandler;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
/** /**
* Provides a set of helper methods for dealing with XML, * Provides a set of static helper methods for dealing with XML,
* including file parsing &amp; object -> string serialization * including file parsing &amp; object -> string serialization
*/ */
public class XML { public class XML {
@ -51,13 +51,16 @@ public class XML {
// private static XMLConfig s_config; // private static XMLConfig s_config;
private static Map s_formatters = new HashMap(); private static final Map s_formatters = new HashMap();
static { static {
s_log.debug("Static initalizer starting..."); s_log.debug("Static initalizer starting...");
s_formatters.put(Date.class, new DateTimeFormatter()); s_formatters.put(Date.class, new DateTimeFormatter());
s_log.debug("Static initalizer finished."); s_log.debug("Static initalizer finished.");
} }
/**
* Constructor. All methods are static, no initialization required.
*/
private XML() {} private XML() {}
/** /**
@ -74,6 +77,8 @@ public class XML {
/** /**
* Registers a formatter for serializing objects of a * Registers a formatter for serializing objects of a
* class to a String suitable for XML output. * class to a String suitable for XML output.
* @param klass
* @param formatter
*/ */
public static void registerFormatter(Class klass, public static void registerFormatter(Class klass,
Formatter formatter) { Formatter formatter) {
@ -82,6 +87,7 @@ public class XML {
/** /**
* Unregisters a formatter against a class. * Unregisters a formatter against a class.
* @param klass
*/ */
public static void unregisterFormatter(Class klass) { public static void unregisterFormatter(Class klass) {
s_formatters.remove(klass); s_formatters.remove(klass);
@ -98,6 +104,7 @@ public class XML {
/** /**
* Looks for the best matching formatter. * Looks for the best matching formatter.
*
* @param klass the class to find a formatter for * @param klass the class to find a formatter for
* @return the formatter, or null if non is registered * @return the formatter, or null if non is registered
*/ */
@ -115,7 +122,10 @@ public class XML {
* matching registered Formatter implementation. Looks * matching registered Formatter implementation. Looks
* for a formatter registered against the object's * for a formatter registered against the object's
* class first, then its superclass, etc. If no formatter * class first, then its superclass, etc. If no formatter
* is found, uses the toString() method * is found, uses the toString() method.
*
* @param value
* @return
*/ */
public static String format(Object value) { public static String format(Object value) {
if (value == null) { if (value == null) {
@ -219,11 +229,14 @@ public class XML {
/** /**
* Prints the skeleton structure of the element to the supplied print * Prints the skeleton structure of the element to the supplied print
* writer. * writer.
* @param element
* @param writer
**/ **/
public static void toSkeleton(final Element element, public static void toSkeleton(final Element element,
final PrintWriter writer) { final PrintWriter writer) {
XML.traverse(element, 0, new Action() { XML.traverse(element, 0, new Action() {
@Override
public void apply(Element elem, int level) { public void apply(Element elem, int level) {
final String padding = " "; final String padding = " ";
for (int ii=0; ii<level; ii++) { for (int ii=0; ii<level; ii++) {
@ -242,6 +255,9 @@ public class XML {
/** /**
* This is a wrapper for {@link #toSkeleton(Element, PrintWriter)}. * This is a wrapper for {@link #toSkeleton(Element, PrintWriter)}.
*
* @param element
* @return
**/ **/
public static String toSkeleton(Element element) { public static String toSkeleton(Element element) {
StringWriter writer = new StringWriter(); StringWriter writer = new StringWriter();
@ -253,6 +269,10 @@ public class XML {
/** /**
* Pre-order, depth-first traversal. * Pre-order, depth-first traversal.
*
* @param elem
* @param level
* @param action
**/ **/
public static void traverse(Element elem, int level, Action action) { public static void traverse(Element elem, int level, Action action) {
action.apply(elem, level); action.apply(elem, level);

View File

@ -22,6 +22,7 @@ import com.arsdigita.runtime.AbstractConfig;
import com.arsdigita.util.parameter.Parameter; import com.arsdigita.util.parameter.Parameter;
import com.arsdigita.util.parameter.BooleanParameter; import com.arsdigita.util.parameter.BooleanParameter;
import com.arsdigita.util.parameter.StringParameter; import com.arsdigita.util.parameter.StringParameter;
import javax.xml.transform.TransformerFactory;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
@ -37,31 +38,14 @@ import org.apache.log4j.Logger;
*/ */
public final class XMLConfig extends AbstractConfig { public final class XMLConfig extends AbstractConfig {
/** Internal logger instance to faciliate debugging. Enable logging output
* by editing /WEB-INF/conf/log4j.properties int hte runtime environment
* and set com.arsdigita.xml.XMLConfig=DEBUG by uncommenting
* or adding the line. */
private static final Logger s_log = Logger.getLogger(XMLConfig.class); private static final Logger s_log = Logger.getLogger(XMLConfig.class);
/** Private instance of this class to be returned after initialization. */
private static XMLConfig s_config; private static XMLConfig s_config;
// supported XSL transformer implementations
private static final String RESIN =
"com.caucho.xsl.Xsl";
private static final String JD_XSLT =
"jd.xml.xslt.trax.TransformerFactoryImpl";
private static final String XSLTC =
"org.apache.xalan.xsltc.trax.TransformerFactoryImpl";
private static final String SAXON =
"com.icl.saxon.TransformerFactoryImpl";
private static final String SAXON_HE =
"net.sf.saxon.TransformerFactoryImpl";
private static final String XALAN =
"org.apache.xalan.processor.TransformerFactoryImpl";
// supported documentBuilder implementations
private static final String DOM_XERCES =
"org.apache.xerces.jaxp.DocumentBuilderFactoryImpl";
private static final String DOM_RESIN =
"com.caucho.xml.parsers.XmlDocumentBuilderFactory";
// supported SAX parser implementations
private static final String SAX_XERCES =
"org.apache.xerces.jaxp.SAXParserFactoryImpl";
private static final String SAX_RESIN =
"com.caucho.xml.parsers.XmlSAXParserFactory";
/** /**
* Returns the singleton configuration record for the XML functionality * Returns the singleton configuration record for the XML functionality
@ -77,23 +61,51 @@ public final class XMLConfig extends AbstractConfig {
return s_config; return s_config;
} }
// supported XSL transformer implementations
private static final String RESIN =
"com.caucho.xsl.Xsl";
private static final String SAXON =
"com.icl.saxon.TransformerFactoryImpl";
private static final String SAXON_HE =
"net.sf.saxon.TransformerFactoryImpl";
private static final String XALAN =
"org.apache.xalan.processor.TransformerFactoryImpl";
private static final String XSLTC =
"org.apache.xalan.xsltc.trax.TransformerFactoryImpl";
// supported documentBuilder implementations
private static final String DOM_XERCES =
"org.apache.xerces.jaxp.DocumentBuilderFactoryImpl";
private static final String DOM_RESIN =
"com.caucho.xml.parsers.XmlDocumentBuilderFactory";
// supported SAX parser implementations
private static final String SAX_XERCES =
"org.apache.xerces.jaxp.SAXParserFactoryImpl";
private static final String SAX_RESIN =
"com.caucho.xml.parsers.XmlSAXParserFactory";
private final Parameter m_xfmr = new StringParameter( private final Parameter m_xfmr = new StringParameter(
"waf.xml.xsl_transformer", Parameter.REQUIRED, "saxon"); "waf.xml.xsl_transformer",
Parameter.REQUIRED, "saxon");
private final Parameter m_builder = new StringParameter( private final Parameter m_builder = new StringParameter(
"waf.xml.dom_builder", Parameter.REQUIRED, "xerces"); "waf.xml.dom_builder",
private final Parameter m_parser = new StringParameter("waf.xml.sax_parser", Parameter.REQUIRED, "xerces");
Parameter.REQUIRED, private final Parameter m_parser = new StringParameter(
"xerces"); "waf.xml.sax_parser",
private Parameter m_activateFullTimeFormatter = new BooleanParameter( Parameter.REQUIRED, "xerces");
private final Parameter m_activateFullTimeFormatter = new BooleanParameter(
"waf.xml.activate_full_date_formatter", "waf.xml.activate_full_date_formatter",
Parameter.OPTIONAL, Parameter.OPTIONAL, false);
new Boolean(
false));
/** /**
* Constructs an empty XMLConfig object following the singelton pattern. * Constructs an empty XMLConfig object following the singelton pattern.
* *
* They are meant as an singelton pattern (with private constructor), but * They are meant as a singelton pattern (with private constructor), but
* it does not work with the associated classes AbstractConfig and * it does not work with the associated classes AbstractConfig and
* ConfigRegistry because they can currently not deal with a private constructor * ConfigRegistry because they can currently not deal with a private constructor
*/ */
@ -109,6 +121,7 @@ public final class XMLConfig extends AbstractConfig {
} }
/* ************ public getter / setter section ************ */ /* ************ public getter / setter section ************ */
/** /**
* Returns the XSL Transformer factory class name to use. * Returns the XSL Transformer factory class name to use.
* *
@ -127,8 +140,6 @@ public final class XMLConfig extends AbstractConfig {
return XALAN; return XALAN;
} else if (m_key.toLowerCase().equals("resin")) { } else if (m_key.toLowerCase().equals("resin")) {
return RESIN; return RESIN;
} else if (m_key.toLowerCase().equals("jd.xslt")) {
return JD_XSLT;
} else if (m_key.toLowerCase().equals("saxonhe")) { } else if (m_key.toLowerCase().equals("saxonhe")) {
return SAXON_HE; return SAXON_HE;
} else { } else {
@ -137,6 +148,30 @@ public final class XMLConfig extends AbstractConfig {
} }
} }
/**
* Returns the XSL Transformer factory class name to use.
*
* The method assures that the return value is a valid class name.
*
* @return String XSL Transformer factory class name
*/
public final TransformerFactory getnewXSLTransformerFactoryInstance() {
// Defined values: saxon (default)|jd.xslt|resin|xalan|xsltc
// returns full qualified classname
String classname = getXSLTransformerFactoryClassname();
if (classname.isEmpty()) {
//return plattform default
return TransformerFactory.newInstance();
} else {
// return configured class
return TransformerFactory.newInstance( classname,
null );
}
}
/** /**
* Returns the Document Builder factory class name to use * Returns the Document Builder factory class name to use
* *
@ -177,6 +212,8 @@ public final class XMLConfig extends AbstractConfig {
/** /**
* Returns the activateFullTimeFormatter flag. * Returns the activateFullTimeFormatter flag.
*
* @return
*/ */
public boolean getActivateFullTimeFormatter() { public boolean getActivateFullTimeFormatter() {
return ((Boolean) get(m_activateFullTimeFormatter)).booleanValue(); return ((Boolean) get(m_activateFullTimeFormatter)).booleanValue();
@ -184,6 +221,7 @@ public final class XMLConfig extends AbstractConfig {
/** /**
* Sets the activateFullTimeFormatter flag. * Sets the activateFullTimeFormatter flag.
* @param activateFullTimeFormatter
*/ */
public void setActivateFullTimeFormatter(boolean activateFullTimeFormatter) { public void setActivateFullTimeFormatter(boolean activateFullTimeFormatter) {
set(m_activateFullTimeFormatter, new Boolean(activateFullTimeFormatter)); set(m_activateFullTimeFormatter, new Boolean(activateFullTimeFormatter));

View File

@ -24,7 +24,6 @@ import javax.xml.transform.TransformerException;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.xml.sax.SAXParseException; import org.xml.sax.SAXParseException;
import org.xml.sax.SAXException; import org.xml.sax.SAXException;
import jd.xml.xslt.parser.XsltParseException;
/** /**
* This class wraps a TransformerException and it "preserves" its * This class wraps a TransformerException and it "preserves" its
@ -190,8 +189,6 @@ public class TransformerExceptionContainer {
if (cause != null && (cause instanceof TransformerException || if (cause != null && (cause instanceof TransformerException ||
cause instanceof SAXException)) { cause instanceof SAXException)) {
return getOriginalException((Exception) cause); return getOriginalException((Exception) cause);
} else if (cause instanceof XsltParseException) {
return getOriginalException(((XsltParseException)cause).getException());
} else { } else {
return ex; return ex;
} }

View File

@ -25,8 +25,10 @@
</unzip> </unzip>
<!-- Copy additional files needed for operation --> <!-- Copy additional files needed for operation -->
<!--
<copy file="ccm-core/lib/xercesImpl.jar" <copy file="ccm-core/lib/xercesImpl.jar"
todir="${app.server.shared.dir}/endorsed" preservelastmodified="true"/> todir="${app.server.shared.dir}/endorsed" preservelastmodified="true"/>
-->
<copy file="tools-ng/devel/lib/ojdbc14.jar" <copy file="tools-ng/devel/lib/ojdbc14.jar"
todir="${app.server.shared.dir}" preservelastmodified="true"/> todir="${app.server.shared.dir}" preservelastmodified="true"/>
<copy file="tools-ng/devel/lib/postgresql-jdbc.jar" <copy file="tools-ng/devel/lib/postgresql-jdbc.jar"
@ -77,10 +79,10 @@
<!-- Previously required to prevent Tomcat from using AElfred to check web.xml / taglibs --> <!-- Previously required to prevent Tomcat from using AElfred to check web.xml / taglibs -->
<!-- seems to work now without, please comment in if something goes wrong with XML processing <!-- seems to work now without, please comment in if something goes wrong with XML processing
-->
<sysproperty key="javax.xml.transform.TransformerFactory" value="com.icl.saxon.TransformerFactoryImpl" /> <sysproperty key="javax.xml.transform.TransformerFactory" value="com.icl.saxon.TransformerFactoryImpl" />
<sysproperty key="javax.xml.parsers.DocumentBuilderFactory" value="org.apache.xerces.jaxp.DocumentBuilderFactoryImpl" /> <sysproperty key="javax.xml.parsers.DocumentBuilderFactory" value="org.apache.xerces.jaxp.DocumentBuilderFactoryImpl" />
<sysproperty key="javax.xml.parsers.SAXParserFactory" value="org.apache.xerces.jaxp.SAXParserFactoryImpl" /> <sysproperty key="javax.xml.parsers.SAXParserFactory" value="org.apache.xerces.jaxp.SAXParserFactoryImpl" />
-->
<!-- standard parameter to Tomcat operation --> <!-- standard parameter to Tomcat operation -->
<sysproperty key="catalina.home" value="${app.server.home.dir}" /> <sysproperty key="catalina.home" value="${app.server.home.dir}" />
@ -92,7 +94,7 @@
<jvmarg value="-XX:MaxPermSize=128m" /> <jvmarg value="-XX:MaxPermSize=128m" />
<jvmarg value="${app.server.debugger}" /> <jvmarg value="${app.server.debugger}" />
<classpath> <classpath>
<pathelement path="${app.server.home.dir}/bin/bootstrap.jar" /> <pathelement path="${app.server.home.dir}/bin/bootstrap.jar:${app.server.home.dir}/bin/tomcat-juli.jar" />
</classpath> </classpath>
</java> </java>
</target> </target>