[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: RE: working with text (was RE: XPath 1.5?)


xpath examples text
> At 12:45 PM 5/7/2002 -0400, Simon St.Laurent wrote:
> 
> >It's very useful because the representation doesn't _require_ you to
> >process it in a particular way.  The looseness of the representation (as
> >Uche pointed out earlier) is actually a benefit for exchanging XML among
> >diverse processing environments.
> 
> Please illustrate this benefit with an example that is concrete enough to 
> evaluate. Show me an example where the typing of XPath 2.0 gets in your way.

Better.

The strong typing of XPath 2.0 makes it harder to understand and implement XPath 2.0.  Furthermore, the fact that XPath 2.0 has built in the concept of datatypes according to the XSDL canon forces out the development of generic typing for XPath.

Your earlier example:

avg( input()//person/salary )

I have no problem with your being able to take advantage of the knowledge that in your application context, this can be verified, optimized, and treated in various ways as befit some useful physical representation of the data.

Now, if I want to declare 

<irrnum>3.14</irrnum>

As an irrational number, and use the same capacity for verification, optimization, and treatment, can you tell me how to do so in standard XSDL and standard XPath 2.0?

The answer is that you cannot.  Why?  Because I cannot write a standard constraint of irrationality, since the XSDL group in their wisdom decided this is not an interesting data type.  I cannot even use their paltry extension mechanism for doing so.  I cannot use standard facilities for the optimization that you trumpet so loudly.

If we had a generic constraint mechanism, which might or might not be part of a schema definition language, and if this mechanism were modular enough not to overwhelm the basis of the XML specs that provided facilities for it, then I would have no complaint about addressing what I understand from this thread to be the sorts of use cases that drove XQuery, XPath 2.0 and XSLT 2.0.


-- 
Uche Ogbuji                                    Fourthought, Inc.
http://uche.ogbuji.net    http://4Suite.org    http://fourthought.com
Track chair, XML/Web Services One (San Jose, Boston): http://www.xmlconference.com/
DAML Reference - http://www.xml.com/pub/a/2002/05/01/damlref.html
RDF Query using Versa - http://www-106.ibm.com/developerworks/xml/library/x-think10/index.html
XML, The Model Driven Architecture, and RDF @ XML Europe - http://www.xmleurope.com/2002/kttrack.asp#themodel



PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.