November 20, 2008, 07:45:59 am *
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Large Methods: LOC with blanks?  (Read 2473 times)
zubi
Newbie
*
Posts: 3


« on: June 06, 2007, 07:41:58 am »

Hello

While exploring some default queries one thing catched my eye: the query Large Methods seems to count blank lines. Is there a way to filter those?
Logged
Oege de Moor
Newbie
*
Posts: 30


« Reply #1 on: June 06, 2007, 09:11:05 am »

Thanks for your continued interest!

No, as yet there is no information regarding blanks and comments stored in the database. It's not hard to add, of course, so we'll do it soon. As a temporary work-around, you could query for methods that make many method calls instead, which may be a better measure of size than just the number of lines:

Code:
from Method c, int n
where c.fromSource()
      and
      n=count(c.getACall())
      and
      n > 50
select c, n order by n desc


Cheers,

-Oege
Logged
zubi
Newbie
*
Posts: 3


« Reply #2 on: June 06, 2007, 10:56:57 am »

thx for your reply!
Logged
Unpublished
Newbie
*
Posts: 6


« Reply #3 on: October 01, 2007, 09:49:39 am »

Hello,

has this also been added in the new version 0.3.0?
Seem's to me that getNumberOfLines() still is counting blank lines and comments.

Regards
Franz
Logged
Mathieu Verbaere
Administrator
Newbie
*****
Posts: 26


« Reply #4 on: October 02, 2007, 05:59:00 pm »

Sorry, it didn't go into 0.3, but it's coming!
Thanks for bearing with us.

Mathieu
Logged
elnar
Administrator
Newbie
*****
Posts: 17


« Reply #5 on: October 27, 2007, 03:44:58 am »

Dear Franz,

as promised, the new release now counts the right number of lines of code and excludes blank and comment lines. You can also measure the number of lines of code for comments and compute metrics such as "level of documentation". Enjoy!
Logged
Pages: [1]
  Print  
 
Jump to: