List of usage examples for org.apache.commons.validator ValidatorResources getValidatorActions
public Map<String, ValidatorAction> getValidatorActions()
Map
of the ValidatorAction
s. From source file:net.jawr.web.resource.bundle.generator.validator.CommonsValidatorGenerator.java
@SuppressWarnings("unchecked") private StringBuffer buildStaticJavascript(ValidatorResources validatorResources) { StringBuffer sb = new StringBuffer(); Iterator<ValidatorAction> actions = validatorResources.getValidatorActions().values().iterator(); while (actions.hasNext()) { ValidatorAction va = actions.next(); if (va != null) { String javascript = va.getJavascript(); if ((javascript != null) && (javascript.length() > 0)) { sb.append(javascript).append("\n"); }//w w w . j ava 2 s .c o m } } return sb; }
From source file:org.apache.struts.faces.taglib.JavascriptValidatorTag.java
protected String getJavascriptStaticMethods(ValidatorResources resources) { StringBuffer sb = new StringBuffer(); sb.append("\n\n"); Iterator actions = resources.getValidatorActions().values().iterator(); while (actions.hasNext()) { ValidatorAction va = (ValidatorAction) actions.next(); if (va != null) { String javascript = va.getJavascript(); if (javascript != null && javascript.length() > 0) { sb.append(javascript + "\n"); }/* w w w. j a va 2 s. c o m*/ } } return sb.toString(); }
From source file:org.apache.struts.taglib.html.JavascriptValidatorTag.java
protected String getJavascriptStaticMethods(ValidatorResources resources) { StringBuffer sb = new StringBuffer(); sb.append("\n\n"); Iterator actions = resources.getValidatorActions().values().iterator(); while (actions.hasNext()) { ValidatorAction va = (ValidatorAction) actions.next(); if (va != null) { String javascript = va.getJavascript(); if ((javascript != null) && (javascript.length() > 0)) { sb.append(javascript + "\n"); }/*w ww . j ava 2 s . co m*/ } } return sb.toString(); }
From source file:org.apache.velocity.tools.struts.ValidatorTool.java
/** * * @param resources the validation resources * @return the static javascript methods *///from ww w . j a v a 2s .c o m protected String getJavascriptStaticMethods(ValidatorResources resources) { StringBuffer sb = new StringBuffer("\n\n"); Iterator actions = resources.getValidatorActions().values().iterator(); while (actions.hasNext()) { ValidatorAction va = (ValidatorAction) actions.next(); if (va != null) { String javascript = va.getJavascript(); if (javascript != null && javascript.length() > 0) { sb.append(javascript + "\n"); } } } return sb.toString(); }