Discovering class structure from bytecode

M

Mac

Hi all,

We've been told to build a system to estimate effort on building
new java systems and also on maintenance. Basically it has to
different areas. First: main resources are identified (jsps, servlets,
ejbs, jca, html, etc, etc.). Each one is assigned a complexity based
on some characteristics (number of methods, number of fields, etc). As
a result we get an estimation of effort measured in hours. Well I
sure, it won´t be extremely accurate but it could work...

The other area is more interesting from a technical point of view.
It consists on performing the same estimation once the project is
finished. So, the system should take the binaries or the sources of
the estimated proyect and perform an automatic estimation. Again this
estimation relies on the structure of classes and their relationhips
(number of methods, calls to other methods, etc)

Im looking for a tool that help me to open a jar file and to load
the estructure of all of its classes (from source or binary, it's the
same) so I can get the number and names of the methods of a class, how
many calls to other classes it has, which is its parent class, how
many interfaces does it implement, etc...

I've been taking a look to bcel, maybe it could be usefull.

Any body knows an utility to achieve this??? Thanks!
 
R

Roedy Green

So, the system should take the binaries or the sources of
the estimated proyect and perform an automatic estimation

If you can't find the complexity measuring tools you are after, what
you might look for are tools to parse byte code or parse java to roll
your own. That, however, would be quite a major project and could
well cost you considerably more than you save. It sounds like
interesting work I would like to tackle.

See http://mindprod.com/jgloss/jasm.html
http://mindprod.com/jgloss/parser.html
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top