Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - Re: Relax NG:table [Thread Next] Re: Relax NG:tableTo: NULL Date: 2/2/2006 4:55:00 PM This is an interesting remark : it seems preferable for an editor to
*suggest* rather than to *force* ; thus, the user would be allowed to
leave a valid state.
I thought that the first <column> could be taken as the model for the
rest of the <table>, but there is certainly a better strategy to compute
the boundaries :
-if there is a single <column>,
min-occurs=0 (or 1 ?)
max-occurs=unbounded
-if there are several <column>s :
min-occurs=max(number of <cell>s in the other <column>s)
max-occurs=min(number of <cell>s in the other <column>s)
So, considering a <column>, the others are "the reference", and you are
*suggested* to converge, either by deleting or adding <cell>s, until all
the <column>s have the same number of <cell>s ; however, even if you are
not suggested to add a new <cell>, you are *allowed* to do so anyway.
This is strange because having min-occurs > max-occurs is possible ; for
the moment I was reporting this case as an error in the schema, but I
could reconsider this (maybe by reporting a warning instead), as it's
only a case where some conditions are not met and can be corrected in
many actions.
I'm still convinced that defining content models dynamically increases
significantly the expressiveness of schemata. This is the power of
Active Schema.
George Bina wrote:
> Hmm, I do not understand what can be predicetd here. The column element
> contains cell and that's all. Assumming you have a table with 2 columns
> and each column with 3 cells. Now if you want to have 4 cells in each
> column no matter where you start you will pass through an invalid state
> so would you prefer to have no hints than to have cell offered as
> possible entry inside column?
>
> Best Regards,
> George
> ---------------------------------------------------------------------
> George Cristian Bina
> <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
> www.---.com
>
--
Cordialement,
///
(. .)
--------ooO--(_)--Ooo--------
| Philippe Poulard |
-----------------------------
http://reflex.gforge.inria.fr/
Have the RefleX !
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
