public abstract class AbstractCheckValidator extends java.lang.Object implements ICheckValidator
Modifier and Type | Class and Description |
---|---|
protected static class |
AbstractCheckValidator.CheckValidatorStateAccess |
org.eclipse.emf.ecore.EValidator.Descriptor, org.eclipse.emf.ecore.EValidator.PatternMatcher, org.eclipse.emf.ecore.EValidator.Registry, org.eclipse.emf.ecore.EValidator.SubstitutionLabelProvider, org.eclipse.emf.ecore.EValidator.ValidationDelegate
OPTION_CATEGORIES, OPTION_CATEGORIES_OTHER_ID, OPTION_ENABLE_INTRINSIC_MODEL_INTEGRITY_CONSTRAINTS, OPTION_PROGRESS_MONITOR
Constructor and Description |
---|
AbstractCheckValidator() |
AbstractCheckValidator(CheckValidatorRegistry checkValidatorRegistry) |
Modifier and Type | Method and Description |
---|---|
protected void |
addCheckMethod(ICheckValidator validator,
java.lang.reflect.Method method) |
protected CheckMethodWrapper |
createCheckMethodWrapper(ICheckValidator validator,
java.lang.reflect.Method method) |
protected org.eclipse.emf.common.util.Diagnostic |
createDiagnostic(Severity severity,
java.lang.String message,
java.lang.Object[] data) |
protected java.lang.Object[] |
createLocationData(org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index) |
protected void |
error(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature) |
protected void |
error(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index) |
protected void |
error(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index,
java.lang.Object[] data) |
Catalog |
getCheckCatalog() |
protected java.util.List<CheckMethodWrapper> |
getCheckMethodsForModelObjectType(java.lang.Class<?> modelObjectType) |
protected java.lang.Class<?> |
getMethodWrapperType(org.eclipse.emf.ecore.EObject eObject)
Deprecated.
Use
getModelObjectType(EObject) instead. |
protected java.lang.Class<?> |
getModelObjectType(org.eclipse.emf.ecore.EObject eObject) |
java.lang.ThreadLocal<CheckValidatorState> |
getState() |
protected void |
info(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature) |
protected void |
info(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index) |
protected void |
info(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index,
java.lang.Object[] data) |
protected void |
initCheckMethods() |
protected java.lang.Object[] |
insertLocationData(java.lang.Object[] data,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index) |
protected void |
issue(org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index,
java.lang.Object... messageArguments)
Use this method only if a check catalog is contributed.
|
protected void |
issue(org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
java.lang.Object... messageArguments)
Use this method only if a check catalog is contributed.
|
protected void |
issue(java.lang.Object object,
org.eclipse.emf.ecore.EStructuralFeature feature,
java.lang.Object... messageArguments) |
protected void |
setCurrentObject(CheckValidatorState state,
java.lang.Object object) |
protected int |
toDiagnosticSeverity(Severity severity) |
boolean |
validate(org.eclipse.emf.ecore.EClass eClass,
org.eclipse.emf.ecore.EObject eObject,
org.eclipse.emf.common.util.DiagnosticChain diagnostics,
java.util.Map<java.lang.Object,java.lang.Object> context) |
boolean |
validate(org.eclipse.emf.ecore.EDataType eDataType,
java.lang.Object value,
org.eclipse.emf.common.util.DiagnosticChain diagnostics,
java.util.Map<java.lang.Object,java.lang.Object> context) |
boolean |
validate(org.eclipse.emf.ecore.EObject eObject,
org.eclipse.emf.common.util.DiagnosticChain diagnostics,
java.util.Map<java.lang.Object,java.lang.Object> context) |
protected void |
warning(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature) |
protected void |
warning(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index) |
protected void |
warning(java.lang.String message,
org.eclipse.emf.ecore.EObject object,
org.eclipse.emf.ecore.EStructuralFeature feature,
int index,
java.lang.Object[] data) |
public AbstractCheckValidator()
public AbstractCheckValidator(CheckValidatorRegistry checkValidatorRegistry)
protected java.lang.Class<?> getModelObjectType(org.eclipse.emf.ecore.EObject eObject)
@Deprecated protected java.lang.Class<?> getMethodWrapperType(org.eclipse.emf.ecore.EObject eObject)
getModelObjectType(EObject)
instead.protected void setCurrentObject(CheckValidatorState state, java.lang.Object object)
protected void initCheckMethods()
protected void addCheckMethod(ICheckValidator validator, java.lang.reflect.Method method)
protected CheckMethodWrapper createCheckMethodWrapper(ICheckValidator validator, java.lang.reflect.Method method)
public boolean validate(org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.common.util.DiagnosticChain diagnostics, java.util.Map<java.lang.Object,java.lang.Object> context)
validate
in interface org.eclipse.emf.ecore.EValidator
public boolean validate(org.eclipse.emf.ecore.EClass eClass, org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.common.util.DiagnosticChain diagnostics, java.util.Map<java.lang.Object,java.lang.Object> context)
validate
in interface org.eclipse.emf.ecore.EValidator
protected java.util.List<CheckMethodWrapper> getCheckMethodsForModelObjectType(java.lang.Class<?> modelObjectType)
public boolean validate(org.eclipse.emf.ecore.EDataType eDataType, java.lang.Object value, org.eclipse.emf.common.util.DiagnosticChain diagnostics, java.util.Map<java.lang.Object,java.lang.Object> context)
validate
in interface org.eclipse.emf.ecore.EValidator
protected void issue(java.lang.Object object, org.eclipse.emf.ecore.EStructuralFeature feature, java.lang.Object... messageArguments)
protected void issue(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, java.lang.Object... messageArguments)
object
- feature
- messageArguments
- protected void issue(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.Object... messageArguments)
object
- feature
- index
- messageArguments
- protected void error(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature)
protected void error(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index)
protected void error(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.Object[] data)
protected void warning(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature)
protected void warning(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index)
protected void warning(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.Object[] data)
protected void info(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature)
protected void info(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index)
protected void info(java.lang.String message, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index, java.lang.Object[] data)
protected java.lang.Object[] insertLocationData(java.lang.Object[] data, org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index)
protected java.lang.Object[] createLocationData(org.eclipse.emf.ecore.EObject object, org.eclipse.emf.ecore.EStructuralFeature feature, int index)
protected int toDiagnosticSeverity(Severity severity)
protected org.eclipse.emf.common.util.Diagnostic createDiagnostic(Severity severity, java.lang.String message, java.lang.Object[] data)
public java.lang.ThreadLocal<CheckValidatorState> getState()
getState
in interface ICheckValidator
public Catalog getCheckCatalog()