The source code for the method is in the class that is used to create the applet. Still, it's better to think of the instance method as belonging to the object, not to the class. The non-static subroutines in the class merely specify what instance methods objects created from the class will contain. The messages that they scroll can be different. As you can see, the static and the non-static portions of a class are very different things and serve very different purposes.
Many classes contain only static members, or only non-static.
However, it is possible to mix static and non-static members in a single class, and we'll see a few examples later in this chapter where it is reasonable to do so. By the way, static member variables and static member subroutines in a class are sometimes called class variables and class methods , since they belong to the class itself, rather than to instances of that class. This terminology is most useful when the class contains both static and non-static members. So far, I've been talking mostly in generalities, and I haven't given you much idea what you have to put in a program if you want to work with objects. Let's look at a specific example to see how it works.