T
- constrainable typepublic interface ConstraintProvider<T extends Constrainable>
The ConstraintProvider interface must be implemented by any class that contributes Constraints to the DictionaryValidationService. Multiple ConstraintProviders can be registered simultaneously, and each can contribute constraints for any number of constraint types.
These constraints can be looked up in a variety of ways. They may be:
CaseConstrainable
LengthConstrainable
The goal here is to provide a mechanism that enables implementing institutions to inject new Constraints and ConstraintProcessor classes into the DictionaryValidationService implementation via dependency injection.
Modifier and Type | Method and Description |
---|---|
List<Constraint> |
getConstraints(T definition,
Class<? extends Constraint> constraintType)
gets the constraints provided
|
boolean |
isSupported(Constrainable definition)
checks whether this provider supports the provided definition
|
List<Constraint> getConstraints(T definition, Class<? extends Constraint> constraintType)
definition
- - a Data Dictionary definition e.g. ComplexAttributeDefinition
or CollectionDefinition
constraintType
- - a java class that represents the constraintboolean isSupported(Constrainable definition)
definition
- - a Data Dictionary definition e.g. AttributeDefinition
Copyright © 2005–2015 The Kuali Foundation. All rights reserved.