You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xmlbeans-dev@xml.apache.org by "Jayaraman, Babu" <ba...@qwest.com> on 2004/05/21 01:16:09 UTC
XmlObject.Validate ? how to use?
Hello,
Does anyone know how to use validate function on XMLObject? It just
returns true/false, but if I want to capture the reason for failing the
validation it would be really useful.
Thanks,
-Babu
- ---------------------------------------------------------------------
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/
Re: XmlObject.Validate ? how to use?
Posted by David Waite <ma...@akuma.org>.
The reasons for failure are captured within a collection by creating an
XmlObject, calling setErrorListener(Collection) on it, then calling
validate() on your XmlObject. When validate returns false, you can
examine the contents of the collection for error information.
-David Waite
On May 20, 2004, at 5:16 PM, Jayaraman, Babu wrote:
> Hello,
> Does anyone know how to use validate function on XMLObject? It just
> returns true/false, but if I want to capture the reason for failing the
> validation it would be really useful.
>
> Thanks,
> -Babu
>
> - ---------------------------------------------------------------------
> 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/
>
- ---------------------------------------------------------------------
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/
Re: XmlObject.Validate ? how to use?
Posted by David Waite <ma...@akuma.org>.
The reasons for failure are captured within a collection by creating an
XmlObject, calling setErrorListener(Collection) on it, then calling
validate() on your XmlObject. When validate returns false, you can
examine the contents of the collection for error information.
-David Waite
On May 20, 2004, at 5:16 PM, Jayaraman, Babu wrote:
> Hello,
> Does anyone know how to use validate function on XMLObject? It just
> returns true/false, but if I want to capture the reason for failing the
> validation it would be really useful.
>
> Thanks,
> -Babu
>
> - ---------------------------------------------------------------------
> 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/
>
- ---------------------------------------------------------------------
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/