How many objects are created for a singleton class
Answer Posted / rajani nagandla
The Singleton is a useful Design Pattern for allowing only
one instance of your class.The Singleton's purpose is to
control object creation, limiting the number to one but
allowing the flexibility to create more objects if the
situation changes. Since there is only one Singleton
instance, any instance fields of a Singleton will occur
only once per class, just like static fields.
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What type of value does sizeof return?
Why use string handling in Java?
What is array size in java?
What is a boolean in java?
What is the public method modifier?
How to create a base64 decoder in java8?
Write a method to check if input string is palindrome?
Explain try and catch keywords in java?
Write a program to print fibonacci series up to count 10.
What are the different ways of implementing thread? Which one is more advantageous?
What is the use of callablestatement?
Can I uninstall java?
what are the disadvantages of indexes in oracle?
What is a line break example?
What do you mean by local variable and instance variable?