how to handle a singleton service locator. when multiple threads
are trying to get the singleton object in same time
Answer Posted / gowramma m
Two ways to create threads
1)by creating thread class
class classname extends Thread
{
}
2)By converting class to thread ie using Runnable interface
Is This Answer Correct ? | 1 Yes | 7 No |
Post New Answer View All Answers
What is java abstraction with example?
Which is better list or arraylist in java?
How can we create a thread in java?
Why is the singleton pattern considered to be an anti pattern?
What is lambda in java?
why Interface used?
Who developed java?
What is private static in java?
What is the hashcode () and equals () used for?
What does void * mean?
What are the major drawbacks of external iteration?
when to use ArrayList and when to use HashMap in webApplication.
What is the use of string and stringbuffer?
Explain the advantages of packages in java?
What is OOP's Terms with explanation?