On 18/10/05, Eric van der Vlist <[EMAIL PROTECTED]> wrote:
> > <data type="token">
> > <param
> > name="pattern">\d{4}(-((0[1-9])|(1[0-2]))(-(([0-2][1-9])|(3[0-1])))?)?</param>
> > <param name='flags'>Pattern.COMMENT</param>
> > </data>
> >
> > I'm ignoring the XSD issue for the moment.
> > Does that syntax look OK?
>
> What do you mean by OK?
>
> <param name='flags'>Pattern.COMMENT</param> could have been an option
> but this isn't part of the current spec!
>
> Note that you can have several pattern parameters in which case, it
> wouldn't have been very clear to which pattern param a flags param
> belonged...
OK. Thanks Eric.
>
> In your regexp, you should take care that \d{4} allows any Unicode digit
> not only [0-9]. That's why when you derive token datatypes, it's safer
> to write [0-9] (if that's what you mean).
>
> The other option is to use a xsd:date instead of token.
>
> And if you want to leave days and months optionals, you can make a
> choice between the corresponding WXS datatypes...
Yes, that's what I wanted.
yy[-mm[-dd]] was the goal.
I gave up on WXS dates.
Thanks for the hint on \d.
What do you think of an extension library for relax NG?
erng?
regards
--
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk
------------------------ Yahoo! Groups Sponsor --------------------~-->
Most low income households are not online. Help bridge the digital divide today!
http://us.click.yahoo.com/cd_AJB/QnQLAA/TtwFAA/2U_rlB/TM
--------------------------------------------------------------------~->
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/rng-users/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/