EA-27916 - SOE: RefMethodImpl.updateReturnValueTemplate

This commit is contained in:
anna
2011-05-23 14:32:26 +04:00
parent bb5e5e0fe7
commit ea2e67e3e6
@@ -179,6 +179,9 @@ public class RefMethodImpl extends RefJavaElementImpl implements RefMethod {
@NotNull
public Collection<RefMethod> getSuperMethods() {
if (mySuperMethods == null) return EMPTY_METHOD_LIST;
if (mySuperMethods.size() > 10) {
LOG.info("method: " + getName() + " owner:" + getOwnerClass().getQualifiedName());
}
return mySuperMethods;
}
@@ -216,7 +219,7 @@ public class RefMethodImpl extends RefJavaElementImpl implements RefMethod {
}
public void addSuperMethod(RefMethodImpl refSuperMethod) {
if (!getSuperMethods().contains(refSuperMethod)) {
if (!getSuperMethods().contains(refSuperMethod) && !refSuperMethod.getSuperMethods().contains(this)) {
if (mySuperMethods == null){
mySuperMethods = new ArrayList<RefMethod>(1);
}
@@ -225,7 +228,7 @@ public class RefMethodImpl extends RefJavaElementImpl implements RefMethod {
}
public void markExtended(RefMethodImpl method) {
if (!getDerivedMethods().contains(method)) {
if (!getDerivedMethods().contains(method) && !method.getDerivedMethods().contains(this)) {
if (myDerivedMethods == null) {
myDerivedMethods = new ArrayList<RefMethod>(1);
}