Dominique Devienne wrote:
From: Christopher Lenz [mailto:[EMAIL PROTECTED]
Dominique Devienne wrote:
From: peter reilly [mailto:[EMAIL PROTECTED]
On Monday 17 November 2003 17:01, Dominique Devienne wrote:
So the NS for <project> and <target> does not matter?
Conceptually they are part of the Ant XML dialect to me,
so seeing them in no namespace at all seems weird??? --DD

If no namespace uri is picked for the empty prefix, it is up to the processor to pick one, in ant's case this is antlib:org.apache.tools.ant.

Ah, thanks for the precision. I didn't know this rule.

Slightly related, if I extracted or wrote a schema for Ant,
and specified an xsi:schemaLocation attribute in <project>,
will Ant ignore the attribute, or barf?

If you also define the namespace prefix "xsi", the document is still well-formed so everything should be fine. Xerces will not try to validate the build file though, since Ant doesn't put the parser in validating mode, of course.

Granted. But Peter apparently says that even though the document is well-formed (declared proper xsi NS prefix), Ant might still refuse it...

Right, I forgot that Ant currently ignores the namespaces of attributes. ;-)

I'm not sure whether it's a valid behavior as far as pure XML processing is
concerned. xsi:schemaLocation is just one example, there are other XML
technologies which use namespace'd XML attributes, like XInclude, XLink,
etc... Ant not supporting any of these might be problematic!?!? --DD

I agree. Attributes in a semantically unknown namespace should be ignored. Actually, I think only attributes in the same namespace as the element should be considered, i.e. those with no namespace prefix.


Hmm, not sure whether the magic "ant-type" attribute should be in the Ant core namespace, but it probably should...

--
Christopher Lenz
/=/ cmlenz at gmx.de


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to