What is the use of ActionErrors in Struts
Answer / biru
In Validate method for each validation error we need to
construct an object of ActionMessage class and we need to
add each ActionMessage class object to ActionErrors class
object .
Ex:
public ActionErrors validate(ActionMapping
am,HttpServletRequest)
{
ActionErrors aes=new ActionErrors();
if(uname.length==0)
{ ActionMessage am1=new ActionMessage("uname.wrong")
aes.add("uname",am1);
}
}
Is This Answer Correct ? | 5 Yes | 0 No |
what are tiles in struts?
What is the default suffix for struts2 action uri ?
What is the use of interceptor?
What are the aware interfaces in struts2?
What is includeaction?
How action mapping is configured in Struts?
What is the difference between Jakarta Struts and Apache Struts? Which one is better to use?
what is frame work in struts?
Who wrote struts?
What are the differences between Struts1 and Struts2 or how Struts2 is better than Struts1?
What does action do in struts?
what are the type of forward class in Struts?