Ann: rexml 2.5.4

Hello everybody,

Sorry for the long silence. I’ve been slowly accruing bugfixes and
whatnot, and got some time to make a release of the development
branch. So much to do, so little time…

puts RAA.entry[‘rexml’].description()

REXML is an XML 1.0 compliant, reasonably fast, non-validating XML
parser that supports multiple encodings. It has an API that is
designed to be intuitive, straightforward, and terse. REXML includes a
tree model parser, a SAX2 streaming parser, and a pull parser. It also
includes a full XPath implementation. All of REXML’s parsers pass 100%
of the Oasis XML non-validating tests.

Changelog:

  • On request, changed the format of printed elements so that
    whitespace appears before the close of empty tags; EG, “” ->
    ""
  • Improved parsing speed by a chunk
  • Bug #29: SAX2Parser was not processing XML declarations or
    processing instructions.
  • Bug #29: REXML pull parser and SAX2 parser both now report
    :processing_instruction, rather than :instruction. This is less
    consistent with REXML, which tends to be more minimal, but is more
    consistent with the SAX2 parser API. Let me know if you disagree with
    this decision before I go to 2.6.0.
  • Bug #30: In some cases, REXML would refuse to delete an attribute.
    This has been fixed.
  • Bug #31: Ignored element fix applied.
  • Fixed a whitespace parsing bug that resulted in some documents
    causing parse errors.
  • Fixed a tutorial error
  • Added Shift_JIS encoding. This is the same as Shift-JIS, but correct
    IANA registrated name is Shift_JIS. I’ve left Shift-JIS for backwards
    compatibility.
  • Fixed a non-conformance bug in XPath, WRT whitespace in predicates.
  • Changed the unit tests to use the new test/unit API.

Hmm. It occurs to me that you don’t need a validating parser.

You can parse and then validate.

Especially if instead of a DTD, you use James Clark’s Relax NG schema.

ie. XML doc + Relax NG Schema + REXML + A bit of ruby magic and you have a
validating parser.

All that is missing is the “bit of ruby magic”, which would probably be
quite small.

There are already DTD to Relax NG convertors.

Although personally I can’t think why they haven’t just thrown out DTD as
a sorry mistake and moved to Relax NG ages ago…

John Carter Phone : (64)(3) 358 6639
Tait Electronics Fax : (64)(3) 359 4632
PO Box 1645 Christchurch Email : john.carter@tait.co.nz
New Zealand

John’s law :-

All advances in computing have arisen through the creation of an
additional level of indirection, the trick is to work out which
indirection is actually useful.

···

On Mon, 17 Feb 2003, Sean Russell wrote:

REXML is an XML 1.0 compliant, reasonably fast, non-validating XML
parser that supports multiple encodings.

Although personally I can’t think why they haven’t just thrown out DTD as
a sorry mistake and moved to Relax NG ages ago…

If you have endless free time, try following the xml-dev mailing list for all the gory details. Largely it was due to a desire to
maintain some SGML compatibility.

James

Hmm. It occurs to me that you don’t need a validating parser.

You can parse and then validate.

Well, if you have a large XML source, you may want to abort on validation errors before loading the entire document.

James