Skip to Content.
Sympa Menu

xom-interest - RE: [XOM-interest] xml:id initial implementation

xom-interest AT lists.ibiblio.org

Subject: XOM API for Processing XML with Java

List archive

Chronological Thread  
  • From: "Michael Kay" <mike AT saxonica.com>
  • To: "'Elliotte Harold'" <elharo AT metalab.unc.edu>, "'xom-interest'" <xom-interest AT lists.ibiblio.org>
  • Cc:
  • Subject: RE: [XOM-interest] xml:id initial implementation
  • Date: Fri, 21 Jan 2005 17:13:19 -0000

Presumably this means that an xml:id attribute will automatically show up
with

att.getType() == Attribute.Type.ID?

If that's the case, then the id() function in Saxon should pick it up
automatically.

I've implemented xml:id for the native Saxon tree models as well.

Michael Kay
http://www.saxonica.com/

> -----Original Message-----
> From: xom-interest-bounces AT lists.ibiblio.org
> [mailto:xom-interest-bounces AT lists.ibiblio.org] On Behalf Of
> Elliotte Harold
> Sent: 21 January 2005 16:56
> To: xom-interest
> Subject: [XOM-interest] xml:id initial implementation
>
> I've made the initial changes necessary to implement xml:id
> support in
> CVS, though a little work remains to be done. It turns out to be
> trickier than expected, because you have to consider all the
> different
> ways an xml:id attribute can be created, including things
> like changing
> the name or namespace of an attribute that didn't use to be xml:id to
> xml:id. This is helped a little because XOM enforces the rule
> that the
> xml prefix must be bound to the http://www.w3.org/XML/1998/namespace
> namespace. Therefore each method only needs to check the the
> qualified
> name or the local name and namespace URI, whichever is more
> convenient.
>
> I decided that XOM would only autonormalize xml:id attributes
> when they
> come in from a parser. If autonormalization is not sufficient
> to turn an
> xml:id value into an NCName, the builder throws a ParsingException.
> Otherwise, if you try to pass a non-NCName to setValue on xml:id, or
> change a non-xml:id attribute whose value id a non-NCName to
> an xml:id,
> an exception is thrown. XOM does not verify, however, that
> these values
> are unique.
>
>
> --
> Elliotte Rusty Harold elharo AT metalab.unc.edu
> XML in a Nutshell 3rd Edition Just Published!
> http://www.cafeconleche.org/books/xian3/
> http://www.amazon.com/exec/obidos/ISBN=0596007647/cafeaulaitA/
> ref=nosim
>
> _______________________________________________
> XOM-interest mailing list
> XOM-interest AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/xom-interest
>





Archive powered by MHonArc 2.6.24.

Top of Page