Java & J2EE Page 4 - The Basics of Multiple Threads in Java |
We've come to the end of this part. By now you should know the basics of the two possible ways of creating and managing threads under Java. Actually, this is barely the tip of the iceberg. Try to research the topic of multi-threading in Java and you'll surely learn a lot. And don't forget to practice! Theory without application is null (pun intended). This article is going to be followed by a sequel covering a bit more advanced tasks with threads. We're going to learn how to work with groups of threads, what daemon threads are about, how we can change the states of threads, make them stand by, stop, then resume, and all that-and then, finally, we are going to learn thread synchronization. Synchronization along with locks is really crucial to grasp. Moreover, threads can also intercommunicate between each other. This isn't as scary of a process as it may sound at first. In the next article we're going to present one of the most common problems that is often used to exemplify this process: the producer-consumer example. You won't want to miss it! In closing, I'd like to invite you to join our experienced community of technology professionals who focus on all areas of IT&C, from software and hardware to consumer electronics, at Dev Hardware Forums. As well, be sure to check out the community of our sister site at Dev Shed Forums. We are friendly and we'll do our best to help you. |