<p>While going through university and from following the development of SO, I've heard a lot about the Model-View-Controller architectural design pattern. I inadvertently used the MVC pattern even before I knew what it was, and still use it in my everyday job. From what I've seen, it's probably the most popular pattern used today. What I haven't heard much about though, are the alternative patterns you can use instead of MVC. What options are there, and for what reasons would you decide to use them over MVC? I'm also interested in knowing the types of systems they are typical of being used for. Finally, what are the pros and cons that come along with using them?</p>

[{'answer_id': 24498, 'author': 'rmontgomery429', 'author_id': 2627, 'author_profile': 'https://Stackoverflow.com/users/2627', 'pm_score': 6, 'selected': True, 'text': '<ol>\n<li>Passive View - <a href="http://martinfowler.com/eaaDev/PassiveScreen.html" rel="noreferrer">http://martinfowler.com/eaaDev/PassiveScreen.html</a></li>\n<li>Supervising Controller - <a href="http://martinfowler.com/eaaDev/SupervisingPresenter.html" rel="noreferrer">http://martinfowler.com/eaaDev/SupervisingPresenter.html</a></li>\n<li>Model-View-Presenter - <a href="http://martinfowler.com/eaaDev/ModelViewPresenter.html" rel="noreferrer">http://martinfowler.com/eaaDev/ModelViewPresenter.html</a> </li>\n</ol>\n\n<blockquote>\n  <p>My personal favorite is the <em>Passive View</em>. More testable than others I\'ve seen including MVC.</p>\n</blockquote>\n'}, {'answer_id': 24507, 'author': 'Brian Warshaw', 'author_id': 1344, 'author_profile': 'https://Stackoverflow.com/users/1344', 'pm_score': 2, 'selected': False, 'text': '<p>I\'ve occasionally seen MVC without the C, where the view listens for changes in the model\'s data and alters rendering accordingly, and where the methods in the model are bound to event handlers for the view.</p>\n\n<p>For projects where the view is by necessity tightly couple with the data (such as when there are visual components that directly relate to the model or attributes of the model), this can be rather useful, as it cuts out the "middle man."</p>\n\n<p>I think many would argue, though, that this is still MVC, just a hybridized version, and that the bindings established between the view and model are controller logic.</p>\n'}, {'answer_id': 24509, 'author': 'Sören Kuklau', 'author_id': 1600, 'author_profile': 'https://Stackoverflow.com/users/1600', 'pm_score': 2, 'selected': False, 'text': '<p>Well, there\'s Model-View-Presenter, but I think you\'ll find that the most common "alternative" to MVC is really a lack of proper separation. As an extreme example, consider classic ASP pages where HTML, VBScript and SQL are found side-by-side in the same file. (That\'s not a bash of ASP — you\'ll find plenty of such examples in other languages.)</p>\n'}, {'answer_id': 24567, 'author': 'Robby Slaughter', 'author_id': 1854, 'author_profile': 'https://Stackoverflow.com/users/1854', 'pm_score': 2, 'selected': False, 'text': '<p>Although the above answers are quite correct, I think it\'s much more important to note that the words "design pattern" are completely unknown to 90% of all people who create software. They just start writing code. </p>\n\n<p>The challenge is not selecting the best design approach, it\'s convincing others that design has value.</p>\n'}, {'answer_id': 895056, 'author': 'user100985', 'author_id': 100985, 'author_profile': 'https://Stackoverflow.com/users/100985', 'pm_score': 0, 'selected': False, 'text': '<p>You can roll your own MVC with the current ASP.NET framework and still keep the postback model.</p>\n\n<p><a href="http://www.codeproject.com/KB/aspnet/RollingYourOwnMVCwithASP.aspx" rel="nofollow noreferrer">http://www.codeproject.com/KB/aspnet/RollingYourOwnMVCwithASP.aspx</a></p>\n'}, {'answer_id': 3164113, 'author': 'Stephen', 'author_id': 17398, 'author_profile': 'https://Stackoverflow.com/users/17398', 'pm_score': 1, 'selected': False, 'text': '<p>The Presentation-Abstraction-Control (PAC) family of patterns, where interface/interaction is handled by a hierarchy of agents.</p>\n\n<p>The wikipedia article is not great\n<a href="http://en.m.wikipedia.org/wiki/Presentation-abstraction-control" rel="nofollow noreferrer">http://en.m.wikipedia.org/wiki/Presentation-abstraction-control</a></p>\n'}, {'answer_id': 3164128, 'author': 'pr1001', 'author_id': 46768, 'author_profile': 'https://Stackoverflow.com/users/46768', 'pm_score': 1, 'selected': False, 'text': '<p>In the <a href="http://liftweb.net" rel="nofollow noreferrer">Lift</a> web framework we use a <a href="https://www.assembla.com/wiki/show/liftweb/View_First" rel="nofollow noreferrer">View First</a> approach. Basically a view is composed of one or more snippets (somewhat similar to controllers) and snippets can be nested. This works very well with HTML and Scala\'s built-in XML processing capabilities.</p>\n'}, {'answer_id': 3164232, 'author': 'Anurag', 'author_id': 165737, 'author_profile': 'https://Stackoverflow.com/users/165737', 'pm_score': 3, 'selected': False, 'text': '<p>Some other architectural patterns including MVC.</p>\n\n<p><strong>Layered Systems</strong></p>\n\n<p><em>TCP/IP</em></p>\n\n<p><strong>Object-Oriented Organization</strong></p>\n\n<p><em>Model-View-Controller</em>, <em>Presentation-abstraction-control</em>, <em>Model View Presenter</em> and <em>Model View ViewModel</em>. </p>\n\n<p>Examples would be ASP.NET\'s MVC, Ruby on Rails, and bunch of others.</p>\n\n<p><strong>Event Based, Implicit invocation</strong></p>\n\n<p><em>Browser environment (DOM)</em></p>\n\n<p><strong>Pipe and filter architecture</strong></p>\n\n<p><em>Unix pipes</em></p>\n\n<p><strong>Repositories</strong></p>\n\n<p><strong>Table Driven Interpreters</strong></p>\n\n<hr />\n\n<p>You may also find <a href="http://sunner.cn/courses/SA/intro_softarch.pdf" rel="noreferrer">this paper</a> by Garlan &amp; Shaw on Software Architecture a nice read.</p>\n\n<p>Another noteworthy link would be the article on architectural patterns at <a href="http://en.wikipedia.org/wiki/Architectural_pattern_(computer_science)" rel="noreferrer">Wikipedia</a>.</p>\n'}, {'answer_id': 4063267, 'author': 'Ashok', 'author_id': 488987, 'author_profile': 'https://Stackoverflow.com/users/488987', 'pm_score': 2, 'selected': False, 'text': '<p>Well it is quite old now. I would like to mention one more (in the interest of info for additional knowledge) is <strong>PresenterFirst patrern</strong></p>\n\n<p>Here is more information on the same:</p>\n\n<p><a href="http://en.wikipedia.org/wiki/Presenter_First" rel="nofollow">http://en.wikipedia.org/wiki/Presenter_First</a></p>\n\n<p><a href="http://www.atomicobject.com/pages/Presenter+First" rel="nofollow">http://www.atomicobject.com/pages/Presenter+First</a></p>\n\n<p>HTH</p>\n'}, {'answer_id': 5740033, 'author': 'Sujay Ghosh', 'author_id': 102062, 'author_profile': 'https://Stackoverflow.com/users/102062', 'pm_score': 0, 'selected': False, 'text': '<p>What about the <a href="http://en.wikipedia.org/wiki/Observer_pattern" rel="nofollow">Observer</a> pattern. If I am not mistaken , MVC was introduced in Smalltalk and thereafter several publish/ subscribe patterns have come into picture. </p>\n\n<p>The observer pattern (a subset of the publish/subscribe pattern) is a software design pattern in which an object, called the subject, maintains a list of its dependents, called observers, and notifies them automatically of any state changes, usually by calling one of their methods. It is mainly used to implement distributed event handling systems.</p>\n\n<p>Ex : The Save button gets enabled in an editior, only when there is data to be saved. Another example of the observer pattern is Document View architecture in MFC, where in the view gets updated when the document changes .</p>\n'}]
['https://Stackoverflow.com/questions/24496', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/2628/']