- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
I'm pretty sure that you're looking for this.
Admin
Admin
Sorry, I forgot a detail (long time since I used the language properly):
Admin
Admin
Admin
Admin
Admin
Why such a complicated approach to accessing protected members? C++ provides us with a simpler solution which, by the way, allows accessing private members as well:
#define private public #define protected public
Admin
I know of one vendor, whose response to a customer needing access to something that was private, told the customer to just #define private public
Admin
Admin
Admin
JAVA is like precision tool used in cataract removing surgery. Pray that you never get cataracts.
Admin
Admin
And that's pretty much the story of TDWTF. The problem is almost never the technology, except to the extent it facilitates stupid coding. The real problem is the developers who should never be allowed near a keyboard...
Admin
No, Java and PHP are TRWTF when used...
Admin
"Getters" and "setters" is a good sign that the code is not OOP.
Admin
You could have just done #define private public
Anwyay, there is a way of hiding implementation completely. Have a pointer to another class which the user of the library knows nothing about.
Admin
Or you could simply:
#define private public
I'm really surprised no one has pointed this out before now.
Admin
Admin
What is this called?
Peculiar Object Oriented Programming?