Office Document APIs for .NET
ITIL Career Advice
PMP Career Advice
Android Intel XDK
Welcome Guest !
Uses of abstract factory design pattern [Resolved]
on 1/20/2014 |
| Views : 871 | Status :
| Replies : 1
Write New Post
Un Answered Posts
when and in which scenario abstract factory design pattern and how it is different from factory design pattern? what are its advantages? please explain with real world example..
Reply with Attachment
A real life example for the use of the Abstract Factory pattern is providing data access to two different data sources (e.g. a SQL Database and a XML file). You have two different data access classes (a gateway to the datastore). Both inherit from a base class that defines the common methods to be implemented (e.g. Load, Save, Delete).
Which data source shall be used shouldn't change the way client code retrieves it's data access class. Your Abstract Factory knows which data source shall be used and returns an appropriate instance on request. The factory returns this instance as the base class type.
, if this helps please
Mark As Answer
Login to post response
When create Excel file using c# cannot open it
how to resolve it issues
How to resolve this export Issue
How to Solve 'The remote procedure call failed' with reason.
How to sort and paginate the table, Please its very urgent, help me
How to search values while hidden and visible, Please its urgent
How to pass qr image from picture box to RDLC report
What is the advantage of constructor in abstract class c# ?