• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Preliminary Project Stats - 2

 
Anton Golovin
Ranch Hand
Posts: 476
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry, I already posted a topic to this effect, which I deleted. This is the exact, more or less, project stats:

Total lines of code: 4391.
Total programming lines of code: approx. 2000
Commends: approx. 2391

Classes: 19 to 21, I am still considering merging some classes (originally had a verifier class that I am probably going to merge.)

Functionality is hidden behind interfaces.

Values are hard-coded into classes, some find themselves in a DataUtilities class, which holds some of centralized functionality.

Please comment if maybe you think I am underdoing it. The system works quite well, although I am still to implement a data model from AbstractTableModel.

Patterns used: Adapter to ease the Data class into business logic. MVC for the GUI.

Thanks.
[ September 21, 2004: Message edited by: Anton Golovin ]
 
Robert Chisholm
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For what it's worth I totalled what I've recently ripped up in the last 3 weekends as a "release candidate":

18 classes/interfaces total, 2223 lines of code.

That's with 1/3 the comments required (yes, Bad Me).

I used a couple custom exceptions and the following patterns: Service Locator, DAO (esentially Adapter), DTO, and MVC.

Regards,
 
mike acre
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can not believe you've used those patterns and managed to weigh in with just ~20 classes. I've used similar patterns and got 50 top level classes/interfaces.
 
Joakim Eriksson
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Robert Chisholm:
For what it's worth I totalled what I've recently ripped up in the last 3 weekends as a "release candidate":

18 classes/interfaces total, 2223 lines of code.

That's with 1/3 the comments required (yes, Bad Me).

I used a couple custom exceptions and the following patterns: Service Locator, DAO (esentially Adapter), DTO, and MVC.

Regards,


Very impressive (lean code) metrics. My project metrics is around 5500 lines of code, and about 30 top-classes, and that is w.o. Javadocs (but with inline comments). I'm currently trying to refactor the app to a smaller footprint. Especially my gui code is very verbose (50% of the app).
I have six packages: db, net, gui, gui.controller, domain and util

/J
 
Mike Vess
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Whow!! A whole lot of code! This is my statistics and ALL coding is done:

Packages: 5
Classes: 20
NCSS (Non Commenting Source Statements): 1052

Have i missed something? Why is your program code 2000+ lines?
 
mike acre
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm astounded! ~1000 lines of code!

Mine was 3200 NCLC over 50 classes.

I suppose if you haven't used transfer objects with a very minimal GUI, no caching, perhaps just Data & interface - it is about possible.
I know I've been purporting a minimalist design, but that doesn't mean I took my own advice! And that is probably why I'm still waiting for the result.
[ September 21, 2004: Message edited by: mike acre ]
 
Hanna Habashy
Ranch Hand
Posts: 532
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all:
IMHO, software should not be measured with the size and the number of lines of code -of course unless it is abslutely required. One can do the whole project under one thousand line of code and in one or more classes, however it doesn't mean it is a good written code. A software should be measured of how easy it is to be mentained and extended. What I am trying to say is more code that easy to mentain and extend is much better than a compact code that no one can understand.
 
Mike Vess
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I suppose if you haven't used transfer objects with a very minimal GUI, no caching, perhaps just Data & interface - it is about possible.


Minimal gui? I dont know. I have four dialogs, create booking, update booking, book room and database setup. I think that i have done a lot more GUI code than necessary.

I am using RMI for communication and that reduces the amount of code compared to if i had used serialization instead.
 
mike acre
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Hanna Habashy:
IMHO, software should not be measured with the size and the number of lines of code


I think that goes without saying. I am taking it as read that all the designs are basically good, which of course they may not be. Without writing huge replies explaining designs, of course this is a fairly pointless exercise.
 
Robert Chisholm
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I wasn't trying to keep the classes/codebase small really. I treated it like "another project at work". So it just turned out that way.

Also, the B&S project sounds easier than some of the other projects I've heard about.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic