@@ -1617,7 +1617,7 @@ private MoveAttributeRefactoring processPairOfAttributes(UMLAttribute addedAttri
1617
1617
return null ;
1618
1618
}
1619
1619
if (addedAttribute .getName ().equals (removedAttribute .getName ()) &&
1620
- addedAttribute .getType ().equals (removedAttribute .getType ())) {
1620
+ ( addedAttribute .getType ().equals (removedAttribute .getType ()) || ( removedAttribute instanceof UMLEnumConstant && addedAttribute instanceof UMLEnumConstant ))) {
1621
1621
if (isSubclassOf (removedAttribute .getClassName (), addedAttribute .getClassName ())) {
1622
1622
UMLAttributeDiff attributeDiff = new UMLAttributeDiff (removedAttribute , addedAttribute , Collections .emptyList ());
1623
1623
if (!movedAttributeDiffList .contains (attributeDiff )) {
@@ -1944,12 +1944,15 @@ public List<UMLAttribute> getAddedAttributesInCommonClasses() {
1944
1944
List <UMLAttribute > addedAttributes = new ArrayList <UMLAttribute >();
1945
1945
for (UMLClassDiff classDiff : commonClassDiffList ) {
1946
1946
addedAttributes .addAll (classDiff .getAddedAttributes ());
1947
+ addedAttributes .addAll (classDiff .getAddedEnumConstants ());
1947
1948
}
1948
1949
for (UMLClassMoveDiff classDiff : classMoveDiffList ) {
1949
1950
addedAttributes .addAll (classDiff .getAddedAttributes ());
1951
+ addedAttributes .addAll (classDiff .getAddedEnumConstants ());
1950
1952
}
1951
1953
for (UMLClassRenameDiff classDiff : classRenameDiffList ) {
1952
1954
addedAttributes .addAll (classDiff .getAddedAttributes ());
1955
+ addedAttributes .addAll (classDiff .getAddedEnumConstants ());
1953
1956
}
1954
1957
return addedAttributes ;
1955
1958
}
@@ -1958,12 +1961,15 @@ public List<UMLAttribute> getRemovedAttributesInCommonClasses() {
1958
1961
List <UMLAttribute > removedAttributes = new ArrayList <UMLAttribute >();
1959
1962
for (UMLClassDiff classDiff : commonClassDiffList ) {
1960
1963
removedAttributes .addAll (classDiff .getRemovedAttributes ());
1964
+ removedAttributes .addAll (classDiff .getRemovedEnumConstants ());
1961
1965
}
1962
1966
for (UMLClassMoveDiff classDiff : classMoveDiffList ) {
1963
1967
removedAttributes .addAll (classDiff .getRemovedAttributes ());
1968
+ removedAttributes .addAll (classDiff .getRemovedEnumConstants ());
1964
1969
}
1965
1970
for (UMLClassRenameDiff classDiff : classRenameDiffList ) {
1966
1971
removedAttributes .addAll (classDiff .getRemovedAttributes ());
1972
+ removedAttributes .addAll (classDiff .getRemovedEnumConstants ());
1967
1973
}
1968
1974
return removedAttributes ;
1969
1975
}
0 commit comments