Can constructor be synchronized?



Can constructor be synchronized?..

Answer / Neeraj Semwal

Yes, constructors in Java can be declared synchronized to ensure that only one instance of an object can be created at a time. However, it's not commonly used as it can lead to performance issues due to the overhead of synchronization.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

what are the methods of an object class?

3 Answers  


Can java inner class be static?

1 Answers  


How to create a thread in java?

1 Answers  


What are the different types of java?

1 Answers  


Highest level event class of the event-delegation model?

1 Answers  


What is a byte string?

1 Answers  


How do you remove duplicates in java?

1 Answers  


What is the diffrence between inner class and nested class?

1 Answers  


How to display names of all components in a Container?

1 Answers   Microsoft, Wipro,


Define jre i.e. Java runtime environment?

1 Answers  


what is the use of abstract class?

3 Answers   Amdocs, Atos Origin, Invictus,


What is treemap in java?

1 Answers  


Categories