[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Subject: Re: [relax-ng] RELAX NG 2.0 ideas
Here are my base-document proposals for James's ideas. James Clark scripsit: > 1. Repeat M-N times (issue 11); I think this is particularly useful with > regexes, so if we add regexes along the lines that John C proposes, then I > think the balance tips towards these XML syntax: <repeat min="5" max="7"> ... </repeat> Compact syntax: repeat 5 7 { ... } > 2. Richer delimiters for <list> (issue 34); maybe relevant for DSDL > datatypes Introduce a split pattern, where the first child is a regex pattern and the remaining children are the patterns of the split-off portions: XML syntax: <split><regex> ... </regex> ... </split> Compact syntax: split regex { ... } > 3. A way to reference a pattern overriding a particular attribute as XML > Schema allows with xs:restriction (issue 52). This seems too special-purpose and unclean. What if there are multiple attribute name="foo" patterns in a definition? Are all overridden? Why do attributes get magic status, just because XS gives them such? > 4. Better ways to do references between separate grammars (roughly issue > 55); something more like xs:import. I think that this should be left to XPointer and Son-of-RFC-3023. > 5. Mechanism to constrain mixed content, at least the character repertoire > (issue 41). Regexes handle this fairly well though not perfectly. > 6. concur (issue 15) Bring it back as it was before. > 7. Some way to do exclusions (issue 16) Use concur, or else something like: <exclusion> pattern1 pattern2 </exclusion> which matches whatever pattern2 matches, unless some subtree matches pattern1, in which case it fails. > 8. Regexes (along the lines suggested by John C) [obviously] We might want to use something like http://www.w3.org/TR/charcol/ to specify character ranges nicely: the concepts of kernels and hulls are potentially very useful. > 9. A way to define/ref name classes XML syntax: <defName name="..."> ... </name> <refName name="..."/> Compact syntax: name ... = ... name ... (Does this ambiguity create a problem? I think not.) > 10. A better restriction on <interleave> (issue 40); the current one forbids > some useful things > > 11. A less free-wheeling approach to annotations This is too vague to comment on. > 12. Type assignment: a way for the schema to say that it wants > elements/attributes in the instance to be unambiguously associated with > element/attribute patterns in the schema, particularly in conjunction with > 11 > > 13. Parameterized patterns (issue 8) It seems to me that parameterized patterns can be expressed as grammars with the params as separate rules. -- John Cowan <jcowan@reutershealth.com> http://www.reutershealth.com I amar prestar aen, han mathon ne nen, http://www.ccil.org/~cowan han mathon ne chae, a han noston ne 'wilith. --Galadriel, _LOTR:FOTR_
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]
Powered by eList eXpress LLC