Difference between abstract factory pattern and factory
method pattern in .NET with example.

Answer Posted / nitin

Abstract factory pattern is used when you do not want the user to change the existing factories, instead allow him to plugin his factory class to create abstract object. Aim is to keep default framework from changing.

Factory method is used when you give the control of the entire framework to user, and he can add new methods to the factory (inorder to create new object type)

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many types of server controls do we have?Also explain differance between them taking an example of ASP.NET?

2571


What is asp.net mvc5? : Asp.Net MVC

758


Describe the events in the life cycle of a web application.

804


What are the three parts of an http response?

700


What is a postback in asp net?

794


How do I debug an asp.net application that was not written with visual studio.net and that does not use code-behind?

742


What are validator? Name the validation controls in asp.net?

729


Describe the diffeerence between inline and code behind?

726


In a Repeater control how one can provide an alternating color scheme ?

780


Are there any resources for drop-in replacements for the default css that comes with the ASP.NET Website template?

747


What is difference between view state and session state?

666


In Data grid the question is below quantity price total these are 3 fields available in data grid if you enter quantity the total has to update automatically.Price field is already filled completely

1764


What are server objects?

708


How can exception be handled with out the use of try catch?

740


Which asp.net objects encapsulate the state of the client and the browser?

783