|
[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message] What exactly does schema-elementJens T Teubner teubner at us.ibm.comThu Nov 8 17:51:59 PST 2007
http://x-query.com/mailman/listinfo/talk wrote on 11/08/2007 04:29:51 PM: > i have a question concerning the difference between element and > schema-element test? I've read the xsd spec at w3c's but still didn't > get behind the meaning of it. Timothy, the test element(n,t) tests whether an element has the name n and the type annotation t. By contrast, the test schema-element(n) looks up the global element declaration for n in your imported XML Schema document. Then, it tests, whether the name of your node under investigation is compatible with that element declaration (substitution groups are respected here) and whether it matches the type that is required in the global element declaration for n. So schema-element() does a bit more in the sense that it does the lookup in the XML Schema document. In the presence of substitution groups, the schema-element() test can also be a bit more permissive than element() (which strictly looks at the element's name). Jens -- Jens Teubner IBM T.J. Watson Research Center 19 Skyline Drive, Hawthorne, NY 10532 +1 914 784 7179
|
Purchase Stylus Studio Online Today!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|






