Class DefaultRenderingComponentValidator
java.lang.Object
de.hybris.platform.cmsfacades.rendering.validators.component.DefaultRenderingComponentValidator
- All Implemented Interfaces:
org.springframework.validation.Validator
public class DefaultRenderingComponentValidator
extends Object
implements org.springframework.validation.Validator
Validator to validate attributes used to extract a component for rendering.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcheckCode(String codeValue, String fieldName, org.springframework.validation.Errors errors, Predicate<String> predicate) Verifies whether the code exists using provided predicate.protected CatalogCodeExistsPredicateprotected CategoryCodeExistsPredicateprotected ProductCodeExistsPredicatevoidsetCatalogCodeExistsPredicate(CatalogCodeExistsPredicate catalogCodeExistsPredicate) voidsetCategoryCodeExistsPredicate(CategoryCodeExistsPredicate categoryCodeExistsPredicate) voidsetProductCodeExistsPredicate(ProductCodeExistsPredicate productCodeExistsPredicate) booleanvoid
-
Constructor Details
-
DefaultRenderingComponentValidator
public DefaultRenderingComponentValidator()
-
-
Method Details
-
supports
- Specified by:
supportsin interfaceorg.springframework.validation.Validator
-
validate
- Specified by:
validatein interfaceorg.springframework.validation.Validator
-
checkCode
protected void checkCode(String codeValue, String fieldName, org.springframework.validation.Errors errors, Predicate<String> predicate) Verifies whether the code exists using provided predicate.- Parameters:
codeValue- the code valuefieldName- the code name fielderrors- theErrorsobjectpredicate- the predicate
-
getCategoryCodeExistsPredicate
-
setCategoryCodeExistsPredicate
-
getProductCodeExistsPredicate
-
setProductCodeExistsPredicate
-
getCatalogCodeExistsPredicate
-
setCatalogCodeExistsPredicate
-