Comment on Tutorial - wait(), notify() and notifyAll() in Java - A tutorial By Jagan



Comment Added by : sumit

Comment Added at : 2014-10-30 08:14:55

Comment on Tutorial : wait(), notify() and notifyAll() in Java - A tutorial By Jagan
You are using "this" to start to the thread before constructor has completed. Isn't it a wrong practice to use incompletely initialize objects by letting them escape before constructor completes-
Producer(Q q) {
this.q = q;
new Thread(this, "Producer").start();
}


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. hello sir i want to know how to run this pogram as
View Tutorial          By: Pranjay at 2009-01-07 03:33:45

2. ans to 23:
by using gdb(GNU deb

View Tutorial          By: Bhargav at 2011-11-02 13:23:51

3. is there any way to generate report without seagat
View Tutorial          By: Roshni at 2012-10-01 09:32:41

4. clearly explained the pgm logic....
thnx...

View Tutorial          By: Akshaya at 2011-11-24 04:12:36

5. Thanks for the solution. I must say however that t
View Tutorial          By: Pierre at 2009-11-19 20:16:35

6. Can any one help me writing the code...
In

View Tutorial          By: Prajwal at 2011-11-08 10:19:58

7. It is very useful for me guyzz......thanx.......:-
View Tutorial          By: Rajesh at 2012-09-29 10:11:45

8. its nice.. thank you so much.........
View Tutorial          By: rozen at 2010-04-14 11:21:07

9. I have already establish connection with mysql in
View Tutorial          By: shaishav at 2013-06-20 04:27:44

10. Hello, I have a problem
I cant understand s

View Tutorial          By: henry at 2012-01-10 07:53:05