Win a copy of Java Concurrency Live Lessons this week in the Threads forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

call non-synchronized method within synchronized method (or) synchronized block?  RSS feed

 
kri shan
Ranch Hand
Posts: 1488
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can i call non-synchronized method within synchronized method ?

synchronized int A() {
B();

}

int B() {

}

(or) Can i call non-synchronized method within synchronized block ?
 
Henry Wong
author
Sheriff
Posts: 22866
119
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Sure... why not?

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!