• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Is it a great technique to reduce the documentation?

 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok...ok... it may seems a stupid note but according to the assignement

javadoc style comments must be used for each element of the public interface of each class


I understood correctly that this mean that doing a better analisys of the code to reduce the visibility of methods and setting them as much as possible to private improve the code but also reduce the documentation to write, right?
 
Ranch Hand
Posts: 288
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Maurizio Nagni:

I understood correctly that this mean that doing a better analisys of the code to reduce the visibility of methods and setting them as much as possible to private improve the code but also reduce the documentation to write, right?



I think that it is a good programming practice (ie good encapsulation)to limit the number of public methods in a class to only those methods that clients will need to use the class effectively. As you point out this also has the benefit of reducing the number of javadoc comments that you would need to write. It would still be a good idea to comment all protected and private methods and variables, but regular coments would do fine for this purpose.
 
Maurizio Nagni
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes... i agree that anyway is a good thing to have a proper style to code.... i hate when i do "ctrl-space" in my NetBeans and i discover that the most of the opensource code documentation is empty.... oh well... that's another point. Dot.
 
Looky! I'm being abducted by space aliens! Me and this tiny ad!
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic