private String createDynamicJavascript(ModuleConfig config,
ValidatorResources resources, Locale locale, Form form)
throws JspException {
StringBuffer results = new StringBuffer();
MessageResources messages =
TagUtils.getInstance().retrieveMessageResources(pageContext,
bundle, true);
HttpServletRequest request =
(HttpServletRequest) pageContext.getRequest();
ServletContext application = pageContext.getServletContext();
List actions = this.createActionList(resources, form);
final String methods =
this.createMethods(actions, this.stopOnError(config));
String formName = form.getName();
jsFormName = formName;
if (jsFormName.charAt(0) == '/') {
String mappingName =
TagUtils.getInstance().getActionMappingName(jsFormName);
ActionMapping mapping =
(ActionMapping) config.findActionConfig(mappingName);
if (mapping == null) {
JspException e =
new JspException(messages.getMessage("formTag.mapping",
mappingName));
pageContext.setAttribute(Globals.EXCEPTION_KEY, e,
PageContext.REQUEST_SCOPE);
throw e;