[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Fun With Schemas
On Mon, 14 Mar 2005 15:55:47 -0600, Bullard, Claude L (Len) <len.bullard@i...> wrote: > This one is fun. I know that a validating editor > can use a schema or DTD to create a valid file. > > Can a program do this for files it creates dynamically? > Are there examples of this? We almost do this... We don't use Schema, we have our own metadata source in a relational DB. We can generate a Schema that maps to the same metadata and in theory should be able to validate the data. In practice we don't do this, we use Schematron (also dynamically generated from the same metadata) to to much more complex checking (including cross document validation). > This question came from a programmer who doesn't want > to hardwire the structure of files she creates into > the code that creates them. I had replied with validation > on input (create the file, validate it then), and what > she actually wants to do is use the schema to drive > the file builder using say, SAX or its analog. Mainly, > she doesn't want to rewrite the code when new versions > of the document inevitably occurs. She just wants to > modify the schema. Works for editors but of course, > they run in human time, but other than performance, I > can't think of a reason WHY she couldn't do it. > > What about it? Performance is tricky. We can justify the hardware on the basis that the data that we are collecting changes on a very regular basis (we collect research data, part of the problem is figuring out what data is relevant). If you don't have a solid business reason for needing this degree of dynamic assembly I'd personally wnat to double (or triple check) check that it was justified. If you really do want to go down this path I wouldn't be surprised if some of the Hibernate related stuff come close to doing what you want directly... -- Peter Hunsberger
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|