xml-xmlbeans-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aleksander Slominski <as...@cs.indiana.edu>
Subject v1: efficient detecting if XML can be mapped to XmlPbject ...
Date Fri, 19 Mar 2004 23:31:07 GMT

one way to check if XML fragment can be mapped by XmlBeans to known 
XmlObject is try to do it:

   try {

            XmlObject response = XmlObject.Factory.parse(xmlString);

        } catch (XmlException e) {
            //not supported

is there some better method? (efficiency)?

if i know QName of top element (or its xsi:type if present) will

!= null) { ... }

be the best way to do such check?



The best way to predict the future is to invent it - Alan Kay

- ---------------------------------------------------------------------
To unsubscribe, e-mail:   xmlbeans-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xmlbeans-dev-help@xml.apache.org
Apache XMLBeans Project -- URL: http://xml.apache.org/xmlbeans/

View raw message