GeekInterview.com
  I am new, Sign me up!
 
GeekInterview.com  >  Tech FAQs  >  Programming  >  Struts
Go To First  |  Previous Question  |  Next Question 
 Struts  |  Question 47 of 65    Print  
If perform and execute methods are the same, why they replaced execute in place of perform from 1.0 to 1.1?

  
Total Answers and Comments: 1 Last Update: August 08, 2007     Asked by: sree 
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
August 17, 2007 07:20:49   
g4java Member Since: July 2007   Contribution: 28    

RE: If perform and execute methods are the same, why t...
The reason for doing this was because the perform() could only throw IOException and ServletException and it was realized that Action classes should be able to throw any Exception required by the programmer. Since it was desired that code still be backward compatible a new method was added in place the perform() method. The new method is execute(). Here is the method signature:

public ActionForward execute(ActionMapping mapping ActionForm form
HttpServletRequest request HttpServletResponse response)
throws java.lang.Exception

As you can see the only difference is that execute() is declared to throw Exception rather than IOException and ServletException.

 
Is this answer useful? Yes | No

 Related Questions

Latest Answer :   Hi,   am srinivas, perform method is returns ActionForward(), not Message or ActionErrors ...
Read Answers (7) | Asked by : Pranjal

If perform and execute methods are the same, why they replaced execute in place of perform from 1.0 to 1.1?
Read Answers (1) | Asked by : sree

With diagram.ActionServlet having around 16 methods? 
View Question | Asked by : Chandra Judhagiri


 Sponsored Links

 
Related Articles

Concepts of Object-Oriented Programming

Object Oriented JavaScript In this chapter you ll learn about OOP Object Oriented Programming and how it relates to JavaScript As an ASP NET developer you probably have some experience working with objects and you may even be familiar with concepts such as inheritance However unless you re already a
 

SQL Programming

SQL Programming Overview Anybody who has done something for a long time has probably wanted to change how things work at some point or another. A worker at a mill might have found a more efficient way of cutting logs, or a mathematics teacher might have had a hand in changing a school’s al
 

WinRunner Programming Concepts

If you want to create WinRunner scripts that are highly efficient, there are important programming concepts that you will want to become familiar with. Understanding these concepts will provide you with a large number of key benefits. In addition to understanding these concepts, you must also learn
 

Programming Languages Certification

IT Certification programs have several options that will offer you the best knowledge.  By learning everything that you need to know about information technology you will be able to open new doors to your career and personal business desires.  IT Certification offers several vari
 

JavaScript Window Object Timeout Methods

JavaScript Window Object Timeout Methods In this JavaScript tutorial you will learn about setTimeout clearTimeout and open methods of window object along with syntax usage and examples for each method mosgoogle center setTimeout The setInterval method of Window object is used to call a function or
 

JavaScript Document Object Methods Part II

JavaScript Document Object Methods Part II In this JavaScript tutorial you will learn about document object methods getElementsByTagName getSelection handleEvent releaseEvents routeEvent write writeln along with syntax examples and brief explanation mosgoogle center getElementsByTagName The the getE
 

JavaScript Document Object Methods Part I

JavaScript Document Object Methods Part I In this JavaScript tutorial you will learn about methods of document object along with syntax and examples This section covers captureEvents open close getElementById getElementsByName methods with explanations for each method mosgoogle center Methods of d
 

JavaScript History Object Properties and Methods

JavaScript History Object  Properties and Methods In this JavaScript tutorial you will learn about history object properties and methods length current next previous properties back forward and go methods along with syntax and examples mosgoogle center The history property has the return v
 

JavaScript Array Object Methods – Part II

JavaScript Array Object Methods Part II In this JavaScript tutorial you will learn about on array object methods slice splice toString shift and unshift methods along with general syntax and examples mosgoogle center slice By using the methods of the array object the programmer is able to retriev
 

JavaScript Array Object Methods – Part I

JavaScript Array Object Methods Part I In this JavaScript tutorial you will learn about Array Object Methods concat join pop push and reverse methods  along with general syntax and examples mosgoogle center concat The concat method is used to join two or more Array objects together to pro
 

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

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

Page copy protected against web site content infringement by Copyscape