Briefly reading over the above article I find that getters and setters are bad OO design and should be avoided as they go against Encapsulation and Data Hiding. As this is the case how can it be avoided when creating objects and how can one model objects to take this into account.
Ccna final exam - java, php, javascript, ios, cshap all in one. This is a collaboratively edited question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
Showing posts with label encapsulation. Show all posts
Showing posts with label encapsulation. Show all posts
Wednesday, April 25, 2012
Getters and Setters are bad OO design?
Subscribe to:
Posts (Atom)