Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

why do we typecast ActionForm into out plain java bean
class in Action class?

Answer Posted / jagadeesh b.n

Bcoz as u all know, casting are of 2 types Upcast(implicit)
and Downcast(Explicit)in core java.....Upcasting means
converting lower datatype(int) to higher datatype(long) and
Downcast means its a viceversa of upcast...(long to int)...

As u know in struts ActionForm is a superclass where as ur
Java bean program is a simple class with private fields and
set/get methods for conversion of superclass to sublclass
we use typecasting in struts...

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is it called struts?

999


Lists the bundled validators in struts?

1069


What is the purpose of @stringlengthfieldvalidator annotation?

1150


How to use dispatchaction?

1093


how to develop the submit and search operations in single jsp using struts?

3057


What is the purpose of @requiredstringvalidator?

997


What are the classes used in struts?

1137


how to connect from struts to database through hibernet and where u can modify the class

2603


Can you give an overview of how a struts application flows?

1001


What is difference between spring and struts?

1002


How can we handle exceptions thrown by application in Struts2?

991


What is java struts?

994


What is apache struts used for?

975


Which configuration file is used for storing jsp configuration information in struts?

1061


How to combine the struts with velocity template?

996