You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by "Michael Glavassevich (JIRA)" <xe...@xml.apache.org> on 2014/10/03 16:30:33 UTC

[jira] [Comment Edited] (XERCESJ-1646) Report warning when the maxLength limit is exceeded in an enumeration

    [ https://issues.apache.org/jira/browse/XERCESJ-1646?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14158035#comment-14158035 ] 

Michael Glavassevich edited comment on XERCESJ-1646 at 10/3/14 2:29 PM:
------------------------------------------------------------------------

At most this is a warning. It can't be reported as an error.


was (Author: mrglavas@ca.ibm.com):
At most this is a warning, it can't be reported as an error.

> Report warning when the maxLength limit is exceeded in an enumeration
> ---------------------------------------------------------------------
>
>                 Key: XERCESJ-1646
>                 URL: https://issues.apache.org/jira/browse/XERCESJ-1646
>             Project: Xerces2-J
>          Issue Type: Improvement
>          Components: XML Schema 1.0 Datatypes, XML Schema 1.0 Structures
>    Affects Versions: 2.11.0
>            Reporter: Octavian Nadolu
>            Priority: Trivial
>
> If the maxLength limit is exceeded in an enumeration, Xerces engine does not report this error. 
> If I use Saxon engine I get en warning message: 
> "Enumeration value "REQUESTED_CHARGE" is not a valid instance of the type: it contravenes the maxLength facet"
> You can find below a sample schema. I tested on the xml-schema-1.1-dev branch.
> {code:xml}
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
>     <xsd:simpleType name="PaymentStatus">
>         <xsd:restriction base="xsd:string">
>             <xsd:maxLength value="15"/>
>             <xsd:enumeration value="AWAIT_PAY_INFO"/>
>             <xsd:enumeration value="AWAIT_AUTH"/>
>             <xsd:enumeration value="REQUESTED_AUTH"/>
>             <xsd:enumeration value="REQUESTED_CHARGE"/>
>             <xsd:enumeration value="PAID"/>
>         </xsd:restriction>
>     </xsd:simpleType> 
> </xsd:schema>
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: j-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: j-dev-help@xerces.apache.org