This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes XML and Related Technologies and the fly likes Checking XSD constraints at runtime Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Checking XSD constraints at runtime" Watch "Checking XSD constraints at runtime" New topic

Checking XSD constraints at runtime

Mike Himstead
Ranch Hand

Joined: Apr 12, 2006
Posts: 178

I'm looking for an XML binding framework with a certain feature. What I'd like to have is a possibility to create objects from an XML scheme which know there constraints so I can check them at runtime. I don't want to unmarshall the objects and validate against the XSD.
[ June 21, 2006: Message edited by: Mike Himstead ]
Robert Hayes
Ranch Hand

Joined: Oct 24, 2004
Posts: 116
Check out XMLBeans.

There are various ways to do validation at runtime. Just make sure you read the validation documentation because it's "off" by default.

Here's the validation documentation.

[ June 19, 2006: Message edited by: Robert Hayes ]
Purushoth Thambu
Ranch Hand

Joined: May 24, 2003
Posts: 425
There are quite few data binding implementations available like castor, jaxb. Before you decide on which one to use it's better to look around to see the performance of these binding solutions. You can find really nice article about performance of varioud binding solutions in IBM's developerswork.]Various data binding frameworks overview]Performance of various of data binding frameworks
[ June 19, 2006: Message edited by: Purushothaman Thambu ]
I agree. Here's the link:
subject: Checking XSD constraints at runtime
It's not a secret anymore!