Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Inheritance

 
Rodger, Gao
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Can anyone help on this?
If I have a parent class with one method in synchronized feature, is the synchronzed feature inherited by its sub class?
Thanks all.
Rodger Gao
 
Mike Birken
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Synchronized methods are inherited as long as they are not private. A non-private synchronized method can be overridded and the replacement method does not have to be synchronized (it is optional).
- Mike
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic