protected void commitRelationshipMaps( ArrayMap<String, IntArray> cowRelationshipAddMap, ArrayMap<String, IntArray> cowRelationshipRemoveMap) { if (relationshipMap == null) { // we will load full in some other tx return; } if (cowRelationshipAddMap != null) { for (String type : cowRelationshipAddMap.keySet()) { IntArray add = cowRelationshipAddMap.get(type); IntArray remove = null; if (cowRelationshipRemoveMap != null) { remove = cowRelationshipRemoveMap.get(type); } IntArray src = relationshipMap.get(type); relationshipMap.put(type, IntArray.composeNew(src, add, remove)); } } if (cowRelationshipRemoveMap != null) { for (String type : cowRelationshipRemoveMap.keySet()) { if (cowRelationshipAddMap != null && cowRelationshipAddMap.get(type) != null) { continue; } IntArray src = relationshipMap.get(type); IntArray remove = cowRelationshipRemoveMap.get(type); relationshipMap.put(type, IntArray.composeNew(src, null, remove)); } } }