Détail du package

xmlchars

lddubeau114.6mMIT2.2.0

Utilities for determining if characters belong to character classes defined by the XML specs.

XML, validation

readme

Utilities for determining whether characters belong to character classes defined by the XML specs.

Organization

It used to be that the library was contained in a single file and you could just import/require/what-have-you the xmlchars module. However, that setup did not work well for people who cared about code optimization. Importing xmlchars meant importing all of the library and because of the way the code was generated there was no way to shake the resulting code tree.

Different modules cover different standards. At the time this documentation was last updated, we had:

  • xmlchars/xml/1.0/ed5 which covers XML 1.0 edition 5.
  • xmlchars/xml/1.0/ed4 which covers XML 1.0 edition 4.
  • xmlchars/xml/1.1/ed2 which covers XML 1.0 edition 2.
  • xmlchars/xmlns/1.0/ed3 which covers XML Namespaces 1.0 edition 3.

Features

The "things" each module contains can be categorized as follows:

  1. "Fragments": these are parts and pieces of regular expressions that correspond to the productions defined in the standard that the module covers. You'd use these to build regular expressions.

  2. Regular expressions that correspond to the productions defined in the standard that the module covers.

  3. Lists: these are arrays of characters that correspond to the productions.

  4. Functions that test code points to verify whether they fit a production.

changelog

2.2.0 (2019-09-06)

Features

  • add isCharAndNotRestricted to xml/1.1/ed2 (907ae53)

2.1.1 (2019-06-24)

Features

  • add support for the RestrictedChar production (1ff2542)

2.1.0 (2019-06-24)

Features

  • add support for the RestrictedChar production (d6c4384)

2.0.1 (2019-06-23)

Performance Improvements

  • remove the include calls (338b9b1)

2.0.0 (2019-06-23)

Code Refactoring

  • drop the xmlchars module (b9f8285)

Features

  • add initial support for XML 1.1. edition 2 (baaa734)

Performance Improvements

  • include is faster than individual tests (db94653)
  • reorganize isChar for speed (98748bc)
  • reorganize name tests for speed (a55561d)

BREAKING CHANGES

  • the xmlchars module, which had been deprecated, is now gone.

1.3.1 (2018-10-01)

1.3.0 (2018-09-06)

Features

  • introduce fine-grained modules (e49461b)

1.2.0 (2018-09-06)

Features

  • add the lists namespace (7bfcca0)
  • add the XMLNS_1_0 namespace (022239c)

1.1.0 (2018-07-23)

Features