Previous Page Next Page Start of Tutorial > Start of Trail > Start of Lesson Lesson Contents

Trail:
Essential Java Classes
Lesson:
Doing Two or More Tasks At Once: Threads



Help on searching
is available.

Search technology
by Excite, Inc.

Customizing a Thread's run Method

The run method gives a thread something to do. Its code implements the thread's running behavior. It can do anything that can be encoded in Java statements: compute a list of prime's, sort some data, perform some animation.

The Thread class implements a generic thread that, by default, does nothing. That is, the implementation of its run method is empty. This is not particularly useful, so the Thread class defines API that lets a Runnable object provide a more interesting run method for a thread.

There are two techniques for providing a run method for a thread:

 
Previous Page Next Page Start of Tutorial > Start of Trail > Start of Lesson Lesson Contents

Michel RIVEILL

Laboratoire I3S - Bât. ESSI
930 Route des Colles
06903 Sophia Antipolis CEDEX

email : riveill at unice.fr

Généralité

Projet Rainbow

Ressources en lignes

Les rubriques des cours :

 

Rechercher sur ce site avec Google

 

dernière mise à jour
le 08 juillet 2003

 

 

Réservation d'Hôtel à Prix Réduits - HotelClub