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

Printed representation of a Parser should be XML-ish

XMLWordPrintableJSON

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • s5
    • s4
    • Back End
    • None

      (I put this in s5 because it will likely get fixed as part of DFDL-343 which is a blocking issue)

      Printed rep of parsers is unintelligible. Change to an XML representation.

      Also provide a way to print out with depth limit so that you don't have to print out the whole parser every time, you can print out the top level and have deeper parts elided as '...'

      This is badly needed for debugging.

      Example printed rep:
      <seq xmlns="daffodil">
      <StartElement name="nested_seq" />
      <seq>
      <StartChildren />
      <StartSequence />
      <StartArray />
      <RepUnbounded>
      <seq>
      <StartElement name="seq_03" />
      <Init>%WSP*;</Init>
      <StartChildren />
      <StartSequence />
      <StartArray />
      <RepUnbounded>
      <seq>
      <StartElement name="seq_02" />
      <Init>?</Init>
      <StartChildren />
      <StartSequence />
      <alt>
      <seq>
      <StartElement name="seq_01" />
      <seq>
      <StartChildren />
      <StartSequence />
      <StartElement name="data_02" />
      <StringPatternMatched />
      <EndElement name="data_02" />
      <StartElement name="data_01" />
      <StringPatternMatched />
      <EndElement name="data_01" />
      <EndSequence />
      <EndChildren />
      </seq>
      <EndElement name="seq_01" />
      </seq>
      <seq>
      <StartElement name="data_01" />
      <StringPatternMatched />
      <EndElement name="data_01" />
      </seq>
      </alt>
      <EndSequence />
      <EndChildren />
      <EndElement name="seq_02" />
      </seq>
      </RepUnbounded>
      <EndArray />
      <EndSequence />
      <EndChildren />
      <EndElement name="seq_03" />
      </seq>
      </RepUnbounded>
      <EndArray />
      <EndSequence />
      <EndChildren />
      <Term>$</Term>
      </seq>
      <EndElement name="nested_seq" />
      </seq>

              pchu Paul Chu (Inactive)
              mbeckerle.dfdl Mike Beckerle
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: