File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ProjectMetrics | Urgent

 
kritika ram
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a certain API whose jar file will be included in the classpath of my project, my manager wants me to find out the number of executable lines of code in the API that is used by my project. I need a utility that can help me with this.
I looked up locmetrics and locc but iam unable to find any software that can find out the number of executable lines in an API that iam using. All of them print the number of lines in my code.

Any help is appreciated. Thanks in advance.
 
Stu Thompson
Hooplehead
Ranch Hand
Posts: 136
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What tools exactly are you using? I would think that you could instruct them via parameters to only look at the jar file in question.

Stu
 
kritika ram
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Iam using tools like locMetrics but should I use code coverage tools like Corbetura and EclipsePro to find the number of lines inside the jar ?

The code is not a JUnit test case but a sample code using the API. The Sample Code is using struts to display the results on a JSP page. But I fail to understand how to use code coverage tools meant for JUnit tests with sample Code.

Thanks again for the help.
 
Stu Thompson
Hooplehead
Ranch Hand
Posts: 136
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
LocMetrics is cute, but clearly only works with source files. One should be able to produce *some* metrics...but not everything that you could get from the source. E.g.: I have integrated lint4j into my build. It works on both java source and compiled classes...but it does not do LoC. As I understand it LoC shouuld be possible but I do not know for a fact.

I've taken a look-see on 'the google' but have not found anything. Sorry.

Maybe a rancher with a bigger cowboy hat than me can help out.

EDIT: Can you get the source to the jar file? That would, of couse, get you the LoC metrics quick like.

Stu
[ October 31, 2006: Message edited by: Stu Thompson ]
 
kritika ram
Greenhorn
Posts: 12
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Stu : thanks.. I found a good code coverage tool called 'Clover'that runs on sample code as well apart from unit tests and it works fine with Tomcat for testing my web application.

I need to test it with bea-weblogic. I hope it works.

Thanks again
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic