/* (non-Javadoc) * @see br.cos.ufrj.lens.odyssey.tools.psw.metamodels.core.interfaces.CoreClassifier#getInitOrDerivedConstraint(br.cos.ufrj.lens.odyssey.tools.psw.metamodels.core.interfaces.CoreModelElement) */ public OclDeriveConstraint getDeriveConstraint(string elementName) { OclConstraint result; this.deriveConstraints.TryGetValue(elementName, out result); if (result == null) { List <object> allSuperTypes = classifier.getAllAncestors(); for (IEnumerator iter = allSuperTypes.GetEnumerator(); iter.MoveNext() && (result == null);) { CoreClassifier superType = (CoreClassifier)iter.Current; result = superType.getLocalDeriveConstraint(elementName); } } return((OclDeriveConstraint)result); }