4 ms·
Lazy Initialization in Java - Surprisingly Tricky
- bgrainger 14y agoThe list of proposed solutions is missing the single-element enum type approach: http://stackoverflow.com/a/71399 http://stackoverflow.com/a/71399
- antrix 14y ago(author here) Two points, (a) I was describing general lazy initialization, not just Singletons and (b)I believe the Enum approach is not lazy.