Class AUniqueStringFieldValidator<TEntity extends de.xima.cmn.dao.interfaces.IEntity<Long>>

  • Type Parameters:
    TEntity - Type of the entity owning the field.
    All Implemented Interfaces:
    Serializable, EventListener, javax.faces.validator.Validator
    Direct Known Subclasses:
    AUniqueNameValidator

    public abstract class AUniqueStringFieldValidator<TEntity extends de.xima.cmn.dao.interfaces.IEntity<Long>>
    extends AUniqueEntityFieldValidator<TEntity,​String>
    Abstract base class for faces validators that check whether a certain string field of an entity is unique amongst all existing entities within a certain scope.
    Since:
    7.0.0
    Author:
    XIMA MEDIA GmbH
    See Also:
    Serialized Form
    • Field Detail

      • ignoreCase

        protected final boolean ignoreCase
    • Constructor Detail

      • AUniqueStringFieldValidator

        protected AUniqueStringFieldValidator​(Class<TEntity> entityClass)
      • AUniqueStringFieldValidator

        protected AUniqueStringFieldValidator​(Class<TEntity> entityClass,
                                              boolean ignoreCase)
    • Method Detail

      • hasValue

        protected final boolean hasValue​(String value)
        Specified by:
        hasValue in class AUniqueEntityFieldValidator<TEntity extends de.xima.cmn.dao.interfaces.IEntity<Long>,​String>
        Parameters:
        value - The converted field value.
        Returns:
        true if the value is non-empty, or false otherwise. When empty, this validator is skipped.