jone wars wrote:i need realtime example of singleton class.
when should we go for singleton class???
I agree with everything Manuel said - almost never - however, one well-known use of singletons is for a logger (ie, the encapsulation of a logging service).
For more information, I suggest you read
this.
Winston