Repository navigation
v0.4.9
XML v0.4.9
This release adds string_value, pretty = false for write, eachattribute! on a Cursor, and the doctype = :refuse keyword. It also makes wellformed = :strict refuse more documents that XML 1.0 forbids: 679 of the W3C suite's 1257 not-well-formed documents, against 596 with v0.4.8.
New:
string_value(node)returns the text of an element, whatever it holds, as XPath 1.0 defines the string-value of a node.writetakespretty = false, which adds and drops no white space between the nodes.eachattribute!(c)reads the attributes of aCursor's element once, where the cursor stands.doctype = :refuserefuses a document that has a DOCTYPE, before any of its declarations is read.
With these changes, the same call can give another result than with v0.4.8:
text()inxpathalso selects CDATA sections.:strictrefuses a name that breaks the Name rule, such as<doc 12="34"/>.:strictrefuses a processing instruction whose target isxmlin any case, or that neither white space nor?>follows.sourcetext,sourcespanandsplicetexton aFlatNodekeep the line ends of the document, as on aLazyNode.LazyNodeandCursorread the line ends of a declared entity's text asNodeandFlatNodedo.tagon aFlatNodereturns an empty string for a processing instruction without a target, as the other readers do.- A DOCTYPE is read when the comment before it begins with
>.
Deprecated: for_each_child and @for_each_child, to be removed in v0.5. Call for_each_child! and @for_each_child! instead.
Fixes:
- Under Julia 1.10, the readers search texts and attribute values through their bytes.
next!on aCursorreaches the end of a document about twice as fast as in v0.4.8. - A tag with many attributes is checked for duplicates in O(n log n) time, whatever its names.
- A chain of declared entities is checked in memory proportional to its length.
The CHANGELOG gives the details of each change.