ensure a class only has one instance and provide a global access point
in java: private constructor, static method with static variable
eg. choco-o-holic
real-world:
- VB form instance
Subscribe to:
Post Comments (Atom)
Design Patterns give you a shared vocabulary to communicate with other developers so they know immediately and precisely the design you are thinking. Think architecture at the pattern level rather than at the object level.
No comments:
Post a Comment