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

Style Guide

 
Michael Hildner
Ranch Hand
Posts: 297
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After reading the response to my first assignment submission, I thought I'd better read that style guide again. Can anyone explain this further:
Hungarian Notation violates OO abstraction and is not to be used.
I know what Hungarian notation is, a little shaky on OO abstrataction.
Thanks
 
paul wheaton
Trailboss
Pie
Posts: 21188
Firefox Browser IntelliJ IDE Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is one that we've covered in some huge detail in the past. Do a search on all forums for "hungarian" to find all that old stuff.
A quick description is that with abstraction, you don't know anything about the innards of a variable. The variable just holds data. If you use HN, you are exposing its innards, so you have lost your abstraction.
There are lots of other reasons to not use HN, most involve refactoring. The search should turn up far more than you ever wanted to know.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic