Question
a.
Singleton classes should be used whenever it is important that only a single instance of a class exist and that that single instance be widely accessible
b.
The Singleton pattern can also be used, with slight modifications, when a limited number of instances greater than one are desired
c.
Access restrictions are usually easy to add by restricting the visibility of either the class or the factory method
d.
All of the mentioned
Posted under Software Architecture and Design
Engage with the Community - Add Your Comment
Confused About the Answer? Ask for Details Here.
Know the Explanation? Add it Here.
Q. Which of the following are true for the singleton class?
Similar Questions
Discover Related MCQs
Q. Which of the following are true for prototype pattern?
View solution
Q. Any class using the built-in cloning mechanism is supposed to do which of the following?
View solution
Q. Which of the following are correct for copy constructor?
View solution
Q. Which of the following pattern has Step up phase as its activity?
View solution
Q. What happen in the operational phase of Reactor pattern?
View solution
Q. The reactor patterns provide a good model for event-driven portions of a program for which of the following reasons?
View solution
Q. Which of the following are consequences for command pattern?
View solution
Q. Which among these are advantages for Function Class?
View solution
Q. Which of the several aspects of the Command pattern may be varied or elaborated to help achieve particular design goals
View solution
Q. Which of the following are the consequences for Command pattern?
View solution
Q. Which of the following is incorrect?
View solution
Q. Which of the following are true?
View solution
Q. Which of the following is incorrect?
View solution
Q. Which of the following is correct?
View solution
Q. Which of the following is correct?
View solution
Q. Which of the following is incorrect?
View solution
Q. Which of the following is correct?
View solution
Suggested Topics
Are you eager to expand your knowledge beyond Software Architecture and Design? We've curated a selection of related categories that you might find intriguing.
Click on the categories below to discover a wealth of MCQs and enrich your understanding of Computer Science. Happy exploring!