1 17 package org.eclipse.emf.ecore; 18 19 20 import java.util.Map ; 21 22 import org.eclipse.emf.common.util.DiagnosticChain; 23 24 25 28 public interface EValidator 29 { 30 33 String MARKER = "org.eclipse.emf.ecore.diagnostic"; 34 35 40 String URI_ATTRIBUTE = "uri"; 41 42 45 public interface Descriptor 46 { 47 51 EValidator getEValidator(); 52 } 53 54 57 interface Registry extends Map 58 { 59 62 EValidator getEValidator(EPackage ePackage); 63 64 67 Registry INSTANCE = new org.eclipse.emf.ecore.impl.EValidatorRegistryImpl(); 68 } 69 70 73 interface SubstitutionLabelProvider 74 { 75 78 String getObjectLabel(EObject eObject); 79 80 83 String getFeatureLabel(EStructuralFeature eStructuralFeature); 84 85 88 String getValueLabel(EDataType eDataType, Object value); 89 } 90 91 94 interface PatternMatcher 95 { 96 99 boolean matches(String value); 100 } 101 102 108 boolean validate(EObject eObject, DiagnosticChain diagnostics, Map context); 109 110 boolean validate(EClass eClass, EObject eObject, DiagnosticChain diagnostics, Map context); 111 112 boolean validate(EDataType eDataType, Object value, DiagnosticChain diagnostics, Map context); 113 } 114 | Popular Tags |