Chapter 11

The Inside Story


check Putting a class inside another class

check Putting strings where they belong

check Using Java's special tricks to avoid programming hassles

In common English usage, an insider is someone with information that's not available to most people. An insider gets special information because of her position within an organization.

American culture has many references to insiders. Author John Gunther became famous for writing Inside Europe and Inside Africa and other books in his Inside series. On TV crime shows, an inside job is a theft or a murder committed by someone who works in the victim's own company. So significant is the power of inside information that, in most countries, insider stock trading is illegal.

In the same way, a Java class can live inside another Java class. When this happens, the inner class has useful insider information. This chapter explains why.

A Button-Click Example

The last listing in Chapter 3 illustrates the industrial-strength way to make a button respond to a click. In Chapter 3, I treat the listing like a black box. I show you the listing, but I don't write much about it.

Now you're reading Chapter 11, and you know a ...

Get Java Programming for Android Developers For Dummies, 2nd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.