T - the Object type being validated.public class DefaultAttributeContentValidator<T> extends java.lang.Object implements AttributeContentValidator<T>
AttributeContentValidator.
Works as a dispatcher to other AttributeValidators, by processing all validations stored in
injected in this Bean if a Predicate<AttributeDesciptorModel> holds true.| Modifier and Type | Field and Description |
|---|---|
protected static java.lang.String |
COLLECTION_TYPE |
| Constructor and Description |
|---|
DefaultAttributeContentValidator() |
| Modifier and Type | Method and Description |
|---|---|
protected java.util.Map<java.util.function.Predicate<AttributeDescriptorModel>,AttributeContentValidator> |
getValidatorMap() |
protected boolean |
isCollection(AttributeDescriptorModel attribute)
will return true if this property is a collection (localized or not) as per our platform type system
|
void |
setValidatorMap(java.util.Map<java.util.function.Predicate<AttributeDescriptorModel>,AttributeContentValidator> validatorMap) |
java.util.List<ValidationError> |
validate(T value,
AttributeDescriptorModel attributeDescriptor)
Performs validation on the given arguments.
|
protected static final java.lang.String COLLECTION_TYPE
public java.util.List<ValidationError> validate(T value, AttributeDescriptorModel attributeDescriptor)
AttributeContentValidatorvalidate in interface AttributeContentValidator<T>value - the value objectattributeDescriptor - the attribute descriptor of the given value.protected boolean isCollection(AttributeDescriptorModel attribute)
attribute - the AttributeDescriptorModel describing the metadata of the property of a classprotected java.util.Map<java.util.function.Predicate<AttributeDescriptorModel>,AttributeContentValidator> getValidatorMap()
public void setValidatorMap(java.util.Map<java.util.function.Predicate<AttributeDescriptorModel>,AttributeContentValidator> validatorMap)
Copyright © 2018 SAP SE. All Rights Reserved.