Package com.kenshoo.pl.entity.spi
Interface AncestorsValidator
-
- All Superinterfaces:
ChangeValidator
public interface AncestorsValidator extends ChangeValidator
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.stream.Stream<EntityField<?,?>>ancestorsFields()ValidationErrorvalidate(CurrentEntityState ancestorsFieldsState)Called by the framework to check if the change is restricted by ancestors.
-
-
-
Method Detail
-
ancestorsFields
java.util.stream.Stream<EntityField<?,?>> ancestorsFields()
- Returns:
- the fields of the ancestor entities whose value is required for the validation
-
validate
ValidationError validate(CurrentEntityState ancestorsFieldsState)
Called by the framework to check if the change is restricted by ancestors. The implementation can query theentityonly for the fields it has declared inancestorsFields().- Parameters:
ancestorsFieldsState- ancestor's fields- Returns:
- a validation error if any,
nullif none
-
-