Program on if static synchronized method is executing then other static synchronized method won't executing but static non synchronized...
Read More
92 Program with synchronized and non-synchronized thread in Java
Code : class Institute { synchronized public void classRoom( String facultyName ) { for(int i=1;i<=10;i++) ...
Read More
91 Program on Synchronization in Java 1
Code : class Institute { synchronized public void classRoom( String facultyName ) { for(int i=1;i<=10;i++) { Sy...
Read More
89 How can we Call Join on Main Thread in Java?
Code : public class Test extends Thread { static Thread mt = null; // Main Thread @Override public void run() { tr...
Read More
88 Program on sleep() of java.lang.Thread in Java?
Code : public class Test extends Thread { @Override public void run() { try { System.out.println("run: &q...
Read More
87 Program on Java.lang.Thread.join() - Java Thread Join in Java ?
Code : public class Test extends Thread { @Override public void run() { for(int i =1;i<=10;i++) System.out.printl...
Read More
86 Program to check which method is executing by which Thread in Java?
Code : package Atharva; public class Test extends Thread { @Override public void run() { System.out.println("run:...
Read More
85 How Can We Define Multiple User Define Threads by Using Thread Class and Runnable Interface?
Code : class MyThread implements Runnable { @Override public void run() { for(int i=1;i<=10;i++) System.out.println...
Read More
84 How to develop user define thread in Java?
By Directly Writing Logic in Run Method Code : class MyThread extends Thread { @Override public void run() { for(int i=...
Read More
Subscribe to:
Posts (Atom)