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
What is the purpose of global-forwards tag in struct-config.xml?
What is the purpose of @conversion?
Explain how can we upload files in struts2 application?
What is http redirect?
What are the components of struts framework?
What are the major differences between html tags and strut specific html tags?
What do struts do?
What is the purpose of @result?
How many servlet controllers are used in a Struts Application?
In which method of action class the business logic is executed?
Does Struts2 action and interceptors are thread safe?
Describe the basic steps used to create a tiles application?
What is the default suffix for struts2 action uri ?
What are interceptors in struts 2?
What is struts? Explain