From: Abbas M. <abb...@ya...> - 2006-10-27 19:51:46
|
Hi this is a function in form.js in org/apache/cocoon/forms/flow/javascript/Form.js for loading data from xml files to forms ---------------------------------------------------------------------------------------------------------- Form.prototype.loadXML = function(uri) { var source = null; var resolver = null; try { resolver = cocoon.getComponent(Packages.org.apache.cocoon.environment.SourceResolver.ROLE); source = resolver.resolveURI(uri); Packages.org.apache.cocoon.components.source.SourceUtil.toSAX(source, this.getXML()); } finally { if (source != null) resolver.release(source); cocoon.releaseComponent(resolver); } } --------------------------------------------------------------------------------------------------------- when I call it on an exist source it returns this error: org.mozilla.javascript.EvaluatorException: "resource://org/apache/cocoon/forms/flow/javascript/Form.js", line 287: The choice of Java method org.apache.cocoon.components.source.SourceUtil.toSAX matching JavaScript argument types (org.exist.cocoon.XMLDBSource,org.apache.cocoon.forms.util.XMLAdapter) is ambiguous; candidate methods are: void toSAX(org.apache.excalibur.xml.sax.XMLizable,org.xml.sax.ContentHandler), void toSAX(org.apache.excalibur.source.Source,org.xml.sax.ContentHandler) I have looked at exist javadocs it says that org.exist.cocoon.XMLDBSource implements both org.apache.excalibur.source.Source and org.apache.excalibur.xml.sax.XMLizable. how this problem can be solved? thanks --------------------------------- Get your email and more, right on the new Yahoo.com |