If Ubuquity supports XML Schema?

3 views
Skip to first unread message

Gogo Liang

unread,
Aug 26, 2009, 11:33:20 PM8/26/09
to Ubiquity XForms Developers
HI All. I have no idea that if the Ubuquity XForms supports XML
Schema? When I do a example, I want to use xml schema file which
identifies some rules and use the way below to import it into my
xforms file.
<xf:model schema="test.xsd" >.......

But it's seen that it can validate the input fields. While many
example I found online, they also use this way to import the XSD fild.
So I have a doubt that if Ubuquity supports XML Schema? If it does,
how to use a XSD file to validate the input fields within xforms? Can
anyone paste a example online?

By the way, How many ways are there integrating Javascript into xforms
and how to integrate?

Thank you in advance!



Mark Birbeck

unread,
Aug 27, 2009, 11:08:23 AM8/27/09
to ubiquit...@googlegroups.com
Hi Gogo,

I'm afraid that UXF doesn't support separate XML schemas.

On the question of incorporating JavaScript into forms, could you ask
that again with a new subject line?

I think that question may generate some useful discussion, so it would
be handy for future readers if there is a separate thread.

Thanks!

Regards,

Mark
--
Mark Birbeck, webBackplane

mark.b...@webBackplane.com

http://webBackplane.com/mark-birbeck

webBackplane is a trading name of Backplane Ltd. (company number
05972288, registered office: 2nd Floor, 69/85 Tabernacle Street,
London, EC2A 4RR)

Gogo Liang

unread,
Aug 27, 2009, 11:54:54 AM8/27/09
to Ubiquity XForms Developers
Thank you for your reply. But I feel a little pity that it does't
support separate XML schemas.

On Aug 27, 11:08 pm, Mark Birbeck <mark.birb...@webbackplane.com>
wrote:
> mark.birb...@webBackplane.com

John Boyer

unread,
Aug 27, 2009, 12:30:10 PM8/27/09
to ubiquit...@googlegroups.com

I'd like to have full schema support as well, and it is feasible, but it's also a matter of feature prioritization.

However, in case you didn't know, Ubiquity XForms does currently offer the "type" attribute to support the basic XML schema datatypes as well as their xforms variants.  So, if you do have a schema that assigns basic datatypes, it would be possible to convert that into some xforms binds with type attributes.
If your schema expresses patterns and other datatype restrictions, it would be more challenging but some of those could be converted to xforms constraint expressions.

So, as far as data validation is concerned, you can get the same functionality to the end user, just with some extra effort being required.  This is part of why the full schema support would not be as high a priority.  The primary focus is on ensuring there is at least one way to serve the end-user, and then of course the choice of which way to do that would be based on how general the solution is and how close to core XForms the feature is.  In the case of type and constraint, they are core XForms features that offer more generalized and powerful data validation than can be obtained from an XML schema.

Anyway, looking forward to the future, if a javascript XML schema engine became available we'd use that obviously, but otherwise I could see structural validation taking a back seat to extending datatype validation.  In other words, it would be faster and most beneficial to focus on reading schemas to find the parts that express datatype validation and then represent those in some way (possibly even as implicit constraints).  The structural validation tends to be less useful in a deployed app because there is often very little to nothing that an end-user can do about it.   Generally, it's the form author's job to design the form in such a way that the user does not run afoul of structural violations.

Cheers,
John M. Boyer, Ph.D.
STSM, Interactive Documents and Web 2.0 Applications
Chair, W3C Forms Working Group
Workplace, Portal and Collaboration Software
IBM Victoria Software Lab
E-Mail: boy...@ca.ibm.com  

Blog:
http://www.ibm.com/developerworks/blogs/page/JohnBoyer
Blog RSS feed:
http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw




From: Gogo Liang <gogo.le...@gmail.com>
To: Ubiquity XForms Developers <ubiquit...@googlegroups.com>
Date: 08/27/2009 08:55 AM
Subject: Re: If Ubuquity supports XML Schema?


Gogo Liang

unread,
Aug 27, 2009, 10:03:27 PM8/27/09
to Ubiquity XForms Developers
Thank you for making such a detailed explanation. If UXF supports XML
Schema, it would be very nice. I hope that we can discuss more about
XForms in the near future.
Reply all
Reply to author
Forward
0 new messages