Class AbstractValidator

    • Constructor Detail

      • AbstractValidator

        public AbstractValidator​(java.lang.String strValidatorName,
                                 java.lang.String strValidatorDisplayName,
                                 java.util.List<java.lang.String> listAvailableEntryType)
        Constructor of the AbstractValidator
        Parameters:
        strValidatorName - The validator bean name
        strValidatorDisplayName - The validator display name
        listAvailableEntryType - The list of available entrytype
      • AbstractValidator

        public AbstractValidator​(java.lang.String strValidatorName,
                                 java.lang.String strValidatorDisplayName,
                                 java.util.List<java.lang.String> listAvailableEntryType,
                                 java.util.Locale locale)
        Constructor of the AbstractValidator
        Parameters:
        strValidatorName - The validator bean name
        strValidatorDisplayName - The validator display name
        listAvailableEntryType - The list of available entrytype
        locale - The locale
    • Method Detail

      • validate

        public boolean validate​(java.util.List<FormQuestionResponse> formQuestionResponse,
                                Control control)
        Specified by:
        validate in interface IValidator
        Parameters:
        formQuestionResponse - The List response to control
        control - The control to verify
        Returns:
        boolean that indicate the validation result
      • getValidatorBeanName

        public java.lang.String getValidatorBeanName()
        Specified by:
        getValidatorBeanName in interface IValidator
        Returns:
        the validator bean name
      • getValidatorDisplayName

        public java.lang.String getValidatorDisplayName()
        Specified by:
        getValidatorDisplayName in interface IValidator
        Returns:
        the validator display name
      • getDisplayHtml

        public java.lang.String getDisplayHtml​(Control control)
        Specified by:
        getDisplayHtml in interface IValidator
        Parameters:
        control - The control to build model
        Returns:
        the HTML to display
      • getListAvailableEntryType

        public java.util.List<java.lang.String> getListAvailableEntryType()
        Specified by:
        getListAvailableEntryType in interface IValidator
        Returns:
        the list of available entrytype for this validator
      • getJavascriptValidation

        public java.lang.String getJavascriptValidation()
        Description copied from interface: IValidator
        Only the content of the function should be returned. The parameter names are in FormsConstants, JS_PARAMETER_INPUT_VALUE and JS_PARAMETER_CONTROL_VALUE
        Specified by:
        getJavascriptValidation in interface IValidator
        Returns:
        the javascript validation code for Conditional display control
      • getJavascriptControlValue

        public java.lang.String getJavascriptControlValue​(Control control)
        Specified by:
        getJavascriptControlValue in interface IValidator
        Parameters:
        control - The control
        Returns:
        the control value needed for javascript