xmlsbeans 2.5 does not check sequence order ?

2011-05-04 Thread philippe . legay . externe
Hello, I parse a xml string, but wmlsbeans does not see that the version element is not present ! I am expecting an exception like I have one when there is a syntax error in the xml string. So my problems with xmlsbeans 2.5 are : - xmlsbeans does not throw an exception when an element of a

Re: xmlsbeans 2.5 does not check sequence order ?

2011-05-04 Thread Jacob Danner
In general xmlbeans will not throw an exception for instances that are invalid according to the schema. If you want to throw an exception on this, try validating the instance with an xmloptions that includes an error listener. If after checking the error list for errors you are concerned with

Re: xmlsbeans 2.5 does not check sequence order ?

2011-05-04 Thread Jerry Sy
read about xmlbeans validation here http://xmlbeans.apache.org/docs/2.0.0/guide/conValidationWithXmlBeans.html I test using this code String testschema = "?xml version=\"1.0\" encoding=\"UTF-8\"?\n" + "xsd:schema\n" + "