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?
Virtual class
Abstract class
Singleton class
Friend class
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
104 comments Page 4 of 11.

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.

Kiran said:   1 decade ago
So the class derived as private is called singleton class?

Kamal dhaker said:   1 decade ago
How we create singleton class?

Sonu said:   1 decade ago
What is meant by singleton class?

Ananadan b said:   1 decade ago
How to make singleton class?

Shaju said:   1 decade ago
Singleton means only one instance or object at a time can be created.

Why using (for eg: only one person can open a mailbox from a system using a web browser from a system).

Shaju said:   1 decade ago
Making constructor as private it will not allow any other function even main to create an object. Only inside class, object can be created.

Rohit said:   1 decade ago
What is use of this mainly in c++?

Ramya said:   1 decade ago
I expect that friend, virtual class doesn't access more than one object.

Lakshmi.T.R said:   1 decade ago
Is there any other special features of singleton classes?


Post your comments here:

Your comments will be displayed after verification.