Uploaded image for project: 'Cocoon'
  1. Cocoon
  2. COCOON-1906

[PATCH] simple-xml binding does not work with non file sources

    XMLWordPrintableJSON

Details

    • Urgent
    • Patch available

    Description

      The cocoon forms flowscript API comes with a helper method form.loadXML, that retrieves data from an xml document. The current implementation however does not work with documents that are referenced not as files, but as SitemapSources, e.g. via the cocoon:/ or xmldb:// pseudo-protocol. In this case the Rhino engine is unable to resolve the ambiguity between two method signatures:

      org.mozilla.javascript.EvaluatorException: "resource://org/apache/cocoon/forms/flow/javascript/Form.js", line 287: The choice of Java constructor toSAX matching JavaScript argument types (org.apache.cocoon.components.source.impl.SitemapSource,org.apache.cocoon.forms.util.XMLAdapter) is ambiguous; candidate constructors are:
      void toSAX(org.apache.excalibur.xml.sax.XMLizable,org.xml.sax.ContentHandler)
      void toSAX(org.apache.excalibur.source.Source,org.xml.sax.ContentHandler)

      Attachments

        1. cocoon-forms-javascript-disambiguation.patch
          0.9 kB
          Lars Trieloff
        2. cocoon-formsbinding-sourceutil.patch
          2 kB
          Lars Trieloff
        3. cocoon-formsbinding-sample.patch
          1 kB
          Lars Trieloff

        Activity

          People

            vgritsenko Vadim Gritsenko
            lars3loff Lars Trieloff
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: