Hide
Meet people who work on similar things as you – get help if you need it Join Siafoo Now or Learn More

Singleton for eclipse Atom Feed 0

In Brief Snippet for the Singleton pattern.
# 's
 1private static final ${enclosing_type} INSTANCE = new ${enclosing_type}();
2
3/**
4 * Default constructor.
5 */
6protected ${enclosing_type}(){
7}
8
9/**
10 * Returns an instance of this component.
11 *
12 * @returns an instance of this component
13 */
14public static ${enclosing_type} get(){
15 return INSTANCE;
16}

Snippet for the Singleton pattern.