aspose file tools*
The moose likes OO, Patterns, UML and Refactoring and the fly likes differences between abstarct factory pattern and factory method Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » OO, Patterns, UML and Refactoring
Bookmark "differences between abstarct factory pattern and factory method" Watch "differences between abstarct factory pattern and factory method" New topic
Author

differences between abstarct factory pattern and factory method

shambhu lingam
Greenhorn

Joined: Sep 26, 2002
Posts: 3
can someone throw light on differences between abstract factory pattern and factory method pattern?.
i have a feeling(may be a wrong idea) that they both can be used in the same context .
thanks
Shambhu Lingam
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
http://c2.com/cgi/wiki?FactoryPattern


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Malay Thakkar
Ranch Hand

Joined: Jun 22, 2000
Posts: 52
Abstract Factory Pattern
Abstract Factory is a tool kit; the usage is when you want to create related objects.
Factory Pattern
This pattern helps to model an interface for creating an object which at creation time can let its subclasses decide which class to instantiate. We call this a Factory Pattern since it is responsible for "Manufacturing" an Object. It helps instantiate the appropriate Subclass by creating the right Object from a group of related classes. The Factory Pattern promotes loose coupling by eliminating the need to bind application-specific classes into the code.
From the intent perspective, there is nothing similar about the two.
Regards
Malay
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: differences between abstarct factory pattern and factory method