File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Diff btw Front Controller and MVC?

 
Jingh Yi
Ranch Hand
Posts: 90
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does anyone know the difference when we should pick Front Controller as design pattern instead of MVC? Isn't MVC just an implementation of Front Controller?

Thanks!
Jenny
 
Mat Williams
Ranch Hand
Posts: 215
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

There are two key differences that I am aware of, there may be more.

1) Front Controller is a central point where all requests go initially. MVC may use a single point for all request to go or they may not. The key point here is that the Front Controller mandates a single point MVC does not.

2) MVC mandates that the model, view and controller components are all distinct entities, ie view is a jsp, model is a javabean and controller is a servlet. Front Contoller does not, as far as the Front Controller goes the model and view components of a MVC pattern may be the same entity ie a jsp or servlet that also contains business logic.

HTH

Matthew
 
Leandro Melo
Ranch Hand
Posts: 401
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Strictly speaking, MVC is more likely a "Architecture Pattern" and not a design patter. For instance, the whole idea of MVC comes from the use of other well know design patterns like Observer, Composite and Strategy.

MVC 2, which is an adpatation we use for the web environment is also based on this. Check out Sun's blueprints about MVC. However, it doesn't necessarily mean that you have to use a Front Controller as central piece of your Controller part. Note the MVC is just too much more than a single Front Controller pattern. It's got all the links among Model, View and Control.
[ August 01, 2005: Message edited by: Leandro Melo ]
 
Jingh Yi
Ranch Hand
Posts: 90
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, guys. good explanations.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic