I would need a tool which create an xml containing metadata of java classes.
With metadata, i mean informations you could get with the reflection api (java.lang.reflect) ... a thing like this :
<class package="org.my.package" name="MyClass">
<annotations>
<annotation typeRef="javax.ejb.Sateless">
</annotations>
<implementedInterfaces>
<implementedInterface typeRef="org.my.package.LocalInterface"/>
<implementedInterface typeRef="org.my.package.RemoteInterface"/>
...
</implementedInterfaces>
<attributes>
<attribute typeRef="java.lang.String" name="stringValue"/>
...
</attributes>
<methods>
<method name="doSomeServiceImplementation" returnTypeRef="org.my.package.MyDto">
<annotations>
<annotation typeRef="java.lang.Override"/>
</annotations>
<parameters>
<parameter name="someParameter" typeRef="java.lang.String"/>
<parameter name="anotherParameter" typeRef="java.lang.Integer"/>
...
</parameters>
</method>
</methods>
</class>
and so on ... This portion of xml is an example of what i would like to obtain.
The javadoc uses this kind of metadata, surely ... But an html files package is not usable for us : we want to query the metadata in order to build a services directory.
Parsing html's javadoc with this goal is tedious.
I could also build a so xml file with a service which will look over classloaders, and the java.lang.reflect will do the rest ...
But it's tedious too, and I'm sure there's someone, somewhere, who has solve this problem.
If you know a tool ... It'd be great !
Thank's guyz ! Thank's girlz too ;)
Steve
No comments:
Post a Comment