ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage   interview questions urls   External Links  Contact Us     Login  |  Sign Up                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories  >>  Software  >>  Java J2EE  >>  Java Related  >>  Struts
 
 


 

 
 Core Java interview questions  Core Java Interview Questions
 Advanced Java interview questions  Advanced Java Interview Questions
 Swing interview questions  Swing Interview Questions
 EJB interview questions  EJB Interview Questions
 Servlets interview questions  Servlets Interview Questions
 Struts interview questions  Struts Interview Questions
 JDBC interview questions  JDBC Interview Questions
 JMS interview questions  JMS Interview Questions
 SunOne interview questions  SunOne Interview Questions
 J2EE interview questions  J2EE Interview Questions
 Weblogic interview questions  Weblogic Interview Questions
 Websphere interview questions  Websphere Interview Questions
 Java Networking interview questions  Java Networking Interview Questions
 Java J2EE AllOther interview questions  Java J2EE AllOther Interview Questions
Question
life cycle of struts?
 Question Submitted By :: Guest
I also faced this Question!!     Rank Answer Posted By  
 
  Re: life cycle of struts?
Answer
# 1
process of creating , invoking , destroying the servlet is
known as "life cycle of struts". here three methods are
involved 

1.init() :

Total intialization part of servlet ll be there in this .

2.service() :

Actual Bussiness code ll be there  in this method

3.destroy() :

just destroying the servlet  .
 
Is This Answer Correct ?    0 Yes 12 No
Purna
 
  Re: life cycle of struts?
Answer
# 2
In life cycle of struts there r several part are there 

ActionServlet
Struts-config.xml
RequestProceser
formBean
Action class
 
Is This Answer Correct ?    7 Yes 2 No
Kiran
 
 
 
  Re: life cycle of struts?
Answer
# 3
There are many steps, 

1. After getting the request from the client, the 
ActionServlet invokes the goGet() or doPost() method, in 
which there is a invokation of process() method.This method 
desides the module.

2. Action servlet dispatches the request to RequestProcesor 
class which does some core works of ActionServlet.Then 
invokes the appropriate Action class.

3. Action class does main business logic and data accessing 
(communicating with Moedl) thru execute() method and which 
returns the ActionForward object.

4. In b/w the form field validations happens in form bean.

5. Depends upon the value of ActionForward object the view 
is decided to display.(output)


4. Form bean is invoked for form field validation,
 
Is This Answer Correct ?    0 Yes 4 No
Kartheeswari
 
  Re: life cycle of struts?
Answer
# 4
The request is given to Action Servlet i.e; doGet or 
doPost.
ActionServlet with the help of request uri locates one of 
the RequestProcessor and dispatch the request to 
RequestProcessor i.e; process method on RequestProcessor is 
called InRequestProcessor.

It processes content type.
processes Locale.
processes actionPath.
processes actionMapping.
processes formBean.
processes action.
Error handling.

After processing action(i.e; execute method) depending on 
the results locate the path to view(with the help of 
ActionMapping) and dispatch the request to the located 
path.
 
Is This Answer Correct ?    2 Yes 0 No
Chandu
 
  Re: life cycle of struts?
Answer
# 5
When the Framework is loaded, it first loaded the Web.xml 
file. Then from the Servlet tag of Web.xml, it identifies 
the ActionServlet(or the Struts-Cofig.xml). Then from 
welcome-file tag of Struts-Cofig.xml, it identifies the 
first JSP page and runs it. Then when the request comes 
through that jsp, from acion-mappings tag of Struts-
Cofig.xml it identifies the request, through path tag
(request name) and input tag (jsp name), through name tag 
it identifies which bean is needed to access the data and 
through type tag it identifies which Action should be 
invoked. Then through the forward tag it identifies to 
which jsp it has to forward the response.
 
Is This Answer Correct ?    2 Yes 0 No
Ayan Mukherjee
 
  Re: life cycle of struts?
Answer
# 6
Sorry in the previous answer I made one mistake, welcome-
file-list is located in web.xml not in Struts-cofig.xml
 
Is This Answer Correct ?    1 Yes 0 No
Ayan Mukherjee
 

 
 
 
Other Struts Interview Questions
 
  Question Asked @ Answers
 
how canu done chechin and check out of u r project using with sample examples? CTS4
where you will implement the tiles in struts? Wipro2
How to pass runtime Parameter in Struts1.2?  1
Which parser is used in Struts to parse the Structconfig.xml file. iFlex16
If we close the browser,when the specific user session is active.Again if we open browse how to retrive it same user??what code i have to da??? TCS2
why do we typecast ActionForm into out plain java bean class in Action class?  3
i have 500 jsps in my application,and i have same forward name for each jsp,so it lokks in strutsconfig.xml,from 1 to 500,but i want send 498 page directly,how can i cingigure my application TCS2
what r the disadvantages of MVC-2 Architecture? Process-IT1
What is Struts Frame Work Architecture(With Diagram) ? CMC1
What is MVC Architecture? HCL4
when connecting with the database,if database server is down,ho can we handle this exception in struts,how can we send error message to the user? Wipro3
What is the difference between a Strut and a Class?  1
What is Struts Flow? CTS4
multiple instances for action class is it possible iFlex5
what is the difference between *.do & /do.*/? So what is the diffenence btn extension mapping & path mapping.What is those difference in work effect? Wipro6
In Struts Programming which is the controller,which is the model?  9
we have 7 jsp pages .At last page we have a submit button when we click it it will store all jsps data which we provide will store into database. when we starting providing data in jsp pages when we are at 3rd jsp at that time sessions timeout where the data will be store which we r provide in last two jsps?  1
what is the difference between ServletContext and ServletConfig?  3
how the error can be showed in the jsp page in struts? Wipro2
How to depoly your struts application in JBOSS Satyam1
 
For more Struts Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com