Uploaded image for project: 'Daffodil'
  1. Daffodil
  2. DAFFODIL-1871

XMLTextInfosetOutputter endDocument should flush the writer

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.1.0
    • Component/s: API, Back End
    • Labels:
      None

      Description

      This an API issue.

      Since XMLTextInfosetOutputter doesn't have a flush() method of its own, then it needs to perform a flush() of the java.io.Writer that it is writing to, automatically.

      I would suggest that on endDocument it should do a flush(). One can argue it should flush as part of endElement for complex elements as well, but at least on endDocument.

      The absence of this flush() behavior caused one JAPI developer using Daffodil to waste time mystified about why she was getting 1/2 of an XML document out. Changing her code to just flush the writer after the return from parse() fixed it, but I think the API design really has to either flush automatically (my preference), or the XMLTextInfosetOutputter should have a flush() method of its own which flushes any state it has (today there is none), then flushes the writer it surrounds.

        Attachments

          Activity

            People

            • Assignee:
              dfthompson Dave Thompson
              Reporter:
              mbeckerle Michael Beckerle
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: