users@jaxb.java.net

On Demand Validation Errors

From: Marcus Walls <marcus.walls_at_ASPECTIVE.COM>
Date: Fri, 17 Jan 2003 10:47:51 -0700

I am finding it difficult to retrieve helpful error information
when on-demand validation fails, regarding the source of the error.

I am using the ValidationEventCollector and when a validation
error occurs I retrieve the validation events correctly, but the
location information received via the ValidationEventLocator
interface does not seem to provide enough information to determine
the cause of the error.

The getObject method on the ValidationEventLocator will correctly
return the object in which the error occurs, but there appears
to be no way to determine which element is causing the problem.

I get the message:

  "the length of the value is 19, but the required maximum is 16"

When I would like to get something like:

  "the length of <myValue> is 19, but the required maximum is 16"

Is there any way round this?

Thanks

Marcus