> I reviewed the Canonical Spec as I read your comment and agree with you. It
> seems to me that most of Canonical Algorithm is part of XPath. Do you
> implement
> something like XML Information Set Mapping. Could you tell me what is NOT
> provided by such a XPath Impl? Following sipplet contains the chances that
> are
> necessary to transform a xml document into cannocial form:
Yah, C14N tends to mostly just be an application of xpath.
The part that isn't part of the XPath W3C-REC is the 'document order'
of various things. XPath doesn't define the orderings of attributes
or namespaces, and we have to look direclty at the C14N spec to
find that.
Under the Normal Case, an xpath engine that enforces C14N orderings will
be less-efficient, because in more normal uses of xpath, lexigraphical
ordering of namespaces and attributes isn't really needed, and the
overhead in sorting would just degrade performance.
Rearrangement of namespaces also fall outside the scope of the xpath
spec.
-bob
>
> <sipplet>
> - The document is encoded in UTF-8 (i think that is dom4j standard)
> - Line breaks normalized to #xA on input, before parsing
> - Attribute values are normalized, as if by a validating processor
> - Character and parsed entity references are replaced
> - CDATA sections are replaced with their character content
> - The XML declaration and document type declaration (DTD) are removedEmpty
> elements are converted to start-end tag pairs
> - Whitespace outside of the document element and within start and end tags
> is normalizedAll whitespace in character content is retained (excluding
> characters
> removed during line feed normalization)
> Attribute value delimiters are set to quotation marks (double quotes)Special
>
> characters in attribute values and character content are
> replaced by character references
> -Superfluous namespace declarations are removed from each elementDefault
> attributes are added to each element
> -Lexicographic order is imposed on the namespace declarations and
> attributes of each element
> </sipplet>
>
> I guess some of that aspects are not covered by an XPath Implementation?
> What
> did you think?
> How fast would it be? Rember that Java MAC Functions are not so fast as
> should
> ;-) (we will use SHA-1 ).
>
> As James emphasised serveral times XPath is one of the powerfull features of
>
> dom4j and I like it very much.
>
> Regards
> Toby
>
> --
> GMX - Die Kommunikationsplattform im Internet.
> http://www.gmx.net
>
> --
> GMX Tipp:
>
> Der zweitgroesste Lotto-Jackpot aller Zeiten: 36 Mio. DM suchen einen
> Gewinner!
> Jetzt online tippen und nebenbei noch eine Reise nach Las Vegas gewinnen!
> http://www.get1.de/gmx-gewinnspiel2
_______________________________________________
dom4j-dev mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dom4j-dev