Added: 2 years ago
From: questpondvideos
Views: 5,573
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:

All Comments (7)

Sign In or Sign Up now to post a comment!
  • This means we need to add more if else conditions in the FactoryClass if we try to create a new instance of another new class type.

    else if (invoiceType==4){ objnew = new NewClass();

    }

    What is the best way to avoid this situations?

  • A key point is that the Factory class is a singleton. Also, it is worth noting that refactoring breaks existing clients.

  • Could you please also explain the AbstractFactory pattern? This one is awesome.

  • where can I download the source code?

    thanks!

  • Clear explanation thanks :)

Loading...
Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more