At 21:02 26/04/2002 +1000, you wrote:
>Bert Van Kets wrote:
> > I have been updating the sitemap DTD, using the
> > src\webapp\resources\entities\sitemap-v02.dtd file, and found that a 
> lot of
> > attributes and elements are missing.  ex. the logger attribute is not 
> present.
>
>Beware. Note the comments in the top of the DTD, wherein
>it says that the DTD has been reverse-engineered from
>the *.xmap files at that time. Note also that the DTD is
>deliberately lax, because it was just trying to document the
>structure rather than set up strict validation rules. That was
>seen as the first step.

I saw the mention and tried it in XMLSPy myself.  The result is 
awful.  Attributes and child elements that are present are always set as 
obligatory.  I would have to go through the whole list and adjust nearly 
everything.  I'd rather reverse engineer by hand.


> > I did it to use this DTD in XMLSpy to see all the possible attributes and
> > child elements of a given element.
>
>Great idea. At the time of the last revision, i was hoping
>to sort it out, so that i could use a tool that reads a DTD and
>automatically generates some user documentation. I also
>expected that XML validation was a crucial component.
>However, no-one seemed interested at the time.

With the new "documentation Manager" things might change ;-)


> > Is there a specific reason why the DTD is out of sync with the current
> > sitemap, apart from that fact that Cocoon doesn't use the DTD.
>
>It has always been out of sync. A few brave souls have tried
>to update the DTD following on from some discussion item
>on the list.
>
>It seems that all work must happen in the actual Java classes.
>Design work, adding new elements and attributes, seems to
>not happen in XML-land.
>
>On occasion this makes me wonder if there is too much
>programmatic focus in Cocoon and not enough utilisation
>of the magic of reliable XML. If the build process, and sitemap
>generation process, started with a validation run then surely
>the Java code could rely on that and so be more efficient.
>
> > Does anybody have a full up-to-date sitemap DTD?
> >
> > If it doesn't exist yet I will update my file using all the existing
> > sitemaps in the current CVS HEAD and commit the new file.
>
>Please, please do. Other ways to verify the DTD would be
>to compare with xdocs for generators, transformers etc. and
>also with the various Javadocs. If you can manage some
>tweaks to xdocs as you go, then that would be fantastic.

Doing my first real project in Cocoon I noticed a chronic lack of 
up-to-date documentation regarding possible parameters, attributes, child 
elements, ...
Whenever I found something I adjusted my local CVS copy with a "my docs" 
section.
Going through the API docs is indeed the best way of getting an up-to-date 
DTD.  If I adjust the xdocs at the same time, we will have up-to date 
docs.  The only problem that remains is that my day is only 24 hours long :(
(come to think of it, my day is only 12 hours long, the other 12 belong to 
my wife :-))

Anyway, I'll get cooking up the DTD and see where I go from there.

Bert


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to