if (lang.equals("javaclass") && (scriptSrc != null))
throw new TransformerException(XSLMessages.createMessage(XSLTErrorResources.ER_ELEM_CONTENT_NOT_ALLOWED, new Object[]{scriptSrc}));
//"Element content not allowed for lang=javaclass " + scriptSrc);
// Register the extension namespace if it has not already been registered.
ExtensionNamespaceSupport extNsSpt = null;
ExtensionNamespacesManager extNsMgr = sroot.getExtensionNamespacesManager();
if (extNsMgr.namespaceIndex(declNamespace,
extNsMgr.getExtensions()) == -1)
{
if (lang.equals("javaclass"))
{
if (null == srcURL)
{
extNsSpt = extNsMgr.defineJavaNamespace(declNamespace);
}
else if (extNsMgr.namespaceIndex(srcURL,
extNsMgr.getExtensions()) == -1)
{
extNsSpt = extNsMgr.defineJavaNamespace(declNamespace, srcURL);
}
}
else // not java
{
String handler = "org.apache.xalan.extensions.ExtensionHandlerGeneral";
Object [] args = {declNamespace, this.m_elements, this.m_functions,
lang, srcURL, scriptSrc, getSystemId()};
extNsSpt = new ExtensionNamespaceSupport(declNamespace, handler, args);
}
}
if (extNsSpt != null)
extNsMgr.registerExtension(extNsSpt);
}