I've been working on getting the Schema timeDuration and timeInstant datatypes 
for Xerces-J going over the weekend.  To do
enumeration and bounds checking, the attribute value and its constraints have 
to be normalized to a common unit of measure, say
milliseconds.  Once that's done and the value is determined to be valid, it 
would seem a shame to just throw that normalized value
away.  Many applications will have to normalize it again to make any use of it.

So, I'd like to propose a change to the datatype validator API.  Currently, the 
xValidator.validate() methods accept a String and
return void.  I'd like to see that changed to both accept and return an int 
that would be a StringPool index.  The StringPool object
itself would be passed via the constructors when they are invoked by 
XSchemaValidator.  The validate method could return either a
new index corresponding to the normalized value, or simply return the original 
value index.  The whole thing could be turned on or
off via a 'normalize-attribute-values' feature.

Comments anyone?  FYI: I've got timeDuration working pretty well and should 
have timeInstant in a day or so.  I'll post the diffs
using the current method signatures and leave the proposed change for possible 
later value added.

george

Reply via email to