what is private constructor?what are the uses of writing
private constructor in our program?
Answer Posted / udaychow
only once instance of a particular class is allowed.through
private constructor only we can achieve singleton design
pattern.
| Is This Answer Correct ? | 8 Yes | 8 No |
Post New Answer View All Answers
What is class and its types?
You can create a string object as string str = “abc”; why cant a button object be created as button bt = “abc”;? Explain
Can you tell me range of byte?
Can Exception handling we can handle multiple catch blocks?
What is variable explain?
Is java util list serializable?
What is the purpose of void class?
In case of inheritance what is the execution order of constructor and destructor?
What is a buffer in computer?
Can you override static methods?
How are java objects passed to a method and what are native methods?
what is synchronization? : Java thread
What are the new features in java 8?
What are runtime exceptions?
Explain wait(), notify() and notifyall() methods of object class ?