commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <>
Subject Re: [clazz] Doclet for metadata? (was: Type-based or instance-based metadata?)
Date Sun, 27 Oct 2002 01:42:33 GMT
Dmitri Plotnikov wrote:
> I appreciate the power of attributes and I think we should consider
> supporting them very seriously.  But before we do that, we need to figure
> out the hourse-cart relationship between [clazz] and doclet-based metadata.
> Will doclets be *the* design for [clazz] or *a* pluggable implementation?

Think of the finished product not in "doclet" style implementations, but in
the bytecode/dynamicly generated metainfo that is stored in/with the source

The "doclet" is only one way of generating the attributes.  You can also do
so with BCEL.  In fact, BCEL would probably be used to generate the new
IClass implementation for the attribute enabled classes.

> If we choose to commit [clazz] to the doclet approach,
> 1. We have to have source code processing as a mandated part of the build
> process.

This can be applied in an ANT task.

> 2. We cannot add or modify metadata for pre-existing or code-generated
> classes.

Sure you can.  You would create the ClazzGenerator that would generate the
Class implementation that accesses the attributes.  The Doclet would use the
ClazzGenerator as one way of generating the attributes.  We would probably
have to use BCEL to generate the attribute classes.

> 3. We still haven't answered the requirements for DynaBeans, Maps where
> there is no source code to augment with doclets.

We don't need source code.  We should never require the sourcecode to exist
for the system.

> IMO, we should allow a doclet-based plug-in, but it should be a
> specialization of a more generic mechanism.

It is merely one face or facade that uses the central mechanism.


"They that give up essential liberty to obtain a little temporary safety
  deserve neither liberty nor safety."
                 - Benjamin Franklin

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message