O'Reilly logo

Java Programming for Android Developers For Dummies, 2nd Edition by Barry A. Burd

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 7

Though These Be Methods, Yet There Is Madness in't

IN THIS CHAPTER

check Matching Java types

check Calling methods effectively

check Understanding method parameters

In Chapter 4, I compare a method declaration to a recipe for scrambled eggs. In this chapter, I compute the tax and tip for a meal in a restaurant. And in Chapter 9 (spoiler alert!), I compare a Java class to the inventory in a cheese emporium. These comparisons aren't far-fetched. A method's declaration is a lot like a recipe, and a Java class bears some resemblance to a blank inventory sheet. But instead of thinking about methods, recipes, and Java classes, you might be reading between the lines. You might be wondering why I use so many food metaphors.

The truth is, my preoccupation with food is a recent development. Like most men my age, I've been told that I should shed my bad habits, lose a few pounds, exercise regularly, and find ways to reduce the stress in my life. (I've argued to my Wiley editors that submission deadlines are a source of stress, but so far the editors aren't buying a word of it. I guess I don't blame them.)

Above all, I've been told to adopt a healthy diet: Skip the chocolate, the cheeseburgers, the ...

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