What is singleton class?
Answer Posted / ashish srivastava
public class Singleton {
private static Singleton s = new Singleton();
private Singleton(){
}
public static Singleton getObject(){
return s;
}
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can we create more than one object singleton class?
What do you understand by abstract classes?
Can You Have Virtual Functions In Java?
What is a values collection view ?
What are different types of encoding?
What is the use of accept () method in java?
How many types of keywords are there?
Why static functions are used?
What is a dynamic array java?
Where to store local variables?
Is a method a procedure?
What is a parameter in a function?
how to prepare for IT Officers Interview in Banks
What is return code?
What is string builder?