开发者

What are the advantages of MVC over 3-Layer Architecture in web applications?

开发者 https://www.devze.com 2023-01-03 23:39 出处:网络
Please note that I\'m referring to 3-layer (logical layering) and not 3-tier (physical). Also don\'t get it开发者_开发技巧 wrong I\'m not obsessed with design patterns. I\'m a computer science studen

Please note that I'm referring to 3-layer (logical layering) and not 3-tier (physical).

Also don't get it开发者_开发技巧 wrong I'm not obsessed with design patterns. I'm a computer science student and they've asked me this trick question so I'm trying to find a smart answer.

Thanks for you answers in advance!


They're not competing idealogies, MVC traditionally deals with the presentation layer of an app, i.e. one of the three layers.


MVC is all about seperation of concerns - but deals with specifics in that the View is loosely-coupled to the model and controller; with 3-tier this is not explicitly required.

Yes - you can (and should) have all three tiers loosely-coupled but that's not explicitly required by 3-Tier; with MVC it is.

As an aside: MVC is a specific pattern that looks at a specific issue, I would be careful when referring to it as an "architecture".

An advantage of Microsofts ASP.NET MVC implementation is that is offers various integration points and flexibility which aren't so easily accessible with "standard" ASP.NET - which I guess you could say was/is traditionally used when build web-based 3-trie systesm in the MS space.


The reason the question is a trick on is that MVC is a three layered design.

Model is the database, View is the UX and Controller is the Application Layer.

0

精彩评论

暂无评论...
验证码 换一张
取 消