[Home] [By Thread] [By Date] [Recent Entries]
The first thing I do with a DTD is get rid of the parameter entities. IOW, what I care about is scanning it quickly to figure out the structures. I let the engine do the actual validation. Occasionally, I get these wrong and then I am happy to let the machine correct me. Once a DTD has been heavily parameterized, even where named well, a lot of context disappears. Understand that my task at hand for the first time in my oddly disjointed career is to write the FOSI from scratch without XSLT. Old School. (not my choice; given as a requirement). Having to switch from a DTD-declared system to an XSD declared system, get the business rules from the first and then apply them to the second so the third thing, the PDF rendered document, hides all of that and adds the stuff that the XSDs didn't have slots for (say TMIN numbers, say TOCs, say two way links) and in the output it covers all of that in a standard hierarchically numbered document are part of the "challenge". Note that with the sorta-exceptions of specvals that behave sorta-like if/thens, the programming code is in the editor and renderer black boxes. This is a "data drive it, stupid" *epic* (inside joke). It's been... fun... like hitting one's head against a wall to figure out which wart bleeds first. OTOH, it is a revelation a day about why certain decisions for XML design make sense, when to break the schema, how to apply an out-of-band wrapper document, and so on. As I said: Old School. At times like this I am very glad that I was around when SGML was a draft because I usually know where the hidden rocks are, who made a map of the river and how to read it. In this thread which I read with some entertainment value, I have sympathy for those who have not watched the adventure from jump street. We earned our grey beards one crusty hair at a time. It must be real hell to do it now. I'm orchestrating a Jacques Brel song this month to record later, so the music metaphor is on my mind. He's a great one to study for the surface simplicity of a chord progression enabling an easy melody that gets it's soul and movement from the accidentals in the harmonies. He was a master of tension realized as emotion. Rock and folk just aren't enough these days. So it is with XML: learn until you die at the desktop. len Quoting John Cowan <johnwcowan@g...>: On Mon, Nov 18, 2013 at 11:06 AM, <cbullard@h...> wrote: "So the advantage of DTDs is that they are gibberish to all?"No. The advantage is almost everything a human needs to read to interpret them is in one place. XSD may be richer in types and a parser writer's wet dream, but as a simple human lookup, it [expletive deleted].Sure, but I wasn't comparing DTDs to XSD at all, but to RNG compact syntax. It's true that the pieces can be pretty scattered because you can create arbitrary named patterns, but that's actually *less* arbitrary than parameter entities. The advantage of spreading things out in RNG compact syntax is *so that* you can create better, clearer names, a facility that can obviously be abused.MODERATO (quit bitching about the key signature and just play it).
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] |

Cart



