W3C home > Mailing lists > Public > www-forms@w3.org > May 2006

Re: Because type is for datatype, there should not be a problem for XForms Basic

From: John Boyer <boyerj@ca.ibm.com>
Date: Thu, 4 May 2006 13:03:35 -0700
To: "Allan Beaufour" <beaufour@gmail.com>
Cc: www-forms@w3.org, www-forms-request@w3.org
Message-ID: <OFEA5A7EE5.09EF525D-ON88257164.0060293A-88257164.006E30A3@ca.ibm.com>
Hi Allan,

Apologies, I missed your email of April 4 asking for more information 
about my posting.

Because others may not want to go fishing for that email, I'll explain 
again: I asked what other
implementers were doing when a form author attempts to assign a 
non-datatype using the
XForms type MIP.  You responded that you didn't understand the question 
because a datatype
can be simple or complex and then asked what was missing...

The issue is that the notion of datatype is clearly defined in XML schema 
to be a validation
of character string content.

The datatype of string content could come from a simple type or from a 
complex type.

The part I believe you were missing from my last post was that I did not 
make note to the
reader of the fact that complex types can exist for more than one reason. 
Some complex
types still only assign simple content to the elements they describe. 
These are elements
that have no element children (this includes mixed content, of course).

What I am getting at is that the XForms type MIP, by definition, is used 
for assigning a datatype.
This implies that an element being tested for validity against a type MIP 
setting should only 
be reporting the result of the datatype validity (as defined in Schema 
Part 2) even if the type
assigned is complex.  Moreover, I wouldn't expect an XForms processor to 
even test for
type MIP conformance on a node with element children.  I base this opinion 
on the fact that
the default is xsd:string (see section 6.1.1), which cannot validate 
structured data.

I asked what others are doing partly to raise awareness of what the spec 
actually says about
the type MIP because I've heard a lot of comments recently that caused me 
to believe that
at least some folks believed that the type MIP could be used to assign a 
structural complex
type, so I've asked the working group members and implementers to have a 
look at this issue.

John M. Boyer, Ph.D.
Senior Product Architect/Research Scientist
Co-Chair, W3C XForms Working Group
Workplace, Portal and Collaboration Software
IBM Victoria Software Lab
E-Mail: boyerj@ca.ibm.com  http://www.ibm.com/software/

Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer

"Allan Beaufour" <beaufour@gmail.com> 
Sent by: www-forms-request@w3.org
05/04/2006 01:47 AM

John Boyer/CanWest/IBM@IBMCA
Re: Because type is for datatype, there should not be a problem for XForms 

On 5/3/06, John Boyer <boyerj@ca.ibm.com> wrote:
> On the technical question you asked, I think that mixed content would 
never be invalid according to
> the XForms type MIP because XForms type is only for assigning datatypes, 
which means to me that
> the type MIP has nothing whatsoever to do with elements that do not 
contain datatype-able content.

And to me datatypes are both simple and complex schema types.
Regarding that, I asked you what I missed (if anything) in a mail of
April 4th. You never answered.

> The example you give below of xforms:input ref="/data" would actually 
cause a binding to the first
> text node child of the data element, not the data element itself.

That's not true. The binding is to the element, but the displayed
content is the first text node child of data.

JB: True, my mistake.  The data content display *and* exchanged with the 
model is based on the first text node, but validity assessments seem to be 
a bit of a different story, which was the relevant piece here.

... Allan
Received on Thursday, 4 May 2006 20:05:58 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:36:17 UTC