LOC in Java

This forum is user-to-user based and not regularly monitored by IDM.
Please see the note at the top of this page on how to contact IDM.

LOC in Java

Postby jdaues » Mon Jan 12, 2009 9:45 am

Can UE count the number of lines of code in a Java file?
(not # of lines in the file, # of lines of code)
jdaues
Newbie
 
Posts: 3
Joined: Mon Jan 12, 2009 9:42 am

Re: LOC in Java

Postby pietzcker » Mon Jan 12, 2009 10:52 am

What's the difference? Just empty lines or also lines that contain only comments? Or...?
User avatar
pietzcker
Master
Master
 
Posts: 241
Joined: Sun Aug 22, 2004 11:00 pm

Re: LOC in Java

Postby jdaues » Mon Jan 12, 2009 11:11 am

yes, something like that...don't count empty lines, comments.
One way to count LOC is to count semi-colons, but that is a bit simplistic.
jdaues
Newbie
 
Posts: 3
Joined: Mon Jan 12, 2009 9:42 am

Re: LOC in Java

Postby jorrasdk » Mon Jan 12, 2009 12:39 pm

Sure, a precise definition of how to count LOC is needed as explained in the Wikipedia article Source lines of code.

If you have a good understanding of your coding standards you could perhaps code a script to count LOC for your projects, but why not use a tool made for this exact purpose ? You might even be able to integrate such a tool with UE as a User Tool.

I have no experience with tools for counting LOC - but these came out on top in a google search:

User avatar
jorrasdk
Master
Master
 
Posts: 275
Joined: Mon Mar 19, 2007 11:00 pm
Location: Denmark


Return to UltraEdit General Discussion