Is there any way to achieve the same effect of 'relevant' MIP with XML Schema?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Is there any way to achieve the same effect of 'relevant' MIP with XML Schema?

Sardine Kao
Dear All,

XForms supports two ways of performing validation:

1. With Model Item Properties (MIPs) in the model, called constraint and
type.
2. With an XML Schema. XML Schema is a W3C standard to specify
constraints on XML documents, including constraints on the structure of
the document or on the data types contained.

<xforms:bind nodeset="verification-code" relevant="../type = 'visa' or
../type = 'mastercard'"/>

Is there any way to achieve the same effect with XML Schema?

I means "conditional structure" quoted from
http://xsd.stylusstudio.com/2001Sep/post04015.htm.

Regards,
Sardine Kao.




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: Is there any way to achieve the same effect of 'relevant' MIP with XML Schema?

Erik Bruchez
Administrator
Sardine,

In XForms, validation strictly impacts the "valid" and "type"  
properties, but not relevance.

So the answer is no, at least not out of the box.

You could probably pre-process a schema (e.g. with XSLT) in order to  
produce relevance binds though.

-Erik

On Jan 15, 2009, at 7:34 PM, Sardine Kao wrote:

> Dear All,
>
> XForms supports two ways of performing validation:
>
> 1. With Model Item Properties (MIPs) in the model, called constraint  
> and
> type.
> 2. With an XML Schema. XML Schema is a W3C standard to specify
> constraints on XML documents, including constraints on the structure  
> of
> the document or on the data types contained.
>
> <xforms:bind nodeset="verification-code" relevant="../type = 'visa' or
> ../type = 'mastercard'"/>
>
> Is there any way to achieve the same effect with XML Schema?
>
> I means "conditional structure" quoted from
> http://xsd.stylusstudio.com/2001Sep/post04015.htm.
>
> Regards,
> Sardine Kao.
>
>
>
> --
> You receive this message as a subscriber of the [hidden email]  
> mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> OW2 mailing lists service home page: http://www.ow2.org/wws
--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws