C++ Programming - OOPS Concepts - Discussion
Discussion Forum : OOPS Concepts - General Questions (Q.No. 1)
1.
Which of the following type of class allows only one object of it to be created?
Discussion:
104 comments Page 3 of 11.
Jagdish said:
5 years ago
If a class has only one object created and that is the only object of the class. Then the object is known as the singleton object.
(7)
Harsh Nandal said:
7 years ago
Singleton class is a class that can have only one object/element/instance at a time and is designed to control object creation.
Manish singh said:
1 decade ago
When class having only one class is called singleton class;
Means that single=means one it means that required of one object.
Means that single=means one it means that required of one object.
Deepu George Jacob said:
1 decade ago
Singleton class mainly used to limit object creations. Singleton class return only single object for all the declarations.
Lalit Kumar Soni said:
1 decade ago
I can't understand following statement:
static A* m_objA;
And Also term Singleton & Longer class.
static A* m_objA;
And Also term Singleton & Longer class.
Ganesh Vahinde said:
1 decade ago
The singleton class is such class which has only single instance, so that it's know as singleton class.
Nilesh said:
1 decade ago
Using any class we can create any number of objects 1, 2, 3. So on then why to use singleton class?
Abc said:
1 decade ago
The names of variables, function, labels and various other user-defined objects are called what?
JesusPriya said:
1 decade ago
What is singleton class?
Ans: A class which is having single object known as singleton class.
Ans: A class which is having single object known as singleton class.
Awadh said:
1 decade ago
Please elaborate the functioning and use of this class, not getting properly.
Thanks.
Thanks.
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers