Interface ServiceCommandValidator

    • Method Detail

      • addFieldValidationError

        void addFieldValidationError​(String fieldName,
                                     String messageKey)
        Add a new validation error.
        Parameters:
        fieldName - the field that is not valid
        messageKey - the i18n key for the validation error message
      • addValidationError

        void addValidationError​(String messageKey,
                                Object... messageArguments)
        Add a new validation error.
        Parameters:
        messageKey - the i18n key for the validation error message
        messageArguments - the arguments to be merged into the error message
      • addFieldValidationError

        void addFieldValidationError​(String fieldName,
                                     String messageKey,
                                     Object... messageArguments)
        Add a new validation error.
        Parameters:
        fieldName - the field that is not valid
        messageKey - the i18n key for the validation error message
        messageArguments - the arguments to be merged into the error message.
      • addFieldValidationError

        void addFieldValidationError​(FieldValidationError fieldError)
        Add a new field validation error.
        Parameters:
        fieldError - the error to add
      • getValidationErrors

        Collection<ValidationError> getValidationErrors()
        Get all validation errors.
        Returns:
        validation errors.