W3C XML Schema includes the notion of a PSVI - Post Schema Validation Infoset. It allows type information from the schema to be annotated onto the structure passed to the application. Note that the PSVI is controversial see:
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.