O'Reilly logo

Covert Java™: Techniques for Decompiling, Patching, and Reverse Engineering by Alex Kalinovsky

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Hacking Non-Public Methods and Variables of a Class

 

“Anything can be made to work if you fiddle with it. If you fiddle with something long enough, you'll break it.”

 
 --Murphy's Technology Laws

The Problem of Encapsulation

Encapsulation is one of the pillars of object-oriented programming. The purpose of encapsulation is separation of the interface from implementation and modularity of application components. It is generally recommended that you make data members private or protected and provide public accessor and mutator functions (also known as getter and setter functions). It is also ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required