Class SimpleRequiredFieldValidator<E extends EntityType<E>,T>
- java.lang.Object
-
- com.kenshoo.pl.entity.spi.helpers.SimpleRequiredFieldValidator<E,T>
-
- All Implemented Interfaces:
ChangeValidator,RequiredFieldValidator<E,T>
public class SimpleRequiredFieldValidator<E extends EntityType<E>,T> extends java.lang.Object implements RequiredFieldValidator<E,T>
-
-
Constructor Summary
Constructors Constructor Description SimpleRequiredFieldValidator(EntityField<E,T> entityField, java.lang.String errorCode)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetErrorCode()EntityField<E,T>requiredField()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.kenshoo.pl.entity.spi.RequiredFieldValidator
fetchFields, requireWhen
-
-
-
-
Constructor Detail
-
SimpleRequiredFieldValidator
public SimpleRequiredFieldValidator(EntityField<E,T> entityField, java.lang.String errorCode)
-
-
Method Detail
-
requiredField
public EntityField<E,T> requiredField()
- Specified by:
requiredFieldin interfaceRequiredFieldValidator<E extends EntityType<E>,T>- Returns:
- the field that have to be
-
getErrorCode
public java.lang.String getErrorCode()
- Specified by:
getErrorCodein interfaceRequiredFieldValidator<E extends EntityType<E>,T>- Returns:
- the error code to return if the field is missing
-
-