OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] A XSD regex to allow a QName in Clark form

It's the one I've tried, without success.
Best, Tom.

Le 2017-09-14 09:56, yamahito a écrit :
<xs:pattern value="Q?\{[^\}]+\}[^:\{\}]+"/>

On Thu, 14 Sep 2017 at 7:55 am, <cmarchand@oxiane.com> wrote:

Hi !

I'm not a regex killer, especially when regex flavour is not the one
use on my linux box...

In a schema, I need a simple type that allows a QName, written
"prefix:localName" or in ClarkeForm "Q{nsUri}localName", or in
the-last-one-I-cant-remember-the-name "{nsUri}localName"

I've started with the one available in XSD schema :

<xs:simpleType name="QName">
<xs:documentation> A QName. This schema does not use the
type xs:QName, but rather defines its own QName type. Although
would define the correct validation on these attributes, a schema
processor would expand unprefixed QNames incorrectly when
the PSVI, because (as defined in XML Schema errata) an unprefixed
xs:QName is assumed to be in the default namespace, which is not the
correct assumption for XSLT. The data type is defined as a
of the built-in type Name, restricted so that it can only contain
colon which must not be the first or last character. TODO: change
implementation to allow use ClarkeForm </xs:documentation>
<xs:restriction base="xs:Name">
<xs:pattern value="([^:]+:)?[^:]+"/>

But my pattern for ClarkeForm isn't correct :
<xs:pattern value="Q?\{[^\{]+\}[^:\{\}]+"/>

Any help will be appreciated.
Thanks in advance,

XML-DEV is a publicly archived, unmoderated list hosted by OASIS
to support XML implementation and development. To minimize
spam in the archives, you must subscribe before posting.

[Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
Or unsubscribe: xml-dev-unsubscribe@lists.xml.org
subscribe: xml-dev-subscribe@lists.xml.org
List archive: http://lists.xml.org/archives/xml-dev/
List Guidelines: http://www.oasis-open.org/maillists/guidelines.php

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS