GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Interview Questions  >  J2EE  >  Java Patterns
Go To First  |  Previous Question  |  Next Question 
 Java Patterns  |  Question 4 of 20    Print  
what is Front Controller design pattern?

  
Total Answers and Comments: 4 Last Update: September 05, 2007     Asked by: satyanarayana 
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: sapna
 

Many interactive Web applications are composed of brittle collections of interdependent Web pages. Such applications can be hard to maintain and extend.


The Front Controller pattern defines a single component that is responsible for processing application requests. A front controller centralizes functions such as view selection, security, and templating, and applies them consistently across all pages or views. Consequently, when the behavior of these functions need to change, only a small part of the application needs to be changed: the controller and its helper classes



Above answer was rated as good by the following members:
yathirajulu
November 07, 2006 12:44:50   #1  
lingareddy        

RE: what is Front Controller design pattern?

A data to the servlet can be pass from outside either in the form of requset parameter(client side) init-parameter(web.xml file and serverside).ActionServlet also get the addional information from out side like name of hte struts-configuration file name of the properties file and etc in the form init-parameter. ActionServlet canbe use directmatch or extesionmatch to make that servlet as FrontController .

<url-pattrern>*.do</url-pattrern>(extesion match)

<url-pattern>/A/B/*</url-pattern>(directory match)


 
Is this answer useful? Yes | No
November 09, 2006 04:19:54   #2  
vikram        

RE: what is Front Controller design pattern?

The controller translates interactions with the view into actions to be performed by the model. In a stand-alone GUI client user interactions could be button clicks or menu selections whereas in a Web application they appear as GET and POST HTTP requests. The actions performed by the model include activating business processes or changing the state of the model. Based on the user interactions and the outcome of the model actions the controller responds by selecting an appropriate view


 
Is this answer useful? Yes | No
March 08, 2007 00:46:53   #3  
SuprajaYKM Member Since: February 2006   Contribution: 3    

RE: what is Front Controller design pattern?

Use a controller as the initial point of contact for handling a request. The controller manages the handling of the request including invoking security services such as authentication and authorization delegating business processing managing the choice of an appropriate view handling errors and managing the selection of content creation strategies.

Benefits:

Centralizes Control.
Improve Managebility
Improves Reusability


 
Is this answer useful? Yes | No
September 05, 2007 11:40:37   #4  
sapna        

RE: what is Front Controller design pattern?

Many interactive Web applications are composed of brittle collections of interdependent Web pages. Such applications can be hard to maintain and extend.


The Front Controller pattern defines a single component that is responsible for processing application requests. A front controller centralizes functions such as view selection security and templating and applies them consistently across all pages or views. Consequently when the behavior of these functions need to change only a small part of the application needs to be changed: the controller and its helper classes


 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    


 
Go To Top


 Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact -  Ask Question -  Propose Category -  Site Updates 

Copyright © 2005 - 2009 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape