On 03.Feb.2003 -- 03:13 PM, Stefano Mazzocchi wrote:
> Christian Haul wrote:
> >Currently, we have the sitemap validation schema (relax ng
> >http://www.oasis-open.org/committees/relax-ng ) in a single file. This
> >schema gets only updated when a new sample violates the schema.
> >It is easy to forget updating the schema file and when attempting it,
> >it does take some time to understand it. Even if relax ng syntax is
> >quite simple.
>
> NOTE: the sitemap validation is broken *right now*.
Thought to have fixed that this morning. rechecking ....
<snip what="large example"/>
> >This would require us to create pattern names for all places where
> >components could have configuration data and those pattern names would
> >be re-used. Relax ng allows to "combine" those grammars to one. And of
> >course an common namespace and syntax for the annotations.
> >
> >This would require a) some smart documentation tool that renders the
> >above e.g. to a table, b) an ant task that extracts these grammars and
> >c) an ant task that merges all these grammars to one file.
> >
> >c) could possibly done using the XConfToolTask. b) could be done with
> >a simple awk script like
> > awk '/<grammar>/,/<\/grammar>/{print $0}' in out
> >but that wouldn't be the java way I guess :-)
> >
> >Thoughts?
>
> I like the approach and I would suggest creating a new comment that
> doesn't conflict with javadoc.
>
> What about
>
> // -> single line comment (no machine-readable semantic meaning)
>
> /* ... */ -> multiline comment (no machine-readable semantic meaning)
>
> /** ... */ -> multiline javadoc (automatic documentation generation)
>
> /*<?relaxng?> ... */
> /*<?dtd?> ... */
> /*<?xmlschema?> ... */ -> multiline schemas (configuration files validation)
Looks good to me.
> This has the advantage of being considered a normal comment by editors
> and by javadoc.
Absolutely. Although javadoc seems to ignore unknown tags. Anyway,
your suggestion is cleaner.
> Note that in the future Avalon 5 is going to include XDoclet-like
> metadata and there is also a new JSR about adding user-definable
> metadata to java classes at bytecode-level, so this path of semantically
> meaningful comments will be used more and more in the future.
>
> If you think about it, we are, in fact, adding more 'namespaces' to java
> comments with a nice fallback capability.
>
> what do you think?
I agree completely.
Chris.
--
C h r i s t i a n H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837 7D73 FEF9 6856 335A 9E08
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]