Nachrichten

Using accessors violates the basic object-oriented (OO) principle of encapsulation, so you should avoid them. This article discusses getter/setter cons and offers an alternative design methodology.