Uploaded image for project: 'ODF Toolkit'
  1. ODF Toolkit
  2. ODFTOOLKIT-110

Attribute namespace declaration now usable by XPath

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • odfdom-0.8.5
    • odfdom-0.9
    • java
    • None
    • Operating System: Linux
      Platform: PC
    • 179

    Description

      When a slide deck is very simple (like attachment 1) it can't be used in

      OdfPresentationDocument.copyForeignSlide()

      It throws the following exceptions:

      ------------------
      javax.xml.xpath.XPathExpressionException
      at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(XPathImpl.java:289)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignLinkRef(OdfPresentationDocument.java:644)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.InsertCollectedStyle(OdfPresentationDocument.java:840)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignStyleRef(OdfPresentationDocument.java:723)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignSlide(OdfPresentationDocument.java:618)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      -----------------------

      and

      This runs on a German system, so a rough translation is:
      "SEVERE The prefix xlink must be resoved"
      ------------------------

      SCHWERWIEGEND: null
      com.sun.org.apache.xpath.internal.domapi.XPathStylesheetDOM3Exception: Das Präfix muss in einen Namensbereich aufgelöst werden: xlink
      at com.sun.org.apache.xpath.internal.compiler.XPathParser.errorForDOM3(XPathParser.java:653)
      at com.sun.org.apache.xpath.internal.compiler.Lexer.mapNSTokens(Lexer.java:638)
      at com.sun.org.apache.xpath.internal.compiler.Lexer.tokenize(Lexer.java:265)
      at com.sun.org.apache.xpath.internal.compiler.Lexer.tokenize(Lexer.java:96)
      at com.sun.org.apache.xpath.internal.compiler.XPathParser.initXPath(XPathParser.java:110)
      at com.sun.org.apache.xpath.internal.XPath.<init>(XPath.java:176)
      at com.sun.org.apache.xpath.internal.XPath.<init>(XPath.java:264)
      at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.eval(XPathImpl.java:193)
      at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(XPathImpl.java:275)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignLinkRef(OdfPresentationDocument.java:644)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.InsertCollectedStyle(OdfPresentationDocument.java:840)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignStyleRef(OdfPresentationDocument.java:749)
      at org.odftoolkit.odfdom.doc.OdfPresentationDocument.copyForeignSlide(OdfPresentationDocument.java:618)
      ------------------------

      once a slide deck contains an image the parsing go through.

      I assume this is true for all high level methods that call OdfPresentationDocument.copyForeignLinkRef() and methods like
      OdfPresentationDocument.deleteLinkRef

      Attachments

        Issue Links

          Activity

            People

              daisy@odftoolkit.org Ying Chun Guo
              j-wicz@odftoolkit.org j-wicz
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: