Uploaded image for project: 'Daffodil'
  1. Daffodil
  2. DFDL-1429

XML output should not insert whitespace around simple values

XMLWordPrintableJSON

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 2.0.0
    • None
    • Back End
    • None

      The pretty printer will sometimes wrap lines by inserting whitespace around a simple value e.g., turning

      <foo>bar</foo>

      into

      <foo>
         bar
      </foo>

      This is simply incorrect. It is changing the value into one with whitespace before and after. Not all XML-consuming applications will tolerate this. Some may view this data as invalid, particularly if the "bar" is some sort of enumeration constant string.

      We need to modify the pretty printer we use (we have our own variant due to another bug/issue we had to work around about CDATA nodes being dropped) so that it does NOT ever insert spaces around simple values. It can insert whitespace between elements, but not around simple values.

              slawrence Steve Lawrence
              mbeckerle.dfdl Mike Beckerle
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: