CSC/ECE 517 Fall 2007/wiki2/3 rl: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
Line 13: Line 13:


== Best Sites for Model View Controller Examples ==
== Best Sites for Model View Controller Examples ==
#[http://www.enode.com/x/markup/tutorial/mvc.html http://www.enode.com/x/markup/tutorial/mvc.html] : This is an awesome introduction to the concept. Short, sweet and to the point explained with the help of a contrived spinner example. This site does not give much details but is really good to get you started.
#[http://www.enode.com/x/markup/tutorial/mvc.html http://www.enode.com/x/markup/tutorial/mvc.html] : This is an awesome introduction to the concept. Short, sweet and to the point explained with the help of a contrived spinner example. This site does not give many details but is really good to get you started.
#[http://csis.pace.edu/~bergin/mvc/mvcgui.html http://csis.pace.edu/~bergin/mvc/mvcgui.html] : This article is written very well. It gives a detailed example of a temperature gauge, complete with source code in Java. I especially like it when the author explains how the components are interconnected, it really helps in understanding the communication between the model view and controller, as introduced in many of the MVC concept websites above.
#[http://csis.pace.edu/~bergin/mvc/mvcgui.html http://csis.pace.edu/~bergin/mvc/mvcgui.html] : This article is written very well. It gives a detailed example of a temperature gauge, complete with source code in Java. I especially like it when the author explains how the components are interconnected.  It really helps in understanding the communication between the model, view and controller, as introduced in many of the MVC concept websites above.
#[http://www.caucho.com/articles/jsp_templates.xtp http://www.caucho.com/articles/jsp_templates.xtp] : An extremely detailed example of how to build a simple guestbook in JSP using the MVC pattern.
#[http://www.caucho.com/articles/jsp_templates.xtp http://www.caucho.com/articles/jsp_templates.xtp] : An extremely detailed example of how to build a simple guestbook in JSP using the MVC pattern.
#[http://www.informit.com/guides/content.aspx?g=java&seqNum=117&rl=1 http://www.informit.com/guides/content.aspx?g=java&seqNum=117&rl=1] : Complete code example using Servlets as the controller, JSP files as the view, and JavaBeans as the model.
#[http://www.informit.com/guides/content.aspx?g=java&seqNum=117&rl=1 http://www.informit.com/guides/content.aspx?g=java&seqNum=117&rl=1] : Complete code example using Servlets as the controller, JSP files as the view, and JavaBeans as the model.

Revision as of 22:56, 23 October 2007

Model View Controller

"Model-view-controller (MVC) is an architectural pattern used in software engineering. In complex computer applications that present a large amount of data to the user, a developer often wishes to separate data (model) and user interface (view) concerns, so that changes to the user interface will not affect data handling, and that the data can be reorganized without changing the user interface. The model-view-controller solves this problem by decoupling data access and business logic from data presentation and user interaction, by introducing an intermediate component: the controller." Taken from Wikipedia


Best Sites for Learning the Model View Controller Concept

  1. http://java.sun.com/blueprints/patterns/MVC-detailed.html : This is a very brief introduction to the MVC concept, ideal if you are in a hurry :). I really like the illustration they used, it delimits the responsibilities of the components very well.
  2. http://ootips.org/mvc-pattern.html : Nicely written introduction; however, it has ascii-art diagrams.
  3. http://www.oreillynet.com/onjava/blog/2003/07/new_way_to_learn_mvc_view_a_si.html : The most innovative way to learn about MVC, through a song. Yes you heard it right, I would recommend this to everyone just because of the hilarious lyrics. Enjoy!
  4. http://www.adobe.com/devnet/flash/articles/mv_controller.html : A fantastic article that details the three components of MVC, benefits of the pattern, how the classes of MVC communicate, and class responsibilities.
  5. http://www.perlmonks.org/?node_id=402070 : An easy introduction to MVC with a handy sequence diagram example.

Best Sites for Model View Controller Examples

  1. http://www.enode.com/x/markup/tutorial/mvc.html : This is an awesome introduction to the concept. Short, sweet and to the point explained with the help of a contrived spinner example. This site does not give many details but is really good to get you started.
  2. http://csis.pace.edu/~bergin/mvc/mvcgui.html : This article is written very well. It gives a detailed example of a temperature gauge, complete with source code in Java. I especially like it when the author explains how the components are interconnected. It really helps in understanding the communication between the model, view and controller, as introduced in many of the MVC concept websites above.
  3. http://www.caucho.com/articles/jsp_templates.xtp : An extremely detailed example of how to build a simple guestbook in JSP using the MVC pattern.
  4. http://www.informit.com/guides/content.aspx?g=java&seqNum=117&rl=1 : Complete code example using Servlets as the controller, JSP files as the view, and JavaBeans as the model.

Best Sites for How to Use the Pattern in Ruby and Java

  1. http://java.sun.com/blueprints/guidelines/designing_enterprise_applications_2e/app-arch/app-arch5.html : This is the design document for the pet store sample that come in built with Java EE. It goes into a lot of detail about how the MVC was used to design this sample. This page provides an excellent resource to understand the benefits of using patterns while working on a projects architecture. It bridges the gap between the theoretical concepts of the pattern and its practical implementations.
  2. http://cristobal.baray.com/indiana/projects/mvc.html : A detailed introduction to the use of MVC with a Java view point which spans several pages, complete with source code. Warning: This site throws many pop ups, so keep your pop up blocker handy.
  3. http://www-128.ibm.com/developerworks/linux/library/l-rubyrails/ : This article gives the details on how to utilize the built-in features of Ruby on Rails to create a web application using MVC.
  4. http://rails.homelinux.org/ : Four Days on Rails is a 40 page pdf that takes you through learning the basics of rails. It includes both a description and code example for the model, view, and controller.