Singletone design question

  • Thread starter Thread starter csharpula csharp
  • Start date Start date
C

csharpula csharp

Hello ,
I have a singeltone and I would like to add some methods to it not only
getInstance() but some other logical methods as to a regular class. Is
it bad design?
Thank you!
 
csharpula said:
Hello ,
I have a singeltone and I would like to add some methods to it not only
getInstance() but some other logical methods as to a regular class. Is
it bad design?
Thank you!

The singleton pattern only describes how you handle the creation of the
class, nothing else. You can add anything you want to your class.
 
csharpula said:
Hello ,
I have a singeltone and I would like to add some methods to it not only
getInstance() but some other logical methods as to a regular class. Is
it bad design?

No.

If you did not add any methods to the class, then what was the
point in creating it ??

Arne
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top