Class ObjectValidator
- java.lang.Object
-
- com.evolveum.midpoint.schema.validator.ObjectValidator
-
public class ObjectValidator extends Object
Validator that can process objects, validate them, check for errors and warning and possibly even transform object during upgrades. The purpose of this object is NOT to apply and validate static schema. Prism will already do that. The purpose is to validate midPoint-specific things. But in fact, it does also work on some generic things, such as deprecated and plannedRemoval markers. Maybe some kind of generic Prism validator can be distilled from this one. But for now let's experiment with this approach. This is NOT a Spring bean by purpose. We want to setup the validator to do various functions depending on how it is used. It may be used from GUI, from task, invoked from ninja and so on.- Author:
- Radovan Semancik
-
-
Constructor Summary
Constructors Constructor Description ObjectValidator(PrismContext prismContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getWarnPlannedRemovalVersion()
boolean
isWarnDeprecated()
boolean
isWarnPlannedRemoval()
void
setAllWarnings()
void
setWarnDeprecated(boolean warnDeprecated)
void
setWarnPlannedRemoval(boolean warnPlannedRemoval)
void
setWarnPlannedRemovalVersion(String warnPlannedRemovalVersion)
<O extends ObjectType>
ValidationResultvalidate(PrismObject<O> object)
-
-
-
Constructor Detail
-
ObjectValidator
public ObjectValidator(PrismContext prismContext)
-
-
Method Detail
-
isWarnDeprecated
public boolean isWarnDeprecated()
-
setWarnDeprecated
public void setWarnDeprecated(boolean warnDeprecated)
-
isWarnPlannedRemoval
public boolean isWarnPlannedRemoval()
-
setWarnPlannedRemoval
public void setWarnPlannedRemoval(boolean warnPlannedRemoval)
-
getWarnPlannedRemovalVersion
public String getWarnPlannedRemovalVersion()
-
setWarnPlannedRemovalVersion
public void setWarnPlannedRemovalVersion(String warnPlannedRemovalVersion)
-
setAllWarnings
public void setAllWarnings()
-
validate
public <O extends ObjectType> ValidationResult validate(PrismObject<O> object)
-
-