Uploaded image for project: 'XalanC'
  1. XalanC
  2. XALANC-407

XalanC output format is not suitable as a document entity

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Resolution: Fixed
    • CurrentCVS
    • None
    • XalanC
    • None
    • Operating System: Other
      Platform: Other
    • 28386

    Description

      Sorry about the bad 'summary'. I'm not sure how to describe this one. I was
      experimenting with Xalan-J a while back and noticed that output from the java
      processor was serialized (no line feed characters) while the C++ processor was
      not. It led me to the following response from the java team:

      ---- NOTE -----

      the difference is significant when the document is used as an external general
      parsed entity. If I refer to the transformed document using an entity
      reference in the following document (apologies for bugs in syntax)

      <!DOCTYPE doc [
      <!ENTITY trans SYSTEM "transformed-output.xml">
      ]>
      <doc>abc&trans;def</doc>

      then the resulting XML with an extra line-feed is equivalent to the following:

      <doc>abc
      <out>1</out></doc>

      but without the line-feed, it's equivalent to this:

      <doc>abc<out>1</out></doc>

      Emitting the extra line-feed could distort the meaning. It would be
      permissible to emit the extra line-feed if either the doctype-system attribute
      was specified on xsl:output or the standalone attribute was specified with the
      value "yes", because in those cases, we must be producing a document entity.

      ---- END NOTE ----

      In short, the no-line-feed output is for conformance reasons. The C++
      processor should behave the same.

      Attachments

        Activity

          People

            Unassigned Unassigned
            june@ca.ibm.com June Ng
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: