W3C home > Mailing lists > Public > www-dom@w3.org > October to December 2002

Re: how to understand: void Element.normalizeNamespaces()

From: Pavithran <pavithran.a@ap.sony.com>
Date: Sun, 7 Oct 2001 10:30:38 +0530
Message-ID: <007e01c14eed$01e22ca0$8401a8c0@pavithrana>
To: "Christian Parpart" <cparpart@surakware.net>, "Philippe Le Hegaret" <plh@w3.org>, "Rowland Shaw" <Rowland.Shaw@crystaldecisions.com>, "Boris Zbarsky" <bzbarsky@MIT.EDU>
Cc: <www-dom@w3.org>

Hi Parpart,
I am also not understanding this namepsaceNormalization alg,
I feel only auther can understand it,hope editor too,
one thing i am very clear ,this algorithm is not covering all scenarios,
even if u implement also it will not normalize...i am sure...
i wasted almost 1 week,
DONT give up,
bye
pavithran

----- Original Message -----
From: "Christian Parpart" <cparpart@surakware.net>
To: "Philippe Le Hegaret" <plh@w3.org>; "Rowland Shaw"
<Rowland.Shaw@crystaldecisions.com>; "Boris Zbarsky" <bzbarsky@MIT.EDU>
Cc: <www-dom@w3.org>
Sent: Monday, October 07, 2002 9:09 AM
Subject: how to understand: void Element.normalizeNamespaces()


>
> WARNING: Unsanitized content follows.
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi all,
>
> as recommented by the current DOM Level 3 Core spec, I should
> take a look into its Appendix B, Namespace Algorithms, wich
> also describes the function void Element.normalizeNamespaces()
> in pseudo code.
>
> Unfortunately the pseudo code is as pseudo as I wasn't able to
> understand it fully. Furthermore, does there exist _any_
> implementation of that function so that I can look there to
> understand? I didn't find it yet in Xerces C and J nor in current
> Mozilla sources. libxml2 doesn't have it of course, too.
>
> The only starting point I had, was one of them having the interface
> declared for void Document.normalizeDocument(). nothing more. I'd
> be happy if someone can point me to any project who implemented
> these namespace normalization.
>
> Am I the only one, trying to implement DOM Level 3 modules? I
> implemented all algorithms as suggested by that namespace algorithms
> appendix, but not that Element.normalizeNamespaces() one :(
>
> 1.) "if (Element's prefix/namespace pair (or default NS if no
>     prefix) are within the scope of binding)"
>
> "within scope of binding" is unclear.
> does it mean both can be found using lookupNamespaceXXX?
>
> In that case I'd code:
> if (lookupNamespacePrefix(prefix, false) &&
lookupNamespaceURI(namespaceURI))
> right?
>
> 2.) "there's a conflicting local default namespace declaration"
>
> What exactly is meant with conflicting? I have really no clue how to
> implement this :(
>
> 3.) "if one ore more prefix bindings are available"
>
> A prefix binding is the corresponding namespaceURI, isn't it? so
> there should be used the first one found starting from current
> element up to the root. Am I wrong? Is that what is meant with
> "binding"?
>
> Unfortunately namespace normalization seems not well documented
> in DOM Level3 Core, or should it be part of Load&Save, or XML
> (Namespaces?)?
>
> It's now the third day I'm trying to fight against my misunderstandings
> caused by this pseudo code. Please help.
>
> Best Regards,
> Christian Parpart.
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.0.7 (GNU/Linux)
>
> iD8DBQE9oQIJPpa2GmDVhK0RAkiTAJ9UxGnK1c0HaVDqbIE3jrFHPOK7hACfUFDf
> osf6aPYJf4pkgIOo989EGyU=
> =lKLE
> -----END PGP SIGNATURE-----
Received on Monday, 7 October 2002 00:57:26 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:56 GMT