Creational patterns

It can be difficult to control the creation of objects that need complex initialization. In addition, sometimes, we need to decide which object in a class should be created at runtime. This can depend on a state or external values that became known just before a certain moment at runtime, for instance, values that are retrieved from a server or a file. The most common patterns that belong to the creational group are listed here:

  • Factory method
  • Builder
  • Abstract factory
  • Singleton
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.72.74