• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem compiling LookupDispatchAction

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello,
when using LookupDispatchAction i am getting the foll compile time error.
the Action class should be declared abstract since it does not define getKeyMethodMap() present in LookupDispatchAction even though it is present.

My RegGroupClass.jsp has the following "submit"
<html:submit property="submit">
<bean:message key="button.add"/>
</html:submit>


My struts-config action-mapping is as follows.
<action path="/ConfirmAddGroupClass"
type="Group.GroupClassAction"
name="GroupClassActionForm"
scope="request"
input="/GroupClass/RegGroupClass.jsp"
parameter="submit"/>
My GroupClassAction class is as follows.
public class GroupClassAction extends LookupDispatchAction{
Map getKeyMethodMap(ActionMapping mapping,
ActionForm form,
HttpServletRequest request) {
Map map = new HashMap();
System.out.println("in mapping");
map.put("button.add", "add");
return map;
}
public ActionForward add(ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response)
throws IOException, ServletException {
// do add
System.out.println("before forward");
return mapping.findForward("ConfirmAddGroupClass");

}
}

Can anyone plz guide me through this.
thanks in advance
Sana
 
Sana Jay
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hello,
Sorry for the inane question.Just found out the answer.The signature of the getKeyMethodMap() did not match with the one in my ActionClass.
thanks,
Sana
 
reply
    Bookmark Topic Watch Topic
  • New Topic