Package org.jenkinsci.plugins.ewm.utils
Class FormValidationUtil
- java.lang.Object
-
- org.jenkinsci.plugins.ewm.utils.FormValidationUtil
-
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public final class FormValidationUtil extends Object
FormValidation
utility class.- Author:
- Alexandru Somai
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static FormValidation
validateWorkspaceTemplate(String value)
Validates the input String to match a specific workspace template.
-
-
-
Method Detail
-
validateWorkspaceTemplate
@Nonnull public static FormValidation validateWorkspaceTemplate(@Nonnull String value)
Validates the input String to match a specific workspace template. Shows error messages if the input path is not relative, or if it doesn't enclose brackets correctly. Shows warning message if the input template uses standalone '$' symbol instead of '${}'.Note: It may show multiple error/warning messages for the same input String. e.g. '/$abc{abc' has 2 error messages and 1 warning: - error: not relative path - error: not valid enclosing parentheses - warning: unsafe standalone '$' usage
- Parameters:
value
- the input String to be checked- Returns:
- the FormValidation based on the input String
-
-