if (anotherItem.subGroups == null){
return false;
}
if (this.subGroups.size() == anotherItem.subGroups.size()){
for (Map.Entry<Object, AttributeGroup> entry : this.subGroups.entrySet()){
AttributeGroup anotherGroup = anotherItem.subGroups.get(entry.getKey());
if (! entry.getValue().equals(anotherGroup)){
return false;
}
}
}else{
return false;
}
} else if (anotherItem.subGroups != null){
return false;
}
if(this.keyGroups != null) {
if (anotherItem.keyGroups == null){
return false;
}
if (this.keyGroups.size() == anotherItem.keyGroups.size()){
for (Map.Entry<Object, AttributeGroup> entry : this.keyGroups.entrySet()){
AttributeGroup anotherGroup = anotherItem.keyGroups.get(entry.getKey());
if (! entry.getValue().equals(anotherGroup)){
return false;
}
}
}else{