Hi Marcus, Thanks for your submission; we have plan to re-factor the validation API to include better error reporting. We'll make sure we will add your code in the review process.
Thanks, Arnaud > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Thursday, November 21, 2002 11:04 PM > To: [EMAIL PROTECTED] > Subject: [castor-dev] Error messages patch: FieldValidator + PatternValidator > > Not sure if someone is already doing this or not but I added more detailed > error messages for the following two classes: > > org.exolab.castor.xml.FieldValidator > org.exolab.castor.xml.validators.PatternValidator > > > Very minor changes that will produce error messages like the following: > > Message: String: 1234567890123456.1234. Pattern: ^\d{1,15}(\.(\d{1,3})?)?$. > Objects of this type must match the regular expression. > Location: XPATH: Message/Body/BOOKIN/@TotalQuantity > > The @TotalQuantity is a field and was not being added to the > ValidationException as a Location with this attribute (it was unclear what > an attribute really meant in the XPathLocation class, but it seemed like > the "right" thing to do). I also thought it would be nice to see the > original string value the pattern was matching in the message. > > As I am unsure of the convention, I put in the following comments around my > changes: > > // *** Begin MTM changes *** > // [EMAIL PROTECTED] > > ... changes ... > > // *** End MTM changes *** > > I have no problem if those are removed. > > > And thanks for all the hard work that has been done on Castor ... it's a > great tool! > > My aplogies if this not the correct place to submit patches (didn't find > any information about it on the web site - just about cvs commits). > > (See attached file: FieldValidator.java)(See attached file: > PatternValidator.java) > > Marcus > - - > Marcus Malcom > Java Developer > Expeditors International of Washington Inc. > (206) 674-3400 x3585 > [EMAIL PROTECTED] ----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev
