dinesh Archive
The Thread.sleep() method effectively “pauses” the current thread for a given period of time. We used it in our very first threading example to make threads display a message periodically, sleeping between messages. From the …
Features : The JVM schedules using a preemptive , priority based scheduling algorithm. All Java threads have a priority and the thread with he highest priority is scheduled to run by the JVM. In case …
In Java, an object of the Thread class can represent a thread. Thread can be implemented through any one of two ways: Extending the java.lang.Thread Class Implementing the java.lang.Runnable Interface Extending the java.lang.Thread Class For …
When you are programming with threads, understanding the life cycle of thread is very valuable. While a thread is alive, it is in one of several states. A thread can be in one of the …
In this article you can learn the basic steps of creating a thread; this article provides two ways for creating your own thread in Java. Multithreading is a process of executing multiple threads simultaneously. A …
A nested interface is just a regular interface defined inside another class or interface. They are actually defined inside the body of the parent class, not only in the same file. The feature is useful …
A nested class that is declared static is called a static nested class. Memory to the objects of any static nested classes are allocated independently of any particular outer class object. A static nested class …