use of org.cytoscape.model.SavePolicy in project cytoscape-impl by cytoscape.
the class CyTableImpl method swap.
@Override
public void swap(final CyTable otherTable) {
synchronized (lock) {
final CyTableImpl other = (CyTableImpl) otherTable;
final Set<String> tempCurrentlyActiveAttributes = currentlyActiveAttributes;
currentlyActiveAttributes = other.currentlyActiveAttributes;
other.currentlyActiveAttributes = tempCurrentlyActiveAttributes;
final Map<String, ColumnData> tempAttributes = attributes;
attributes = other.attributes;
other.attributes = tempAttributes;
final Map<Object, CyRow> tempRows = rows;
rows = other.rows;
other.rows = tempRows;
final Map<String, CyColumn> tempTypes = types;
types = other.types;
other.types = tempTypes;
final ArrayList<CyColumn> tempListCol = colList;
colList = other.colList;
other.colList = tempListCol;
final ArrayList<CyRow> tempListRow = rowList;
rowList = other.rowList;
other.rowList = tempListRow;
final Map<String, String> tempNormalizedColNames = normalizedColumnNames;
normalizedColumnNames = other.normalizedColumnNames;
other.normalizedColumnNames = tempNormalizedColNames;
final String tempTitle = title;
title = other.title;
other.title = tempTitle;
final boolean tempPub = pub;
pub = other.pub;
other.pub = tempPub;
final boolean tempIsImmutable = isImmutable;
isImmutable = other.isImmutable;
other.isImmutable = tempIsImmutable;
final String tempPrimaryKey = primaryKey;
primaryKey = other.primaryKey;
other.primaryKey = tempPrimaryKey;
final String tempLastInternalError = lastInternalError;
lastInternalError = other.lastInternalError;
other.lastInternalError = tempLastInternalError;
final Map<String, VirtualColumn> tempVirtualColumnMap = virtualColumnMap;
virtualColumnMap = other.virtualColumnMap;
other.virtualColumnMap = tempVirtualColumnMap;
final Map<String, Set<CyColumn>> tempDependents = dependents;
dependents = other.dependents;
other.dependents = tempDependents;
final SavePolicy tempSavePolicy = savePolicy;
savePolicy = other.savePolicy;
other.savePolicy = tempSavePolicy;
}
}
Aggregations